• 🏆 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!

[General] Hero Revival Time

Status
Not open for further replies.
Level 8
Joined
Jul 25, 2006
Messages
177
So what I want to do is, using the wc3 hero revival that works off data from the object editor and gameplay constants is have my heroes revive at an altar in 13 seconds + 2 seconds * their level. How do i have to manipulate the hero's data and gameplay constants for this to work as i propose? I've tried googling it but i believe the anwser has something to do with the gameplay constant:

Hero Revive Cost - Time Level Factor

I'm not sure how to manipulate this number to make revival work how I want. Anyone know about this matter in detail?

Sorry for double post but ive been experimenting with it and for anyone who is curious it appears Hero Revival time is calculated this way. Unit Build Time * level * Time Level Factor

And it caps at Max Time Factor * Unit Build Time

Therefore its impossible to make hero revive the way I'd like to work. Sad panda face, yes.
 
Last edited by a moderator:
Level 17
Joined
Nov 13, 2006
Messages
1,814
So what I want to do is, using the wc3 hero revival that works off data from the object editor and gameplay constants is have my heroes revive at an altar in 13 seconds + 2 seconds * their level. How do i have to manipulate the hero's data and gameplay constants for this to work as i propose? I've tried googling it but i believe the anwser has something to do with the gameplay constant:

Hero Revive Cost - Time Level Factor

I'm not sure how to manipulate this number to make revival work how I want. Anyone know about this matter in detail?

Sorry for double post but ive been experimenting with it and for anyone who is curious it appears Hero Revival time is calculated this way. Unit Build Time * level * Time Level Factor

And it caps at Max Time Factor * Unit Build Time

Therefore its impossible to make hero revive the way I'd like to work. Sad panda face, yes.

i think the only way with trigger

  • Hero Revive
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
    • Actions
      • Wait (((Real((Hero level of (Triggering unit)))) x 2.00) + 13.00) seconds
      • Set TempPoint = (Position of (Triggering unit))
      • Camera - Pan camera for (Triggering player) to TempPoint over 1.00 seconds
      • Hero - Instantly revive (Triggering unit) at TempPoint, Show revival graphics
      • Custom script: call RemoveLocation(udg_TempPoint)
maybe if u want u can do this way too

  • Hero Revive1
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
    • Actions
      • Player - Make (Unit-type of (Triggering unit)) Unavailable for training/construction by (Triggering player)
      • Wait (((Real((Hero level of (Triggering unit)))) x 2.00) + 13.00) seconds
      • Player - Make (Unit-type of (Triggering unit)) Available for training/construction by (Triggering player)
or this way

  • Hero Revive2
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
    • Actions
      • Player - Limit training of (Unit-type of (Triggering unit)) to 0 for (Triggering player)
      • Wait (((Real((Hero level of (Triggering unit)))) x 2.00) + 13.00) seconds
      • Player - Limit training of (Unit-type of (Triggering unit)) to 1 for (Triggering player)
 
Level 9
Joined
Nov 19, 2011
Messages
516
i think the only way with trigger

  • Hero Revive1
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
    • Actions
      • Player - Make (Unit-type of (Triggering unit)) Unavailable for training/construction by (Triggering player)
      • Wait (((Real((Hero level of (Triggering unit)))) x 2.00) + 13.00) seconds
      • Player - Make (Unit-type of (Triggering unit)) Available for training/construction by (Triggering player)

You are making unit avaible or not. In this way before (((Real((Hero level of (Triggering unit)))) x 2.00) + 13.00) seconds I won't be able to start process.
 
Level 17
Joined
Nov 13, 2006
Messages
1,814
You are making unit avaible or not. In this way before (((Real((Hero level of (Triggering unit)))) x 2.00) + 13.00) seconds I won't be able to start process.

yea but then u can make unit unable to revive Hero lv*2 then revive time set to 13, the effect is similiar.

i doubt have any other way but maybe somebody know a methode for this too via easier trigger
 
Level 9
Joined
Nov 19, 2011
Messages
516
  • Hero Revive1
  • Events
    • Unit - A unit Dies
  • Conditions
    • ((Triggering unit) is A Hero) Equal to True
  • Actions
    • Wait ((Real((Hero level of (Triggering unit)))) x 2.00) seconds
    • Unit - Set build progress to 0%.
with 13 revive time
OR
with 99999999 revive time

  • Hero Revive1
  • Events
    • Unit - A unit Dies
  • Conditions
    • ((Triggering unit) is A Hero) Equal to True
  • Actions
    • Wait ((Real((Hero level of (Triggering unit)))) x 2.00) +13 seconds
    • Unit - Set build progress to 100%.
Of coure 2nd one will couse less errors due to max hero level.
 
Level 17
Joined
Nov 13, 2006
Messages
1,814
  • Hero Revive1
  • Events
    • Unit - A unit Dies
  • Conditions
    • ((Triggering unit) is A Hero) Equal to True
  • Actions
    • Wait ((Real((Hero level of (Triggering unit)))) x 2.00) seconds
    • Unit - Set build progress to 0%.
with 13 revive time
OR
with 99999999 revive time

  • Hero Revive1
  • Events
    • Unit - A unit Dies
  • Conditions
    • ((Triggering unit) is A Hero) Equal to True
  • Actions
    • Wait ((Real((Hero level of (Triggering unit)))) x 2.00) +13 seconds
    • Unit - Set build progress to 100%.
Of coure 2nd one will couse less errors due to max hero level.

correct me if i say stupid thing but its jump from 0% suddenly to 100%? what sense have this? another thing what u want build? :D

if u want i got countdown timer instead of altar :/

but have till a methode instead altar and it is the drawing multiboard with "|", what is act like a progressbar but idk how could make with alter what look like normal reviveing
 

Attachments

  • 2.JPG
    2.JPG
    176.4 KB · Views: 291
  • 1.w3x
    22.5 KB · Views: 124
Last edited:
Level 9
Joined
Nov 19, 2011
Messages
516
have my heroes revive at an altar

What was fucked:

No revive on alatar. (But on same position)
Revive without user order.
No gold/wood cost of process.

You coplitated what was easy. My trigers just avoid constant revive time, and makes it variable.

Check this. Revive works perfect, but (hate this word) trigger still need to be fixed (can't get triggering unit variable) and I think it still can be optimized in vJass.

ERROR triggering unit is no unit with event unit - A unit starts reviveing. (Or programers fucked translation)
 

Attachments

  • PB.w3x
    18.4 KB · Views: 108
Level 8
Joined
Jul 25, 2006
Messages
177
Repping you both for your efforts on this matter but I've decided the formula i wanted to use would be too quick of a revival anyway so instead i set build time to 1 on the heroes, made the time level factor 5, with a cap of 99999. As you've probably figured out already this makes the revival time of the hero: 5 seconds * Hero Level.
 
Level 17
Joined
Nov 13, 2006
Messages
1,814
Repping you both for your efforts on this matter but I've decided the formula i wanted to use would be too quick of a revival anyway so instead i set build time to 1 on the heroes, made the time level factor 5, with a cap of 99999. As you've probably figured out already this makes the revival time of the hero: 5 seconds * Hero Level.

just a question, what is max level on ur map?
 
Status
Not open for further replies.
Top