Re: [nbos] [AS] Using Astroscript to update surface map.
Shade Tree
Thu Jan 21st, 2010

Alan,
I will be able to check this out tomorrow. It's been a long time since I messed with Astroscripts. I think the other half of my problem was setting the body property directly instead of using the sector method. I didn't even check on the sector methods until just now. It should all be sorted now from your much appreciated help.

Now I just need to do an optimization/cleanup pass to the actual generating program tomorrow and it'll be ready for the NOX.




Thanks,
Brad.


> Date: Thu, 21 Jan 2010 13:36:30 -0700
> From: alan.bartholet-at-gmail.com
> To: nbossoftware-at-nbos.com
> Subject: Re: [nbos] [AS] Using Astroscript to update surface map.
>
> Hello Brad,
> The offender appears to be a file called <Bodies
> UABI>.planetview.png in the SurfaceMaps folder. I couldn't figure out
> how to fix this with the API but by deleting it manually you are able
> to get the proper surface map to load.
>
> Code:
>
> oldSurfaceMap = AstroDirectory() & "Textures\SurfaceMaps\" &
> EditingBody.IDString & ".planetview.png"
>
> Set fso = CreateObject("Scripting.FileSystemObject")
>
> If fso.FileExists(oldSurfaceMap) Then
> fso.DeleteFile(oldSurfaceMap)
> End If
>
> sector.SetPreviewImage EditingBody, newSurfaceMap
>
> Best Regards,
> Alan Bartholet
>
> On Thu, Jan 21, 2010 at 12:30 PM, Alan Bartholet
> <alan.bartholet-at-gmail.com> wrote:
> > Hello Brad,
> > There is an undocumented Property called IDString that will return
> > you the UABI. As for the texture issues I've did a little poking
> > around and it seems to be specific to the Gas Giant bodies cause it
> > works fine for Terrestrial bodies. I'll poke around at it a little
> > more.
> >
> > Best Regards,
> > Alan Bartholet
> >
> > On Thu, Jan 21, 2010 at 11:00 AM, Shade Tree <shadetreeii-at-hotmail.com> wrote:
> >> If anyone has seen on the NBOS forums I'm writing a program to generate
> >> "better" Gas Giant textures.
> >> ( http://www.nbos.com/forums/viewtopic.php?f=7&t=140&p=406#p406 for info )
> >>
> >>
> >> I've got a beta of the program ready and am working on the astroscript to
> >> integrate it into AS. Everything seems to work fine except when I tell AS
> >> the new png file to use by setting the body.PreviewImageFile property it
> >> will put the information in the correct place but will not update the body
> >> with the new image. I can't find anything to force this update. Even
> >> saving and reloading the sector will not update the view. You need to
> >> manually go into the bodies properties and select the same image it already
> >> has there to force the update.
> >>
> >> Any help would be appreciated. Using v2.01e though the problem exists in
> >> 2.01b as well.
> >>
> >> Thanks,
> >> Brad
> >>
> >> ________________________________
> >> Hotmail: Trusted email with powerful SPAM protection. Sign up now.
> >> _______________________________________________
> >> Nbossoftware mailing list
> >>
> >>
> >>
> >>
> >
> _______________________________________________
> Nbossoftware mailing list
>
>

_________________________________________________________________
Your E-mail and More On-the-Go. Get Windows Live Hotmail Free.
http://clk.atdmt.com/GBL/go/196390709/direct/01/
_______________________________________________
Nbossoftware mailing list



Copyright © 2003-2007, NBOS Software. All rights reserved. 'Fractal Mapper', 'ScreenMonkey', 'Character Sketcher', 'Inspiration Pad', 'Fractal World Explorer', 'Goblin API', 'AstroSynthesis' are trademarks of NBOS Software. 'Dwarven Beserker' art by V. Shane.
Member contributed resources