The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.24-0ubuntu0.18.04.17 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



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
Checkpoints in script not working in any maps
willochill Offline
Member

Posts: 73
Threads: 27
Joined: Apr 2011
Reputation: 0
#1
Checkpoints in script not working in any maps

Whenever I put checkpoints into a script in any of my maps, the map crashes and it shows an error message stating: ERR: "No matching signatures to 'Checkpoint(string@&, string@&, string @&, string@&, string @&'." I posted below a script that I put a checkpoint in. What am I doing wrong?

void OnStart()
{       
       AddUseItemCallback("", "bone_saw_2", "wooden_boards_block_1", "SawGruntAlert", false);
    AddEntityCollideCallback("guest_grunt", "AreaDisableGuestGrunt", "DisableGuestGrunt", false, 1);
    AddEntityCollideCallback("Player", "AreaCheckpointGuestRooms", "CheckpointGuestRooms", true, 1);
}
void SawGruntAlert(string &in asItem, string &in asEntity)
{
    StartPlayerLookAt("wooden_boards_block_1", 0.3f, 0.3f, "");
    PlaySoundAtEntity("SawSound", "23_saw.snt", "wooden_boards_block_1", 0.0f, false);
    AddTimer("SawAfter", 4.0f, "SawAfterevent");
}
void SawAfterevent(string &in asTimer)
{
    SetPlayerSanity(100);
    SetEntityActive("wooden_boards_block_1", false);
    SetEntityActive("wooden_boards_block_broken_1", true);
    StopSound("SawSound", 0);
    AddTimer("TimerAlertGrunt", 1.0f, "AlertGuestGrunt");
    StopPlayerLookAt();
}
void AlertGuestGrunt(string &in asTimer)
{
    SetEntityActive("guest_grunt", true);
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_1", 0.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_2", 0.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_3", 0.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_4", 4.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_5", 0.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_6", 0.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_7", 4.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_8", 0.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_9", 0.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_10", 0.0f, "");
    AddEnemyPatrolNode("guest_grunt", "PathNodeArea_11", 0.0f, "");
}
void DisableGuestGrunt(string &in asParent, string &in asChild, int alState)
{
    SetEntityActive("guest_grunt", false);
}
void CheckpointGuestRooms(string &in asParent, string &in asChild, int alState)
{
    Checkpoint("GuestRoomsCheckpoint", "PlayerStartArea_3", "", "", "");
}
void OnEnter()
{
    PlayMusic("amb_guardian.ogg", true, 1.0f, 0, 0, true);
}






(This post was last modified: 06-07-2011, 11:47 PM by willochill.)
06-07-2011, 11:39 PM
Find


Messages In This Thread
Checkpoints in script not working in any maps - by willochill - 06-07-2011, 11:39 PM



Users browsing this thread: 1 Guest(s)