Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Death areas / out of bounds
Pandemoneus Offline
Senior Member

Posts: 328
Threads: 2
Joined: Sep 2010
Reputation: 0
#2
RE: Death areas / out of bounds

Yes, it is possible.
Create a script area and call it WhateverYouLike.

void OnStart()
{
AddEntityCollideCallback("Player", "WhateverYouLike", "KillThePlayer", false, 1);
}

void KillThePlayer(string &in asParent, string &in asChild, int alState)
{
/**
* Type can be: BloodSplat, Claws or Slash.
* void  GivePlayerDamage(float afAmount, string& asType, bool abSpinHead, bool abLethal);
*/

GivePlayerDamage(1000, "BloodSplat", true, true);
}

//player dies, number has to be 100+ to kill the player when he wasn't damaged yet
//1000 = Amount of Damage, "BloodSplat" = Animation played on the screen when getting damage
//first true = make the player spin when he gets damaged
//second true = makes it lethal damage so you actually die from it

[edit]
The developers actually used
AddPlayerHealth(-200);

Up to you how you want to do it. Big Grin

09-20-2010, 12:08 AM
Find


Messages In This Thread
Death areas / out of bounds - by mitchell - 09-19-2010, 11:59 PM
RE: Death areas / out of bounds - by Pandemoneus - 09-20-2010, 12:08 AM



Users browsing this thread: 1 Guest(s)