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 Help I srsly have no clue what is causing this!
MsHannerBananer Offline
Member

Posts: 218
Threads: 34
Joined: Sep 2013
Reputation: 10
#2
RE: I srsly have no clue what is causing this!

I've looked through, and with some clever use of the find function in Notepad++, you're missing a closing curly bracket

This thing-> }

I'll look through and see if I can find it for you. Smile

EDIT:

FOUND IT! >D

Copy and paste the following script and see if that works for you. Big Grin Also, if you're curious, the missing curly bracket is in your MoveBridge function. Smile

PHP Code: (Select All)
void OnStart()
{
    
AddEntityCollideCallback("Player""AreaBreath""CollideAreaBreath"true1);
    
SetEntityPlayerInteractCallback("FakeCrank""InteractWithCrank"true);
    
SetMessage("Messages""chapter2"0);
    
GiveSanityBoostSmall();
    
AddEntityCollideCallback("Player","AreaDustEnter","CollideDustPaper",true,1);
    
AddUseItemCallback("getoil""DirtyContainer""AreaGetOil""UseContainerOnOil"false);
    
AddUseItemCallback("""glass_container_oil_1""FakeCrank""OilContainerOnFakeCrank"false);
}
    

void CollideAreaBreath(string &in asParentstring &in asChildint alState)
{
    
PlaySoundAtEntity("rocks""03_rock_move.snt""AreaBreath_1"0.0ffalse);
    
CreateParticleSystemAtEntity("warnps""ps_cave_monster_warn.ps""AreaBreath_1"false);
    
StartScreenShake(0.01f0.5f2.0f3.5f);
    
PlaySoundAtEntity("breaths""04_breath.snt""AreaBreath_1"0.0ffalse);
    
PlaySoundAtEntity("rocksm""03_rock_move.snt""AreaBreath_1"RandFloat(2.0f,6.0f), false);
    
CreateParticleSystemAtEntity("breathps""ps_cave_monster_breath.ps""AreaBreath_1"false);
}

void CollideDustPaper(string &in asParentstring &in asChildint alState)
{
    
PlaySoundAtEntity("Wind""general_wind_whirl""Player"2false);
     
CreateParticleSystemAtEntity("PSDoor_3""ps_dust_whirl.ps""AreaDust"false);
}

void InteractWithCrank(string &in asEntity)
{
    
SetMessage("Messages""NeedOil"0);
    
AddQuest("InteractWithCrank""Oil");
    
PlaySoundAtEntity("rocks""16_lever_stuck.ogg""FakeCrank"0.0ffalse);
}

void UseContainerOnOil(string &in asItemstring &in asEntity)
{
    
RemoveItem(asItem);
    
AddTimer("AddContainer"1.1f"TimerAddContainer");    
    
AddTimer("StartCrouch"0.8f"TimerCrouch");    
    
AddTimer("StopCrouch"1.4f"TimerCrouch");        
    
AddTimer("AddContainer"1.6f"TimerStopLookAt");
    
    
    
    
SetLocalVarInt("FilledContainer"1);

    
SetEntityPlayerInteractCallback("AreaOil"""false);
    
    
StartPlayerLookAt("AreaLookAtContainer"33"");
}

void TimerAddContainer(string &in asTimer)
{
    
DestroyParticleSystem("ParticleSystem_42");
    
SetEntityActive("glass_container_oil_1"true);
    
    
CreateParticleSystemAtEntity("fill""ps_oil_jar""glass_container_oil_1"true);
    
    
PlaySoundAtEntity("slurp""16_fill_oil""glass_container_oil_1"0.0ffalse);
}

void TimerCrouch(string &in asTimer)
{
    if(
asTimer == "StartCrouch"){
        
SetPlayerCrouching(true);
        
PlaySoundAtEntity("crouch""player_crouch""Player"0.0ffalse);
        
PlaySoundAtEntity("slurp2""16_water_stream""glass_container_oil_1"0.3ffalse);
        return;
    }
    
    
SetPlayerCrouching(false);
    
PlaySoundAtEntity("stand""player_stand""Player"0.0ffalse);
}

void TimerStopLookAt(string &in asTimer)
{
    
StopPlayerLookAt();    
    
StopSound("slurp2"4.0f);
}

void EntityCallGlassContainer(string &in asEntitystring &in type)
{
    
DestroyParticleSystem("fill");
    
CreateParticleSystemAtEntity("oilsplah""ps_oil_splash.ps""AreaLookAtContainer"true);
    
    
SetEntityPlayerInteractCallback("AreaOil""InteractAreaOil02"false);
}

void OilContainerOnFakeCrank(string &in asItemstring &in asEntity)
{

    
SetEntityActive("FakeCrank"false);
    
SetLeverStuckState(asEntity0true);
    
SetEntityActive("crank_iron_1"true);
    
CreateParticleSystemAtEntity("oilsplah""ps_oil_grease.ps""PS"true);  
        
PlaySoundAtEntity("stand""16_grease_lever.ogg""FakeCrank"0.0ffalse);
}

void MoveBridge(string &in asEntityint LeverState)
{
    if(
LeverState == 1
    {
        
PlaySoundAtEntity("unstucksound""16_bridge_unstuck""ladder"0.0ffalse);    
    
PlaySoundAtEntity("fall""16_winch_bridge""ladder"1.0ftrue);

    
AddTimer("hitground"1.0f"TimerBridgeHitGround");
    
    
StartScreenShake(0.05f0.5f0.1f0.3f);
    
    
SetEntityPlayerInteractCallback("bridge_lever_1"""false);
    
SetMoveObjectStateExt("ladder"2.66880.5false);
    
    
GiveSanityBoostSmall();
    
PlayMusic("23_puzzle.ogg"false0.7f010false);
        
SetLeverStuckState(asEntityLeverStatefalse);
 }
 
}

void TimerBridgeHitGround(string &in asTimer)
{
    
StopSound("fall"0.3f);    
    
StartScreenShake(0.01f1.0f0.1f0.5f);
}

void OnEnter()
{
    
PlayMusic("16_amb.ogg"true0.710true);
}

void OnLeave()
{



(This post was last modified: 06-15-2014, 09:38 AM by MsHannerBananer.)
06-15-2014, 09:31 AM
Find


Messages In This Thread
RE: I srsly have no clue what is causing this! - by MsHannerBananer - 06-15-2014, 09:31 AM



Users browsing this thread: 1 Guest(s)