Zulk RS Posted September 9, 2015 I want to make a generic arena fight. Player walks in and doors close and lock. The doors won't open until all monsters in the room are dead. How do I do this? Thank you. 0 Share this post Link to post
scifista42 Posted September 9, 2015 Give a specific TID to all monsters in the arena. Set their Action (automatically activated upon death) to ACS_Execute to execute a script that would count alive monsters with this given TID (use ThingCount or ThingCountName for this), and if it counted zero (=all dead), it would do whatever you need to unlock the arena. 0 Share this post Link to post
Zulk RS Posted September 9, 2015 Thanks. Now I'm going to prove myself to be the great noob I am by asking this follow-up question: How exactly do I do this? And what is TID? 0 Share this post Link to post
scifista42 Posted September 9, 2015 TID is Thing ID, basically a tag that you can give to individual Things in a map. Scripts are being written into the SCRIPTS window. The script for your task would look something along these lines:#include "zcommon.acs" script 1 (void) { if(ThingCount(T_NONE,5)==0) { // Counts all living monsters whose TID is 5, the condition will be true if there are zero of them // Put your actions to unlock the arena here } }Then give each of your monsters a TID 5 and an action ACS_Execute with the first parameter 1, because the script number is 1. More info here: http://zdoom.org/wiki/ACS http://zdoom.org/wiki/Structure_of_a_script http://zdoom.org/wiki/Script_types http://zdoom.org/wiki/ThingCount http://zdoom.org/wiki/ACS_Execute And finally: http://zdoom.org/wiki/Built-in_ACS_functions and http://zdoom.org/wiki/Action_specials 0 Share this post Link to post
VGA Posted September 9, 2015 You can do this in ZDoom and in vanilla/Boom. Here is a small arena battle in ZDoom that I created as a test of my scripting abilities, the camera textures, the pk3 format, Untrustable's Wolfenstein bosses etc etc. http://forum.zdoom.org/viewtopic.php?f=19&t=46158&p=768880&hilit=bosses+reich#p768880 0 Share this post Link to post
Zulk RS Posted September 10, 2015 Thanks Scifista42! But now I'm going to prove myself to be a bigger noob than |I originally appeared to be (which by itself is pretty big) by requesting you to write the full script (like you did in an earlier post) cause I couldn't understand the examples in the Zdoom wiki. ... Thanks...? 0 Share this post Link to post
scifista42 Posted September 10, 2015 If you want to write ACS scripts at all, there is no good in completely shutting your mind away from understanding them and always letting someone else to do whatever you need for you. If you don't understand something moderately easy, just take a step back, start from the very basics, and gradually continue learning at your own pace. Start here: http://zdoom.org/wiki/A_quick_beginner%27s_guide_to_ACS Then tuturials from here: http://zdoom.org/wiki/ACS#ACS_tutorial (up to Built-in ACS functions) 0 Share this post Link to post
Zulk RS Posted September 10, 2015 Thanks. Finally something even a great noob like me understands! 0 Share this post Link to post
Angry Saint Posted September 10, 2015 VGA said:You can do this in ZDoom and in vanilla/Boom. How can I do this in vanilla? 0 Share this post Link to post
scifista42 Posted September 10, 2015 In vanilla, you can tweak a certain monster type in DEHACKED to call KeenDie function upon its death, which will open a door tagged 666 if all monsters of the same species as the calling monster are already dead. Or you can use my trick - it needs special map design, but works. :) 0 Share this post Link to post
Zulk RS Posted September 11, 2015 I tried to change TID of all the monsters in my arena but there's a problem. Though my understanding of ACS have gotten slightly gotten better, it's still pretty bad. To change TID of anything I need to know the old TID right? Well I have multiple monsters in my arena and some of them are custom monsters I got from Realm667. They are the ST Dark Imp and A Blood Demon. How do I change TID of multiple monsters and custom monsters? 0 Share this post Link to post
scifista42 Posted September 11, 2015 You set thing's TID (tag) directly in the mapping editor. The same way as you set tags to linedefs and sectors. Go to the thing's properties and put a number into the tag field. 0 Share this post Link to post
Angry Saint Posted September 11, 2015 scifista42 said:In vanilla, you can tweak a certain monster type in DEHACKED to call KeenDie function upon its death, which will open a door tagged 666 if all monsters of the same species as the calling monster are already dead. Ok, I was thinking Vanilla without dehacked modifications. 0 Share this post Link to post
scifista42 Posted September 11, 2015 My trick (mentioned in the same post) works without DEHACKED modifications. :) 0 Share this post Link to post
Zulk RS Posted September 11, 2015 scifista42 said:You set thing's TID (tag) directly in the mapping editor. The same way as you set tags to linedefs and sectors. Go to the thing's properties and put a number into the tag field. Ulp! I assumed TID and tags were two different things. 0 Share this post Link to post
Angry Saint Posted September 11, 2015 scifista42 said:My trick (mentioned in the same post) works without DEHACKED modifications. :) I read it but didn't understand. I will have to read it more carefully. Maybe it's better if you post an example wad with it? 0 Share this post Link to post
scifista42 Posted September 11, 2015 The trick is used in my MAP19 of D2INO, on 3 separate places: The first bridge with HKs and Barons, the red key fight with Arachnotrons, and the final arena with Cyberdemon. 0 Share this post Link to post
Zulk RS Posted September 11, 2015 Well... I was finally able to get the desired effect after some slight trial and error. Thanks for your help. 0 Share this post Link to post