Jump to content

Help With Counting the Number of Player's Deaths

game computer help

1 reply to this topic

#1 Dayrider10

  • Members
  • 32 posts

Posted 05 May 2014 - 10:26 PM

Hey Everyone!

I'm working on this game and I'm working with counting the number of deaths. What I want to happen is that once player 1 or player 2 dies it counts the death. The max number of deaths is three so say player 2 kills player 1 three times player 2 wins and vice versa. Well that is not happening. When player 2 kills player 1 it is fine and it counts up to three deaths and it says player 2 wins ,but when I do that for player 1 and he/she kills player 2 it does not count the deaths and it just keeps going. Here is the link:


The counting of the death is at lines 468 - 477.

Thank you!
Live On!

#2 CometWolf

  • Members
  • 1,283 posts

Posted 05 May 2014 - 11:18 PM

You're using 2 different variable names
					    elseif player2deaths == 3 then
			    player2d = player2d + 1

1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users