Jump to content
Sign in to follow this  
bad benson

Make ammo emit light

Recommended Posts

i am working on a flamethrower. everything works fine and looks good. the problem is that it doesn't create any light when used at night which kind of spoils the fun since it doesn't really feel like fire this way. i am using grenade properties for the projectile. i've been trying to base my ammo on flares but when i'm using "simulation = "shotilluminating" it also behaves like a flare which means it flies for a while and than it lights up and falls slowly to the ground.

what i need is just the light not the whole simulation because the flare takes too long to light up. is it possible to add a light to a projectile without using that simulation type? i really don't wanna attach a light to the projetile via scripting because i'm sure there must be a way to do it in the config.

Share this post


Link to post
Share on other sites

Because rockets have trails , it would perhaps be better to define your ammo as a rocket and slow it down i think maybe possible to get nice flame effect from slow rocket and simply change model = "" or some small model ?

the simulation is Hardcoded and there seems no way to give finite changes as i can see it .

Share this post


Link to post
Share on other sites

yea i tried it with the missilecore class as a base and it turned my weapon into a launcher automaticly eventhough i didn't change the weapon class. i gotta try missilebase maybe dunno. thx for the reply though.

Share this post


Link to post
Share on other sites

ah your right of course,

now the simulation of the ammo also affects even animations doesnt it ?

i did some experimenting with new classes from Default some time ago i will try to dig it out.

Share this post


Link to post
Share on other sites

In the original flamethrower, I just attached a lightpoint to the flamethrower 'shells'.

No clue if/how I44 might have changed that.

Something like this:

_li = "#lightpoint" createVehicleLocal getpos _sh;

[...code...]

_li lightAttachObject [_sh, [0,0,0]];

'_sh' is the shell fired by the weapon.

Cheers,

D.

Share this post


Link to post
Share on other sites

Maybe you should take a look at the campfire and what else is ingame already to see how it's done. AFAIK this stuff emits light. Just my 2 cents.

Share this post


Link to post
Share on other sites

thx for the advice guys.

i actually did what you described with the lightpoint i just wanted to know if there's a way around that. a somewhat cleaner way.

yea and i looked into campfires too but couldn't find the base class in which the light and sound are defined. the idea was to have a clean ammo class that just emits light without scripting. like flares but without the whole simulation of only glowing when the projectile starts to fall down straight.

anyways. here's a short video of the flamthrower effect. you can't see the light in it because of the daylight. but i'm pretty proud of the actual fire effect...so here it goes.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×