Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 2 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script Help Hard to find the errors in the HPS file
jessehmusic Offline
Senior Member

Posts: 423
Threads: 102
Joined: Dec 2011
Reputation: 8
#11
RE: Hard to find the errors in the HPS file

(03-05-2012, 12:47 AM)robinnjensen Wrote: Hello, i have been searching through the script areas and i can't seem to find anything, i'm kinda new to this stuff aswell, but i would be great thankfull if any of you guys would like to help me to fix my script ! Smile

here it is
--------------------------------------------------------------------------------------------------
////////////////////////////
//run when entering map
void OnStart()
{
AddUseItemCallback("", "key_study_1", "Freedom", "KeyOnDoor", true);
AddEntityCollideCallback("Player", "PlayerCollide", "MonsterFunction", true, 1);
}




void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Freedom", false, true);
PlaySoundAtEntity("", "unlock_door", "door", 0, false);
RemoveItem("key_study_1");
}




void MonsterFunction(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("servant_brute_2", true);
SetEntityPlayerInteractCallback("cabinetmetal", "Spawn", true);




void Spawn(string &in asEntity)




}
SetEntityActive("corpse_male_1", true);
AddTimer("Scare", 0.5f, "Scare1");




void scare1(string &in asTimer)




GiveSanityDamage(10, true);
PlaySoundAtEntity("", "react_scare.snt", "Player", 0, false);




////////////////////////////
//Run when entering map
void OnEnter()
}




////////////////////////////
// Run when leaving map
void OnLeave()
}
--------------------------------------------------------------------------------------
Really thankfull!


---------------------------
FATAL ERROR
---------------------------
FATAL ERROR: Could not load script file 'custom_stories/Robin's Hell/custom_stories/Robin's Hell/maps/Robin's Hell.hps'!
main (24, 16) : ERR : Expected identifier
main (25, 9) : ERR : Expected identifier
main (29, 1) : ERR : Expected ',' or ';'
main (30, 18) : ERR : Expected identifier
main (35, 1) : ERR : Expected ',' or ';'

---------------------------
OK
---------------------------


void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Freedom", false, true);
PlaySoundAtEntity("", "unlock_door", "
Freedom ", 0, false);
RemoveItem("key_study_1");
}


void MonsterFunction(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("servant_brute_2", true);
SetEntityPlayerInteractCallback("cabinetmetal", "Spawn", true);

}


{
SetEntityActive("corpse_male_1", true);
AddTimer("Scare", 0.5f, "Scare1");
}

void scare1(string &in asTimer)
{
GiveSanityDamage(10, true);
PlaySoundAtEntity("", "react_scare.snt", "Player", 0, false);
}



////////////////////////////
//Run when entering map
void OnEnter()
{
}[align=-webkit-auto]

test that Smile

http://www.moddb.com/mods/jessehmusic - Hospital of horror , WIP
(This post was last modified: 03-05-2012, 04:09 PM by jessehmusic.)
03-05-2012, 04:09 PM
Website Find


Messages In This Thread
RE: Hard to find the errors in the HPS file - by jessehmusic - 03-05-2012, 04:09 PM



Users browsing this thread: 1 Guest(s)