[System] Hero's Hero Revival System

Hero

─║╣ero─
Reaction score
250
Hero's Hero Revival System

I had this system a while ago...and never posted it...I updated it and made various changes to it also.

Made Completely In JASS.

Code:
-----HERO REVIVAL SYSTEM-------

---Requirements----

For Implementation:

Paste The Text from this map's custom header into your map's custom header

Create a trigger...with the Event-A Unit Dies
for the action call either function (Example Below)

Revive Timer Dialog
    Events
        Unit - A unit Dies
    Conditions
    Actions
        Custom script:   call Revive_System_TWindow("Revival Time")

Revive
    Events
        Unit - A unit Dies
    Conditions
    Actions
        Custom script:   call Revive_System()


____________________________________________________
Features: 
-Fully MUI
-No Leaks
-Easily Customizable and Editable
-Revives at Player Start Location
-Pans Camera to the Revival Spot
-Uses a fair timer for the amount of time until ressurection
-Tells that hero's player how long it will take until ressurection
-Allows use of a Timer Dialog (Window)

-Credits

      -Hero12341234

Formula Used:

Code:
constant function Formula_RS takes integer r returns integer
  return  r * 3
endfunction
Meaning Level of the Hero Dying * 3 will give the time until revival...
This is easily customizable by editing the number 3 to whatever number you prefer.

New Features:
Use of the Timer Dialog(Window)


Get the Sample Map Below


Questions? Comments? Bugs? Post Them Here..
 

Attachments

  • Hero Revive System.w3x
    20.7 KB · Views: 121

Hero

─║╣ero─
Reaction score
250
Bump?

Anyways I am updating this system soon..since my JASS skills are better I should be able to make it all in 1 trigger
 

Steel

Software Engineer
Reaction score
109
Minor stuff:

1) You need to nullify all non-boolean, non-integers, non-reals, non-strings. So your unit u needs to be set to null when you are done with it. Same with location p

2)
Code:
constant function Formula_RS takes integer r returns integer
  return  r * 3
endfunction

Code is redundant.

3)
Code:
function Trig_Revive_System takes nothing returns boolean
    return IsUnitType(GetTriggerUnit(), UNIT_TYPE_HERO) == true 
endfunction

to

Code:
function Trig_Revive_System takes nothing returns boolean
    return IsUnitType(GetTriggerUnit(), UNIT_TYPE_HERO) 
endfunction

4)I understand you are learning JASS so let me give you a hand here:
Code:
      call TimerStart (a,h,false,null)
      call PolledWait(h)

This is pretty shotty, you really don't need this. If you have a timer started when it expires you should have it do what you want (GetExpiredTimer function is your friend, check out wc3jass.com for some tutorials on Timers). You shouldn't have to have 2 calls tracking the time duration.
 

Hero

─║╣ero─
Reaction score
250
Lol...did you read my above post?

Anyways I am updating this system soon..since my JASS skills are better I should be able to make it all in 1 trigger

I made this system when I didn't know JASS too well..I only uploaded it now to share it...I can fix it up nicely..but thx for the help anyways +rep for that
 

Steel

Software Engineer
Reaction score
109
Lol...did you read my above post?



I made this system when I didn't know JASS too well..I only uploaded it now to share it...I can fix it up nicely..but thx for the help anyways +rep for that

Yes I did, did you read what I said?
Steel said:
4)I understand you are learning JASS so let me give you a hand here:

If you need more help, I'll help you when I can.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top