Odf functions
Moderator: Moderators
- elfie
- Field Commander

- Posts: 931
- Joined: Fri Jan 25, 2008 8:26 pm
- xbox live or psn: no live
- Location: Coruscant, Jedi Temple
- Contact:
Odf functions
Hey, is there an odf function in the grenade odfs that controls the amount of time until the grenade explodes? Because I want it to explode the second it hits an object or terrain. I tried LifeSpan = "0.5" in the ord file, but that didn't work. Is it even in the odf files or is it hard-coded? Thanks!
-
bhawkgoalie10
- Private Second Class
- Posts: 60
- Joined: Mon Dec 29, 2008 1:55 pm
-
Taivyx
- 2008 Best Games Related Avatar
- Posts: 1706
- Joined: Thu Jun 07, 2007 3:34 pm
- Projects :: Terra Strife - discontinued
- xbox live or psn: No gamertag set
- Contact:
Re: Odf functions
I'm looking for this as well, and just a note to anyone who's pulling random solutions out of a hat, I've tried
Result: After thrown the grenade just stays there in the air, unmoving, and never exploding.
Code: Select all
LifeSpan = "0.0000001'Result: After thrown the grenade just stays there in the air, unmoving, and never exploding.
-
Master_Ben
- Lieutenant General

- Posts: 675
- Joined: Wed Nov 12, 2008 9:50 pm
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Watching your PC over your shoulder. No, the other sholder....
Re: Odf functions
This I found in the grenade odf:
Dunno if it'll help.
Code: Select all
ShotDelay = "1.3"- Fiodis
- Master of the Force

- Posts: 4145
- Joined: Wed Nov 12, 2008 9:27 pm
- Projects :: Rannoch + Tientia + Tools Programming
Re: Odf functions
How about you just set the ordance in the weapon's ODF as the mortar launcher's ordance?
-
bhawkgoalie10
- Private Second Class
- Posts: 60
- Joined: Mon Dec 29, 2008 1:55 pm
Re: Odf functions
awesome lolTaivyx wrote:I'm looking for this as well, and just a note to anyone who's pulling random solutions out of a hat, I've triedCode: Select all
LifeSpan = "0.0000001'
Result: After thrown the grenade just stays there in the air, unmoving, and never exploding.
-
Master_Ben
- Lieutenant General

- Posts: 675
- Joined: Wed Nov 12, 2008 9:50 pm
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Watching your PC over your shoulder. No, the other sholder....
Re: Odf functions
That seems the best Idea. I'd like to know how to do it in an edity way, though.Fiodis wrote:How about you just set the ordance in the weapon's ODF as the mortar launcher's ordance?
- Fiodis
- Master of the Force

- Posts: 4145
- Joined: Wed Nov 12, 2008 9:27 pm
- Projects :: Rannoch + Tientia + Tools Programming
Re: Odf functions
Take a peek at the mortar's ordance's ODF. See if you can find anything suspicious.
-
obiboba3po
- 2008 Most Technically Challenging Avatar
- Posts: 2376
- Joined: Tue Feb 12, 2008 7:46 pm
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: NJ, USA
Re: Odf functions
that should be all you need. after messing around with sky's released cluster bomb, that factor became very crucialTaivyx wrote:I'm looking for this as well, and just a note to anyone who's pulling random solutions out of a hat, I've triedCode: Select all
LifeSpan = "0.0000001'
Result: After thrown the grenade just stays there in the air, unmoving, and never exploding.
- Sky_216
- Droid Pilot Assassin

- Posts: 2086
- Joined: Mon Feb 13, 2006 3:28 am
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
Re: Odf functions
Clearing up a few things
Grenades only explode when they stop moving. The timer won't start until they stop moving. There is a simple code around this -
StartTimerOnContact = "0"
This however means they can blow up midair.
If you set the 'stick' functions all to 1, and give the grenade a lifetime of 0.1 or less, it appears to explode as soon as it hits something (stops moving therefore timer starts therefore explodes). Unfortunately, they can't stick to objects, so will bounce of them.
The simplest way to do this is change the ordnance type to 'shell' (type the mortar launcher normal ordnance uses) rather than 'sticky.' Your nade will blow up the second it hits something.
Grenades only explode when they stop moving. The timer won't start until they stop moving. There is a simple code around this -
StartTimerOnContact = "0"
This however means they can blow up midair.
If you set the 'stick' functions all to 1, and give the grenade a lifetime of 0.1 or less, it appears to explode as soon as it hits something (stops moving therefore timer starts therefore explodes). Unfortunately, they can't stick to objects, so will bounce of them.
The simplest way to do this is change the ordnance type to 'shell' (type the mortar launcher normal ordnance uses) rather than 'sticky.' Your nade will blow up the second it hits something.
Thats because it's been rounded down to 0 (pretty sure minimum value is 0.01) Any 'sticky' type ordnance with lifespan 0 does that. They eventually overload the game because they never disappear.Taivyx wrote:I'm looking for this as well, and just a note to anyone who's pulling random solutions out of a hat, I've triedCode: Select all
LifeSpan = "0.0000001'
Result: After thrown the grenade just stays there in the air, unmoving, and never exploding.
That's how long between throws.Master_Ben wrote:This I found in the grenade odf:Dunno if it'll help.Code: Select all
ShotDelay = "1.3"
- elfie
- Field Commander

- Posts: 931
- Joined: Fri Jan 25, 2008 8:26 pm
- xbox live or psn: no live
- Location: Coruscant, Jedi Temple
- Contact:
Re: Odf functions
Thanks, sky and all of you guys. I'm pretty sure this will work, but I will let you know if I have any problems.
