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
Script and Quest help
Liag Offline
Junior Member

Posts: 8
Threads: 0
Joined: Sep 2010
Reputation: 1
#2
RE: Script and Quest help

//Use AddEntityCollideCallBack() in OnStart() to call this when player enters area
void NameOfArea(string &in asParent, string &in asChild, int alState)
{   //Plays the wind sound in the area
    PlaySoundAtEntity("windwhirl", "general_wind_whirl.snt", "NameOfArea", 0.0f, false);
     //Creates the wind effect in the area
    CreateParticleSystemAtEntity("pswhirl", "ps_dust_whirl.ps", "NameOfArea", false);
    
    SetSwingDoorClosed("name_of_door", true, true); //Closes the door
    
    for(int i = first_torch_number; i <= last_torch_number; i++)
        SetLampLit("name_of_torches_" + i, false, true); //Blows out the torches
        
    SetLanternActive(false, false); //Deactivates the lantern
}

This example is very simple and you should add timers and reaction sounds to make it more realistic.

Also, you're using a semicolon instead of a comma in your AddQuest call (which would generate the error), unless you just got it wrong here.
09-17-2010, 09:59 PM
Find


Messages In This Thread
Script and Quest help - by Jordo76 - 09-17-2010, 07:40 PM
RE: Script and Quest help - by Liag - 09-17-2010, 09:59 PM
RE: Script and Quest help - by Jordo76 - 09-17-2010, 10:31 PM
RE: Script and Quest help - by iTIMMEH - 09-17-2010, 11:06 PM
RE: Script and Quest help - by Jordo76 - 09-17-2010, 11:30 PM



Users browsing this thread: 1 Guest(s)