mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-05-20 08:26:59 -04:00
Added two callbacks to the Director; onTalked and onCommand. Split the command and event starts and keep track of them separately.
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using FFXIVClassic_Lobby_Server.packets;
|
||||
using FFXIVClassic_Map_Server.Actors;
|
||||
using FFXIVClassic_Map_Server.lua;
|
||||
using FFXIVClassic_Map_Server.packets.send.actor;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -10,10 +11,12 @@ using System.Threading.Tasks;
|
||||
namespace FFXIVClassic_Map_Server.actors.director
|
||||
{
|
||||
class Director : Actor
|
||||
{
|
||||
public Director(uint id) : base(id)
|
||||
{
|
||||
{
|
||||
Player owner;
|
||||
|
||||
public Director(Player owner, uint id) : base(id)
|
||||
{
|
||||
this.owner = owner;
|
||||
}
|
||||
|
||||
public virtual BasePacket getSpawnPackets(uint playerActorId, uint spawnType)
|
||||
@@ -37,5 +40,15 @@ namespace FFXIVClassic_Map_Server.actors.director
|
||||
return BasePacket.createPacket(initProperties.buildPacket(playerActorId, actorId), true, false);
|
||||
}
|
||||
|
||||
public void onTalked(Npc npc)
|
||||
{
|
||||
LuaEngine.doDirectorOnTalked(this, owner, npc);
|
||||
}
|
||||
|
||||
public void onCommand(Command command)
|
||||
{
|
||||
LuaEngine.doDirectorOnCommand(this, owner, command);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -1,4 +1,5 @@
|
||||
using FFXIVClassic_Lobby_Server.packets;
|
||||
using FFXIVClassic_Map_Server.Actors;
|
||||
using FFXIVClassic_Map_Server.lua;
|
||||
using FFXIVClassic_Map_Server.packets.send.actor;
|
||||
using System;
|
||||
@@ -11,7 +12,7 @@ namespace FFXIVClassic_Map_Server.actors.director
|
||||
{
|
||||
class OpeningDirector : Director
|
||||
{
|
||||
public OpeningDirector(uint id) : base(id)
|
||||
public OpeningDirector(Player player, uint id) : base(player, id)
|
||||
{
|
||||
this.displayNameId = 0;
|
||||
this.customDisplayName = "openingDire";
|
||||
|
@@ -15,8 +15,8 @@ namespace FFXIVClassic_Map_Server.Actors
|
||||
{
|
||||
private uint weatherId;
|
||||
|
||||
public WeatherDirector(uint weatherId)
|
||||
: base(0x5FF80003)
|
||||
public WeatherDirector(Player player, uint weatherId)
|
||||
: base(player, 0x5FF80003)
|
||||
{
|
||||
this.weatherId = weatherId;
|
||||
|
||||
|
@@ -1,4 +1,5 @@
|
||||
using FFXIVClassic_Lobby_Server.packets;
|
||||
using FFXIVClassic_Map_Server.Actors;
|
||||
using FFXIVClassic_Map_Server.lua;
|
||||
using FFXIVClassic_Map_Server.packets.send.actor;
|
||||
using System;
|
||||
@@ -11,7 +12,8 @@ namespace FFXIVClassic_Map_Server.actors.director
|
||||
{
|
||||
class QuestDirectorMan0l001 : Director
|
||||
{
|
||||
public QuestDirectorMan0l001(uint id) : base(id)
|
||||
public QuestDirectorMan0l001(Player player, uint id)
|
||||
: base(player, id)
|
||||
{
|
||||
this.displayNameId = 0;
|
||||
this.customDisplayName = "questDirect_ocn0Btl02_01";
|
||||
|
Reference in New Issue
Block a user