05-06-2012, 01:28 AM
Hello I have a problem trying to load a map after the player have picked up its lantern and interacts with a door. so it looks something like this
void OnStart()
{
SetEntityPlayerInteractCallback("CastleGate", "StartMap", false);
}
void StartMap(string& asMapName, string& asStartPos)
{
if (HasItem("Lantern.ent") == true)
{
ChangeMap("01CastleBasement.map", "PlayerStartArea_1", "", "");
}
else
{
SetMessage("Messages", "FindItems", 4.0f);
}
}
Been awhile since I made this so might be way off, please help
Spoiler below!
void OnStart()
{
SetEntityPlayerInteractCallback("CastleGate", "StartMap", false);
}
void StartMap(string& asMapName, string& asStartPos)
{
if (HasItem("Lantern.ent") == true)
{
ChangeMap("01CastleBasement.map", "PlayerStartArea_1", "", "");
}
else
{
SetMessage("Messages", "FindItems", 4.0f);
}
}
Been awhile since I made this so might be way off, please help