Friday, 4 March 2022

How to determine the size of object in a List of that object

Have a field in a class called Labyrinth: List<EnemyInstance> BattleZoneEnemy; // 0x98 Wants to use this function but need an EnemyInstance: kill( Labyrinth *this, EnemyInstance enemy); How can I determine the size of enemy so I can iterate BattleZoneEnemy list so I can call Kill() on each of the enemyinstances What I am thinking : void Update(void *_LabyrinthInstance) { // get BattleZoneEnemy (Not sure what are the data type to receive I assume a pointer since its a list) void* BattleZoneEnemy = *(void*)((uint64_t)_LabyrinthInstance + 0x98); if (BattleZoneEnemy) { kill(_LabyrinthInstance, BattleZoneEnemy + size? ); // Can I loop this statement if I know the size of each EnemyInstance? // So I would just add the size for each iteration } } Some advices would be appreciated!

from iOSGods RSS Feed https://ift.tt/N2aVE1K

No comments:

Post a Comment