fredgsanford
Member
- Joined
- Jan 2, 2015
- Messages
- 552
- Reaction score
- 0
I get a bit dif error and i tried to fix but no idea how my error is
ERROR: opening portal -> UNKNOWN
maybe something got changed that makes this not work now you will need to ask out or maybe he will see this and let us know what is up with it? relavent code is
Any idea what got broke or changed out or anyone else?
ERROR: opening portal -> UNKNOWN
maybe something got changed that makes this not work now you will need to ask out or maybe he will see this and let us know what is up with it? relavent code is
Code:
foreach (District dest in book.getDistricts())
{
if (dest.name == portalName)
{
// it comes into here but it never finds the portal name and therefor can't open it and throws unknown error.
Unmount();
Thread.Sleep(2000);
if (book.OpenPortal(portalName))
{
Log("Looking for portal");
DateTime startPortalSearch = DateTime.UtcNow;
while ((DateTime.UtcNow - startPortalSearch).TotalSeconds < 20)
{
foreach (var crea in getCreatures())
{
if (dist(crea) < 10 && crea.name == "Space Gate (Portal)" && crea.ownerUniqId == me.uniqId)
{
Log("Portal Info: " + crea.type + " " + crea.name + " ");
UsePortal(crea);
WaitTeleportCompleted(_MAX_TELEPORT_DELAY * 1000);
Thread.Sleep(5000);
break;
}
}
}
foundIt = true;
}
else
{
Log("ERROR: opening portal -> " + GetLastError());
}