mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-06-10 14:34:32 +02:00
More static actors loaded and can be accessed anywhere. Improved lua scripting to allow small talk.
This commit is contained in:
parent
300748668f
commit
789df97d48
16 changed files with 882 additions and 28 deletions
|
@ -1,4 +1,5 @@
|
|||
using FFXIVClassic_Lobby_Server.packets;
|
||||
using FFXIVClassic_Lobby_Server;
|
||||
using FFXIVClassic_Lobby_Server.packets;
|
||||
using FFXIVClassic_Map_Server.Actors;
|
||||
using FFXIVClassic_Map_Server.dataobjects;
|
||||
using FFXIVClassic_Map_Server.packets.receive.events;
|
||||
|
@ -35,6 +36,7 @@ namespace FFXIVClassic_Map_Server.lua
|
|||
if (File.Exists(luaPath))
|
||||
{
|
||||
Script script = new Script();
|
||||
script.Globals["getStaticActor"] = (Func<string, Actor>)Server.getStaticActors;
|
||||
script.DoFile(luaPath);
|
||||
DynValue result = script.Call(script.Globals["onInstantiate"], player, target);
|
||||
List<LuaParam> lparams = LuaUtils.createLuaParamList(result);
|
||||
|
@ -51,8 +53,7 @@ namespace FFXIVClassic_Map_Server.lua
|
|||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public void doActorOnEventStarted(Player player, Actor target)
|
||||
{
|
||||
|
@ -64,6 +65,7 @@ namespace FFXIVClassic_Map_Server.lua
|
|||
if (File.Exists(luaPath))
|
||||
{
|
||||
Script script = new Script();
|
||||
script.Globals["getStaticActor"] = (Func<string, Actor>)Server.getStaticActors;
|
||||
script.DoFile(luaPath);
|
||||
DynValue result = script.Call(script.Globals["onEventStarted"], player, target);
|
||||
}
|
||||
|
@ -81,6 +83,7 @@ namespace FFXIVClassic_Map_Server.lua
|
|||
if (File.Exists(luaPath))
|
||||
{
|
||||
Script script = new Script();
|
||||
script.Globals["getStaticActor"] = (Func<string, Actor>)Server.getStaticActors;
|
||||
script.DoFile(luaPath);
|
||||
DynValue result = script.Call(script.Globals["onEventStarted"], player, target);
|
||||
}
|
||||
|
@ -104,6 +107,7 @@ namespace FFXIVClassic_Map_Server.lua
|
|||
if (File.Exists(luaPath))
|
||||
{
|
||||
Script script = new Script();
|
||||
script.Globals["getStaticActor"] = (Func<string, Actor>)Server.getStaticActors;
|
||||
script.DoFile(luaPath);
|
||||
DynValue result = script.Call(script.Globals["onEventUpdate"], player, target, eventUpdate.step, eventUpdate.luaParams);
|
||||
}
|
||||
|
@ -121,6 +125,7 @@ namespace FFXIVClassic_Map_Server.lua
|
|||
if (File.Exists(luaPath))
|
||||
{
|
||||
Script script = new Script();
|
||||
script.Globals["getStaticActor"] = (Func<string, Actor>)Server.getStaticActors;
|
||||
script.DoFile(luaPath);
|
||||
|
||||
//Have to do this to combine LuaParams
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue