Author Topic: VCE Help  (Read 882 times)

How would I go about making a brick that, if hit 25 times it disappears and says every time it's hit "Health number/25"

This is a simple way to do that, This is the list:

Onactivate>Player/Client/Minigame Etc.> ModVCE > Add (Name of the Variable) (Amount added)

Then,

OnVariableupdate>Used previous one>IfVariable (Previously used name) (Amount)

OnVariabletrue>Client>Anyprint> You have hit this block <Var:(cl/pl/brick):(Previously used name)

Hope this helps.





OnVariabletrue>Client>Anyprint> "You have hit this block <Var:(cl/pl/brick):(Previously used name)"



You could always use that with Onactivate, Try it out.

-snip-
That is way too confusing, and not exactly what jes wants.

This is what jes wants..
Code: [Select]
onActivate -> Self -> VCE_ifValue -> <var:br:health> -> <= -> 25 -> 1 1
onVariableTrue -> Self -> Dissapear
onVariableTrue -> Self -> VCE_modVariable -> health -> set -> 25
onVariableTrue -> Client -> BottomPrnt -> You chop down the tree!
onVariableFalse -> Self -> VCE_modVariable -> health -> add -> -1
onVariableFalse -> Client -> BottomPrint -> Tree Life: <var:br:health>/25

Noedit: First line, "1 1" shouldn't either be "1 5" or nothing at all, due to there not being any second check.

Tried the attached image and it did not work.

First line, should be <= 0

I must have been really tired when I wrote that.. x.x

First line, should be <= 0

I must have been really tired when I wrote that.. x.x
I tried the attached image and it STILL did not work. It just destroys it on the first hit.

Try this: In that first event, in the empty box next to <= 0, enter "1 2 3 4 5".

If you do that the event will know which of the other events to deal with.

I'm not completely sure if that's why it's not working but it might be.

Try this: In that first event, in the empty box next to <= 0, enter "1 2 3 4 5".
It can only fit up to 1 2 3 4.

Come on you guys, it's a simple mistake.

Code: [Select]
1: onProjectileHit | Self | VCE_ifValue | <var:br:Barricade_1_Health> | <= | 25 | 1 5
You guys forgot the "<var:br" part, you're using a VCE_ifValue event, not a VCE_ifVariable.

I changed the VCEIfValue to VCEIfVariable and it worked :D
*Topic Locked*
Warning - while you were typing a new reply has been posted. You may wish to review your post.

*unlocked*
I changed the events to the attached screenshot and now they don't work.
Please help.



First line, don't use named brick. That sends the check to THAT brick, asking if it has that variable.