Some assistance please 5 replies

Please wait...

Zorg

GF Pwns Me!

50 XP

19th January 2003

0 Uploads

47 Posts

0 Threads

#1 16 years ago

Ok I'm experimenting with making some new systems for the game and I need some help with creating nebulas. Specifically coloring the nebula. What I'm trying to do is make a nebula completely black on the outside and almost black or completely black on the inside and completely opaque. I know so very little about RGBA in python. I know basically this:

quote from internet? "RGB( red [integer], green [integer], blue [integer] [, alpha [integer]] ) [integer]

The RGB() function returns an integer containing the color you specified. red, green, blue are the main components of the color, and can have a value of no intensity (0) to full intensity (255). alpha, which is an optional argument, specifies how opaque the color is. A value of 0 denotes that the color is completely transparent, while a value of 255 is completely opaque. If alpha is not specified, the color will be completely opaque. GetRGB( color [integer] ) [tuple (integer, integer, integer, integer)] GetRGB() returns a four element tuple containing red, green, blue and alpha in that order based on the color you pass it."

Which is somewhat clear about like mud lol. But specifically my question is what am I assigning in the nebula script? I see the line to edit the RGBA that looks like the one below but don't exactly know what I am doing or what these series of numbers does. It seems to be a different setup than the above quote?

Here is what I am looking at/trying to figure out, which crashes the script btw?? :S

pNebula = App.MetaNebula_Create(255.0 / 0.0, 0.0 / 255.0, 0.0 / 0.0, 255.0, 10.5, "data/Backgrounds/nebulaoverlay.tga", "data/Backgrounds/nebulaexternal.tga")

can anyone help me out here?

Thanks ZM




Darkshimmer

Hardpointer/MPMP Creator

50 XP

23rd January 2003

0 Uploads

75 Posts

0 Threads

#2 16 years ago

try the alpha integer at 115... only thing i can think of...

the game seems to like that number since the shields and many of the properties in bc have that alpha integer




StarBright

Pro-Filer thinks I'm cool!!

50 XP

5th February 2003

0 Uploads

457 Posts

0 Threads

#3 16 years ago

You forgot to add the second integer on the alpha number.

But an easier way to do this is:

pNebula = App.MetaNebula_Create(0, 0, 0, 1, "data/Backgrounds/nebulaoverlay.tga", "data/Backgrounds/nebulaexternal.tga")

That's opaque black.

Actually, I don't know much about mapping but I make a lot of torps.




Blackrook32 Game Admin

BCFiles Site Administrator

4,767 XP

5th April 2002

54 Uploads

444 Posts

1 Threads

#4 16 years ago

@Zorg: Try using BanzaiZAP's maps as a template. You can experiment on making your own alterations. I made a starsystem with one of the planetary targets as a asteroid field composed of ice asteroids. Your only limited by your imagination.


"Fortune favors the Bold..."



Zorg

GF Pwns Me!

50 XP

19th January 2003

0 Uploads

47 Posts

0 Threads

#5 16 years ago

Star Bright, Blackrook, Darkshimmer thanks guys, I kinda figured it out, I just made/perfected a new Darkmatter nebula. I am using Bens Banzai systems as a tutorial, template in some places, he made some really interesting systems which I like a lot. I'm going to make a whole bunch of systmes I think and release them as a system pack at some point. Thanks for the help :D




Darkshimmer

Hardpointer/MPMP Creator

50 XP

23rd January 2003

0 Uploads

75 Posts

0 Threads

#6 16 years ago

your welcome