Quote:
Difficulty with AMXX is that it doesn't give access to certain private entity data of buildings, such as owner of a teleporter and whether it's entrance or exit.
|
You can access player's private data with fakemeta module and get/set_pdata_*. Just a matter to find the right offset you need.
Well I can help you a bit.
Looking at IDA, when you create a teleporter, it uses
real_owner from
CBaseEntity to store the player who is building the teleporter, and
m_iType from
CTFTeleporter to specify entry/exit, and it seems to be 4 for entry and 5 for exit.
Here a dump from linux binary:
To use these char-based offsets, you need to calculate first the value windows-based.
Generally, for classes derived from
CBaseMonster, it's +20 for linux, otherwise +16.
Here
CTFTeleporter, should be +20 and +16 for
CBaseEntity.
So:
real_owner = 348 - 16 =
332 ; can be used I think with
get_pdata_ent (but this native is int-based, so you need to do 332 / 4). In 1.8.3-dev, you can use 332 with
get_pdata_ehandle
m_iType = 1728 - 20 =
1708 ; can be used with
get_pdata_int (careful too, this is unfortunately int-based too, so you need to do 708 / 4).
Member with type starting with
CBase, like
m_pPLayer can be retrieved with
get_pdata_cbase (hamsandwich module)
Tell if you don't understand something.
__________________