Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
3 registered members (NewbieZorro, TipmyPip, AndrewAMD), 14,749 guests, and 7 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
entity disappear #76548
06/04/06 03:33
06/04/06 03:33
Joined: May 2005
Posts: 222
T
tek Offline OP
Member
tek  Offline OP
Member
T

Joined: May 2005
Posts: 222
I have a character who shoots and I want a certain entity enemy that I made to dissapear when I shoot him, I don't know what code to use for this, does anyone here know ?
Just that the enemy dissapears not to be seen.
and if possible a code that he will dissapear after maybe 3 or 4 seconds
thank you

Re: entity disappear [Re: tek] #76549
06/04/06 03:52
06/04/06 03:52
Joined: Jun 2006
Posts: 96
Straight_Heart Offline
Junior Member
Straight_Heart  Offline
Junior Member

Joined: Jun 2006
Posts: 96
put this in the function that is called when the entity is shot

function get_shot
{

if(event_type==event_impact) // entity was hit by a bullet
{
sleep(4); //wait 4 seconds
my.invisible=on; //turn invisible
my.passable=on; //turn passable


}

}


//////////////////

action get_shot_ent // this is the enemy to be shot
{

my.enable_entity=on; //make the enemy sensible to getting hit with c_move
my.event=get_shot; // run this function when hit


}


You're not as unique as you think you are, try again.
Re: entity disappear [Re: Straight_Heart] #76550
06/04/06 04:55
06/04/06 04:55
Joined: May 2005
Posts: 222
T
tek Offline OP
Member
tek  Offline OP
Member
T

Joined: May 2005
Posts: 222
Thanks alot straight heart it worked.


Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1