Page 1 of 1
How to set AAPTR via actor pointer?
Posted: Wed Dec 11, 2019 4:20 pm
by Silentdarkness12
I'm continuing to work on another project, but i'm a bit vexed because I need to access an AAPTR, particularly target, in a nonstandard manner. What i'm trying to figure out is, is there a way to set an AAPTR pointer via a normal actor pointer?
Re: How to set AAPTR via actor pointer?
Posted: Thu Dec 12, 2019 6:02 am
by Gez
I don't think so, the AAPTR are, strictly speaking, indices to pointers rather than actual pointers. E.g. AAPTR_TARGET says "use the pointer from the target field", it's not itself the target pointer. It's just a numerical constant after all. So there's no way to "convert" a real pointer into an AAPTR constant. Best you can possibly imagine to do is compare them, see if the mobj pointed by the target field is the same mobj as the one from your pointer.