Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Var add up
#1
How can i add up 2 var and get that value.

Var 1 + Var 2 = Value

Ex:
The var 1 return 2
The var 2 return 3

2 + 3 =5

How can i do that?

Other...
How can i do that.
Get the var 1 value and multiply by the next value?
#2
wiki Wrote:VarAdd(Name, Value) adds to the variable the value (x + value).

Therefore:

Code:
VarAdd(Var1,!Var2!)
or
Code:
!Var1!+!Var2!=!Var3!


Everytime you want to call a variable from outside a variable command (i.e VarAdd, VarSub, VarMod, etc), you need to use "!" right after and before the variable: !var!

To multiple a variable by a constant use:

wiki Wrote:VarMult(Name, Value) multiplies the variable by the value (x * value).
Please, read the wiki: http://wiki.bmega.net/doku.php

[Image: tumblr_linetdmNqm1qzcq51o1_500-thumb-600x337-48077.gif]
#3
Can someone even teach me what is this "var" thing on macro. ye everybody tells me to read wiki but the wiki isn't good at all.. it wont teach me how to use it. Maybe someone can help me? Big Grin
FR€€ Scripts BY: [Image: 29ys76p.png]1337
To see my Scripts click:[/size]

[size=200]HERE
#4
Miksu1337 Wrote:Can someone even teach me what is this "var" thing on macro. ye everybody tells me to read wiki but the wiki isn't good at all.. it wont teach me how to use it. Maybe someone can help me? Big Grin

Var are personal variables, you can use them to store custom values.

You can create a variable on this two ways:

VarSet(MyHP) Self.Health
or
MyHP:= Self.Health

This two ways create a custom variable called MyHP containing the value of Self.Health. You can access that value using this way: !MyHP!

Sample:

MyHP := Self.Health HUD.Display(My Current HP is !MyHP!)
#5
btw sorry i know this is wrong thread. But the last forum was better. i mean this doesn't look good. also maybe u could use repulation system. so everyone can add rep++ to some ppl they like. if u know what i mean
FR€€ Scripts BY: [Image: 29ys76p.png]1337
To see my Scripts click:[/size]

[size=200]HERE
#6
Miksu1337 Wrote:btw sorry i know this is wrong thread. But the last forum was better. i mean this doesn't look good. also maybe u could use repulation system. so everyone can add rep++ to some ppl they like. if u know what i mean

The Rep++ system is the thanks system I have ever used..

About the THEME, it is strange, but I like it... Ofc, I'll improve it.


Forum Jump:


Users browsing this thread: 1 Guest(s)