Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
4 registered members (AndrewAMD, Baklazhan, Ayumi, Hanky27), 1,387 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Identifying entities by name problem #179709
01/24/08 15:23
01/24/08 15:23
Joined: Dec 2003
Posts: 129
Osnabrück, Germany
Ready Offline OP
Member
Ready  Offline OP
Member

Joined: Dec 2003
Posts: 129
Osnabrück, Germany
Ok I don't really know how to explain this but I'll try anyways ^^
I basically want every entity to have a unique name, while they share the same action.

For instance, I could give an entity a name in its action to identify it, like
Code:
entity* myname;
action actioname
{
myname = my;
}


But what if several entities use the same function? I don't want to write a new function for each entity in my level :s

Basically, I want every entity to be able to be manipulated through the console...
Like when I type entityX.z += 100; in the console, it should move entityX up 100 units

I tryed using the entities name (in WED) but then name.z += 100; does nothing at all :s

I bet its something super simple I just don't know what >_>


Do not underestimate people because they have a low post count... :0
Re: Identifying entities by name problem [Re: Ready] #179710
01/24/08 16:08
01/24/08 16:08
Joined: Sep 2005
Posts: 980
Aue, Sachsen, Germany
W
Wicht Offline
User
Wicht  Offline
User
W

Joined: Sep 2005
Posts: 980
Aue, Sachsen, Germany
handle(object);

and

ptr_for_handle(handle);

Re: Identifying entities by name problem [Re: Wicht] #179711
01/24/08 16:25
01/24/08 16:25
Joined: Dec 2003
Posts: 129
Osnabrück, Germany
Ready Offline OP
Member
Ready  Offline OP
Member

Joined: Dec 2003
Posts: 129
Osnabrück, Germany
Aah thanks. Now since I know what I'm looking for, I found a nice little snippet in aum47


Do not underestimate people because they have a low post count... :0

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