Simple question really, i am simply wondering if it is possible to use DamageActor without the use of any TIDs and simple use actor pointers. Cause the wiki page is not exactly clear on that information.
For instance a projectile runs a script that uses damageactor, makes its target (which is the projectile launcher by default) the inflictor and the tracer the target.
Is it possible to use DamageActor only with actor pointers?
Moderator: GZDoom Developers
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
-
- Posts: 136
- Joined: Sat Nov 28, 2015 2:42 pm
-
- Posts: 5038
- Joined: Sun Nov 14, 2010 12:59 am
Re: Is it possible to use DamageActor only with actor pointe
Assuming the projectile is the activator of the script, pass 0 as both tids. Both of the pointer fields now relate to the projectile:
- Victim (what the function calls "target"):
- AAPTR_DEFAULT: projectile damages itself.
- AAPTR_TARGET/TRACER/MASTER: projectile damages its target/tracer/master.
- Inflictor:
- AAPTR_DEFAULT: projectile is the inflictor.
- AAPTR_TARGET/TRACER/MASTER: projectile's target/tracer/master is the inflictor.
Code: Select all
DamageActor(0, AAPTR_TRACER, 0, AAPTR_TARGET, ...);
-
- Posts: 136
- Joined: Sat Nov 28, 2015 2:42 pm
Re: Is it possible to use DamageActor only with actor pointe
Ah alright, thanks. That really clears things up.