Poll

Help plz?

What you're trying to do is simple!
2 (33.3%)
Err...idk what you're trying to do...(only n00bs who don't read vote this)
1 (16.7%)
What you're trying to do has never been done before.
0 (0%)
It is impossible to do this.
1 (16.7%)
I will try to help you.
2 (33.3%)

Total Members Voted: 6

Author Topic: VCE Help  (Read 2499 times)

the first event doesnt work because there is no current health variable the second one would work.

the first event doesnt work because there is no current health variable the second one would work.

Wut do you mean? <var:player:health> is the var replacer for the player's current health, and <var:player:maxHealth> is the var replacer for the player's maximum health. I should be able to mod them both and make them increment as you level up, but it won't even set to what I want to be the starting health.

The player has a limit to 100 Health. To change this, you must copy the script and start a new player type.
If you want like HP upgrades, dexterity, etc; you must have a Client based variable.
By setting its health variable to a default variable, you would then have a client known as health. When you event a bot, you have to event it so you heal your actual health on hit, but lose some of your client variable on it.
How did you do it Kobewarrior? I tried it a few times, trying different things, but it doesn't work. I've tried making it so that when the health variable reaches or goes below 0, it calls a function that kills the bot. How did you do it? My way doesn't work.
When the bot is killed, it must spawn and explosion of any sort and the brick must have its vehicle set to NONE. Once at a 30000 time delay, it should change back to a Standard Bot once you have the event it. This isn't too hard, and it isn't impossible.


onPlayerleaveZone -> Player -> VCE_modVariable -> <var:player:health> -> Set -> 10
onPlayerleaveZone -> Player -> VCE_modVariable -> <var:player:maxHealth> -> Set -> 10

When modifying a variable, you don't use the <var:x:$$$$> format. You just put the variable:

onActivate > Self > ifValue <var:pl:youpressed> [=] 1
onVariableTrue > Player > Kill

for the third line (numbered 2):
onVariableFalse > Self > [Player] youpressed [Set] 1
                    - - OR - -
onVariableFalse > Player youpressed [Set] 1

onVariableFalse > Player > youpressed [Set] 1
Whoopsie!

When the bot is killed, it must spawn and explosion of any sort and the brick must have its vehicle set to NONE. Once at a 30000 time delay, it should change back to a Standard Bot once you have the event it. This isn't too hard, and it isn't impossible.

Ok, that makes a spawning delay, but what I want to do is give the bot a health variable. When the bot is damaged, the bot will heal back to 100, and the damage (gotten from a damage variable) will be subtracted from the bot's health variable. If that variable goes at or below 0, the bot will die. Then you set the brick's vehicle to NONE, wait 30000, and respawn the bot. I'll try that, but the only problem is is that there is no Bot target for onVariable inputs.

Ok, that makes a spawning delay, but what I want to do is give the bot a health variable. When the bot is damaged, the bot will heal back to 100, and the damage (gotten from a damage variable) will be subtracted from the bot's health variable. If that variable goes at or below 0, the bot will die. Then you set the brick's vehicle to NONE, wait 30000, and respawn the bot. I'll try that, but the only problem is is that there is no Bot target for onVariable inputs.
The brick itself is the Bot target.

Every time there is an unexplained problem, there is usually a non-default input.

Start off using the VCE and default events.

The brick itself is the Bot target.

Oooooh ok! So the events for a bot would look like this: (just another guess)


0 onBotSpawn > Self > VCE_modVariable > botHealth > |Set| > 10
1 onBotSpawn > Bot > setBotName > Bob (for CI in minigame, I think)
2 onBotDamaged > Bot > setHealth > 100 (heals it)
3 onBotDamaged > Client > VCE_modVariable > Damage > |randomNum| > maxDmg
4 onBotDamaged > Self > VCE_modVariable > botHealth > |Subtract| > Damage
5 onBotDamaged > Self > VCE_ifVariable > botHealth > |<=| > 0 > 6 8
6 onVariableTrue > Self > setVehicle > |NONE|
7 onVariableTrue > Self > VCE_modVariable > botHealth > |Set| > 10
8 onVaraibleTrue > Self> setVehicle > StandardBot  (15000 Delay)

Oooooh ok! So the events for a bot would look like this: (just another guess)


0 onBotSpawn > Self > VCE_modVariable > botHealth > |Set| > 10
1 onBotSpawn > Bot > setBotName > Bob (for CI in minigame, I think)
2 onBotDamaged > Bot > setHealth > 100 (heals it)
3 onBotDamaged > Client > VCE_modVariable > Damage > |randomNum| > maxDmg
4 onBotDamaged > Self > VCE_modVariable > botHealth > |Subtract| > Damage
5 onBotDamaged > Self > VCE_ifVariable > botHealth > |<=| > 0 > 6 8
6 onVariableTrue > Self > setVehicle > |NONE|
7 onVariableTrue > Self > VCE_modVariable > botHealth > |Set| > 10
8 onVaraibleTrue > Self> setVehicle > StandardBot  (15000 Delay)

Well, I'll try this and see if it works like it hopefully should. Anyone feel free to bump this so that the people who have been helpful can see my most recent work.


Sorry, but I forgot to mention that my problem is not solved until I say so via this topic. I will also lock when I'm done with it.