Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to end a round after AI is killed and award by damage dealed?

Asked by 7 years ago

My question is simple, i already have a script wich is like the one used in disaster game(waittime, gametime and repeat...), but what i want to do now is after the ENEMY(an AI) health=0 the round ends and players get awarded by the damage dealed to ENEMY

how do i know the damage dealed by each player?

1 answer

Log in to vote
0
Answered by 7 years ago

You have to keep track of it. You must ensure that each weapon adds a tag to the AI's humanoid regarding how much damage it did and which player dealt that damage. Some script must "consume" these tags and keep a running total.

0
@chess123mate hmm... a new value inside each player that stores the damage dealed. can work too? Ismax23 0 — 7y
0
Of course - so long as either the weapons increase those values directly or else generate tags that you can monitor and then increase the "damage dealt" values through another script. chess123mate 5873 — 7y
Ad

Answer this question