New Key Problems
Small new problem which will solve a lot of stress...
For every new key do i need a new ".hps" file? Because i tried adding the new key data underneath
with these commands, (this is what is in total)
void OnStart()
{
AddUseItemCallback("", "studykey_1", "mansion_2", "OPEN", true);
}
void OPEN(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("mansion_2", false, true);
PlaySoundAtEntity("", "unlock_door", "mansion_2", 0, false);
RemoveItem("studykey_1");
}
void StudyDoorLocked(string &in entity)
{
if(GetSwingDoorLocked("mansion_2") == true)
{
SetMessage("Messages", "studyroomlocked", 0);
}
}
AddUseItemCallback("", "dungeonkey_2", "mansion_3", "OPEN", true);
void OPEN(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("mansion_3", false, true);
PlaySoundAtEntity("", "unlock_door", "mansion_3", 0, false);
RemoveItem("dungeonkey_2");
}
void DungeonDoorLocked(string &in entity)
{
if(GetSwingDoorLocked("mansion_") == true)
{
SetMessage("Messages", "dungeondoorlocked", 0);
}
}
and it says this,
Main (27,19) : ERR : Expected Identifier
(thats the line that looks like this "AddUseItemCallback("", "dungeonkey_2", "mansion_3", "OPEN", true);"
I tried putting {, and }, around it but it told me to get rid of them...
please help
|