Sprites, textures, sounds, code, and other resources belong here. Share and share-alike!
Forum rules
Before posting your Resource, please make sure you can answer YES to any of the following questions:
Is the resource ENTIRELY my own work?
If no to the previous one, do I have permission from the original author?
If no to the previous one, did I put a reasonable amount of work into the resource myself, such that the changes are noticeably different from the source that I could take credit for them?
If you answered no to all three, maybe you should consider taking your stuff somewhere other than the Resources forum.
Mode, repeatability, activator, trigger rate, what it can be binded to and tid of an actor which action to activate can be changed
Spoiler:
Arg0 Trigger Mode - controls how it can be activated (0-continious trigger while actor is inside; 1-single trigger on exit; 2-single trigger on enter; 3-single trigger on enter and exit;)
Arg1 Repeatability - controls if it's one time use or multiple
Arg2 Activator - controls who can activate it (0-no filter; 1-player; 2-monsters; 4-projectiles; 8-puffs;)
Arg3 Binding - controls if trigger is binded to floor/ceiling or another trigger
Arg4 Target TID - executes this actor's action when triggered, can be used to link multiple trigger boxes together to create jagged hitboxes
gravity field controls trigger rate (not enough arguments are available, so i had to improvise)
proper collision detection thanks to SAT - trigger's angle, pitch, roll rotation is supported
can be rotated by other trigger, but with some limitations, i couldn't resolve them.
Spoiler:
current limitations (maybe there's more. god i hope not):
no multiple rotations, so it works if only one thing changes - angle or pitch or roll (having boxes prerotated in map editor seems to work fine) EXCEPT if changing thing is angle - then pitch and roll must not be prerotated (should be 0)
check out an example map for some use cases i could think of
I think I managed to find one bug tho. On a "on enter" trigger that's set to trigger "true single time" it's possible for multiple actors to trigger it before it disappears. Right now the trigger box only disappears when the triggerer steps away.
In this test map there's a simple ACS script that prints something to the screen depending if a player or a monster triggers it. Alert the pinky and then walk inside the trigger and wait for the pinky to walk inside too. You should see 2 different messages which I presume is not supposed to happen with a "true single time" trigger.
You do not have the required permissions to view the files attached to this post.
Fishytza wrote: ↑Sat Nov 09, 2024 5:58 am
On a "on enter" trigger that's set to trigger "true single time" it's possible for multiple actors to trigger it before it disappears.
sorry for the late fix - i couldn't bring myself to work on it again, the MATH kinda broke me.
should work better now, also changed example map a bit