Gamestudio Links
Zorro Links
Newest Posts
loading historical data 1st time
by AndrewAMD. 04/14/23 12:54
Trade at bar open
by juanex. 04/13/23 19:43
Bug in Highpass2 filter
by rki. 04/13/23 09:54
Adding Limit Orders For IB
by scatters. 04/11/23 16:16
FisherN
by rki. 04/11/23 08:38
AUM Magazine
Latest Screens
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Hecknex World
Who's Online Now
3 registered members (AndrewAMD, The_Judge, Grant), 898 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
rki, FranzIII, indonesiae, The_Judge, storrealba
18919 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
frustrated in ent_remove() #170244
11/30/07 02:09
11/30/07 02:09
Joined: Oct 2003
Posts: 825
22�21'24"N 114�07'30"E
Frederick_Lim Offline OP
User
Frederick_Lim  Offline OP
User

Joined: Oct 2003
Posts: 825
22�21'24"N 114�07'30"E
I am frustrated in ent_remove()

Question: I'd like to know how to detect the entity was removed by ent_remove()?

I found check the entity pointer against NULL is not work, it seems after execute ent_remove(e), the e entity pointer is not NULL. In fact, once the entity removed, I still able to access its skill value.

Because of that, I am not checking the (e != NULL), but checking (e.health < 1).
It seems works prefect, everything looks good. But I am worrying about potential crash.

Re: frustrated in ent_remove() [Re: Frederick_Lim] #170245
12/06/07 21:21
12/06/07 21:21
Joined: Oct 2006
Posts: 106
i_program_games Offline
Member
i_program_games  Offline
Member

Joined: Oct 2006
Posts: 106
If that's the case try something like

ent_remove(pEnt);
pEnt=NULL;//Set it to null yourself?

Also, are you waiting one after the ent_remove command?

ent_remove(pEnt);
wait(1);//did you try this?

Re: frustrated in ent_remove() [Re: i_program_games] #170246
12/08/07 03:21
12/08/07 03:21
Joined: Oct 2003
Posts: 825
22�21'24"N 114�07'30"E
Frederick_Lim Offline OP
User
Frederick_Lim  Offline OP
User

Joined: Oct 2003
Posts: 825
22�21'24"N 114�07'30"E
Thank you. I solved my problem, I just mess up with pointers in my mind.


Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | 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