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


Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Making custom story and error pops up
Sinthetic Offline
Junior Member

Posts: 9
Threads: 1
Joined: Mar 2012
Reputation: 0
#13
RE: Making custom story and error pops up

(03-07-2012, 09:42 PM)Your Computer Wrote: It doesn't crash on me.
So you didnt edit any of the files? Because I sent it to my friend and it crashed for him also.. :I

Just in case, Ill post the first map's .hps file if anyone can notice something wrong with it which could cause
the crash Smile
Spoiler below!


////////////////////////////
// Run first time starting map
void OnStart()
{
AddUseItemCallback("","monsterdoorkey_1","monsterdoor", "UsedKeyOnDoor",true);
AddUseItemCallback("","secretkey_1","sala", "UsedKeyOnDoor2",true);
AddUseItemCallback("","avainhihi_1","alex", "UsedKeyOnDoor3",true);
AddEntityCollideCallback("Player", "jeesus_1", "HolyJesus", true, 1);
AddEntityCollideCallback("jeesusfly_1", "jeesus_1", "Sound", true, 1);
AddEntityCollideCallback("Player", "PlayerCollide", "MonsterFunction", true, 1);
AddEntityCollideCallback("Player", "jumalautakohta", "Sound2", true, -1);
SetEntityCallbackFunc("monsterdoorkey_1", "OnPickup");
AddEntityCollideCallback("Player", "Message_1", "Message1", true, 1);
AddEntityCollideCallback("Player", "kolaa", "Sound4", true, 1);



}
void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("monsterdoor", false, true);
PlaySoundAtEntity("", "unlock_door", "monsterdoor", 0, false);
RemoveItem("monsterdoorkey_1");
}

void UsedKeyOnDoor2(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("sala", false, true);
PlaySoundAtEntity("", "unlock_door", "sala", 0, false);
RemoveItem("secretkey_1");
}

void HolyJesus(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("jeesusfly_1", true);
AddPropForce("jeesusfly_1", 0, 0, 30000, "World");
}


void Sound(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "pystyy.ogg", "jeesus_1", 0, false);
}

void UsedKeyOnDoor3(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("alex", false, true);
PlaySoundAtEntity("", "unlock_door", "alex", 0, false);
RemoveItem("avainhihi_1");
}
void MonsterFunction(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("servant_grunt_1", true);
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_1", 2, "");
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_2", 0, "");
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_3", 0, "");
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_4", 0, "");
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_5", 0, "");

}

void Sound2(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "jumalauta.ogg", "jumalautakohta", 0, false);
}



void OnPickup(string &in asEntity, string &in type)
{
SetEntityActive("veijo", true);
PlaySoundAtEntity("", "24_iron_maiden.snt", "monsterdoorkey_1", 0, false);

}

void Message1(string &in asChild, string &in asParent, int alState)
{
SetMessage("Messages", "Popup1", 0);
}

void Sound4(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "troll.ogg", "kolaa", 0, false);
}










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

}

////////////////////////////
// Run when leaving map
void OnLeave()
{

}


(This post was last modified: 03-08-2012, 04:50 PM by Sinthetic.)
03-08-2012, 01:02 PM
Find


Messages In This Thread
RE: Making custom story and error pops up - by Sinthetic - 03-08-2012, 01:02 PM



Users browsing this thread: 1 Guest(s)