(11-12-2012, 02:35 PM)beecake Wrote: Also where did you ut this line: AddUseItemCallback("", "key5", "water_door", "UsedKeyOnDoor5", true); ?
You did put it in OnStart() right?
Yes... There's nothing wrong with the names either I've checked it a lot of times I've even copy pasted old codes and changed the names and yet it wont work
Heres the entire code for the level
void Onstart()
{
AddUseItemCallback("", "key5", "water_door", "UsedKeyOnDoor5", true);
}
void UsedKeyOnDoor5(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("water_door", false, true);
PlaySoundAtEntity("", "unlock_door", "water_door", 0, false);
RemoveItem("key5");
}
void DoorLockedPlayer2(string &in entity)
{
if(GetSwingDoorLocked("metal_1") == true)
{
SetMessage("Messages", "msgname2", 0);
}
}
void OnEnter()
{
}
void OnLeave()
{
}
Does anyone see something that can cause this problem? I just can't figure it out -.-