Skip to main content
added 210 characters in body
Source Link
Monster
  • 8.2k
  • 1
  • 12
  • 27

Whenever your character measures a collision, you send a message "reset timer".

Have one object with a timer property (which measures in seconds).

  • When the property exceeds 5.0 you restart the scene (property sensor greater than mode).

  • When a message with subject "reset timer" is received set the property back to -5 (property actuator Assign mode)

[Edit] just in case the character detects constant collision, I suggest to enable [True Level Triggering] at the collision sensor. This way the message gets constantly send and the timer gets constantly reset.

Whenever your character measures a collision, you send a message "reset timer".

Have one object with a timer property (which measures in seconds).

  • When the property exceeds 5.0 you restart the scene (property sensor greater than mode).

  • When a message with subject "reset timer" is received set the property back to -5 (property actuator Assign mode)

Whenever your character measures a collision, you send a message "reset timer".

Have one object with a timer property (which measures in seconds).

  • When the property exceeds 5.0 you restart the scene (property sensor greater than mode).

  • When a message with subject "reset timer" is received set the property back to -5 (property actuator Assign mode)

[Edit] just in case the character detects constant collision, I suggest to enable [True Level Triggering] at the collision sensor. This way the message gets constantly send and the timer gets constantly reset.

Source Link
Monster
  • 8.2k
  • 1
  • 12
  • 27

Whenever your character measures a collision, you send a message "reset timer".

Have one object with a timer property (which measures in seconds).

  • When the property exceeds 5.0 you restart the scene (property sensor greater than mode).

  • When a message with subject "reset timer" is received set the property back to -5 (property actuator Assign mode)