• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

strange problem with Inferno {making a dummy summoned through Inferno unselectable}

Status
Not open for further replies.
Level 5
Joined
Jul 12, 2007
Messages
113
Hi,
i just tried to spawn a dummy with Inferno. Now it's possible to select the dummy ingame. How can I prevent that? I gave him the locust-abiity. I even realized that if I set the lifetime of the dummy to 0.01 the Inferno won't do any damage or stun. any idea how to fix these things?
 
Level 9
Joined
Feb 14, 2009
Messages
316
That thing
1) won't work and
2) is very glitchy.

1) Because summoned units are not classified as created. Created units are only those from call CreateNUnitsAtLoc()
2) Imagine the game creates a unit and since it becomes the last created, now the player will be albe to select another units. Common sense, dude.


I'm really curious how the hell Locust ability fails -.-" check twice which unit has locust and which unit is summoned by the spell. This is quite odd...
EDIT: Completely weird. The locust ability makes it invulnerable but still selectable.
EDIT: It's from the spell itself. The same unit, if summoned with another spell, is working.
EDIT:
Found the solution. If you want the inferno unselectable, use
  • Inferno
    • Events
      • Unit - A unit Spawns a summoned unit
    • Conditions
      • (Unit-type of (Summoned unit)) Equal to Infernal
    • Actions
      • Unit - Replace (Summoned unit) with a Infernal using The old unit's relative life and mana
      • Animation - Play (Last replaced unit)'s birth animation
If you want only the meteor, use
  • Inferno - Meteor
    • Events
      • Unit - A unit Spawns a summoned unit
    • Conditions
      • (Unit-type of (Summoned unit)) Equal to Infernal
    • Actions
      • Unit - Remove (Summoned unit) from the game
 
Last edited:
Level 5
Joined
Jul 12, 2007
Messages
113
i've used your first trigger, and it works but now there's annother problem: this trigger spawns the summoned dummy even before the meteor hits the ground. my version of inferno still uses 1 second of delay so the meteor can hit the ground an the damage is dealt at the right time.

EDIT: additionally your trigger prevents the ability from dealing damage and stunning...
 
Last edited:
Level 9
Joined
Feb 14, 2009
Messages
316
I will review this stuff... in fact, I didn't use the ability with anything different from infernal and didn't use it hostily.
Just wait some time.

EDIT:

  • Inferno
    • Events
      • Unit - A unit Spawns a summoned unit
    • Conditions
      • (Unit-type of (Summoned unit)) Equal to Dummy unit from Inferno1
    • Actions
      • Custom script: local unit u
      • Custom script: set u = GetSummonedUnit()
      • Wait 1.00 game time seconds.
      • Custom script: call ReplaceUnitBJ(u, '[YOUR_UNIT_RAWCODE]', 1)
      • -------- OPTIONAL: ---------
      • Animation - Play (Last replaced unit)'s birth animation
You can view unit's raw code in object editor by using CTRL+D. Be sure to place it between ' ' signs, e.g. 'ninf'.

  • Inferno - only meteor
    • Events
      • Unit - A unit Spawns a summoned unit
    • Conditions
      • (Unit-type of (Summoned unit)) Equal to Dummy unit from Inferno2
    • Actions
      • Custom script: local unit u
      • Custom script: call ShowUnit(u, false)
      • Wait 1 game time seconds
      • Custom script: call RemoveUnit(u)
Sorry for JASS scripts if you don't understand them, but it's the only way to make the spell MUI w/o arrays and is a lot easier. Cheers, for more questions write me again. And sorry for the delay.
 
Last edited:
Level 5
Joined
Jul 12, 2007
Messages
113
hi, my trigger now looks like this in the error-window:

function Trig_test_Actions takes nothing returns nothing
local unit u
u = GetSummonedUnit()
call TriggerSleepAction( 1.00 )
call ReplaceUnitBJ(u, '[h00N:hwtw]', 1)
call SetUnitAnimation( GetLastReplacedUnitBJ(), "birth" )
endfunction

the editor says that there's and error at the GetSummonedUnit and at the ReplaceUnitBJ...

sorry and don't know about JASS, only about anti leak functions my friends told me about.

and sorry i didn't post this code properly, but i'm from Germany and it seems the hive website doesn't accept the german code :(

but thx for your help!
 
Level 9
Joined
Feb 14, 2009
Messages
316
Must be like this:

function Trig_test_Actions takes nothing returns nothing
local unit u
set u = GetSummonedUnit() <---- here you missed the set part
call PolledWait( 1.00 ) <---- PolledWait or wait (game-time) is better to use than just wait
call ReplaceUnitBJ(u, 'h00N', 1) <---- unit raw code is written in '' signs and is only the 1st part of the h00N:hwtw
call SetUnitAnimation( GetLastReplacedUnitBJ(), "birth" )
endfunction

NP, you prolly mistyped/read some things.
 
Status
Not open for further replies.
Top