Home   Help Search Login Register  

Author Topic: fragmentaion afetr hit  (Read 1928 times)

0 Members and 1 Guest are viewing this topic.

Offline DeanosBeano

  • Addons Depot Staff
  • *****
  • SirDeanosbeano bstowed on me by sui ;)
    • Fraghaus
fragmentaion afetr hit
« on: 20 Jun 2006, 00:36:17 »
Hi all and ty in advance.
       looked for similar but couldnt find. What i am after is similar to the effect in ecp, where a tank is hit and pieces fly. i have made an addon but when it gets hit / destroyed ,it looks boring. i was hoping to delete the addon on destroyed and then have pieces fly of at random.

also does anybody know a great reffence for thins like ,destr types .etc for e.g destrType="Destructno"; etc . i am new to addons, been scripting for 4 years , pls excuse my noobness, and ty for any advice.

         DB
I love ofp

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: fragmentaion afetr hit
« Reply #1 on: 20 Jun 2006, 02:10:51 »
I am a bit pressed for time at the moment, but as for the DestructTypes,

Try  Models & ClassNames by yours truly here:

http://www.ofpec.com/ed_depot/tutes.htm



Planck
I know a little about a lot, and a lot about a little.

Offline oyman

  • Members
  • *
  • king of pings
Re: fragmentaion afetr hit
« Reply #2 on: 20 Jun 2006, 02:53:13 »
here are the destr types I could find
Code: [Select]
destrType="DestructEngine";
destrType="DestructBuilding";
destrType="DestructTree";
destrType="DestructTent";


You should be able to figure out what they do. But DestructEngine is the one where the thing will explode.

Offline remcen

  • Contributing Member
  • **
  • a.k.a. hottentotten_mike
    • IM:UC
Re: fragmentaion afetr hit
« Reply #3 on: 20 Jun 2006, 13:47:41 »
you can script those effects with an eventhandler.

check out grendel's k-kill scripts for example. (http://ofp.neco.cz/index.php?showthis=8526) afaik it uses the killed eventhandler with which you can trigger further drop command-based scripts then, or eject those pieces of debris from the tank.

the classnames of the debris are FXExploArmor1, FXExploArmor3 and FXExploArmor3 btw.
we're looking for members: IM:UC MOD

Offline DeanosBeano

  • Addons Depot Staff
  • *****
  • SirDeanosbeano bstowed on me by sui ;)
    • Fraghaus
Re: fragmentaion afetr hit
« Reply #4 on: 20 Jun 2006, 17:52:22 »
thanks all for the replies. much appreciated.
one other thing does anyone know ,where i can find the config for thr bis barrel in the ofp route ??
I love ofp

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: fragmentaion afetr hit
« Reply #5 on: 20 Jun 2006, 19:39:04 »
The entries from the game config is so:

Code: [Select]
class BarrelHelper:Thing
{
scope=0;
simulation="thing";
mapSize=0.7;
displayName="$STR_DN_BARREL";
accuracy=0.2;
transportFuel=100;
destrType=destructengine;
};

class BarrelBase:BarrelHelper
{
accuracy=1000; // Never recognize
armor=100;
cost=0;
};

class Barrels:BarrelBase
{
scope=2;
model="Barels.p3d";
displayName="$STR_DN_BARRELS";
transportFuel=400;
};

class Barrel1:BarrelBase
{
scope=2;
model="Barel1.p3d";
displayName="$STR_DN_BARREL_RED";
};

class Barrel2:BarrelBase
{
scope=2;
model="Barel2.p3d";
displayName="$STR_DN_BARREL_BROWN";
};

class Barrel3:BarrelBase
{
scope=2;
model="Barel4.p3d";
displayName="$STR_DN_BARREL_WHITE";
};

class Barrel4:BarrelBase
{
scope=2;
model="Barel3.p3d";
displayName="$STR_DN_BARREL_WHITE";
};


Barrel3................model=Barel4.p3d
and
Barrel4.................model=Barel3.p3d is NOT a mistake


Planck
« Last Edit: 20 Jun 2006, 19:45:00 by Planck »
I know a little about a lot, and a lot about a little.

Offline DeanosBeano

  • Addons Depot Staff
  • *****
  • SirDeanosbeano bstowed on me by sui ;)
    • Fraghaus
Re: fragmentaion afetr hit
« Reply #6 on: 20 Jun 2006, 19:52:07 »
thanks again m8, now i know why i missed this place :).

I love ofp