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
Problem with levels & localvarint
Paulpolska Offline
Member

Posts: 144
Threads: 29
Joined: Jun 2011
Reputation: 0
#1
Problem with levels & localvarint

Where I must put "{" and "}" to this code will work ? I have SetLocalVarInt etc.
Quote: void Dinamite(string &in asEntity, int alState)
{
if(GetLocalVarInt("Button") == 1)
if (alState == 1)
SetMessage("Messages", "Run", 3);
else if(GetLocalVarInt("Button") == 0)
if (alState == 1)
SetMessage("Messages", "test", 0);
AddQuest("button", "button");

}

Ok Problem is finished. Work code are

Quote:void Dinamite(string &in asEntity, int alState)
{
if(GetLocalVarInt("Button") == 1)
{
if (alState == 1)
SetMessage("Messages", "Run", 3);
GiveSanityDamage(10,true);
SetLocalVarInt("Button", 2);
return;
}
else if(GetLocalVarInt("Button") == 0)
{
if (alState == 1)
SetMessage("Messages", "test", 0);
AddQuest("button", "button");
}

}

MY CUSTOM STORY - - STILL ALIVE - -
http://www.moddb.com/mods/still-alive
(This post was last modified: 06-07-2012, 01:12 PM by Paulpolska.)
06-07-2012, 12:40 PM
Find




Users browsing this thread: 1 Guest(s)