Making lives

K

KrazYKoDO

Guest
Lives

How do you make lives??? ive been trying over and over again but it won't work :-(
 

sqrage

Mega Super Ultra Cool Member
Reaction score
514
set your lives into a variable set the variable to your # of lives
then everytime u want to loose 1 make it -1

just to inform you this is a frequently asked question if u did a search u could have found many answers. :eek:
 
K

KrazYKoDO

Guest
what?

first of all i tryed a search and it didn't work well it did but i didn't get what i wanted it was saying wierd things :-\. second of all what u mean put ur live into a variable??? i tryed to do that (yay i got it right) but i could figure out how....
 

Im_On_56k

Hm...
Reaction score
116
Go into trigger editor
At the top of the trigger editor ull see a X, click that X
Now click the +X
Find the Integer and click that.
Set the value to how many lives you want.
Set the name of the integer to Lives
Click Ok

Make a trigger

Update Lives
Code:
Unit - A unit enters lose life <gen>
(Owner of (Triggering unit)) Equal to Player 12 (Brown)
Set Lives = (Lives - 1)
Game - Display to (All players) the text: (O noes a unit as enter the end! You have  + ((String(Lives)) +   lifes left.))
 

BrokenX

New Member
Reaction score
26
This is why we need a tutorial on variables, I know how to do almost every trigger type there is until it gets bigger then a page, but when it comes to variables the only type I know how to do is like a, array type of dialog, dialog button type. Please admins make a variable tutorial thanks <- small request <-, mainly for idiots like me :).
 
S

Senkin

Guest
BrokenX I can help you on most variable questions you may have just PM me and I will do my best to inform you about that variable.
 
S

Senkin

Guest
For the Main question, does the life get lost after a unit hits a region? Or does it get lost by a unit death? Or what?
 
D

darkmaster24

Guest
im the oppposite to broken x i can do loads of trigggers with variables but theres quite alot of the others i cant do

like ones that need co-ordinates
 
S

Senkin

Guest
Co-ordinates is obtainable by viewing the map in WE and having your curser over the area you want the co-ordinates and look at the bottom left hand area of the editor.
 
D

darkmaster24

Guest
well that solves a few mysteries, i had to keep randomly guesssing before
 

KrazYKoDO

New Member
Reaction score
2
hey.

hey guys thanks you the help but i got the variables thing working :) :) :) happy :D :) :) :) thanks anyway though
 

KrazYKoDO

New Member
Reaction score
2
Still stumped

the only thing i am still having trouble with is i can't figure out how to make it so when all of the ppl die you loose a life :confused:
 

KrazYKoDO

New Member
Reaction score
2
Lives

Ok so i got the Live part down.... now all i have to do is make it so that when all of them die you lose a life.... can ne1 help me
plz i really need it
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
"All of them"?

All what? Units? Buildings?
Owned by player 1? Several players at once? Creeps?
How many are they? And where are they coming from?

So many questions, so little time... :)
 

KrazYKoDO

New Member
Reaction score
2
srry about that other post i wasn't thinking straght but i mean all of the people (its a maze you know all of the human owned chars die u lose a life) things like that
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
> its a maze you know

Well, now I do. Before I didn't...


Hm... yes.

Events:
- A unit dies
Conditions:
- Maybe a test on the owner? Or a test on the unit-type? Does your map need it?
Actions:
- "set variable": set myVariable = myVariable + 1
- "if then else (multiple conditions): if myVariable equal to (number of units) then (do something)

Is your map multi-player or single player?
Still a lot of details missing, but, we will see ;)
 

KrazYKoDO

New Member
Reaction score
2
well umm that was really confusing but i will try it thx for the info ill tell you if it works
 
General chit-chat
Help Users

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top