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
"if" help ( again -_-'' )
NaxEla Offline
Senior Member

Posts: 415
Threads: 5
Joined: Dec 2012
Reputation: 28
#8
RE: "if" help ( again -_-'' )

PHP Code: (Select All)
void CompleteOilQuest(string &in asEntity)
{
    
CompleteQuest("oil_quest""Quest_OilQuest_Text");
    
    if(
GetPlayerLampOil() == 0.0f) {
        
SetMessage("map2_messages""QuestOilDone1");
    }
        
    if(
GetPlayerLampOil() > 0.0f && GetPlayerLampOil() <= 5.0f) {
        
SetMessage("map2_messages""QuestOilDone2");
    }
        
    if(
GetPlayerLampOil() > 5.0f && GetPlayerLampOil() < 12.5f) {
        
SetMessage("map2_messages""QuestOilDone3");
    }
        
    if(
GetPlayerLampOil() == 12.5f) {
        
SetMessage("map2_messages""QuestOilDone4");
    }


Try that code.

Btw, does the quest actually get completed? Because if you called the quest "OilQuest", writing "Quest_OilQuest_Text" in this line:
CompleteQuest("oil_quest", "Quest_OilQuest_Text");
will not work. It should just be:
CompleteQuest("oil_quest", "OilQuest");

In Ruins [WIP]
02-21-2013, 12:49 AM
Find


Messages In This Thread
"if" help ( again -_-'' ) - by tonitoni1998 - 02-20-2013, 06:13 PM
RE: "if" help ( again -_-'' ) - by tonitoni1998 - 02-20-2013, 06:57 PM
RE: "if" help ( again -_-'' ) - by Adrianis - 02-20-2013, 06:57 PM
RE: "if" help ( again -_-'' ) - by tonitoni1998 - 02-20-2013, 07:09 PM
RE: "if" help ( again -_-'' ) - by MulleDK19 - 02-20-2013, 11:20 PM
RE: "if" help ( again -_-'' ) - by NaxEla - 02-21-2013, 12:49 AM
RE: "if" help ( again -_-'' ) - by tonitoni1998 - 02-21-2013, 05:42 PM



Users browsing this thread: 1 Guest(s)