Realized the start event packet after a zoneIn kickevent is weird and malformed, fixed for that usecase. Fixed bug with getting PrivateArea script. Missing area scripts now don't show a message (they were optional). Finished scripting out Limsa opening battle.

This commit is contained in:
Filip Maj 2017-03-19 11:39:21 -04:00
parent 545ce18f1f
commit 77e0639410
3 changed files with 9 additions and 4 deletions

View File

@ -21,6 +21,7 @@ namespace FFXIVClassic_Map_Server.actors.area
: base(id, parent.zoneName, parent.regionId, className, bgmDay, bgmNight, bgmBattle, parent.isIsolated, parent.isInn, parent.canRideChocobo, parent.canStealth, true)
{
this.parentZone = parent;
this.zoneName = parent.zoneName;
this.privateAreaName = privateAreaName;
this.privateAreaType = privateAreaType;
}

View File

@ -139,7 +139,7 @@ namespace FFXIVClassic_Map_Server.lua
}
else if (target is Area)
{
return String.Format(FILEPATH_ZONE, ((Zone)target).zoneName);
return String.Format(FILEPATH_ZONE, ((Area)target).zoneName);
}
else
return "";
@ -288,6 +288,7 @@ namespace FFXIVClassic_Map_Server.lua
}
else
{
if (!(target is Area))
SendError(player, String.Format("ERROR: Could not find script for actor {0}.", target.GetName()));
}
}
@ -467,7 +468,7 @@ namespace FFXIVClassic_Map_Server.lua
//script.Call(script.Globals["onTrigger"], LuaParam.ToArray());
Coroutine coroutine = script.CreateCoroutine(script.Globals["onTrigger"]).Coroutine;
DynValue value = coroutine.Resume(player, LuaParam.ToArray());
DynValue value = coroutine.Resume(LuaParam.ToArray());
GetInstance().ResolveResume(player, coroutine, value);
return;
}

View File

@ -63,6 +63,9 @@ namespace FFXIVClassic_Map_Server.packets.receive.events
binReader.BaseStream.Seek(0x31, SeekOrigin.Begin);
if (binReader.PeekChar() == 0x1)
luaParams = new List<LuaParam>();
else
luaParams = LuaUtils.ReadLuaParams(binReader);
}
catch (Exception){