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
Sanity Check
Lizard Offline
Member

Posts: 174
Threads: 23
Joined: Jul 2012
Reputation: 5
#1
Sanity Check

Hi guys

It's been along time since I last worked with amnesia maps and scripting, but I am slowly starting again.

I gotten to a point where i want the game to check the players sanity and if it's below or egual to a certain value, things should happen. I tryed to play around with GetPlayerSanity, but i cant make it work.

Every help would be appreciated.

CURRENT PROJECT:
A Fathers Secret == Just started
(This post was last modified: 06-28-2013, 01:41 PM by Lizard.)
06-28-2013, 12:39 PM
Find
PutraenusAlivius Offline
Posting Freak

Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation: 119
#2
RE: Sanity Check

if(GetPlayerSanity())

If I'm not mistaken.

"Veni, vidi, vici."
"I came, I saw, I conquered."
06-28-2013, 12:49 PM
Find
Lizard Offline
Member

Posts: 174
Threads: 23
Joined: Jul 2012
Reputation: 5
#3
RE: Sanity Check

I have try'ed this without success:

if(GetPlayerSanity<=40)

if((GetPlayerSanity) <= (40))

if(GetPlayerSanity(40))

CURRENT PROJECT:
A Fathers Secret == Just started
(This post was last modified: 06-28-2013, 01:02 PM by Lizard.)
06-28-2013, 12:54 PM
Find
Tomato Cat Offline
Senior Member

Posts: 287
Threads: 2
Joined: Sep 2012
Reputation: 20
#4
RE: Sanity Check

You're forgetting your parentheses. =p

Try this:

PHP Code: (Select All)
if(GetPlayerSanity() <= Number
06-28-2013, 01:26 PM
Find
Lizard Offline
Member

Posts: 174
Threads: 23
Joined: Jul 2012
Reputation: 5
#5
RE: Sanity Check

Thanks for help guys.

Works fine now

CURRENT PROJECT:
A Fathers Secret == Just started
06-28-2013, 01:39 PM
Find




Users browsing this thread: 3 Guest(s)