Regional Superman Trigger Trouble

SilverScreen

New Member
Reaction score
2
MERRY CHRISTMAS and HAPPY HOLIDAYS EVERYONE!

M'kay, I've been agonizing over this for two days, and either it can't be done, or, more than likely, it just requires someone who knows what they're doing.

I've created ArthasX--a beefed up, leveled up version of Arthas. The game starts with Arthas, but when he dies, he is revived in Region C...as ArthasX! (Names are a work in progress.) But once ArthasX leaves Region C, he is supposed to revert back to normal Arthas.

...It's not happening that way at all.

I've been able to handle the simple task of having Arthas revive in Region C, and I've even been able to convert him into ArthasX after that--but it's not region-based. Once he leaves the region, he remains ArthasX.

I tried doing a trigger for the resurrection, then a trigger that says when a unit is in Region C, it is replaced by a ArthasX (Region C cannot be accessed by any other unit--it's a resurrection-accessible only area), but for some reason it creates a TON of ArthasX's instead of just one.

I tried working it so that when Arthas was down to 25 (or less) hitpoints he would be replaced by Arthas X, but then I can't do anything with ArthasX 'cause he's not in the game yet.

That seems to be my main problem thus far. Everything I want to do requires me to select the unit from the map, which is an issue for ArthasX since he doesn't exist unless a condition later in the game is met. Every option I've tried is screwed by this.

Any thoughts? Revive Arthas at Region C, replace him with ArthasX as long as he's in Region C, and then have him revert back to Arthas when he leaves Region C.

Doable? Something simple I'm missing?
 

Accname

2D-Graphics enthusiast
Reaction score
1,463
i would recommend following method.

i guess your arthas is a hero. heroes got exp, items, buffs maybe etc. replacing heroes or copying them is much work. a simple solution for this is the chaos ability. this ability is being made for exactly this purpose (remember the orc campaign when grom is being possessed).

1). create 1 copys of the chaos ability both without techtree requirements. the first one will morph the unit into arthasX the second one into the regular arthas.

2). create a trigger which will make arthas revive when he dies and move him to the centre of region C.

3). create another trigger which fires whenever a unit enters region C. add the chaos(1) ability to the triggering unit

4). create a trigger which fires whenever a unit leaves region C. add the chaos(2) ability to the triggering unit

trigger 1 example:
Trigger:
  • Untitled Trigger 001
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Arthas
    • Actions
      • Set TmpPnt = (Center of RegionC)
      • Hero - Instantly revive (Triggering unit) at TmpPnt, Hide revival graphics
      • Custom script: call RemoveLocation (udg_TmpPnt)


trigger 2 example:
Trigger:
  • Untitled Trigger 002
    • Events
      • Unit - A unit enters RegionC
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Arthas
    • Actions
      • Unit - Add Chaos(1) to (Triggering unit)


trigger 3 example:
Trigger:
  • Untitled Trigger 003
    • Events
      • Unit - A unit leaves RegionC
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to ArthasX
    • Actions
      • Unit - Add Chaos(2) to (Triggering unit)
 

SilverScreen

New Member
Reaction score
2
Wow! That's some thorough triggering for sure! Now I don't feel so bad about not figuring it out on my own.

Thank you a bunch! I'll work on it and see if I can't duplicate it on my end. I'll letcha know how it turns out.

I appreciate you being so specific too--I'm too new to the whole thing to get general ideas.

Terrific! Kudos to you all!
 

Accname

2D-Graphics enthusiast
Reaction score
1,463
if you are new to warcraft III coding you may wonder about this part:
Trigger:
  • Untitled Trigger 001
    • Events
      • ...
    • Conditions
      • ...
    • Actions
      • Set TmpPnt = (Center of RegionC)
      • ...
      • Custom script: call RemoveLocation (udg_TmpPnt)


i am setting a point variable called TmpPnt (you can create variables in the variable Editor, its a golden X in the toolbar) instead of directly using the center of the region as a point.
this is to prevent memory leaks. thats why i also use the line of custom script (basically Jass script taken into the GUI interface) to remove that variable again.

if you dont know about memory leaks you should really start reading some turtorials about it, like this one.


its important to prevent memory leaks in all triggers which are running numerous times in the game. if you dont take care of them your game might start to lag and eventually lag that hard that the game freezes.

good luck with your triggers.
 

canons200

New Member
Reaction score
50
To Accname,
what is this chaos ability does? some people say it exist doesn't make any different =.='
 

Accname

2D-Graphics enthusiast
Reaction score
1,463
open the ability editor. open the "human" tab on "unit abilitys" and there it is, chaos of the siege tank.

the chaos ability is pretty simple, it got only a single effect. if a unit gains it the unit will be transmorphed into another unit, the new unit type is declared by the chaos ability. the morphed unit will still have the same exp, items, hitpoints (not max hitpoints), attributes, main attribute, abilitys, hero points, position, facing, and so on and so on.
its basically the best way of replacing a unit type with another because thats the purpose this ability has been made for.

if you played the reign of chaos campaign you will most likely remember the orc mission in which grom and his orcs are drinking the demonic blood. they all turn red and become powerhouses and such.
this is done using the "chaos" ability.
 

SilverScreen

New Member
Reaction score
2
M'kay...I've got some of it to work, which is great--the chaos was a swell idea. I think my trouble is with regions. For some reason, they aren't doing what their supposed to. I started experimenting with them, and I think I'm doing something wrong. Just as a test, I tried to add "Heavy Rain" to a region in the properties section, and it shows up in the editor, but not when I play the map.

I also tried to assign some very easy triggers to the region and those didn't work. I can revive the hero in the region, but the enter/leave region triggers don't do anything. Is there something I need to change to "activate" the regions or something?

Thanks again to everyone for their help--I'm gett'in close!
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?
  • The Helper The Helper:
    Happy Thursday!
    +1
  • Varine Varine:
    Crazy how much 3d printing has come in the last few years. Sad that it's not as easily modifiable though
  • Varine Varine:
    I bought an Ender 3 during the pandemic and tinkered with it all the time. Just bought a Sovol, not as easy. I'm trying to make it use a different nozzle because I have a fuck ton of Volcanos, and they use what is basically a modified volcano that is just a smidge longer, and almost every part on this thing needs to be redone to make it work
  • Varine Varine:
    Luckily I have a 3d printer for that, I guess. But it's ridiculous. The regular volcanos are 21mm, these Sovol versions are about 23.5mm
  • Varine Varine:
    So, 2.5mm longer. But the thing that measures the bed is about 1.5mm above the nozzle, so if I swap it with a volcano then I'm 1mm behind it. So cool, new bracket to swap that, but THEN the fan shroud to direct air at the part is ALSO going to be .5mm to low, and so I need to redo that, but by doing that it is a little bit off where it should be blowing and it's throwing it at the heating block instead of the part, and fuck man
  • Varine Varine:
    I didn't realize they designed this entire thing to NOT be modded. I would have just got a fucking Bambu if I knew that, the whole point was I could fuck with this. And no one else makes shit for Sovol so I have to go through them, and they have... interesting pricing models. So I have a new extruder altogether that I'm taking apart and going to just design a whole new one to use my nozzles. Dumb design.
  • Varine Varine:
    Can't just buy a new heatblock, you need to get a whole hotend - so block, heater cartridge, thermistor, heatbreak, and nozzle. And they put this fucking paste in there so I can't take the thermistor or cartridge out with any ease, that's 30 dollars. Or you can get the whole extrudor with the direct driver AND that heatblock for like 50, but you still can't get any of it to come apart
  • Varine Varine:
    Partsbuilt has individual parts I found but they're expensive. I think I can get bits swapped around and make this work with generic shit though
  • Ghan Ghan:
    Heard Houston got hit pretty bad by storms last night. Hope all is well with TH.
  • The Helper The Helper:
    Power back on finally - all is good here no damage
    +2
  • V-SNES V-SNES:
    Happy Friday!
    +1
  • The Helper The Helper:
    New recipe is another summer dessert Berry and Peach Cheesecake - https://www.thehelper.net/threads/recipe-berry-and-peach-cheesecake.194169/

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top