mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-07-23 11:05:56 +02:00
mass replaced all methods to pascal case
This commit is contained in:
parent
ed0a0a58f7
commit
24f55139dd
179 changed files with 1585 additions and 1585 deletions
|
@ -52,66 +52,66 @@ namespace FFXIVClassic_Map_Server.Actors
|
|||
this.moveSpeeds[3] = SetActorSpeedPacket.DEFAULT_RUN;
|
||||
}
|
||||
|
||||
public SubPacket createAddActorPacket(uint playerActorId, byte val)
|
||||
public SubPacket CreateAddActorPacket(uint playerActorId, byte val)
|
||||
{
|
||||
return AddActorPacket.buildPacket(actorId, playerActorId, val);
|
||||
return AddActorPacket.BuildPacket(actorId, playerActorId, val);
|
||||
}
|
||||
|
||||
public SubPacket createNamePacket(uint playerActorId)
|
||||
public SubPacket CreateNamePacket(uint playerActorId)
|
||||
{
|
||||
return SetActorNamePacket.buildPacket(actorId, playerActorId, displayNameId, displayNameId == 0xFFFFFFFF | displayNameId == 0x0 ? customDisplayName : "");
|
||||
return SetActorNamePacket.BuildPacket(actorId, playerActorId, displayNameId, displayNameId == 0xFFFFFFFF | displayNameId == 0x0 ? customDisplayName : "");
|
||||
}
|
||||
|
||||
public SubPacket createSpeedPacket(uint playerActorId)
|
||||
public SubPacket CreateSpeedPacket(uint playerActorId)
|
||||
{
|
||||
return SetActorSpeedPacket.buildPacket(actorId, playerActorId);
|
||||
return SetActorSpeedPacket.BuildPacket(actorId, playerActorId);
|
||||
}
|
||||
|
||||
public SubPacket createSpawnPositonPacket(uint playerActorId, uint spawnType)
|
||||
public SubPacket CreateSpawnPositonPacket(uint playerActorId, uint spawnType)
|
||||
{
|
||||
SubPacket spawnPacket;
|
||||
if (!spawnedFirstTime && playerActorId == actorId)
|
||||
spawnPacket = SetActorPositionPacket.buildPacket(actorId, playerActorId, 0, positionX, positionY, positionZ, rotation, 0x1, false);
|
||||
spawnPacket = SetActorPositionPacket.BuildPacket(actorId, playerActorId, 0, positionX, positionY, positionZ, rotation, 0x1, false);
|
||||
else if (playerActorId == actorId)
|
||||
spawnPacket = SetActorPositionPacket.buildPacket(actorId, playerActorId, 0xFFFFFFFF, positionX, positionY, positionZ, rotation, spawnType, true);
|
||||
spawnPacket = SetActorPositionPacket.BuildPacket(actorId, playerActorId, 0xFFFFFFFF, positionX, positionY, positionZ, rotation, spawnType, true);
|
||||
else
|
||||
{
|
||||
if (this is Player)
|
||||
spawnPacket = SetActorPositionPacket.buildPacket(actorId, playerActorId, 0, positionX, positionY, positionZ, rotation, spawnType, false);
|
||||
spawnPacket = SetActorPositionPacket.BuildPacket(actorId, playerActorId, 0, positionX, positionY, positionZ, rotation, spawnType, false);
|
||||
else
|
||||
spawnPacket = SetActorPositionPacket.buildPacket(actorId, playerActorId, actorId, positionX, positionY, positionZ, rotation, spawnType, false);
|
||||
spawnPacket = SetActorPositionPacket.BuildPacket(actorId, playerActorId, actorId, positionX, positionY, positionZ, rotation, spawnType, false);
|
||||
}
|
||||
|
||||
//return SetActorPositionPacket.buildPacket(actorId, playerActorId, -211.895477f, 190.000000f, 29.651011f, 2.674819f, SetActorPositionPacket.SPAWNTYPE_PLAYERWAKE);
|
||||
//return SetActorPositionPacket.BuildPacket(actorId, playerActorId, -211.895477f, 190.000000f, 29.651011f, 2.674819f, SetActorPositionPacket.SPAWNTYPE_PLAYERWAKE);
|
||||
spawnedFirstTime = true;
|
||||
|
||||
return spawnPacket;
|
||||
}
|
||||
|
||||
public SubPacket createSpawnTeleportPacket(uint playerActorId, uint spawnType)
|
||||
public SubPacket CreateSpawnTeleportPacket(uint playerActorId, uint spawnType)
|
||||
{
|
||||
SubPacket spawnPacket;
|
||||
|
||||
spawnPacket = SetActorPositionPacket.buildPacket(actorId, playerActorId, 0xFFFFFFFF, positionX, positionY, positionZ, rotation, spawnType, false);
|
||||
spawnPacket = SetActorPositionPacket.BuildPacket(actorId, playerActorId, 0xFFFFFFFF, positionX, positionY, positionZ, rotation, spawnType, false);
|
||||
|
||||
//return SetActorPositionPacket.buildPacket(actorId, playerActorId, -211.895477f, 190.000000f, 29.651011f, 2.674819f, SetActorPositionPacket.SPAWNTYPE_PLAYERWAKE);
|
||||
//return SetActorPositionPacket.BuildPacket(actorId, playerActorId, -211.895477f, 190.000000f, 29.651011f, 2.674819f, SetActorPositionPacket.SPAWNTYPE_PLAYERWAKE);
|
||||
|
||||
spawnPacket.debugPrintSubPacket();
|
||||
spawnPacket.DebugPrintSubPacket();
|
||||
|
||||
return spawnPacket;
|
||||
}
|
||||
|
||||
public SubPacket createPositionUpdatePacket(uint playerActorId)
|
||||
public SubPacket CreatePositionUpdatePacket(uint playerActorId)
|
||||
{
|
||||
return MoveActorToPositionPacket.buildPacket(actorId, playerActorId, positionX, positionY, positionZ, rotation, moveState);
|
||||
return MoveActorToPositionPacket.BuildPacket(actorId, playerActorId, positionX, positionY, positionZ, rotation, moveState);
|
||||
}
|
||||
|
||||
public SubPacket createStatePacket(uint playerActorID)
|
||||
public SubPacket CreateStatePacket(uint playerActorID)
|
||||
{
|
||||
return SetActorStatePacket.buildPacket(actorId, playerActorID, currentMainState, currentSubState);
|
||||
return SetActorStatePacket.BuildPacket(actorId, playerActorID, currentMainState, currentSubState);
|
||||
}
|
||||
|
||||
public List<SubPacket> getEventConditionPackets(uint playerActorId)
|
||||
public List<SubPacket> GetEventConditionPackets(uint playerActorId)
|
||||
{
|
||||
List<SubPacket> subpackets = new List<SubPacket>();
|
||||
|
||||
|
@ -122,126 +122,126 @@ namespace FFXIVClassic_Map_Server.Actors
|
|||
if (eventConditions.talkEventConditions != null)
|
||||
{
|
||||
foreach (EventList.TalkEventCondition condition in eventConditions.talkEventConditions)
|
||||
subpackets.Add(SetTalkEventCondition.buildPacket(playerActorId, actorId, condition));
|
||||
subpackets.Add(SetTalkEventCondition.BuildPacket(playerActorId, actorId, condition));
|
||||
}
|
||||
|
||||
if (eventConditions.noticeEventConditions != null)
|
||||
{
|
||||
foreach (EventList.NoticeEventCondition condition in eventConditions.noticeEventConditions)
|
||||
subpackets.Add(SetNoticeEventCondition.buildPacket(playerActorId, actorId, condition));
|
||||
subpackets.Add(SetNoticeEventCondition.BuildPacket(playerActorId, actorId, condition));
|
||||
}
|
||||
|
||||
if (eventConditions.emoteEventConditions != null)
|
||||
{
|
||||
foreach (EventList.EmoteEventCondition condition in eventConditions.emoteEventConditions)
|
||||
subpackets.Add(SetEmoteEventCondition.buildPacket(playerActorId, actorId, condition));
|
||||
subpackets.Add(SetEmoteEventCondition.BuildPacket(playerActorId, actorId, condition));
|
||||
}
|
||||
|
||||
if (eventConditions.pushWithCircleEventConditions != null)
|
||||
{
|
||||
foreach (EventList.PushCircleEventCondition condition in eventConditions.pushWithCircleEventConditions)
|
||||
subpackets.Add(SetPushEventConditionWithCircle.buildPacket(playerActorId, actorId, condition));
|
||||
subpackets.Add(SetPushEventConditionWithCircle.BuildPacket(playerActorId, actorId, condition));
|
||||
}
|
||||
|
||||
if (eventConditions.pushWithFanEventConditions != null)
|
||||
{
|
||||
foreach (EventList.PushFanEventCondition condition in eventConditions.pushWithFanEventConditions)
|
||||
subpackets.Add(SetPushEventConditionWithFan.buildPacket(playerActorId, actorId, condition));
|
||||
subpackets.Add(SetPushEventConditionWithFan.BuildPacket(playerActorId, actorId, condition));
|
||||
}
|
||||
|
||||
if (eventConditions.pushWithBoxEventConditions != null)
|
||||
{
|
||||
foreach (EventList.PushBoxEventCondition condition in eventConditions.pushWithBoxEventConditions)
|
||||
subpackets.Add(SetPushEventConditionWithTriggerBox.buildPacket(playerActorId, actorId, condition));
|
||||
subpackets.Add(SetPushEventConditionWithTriggerBox.BuildPacket(playerActorId, actorId, condition));
|
||||
}
|
||||
|
||||
return subpackets;
|
||||
}
|
||||
|
||||
public BasePacket getSetEventStatusPackets(uint playerActorId)
|
||||
public BasePacket GetSetEventStatusPackets(uint playerActorId)
|
||||
{
|
||||
List<SubPacket> subpackets = new List<SubPacket>();
|
||||
|
||||
//Return empty list
|
||||
if (eventConditions == null)
|
||||
return BasePacket.createPacket(subpackets, true, false);
|
||||
return BasePacket.CreatePacket(subpackets, true, false);
|
||||
|
||||
if (eventConditions.talkEventConditions != null)
|
||||
{
|
||||
foreach (EventList.TalkEventCondition condition in eventConditions.talkEventConditions)
|
||||
subpackets.Add(SetEventStatus.buildPacket(playerActorId, actorId, true, 1, condition.conditionName));
|
||||
subpackets.Add(SetEventStatus.BuildPacket(playerActorId, actorId, true, 1, condition.conditionName));
|
||||
}
|
||||
|
||||
if (eventConditions.noticeEventConditions != null)
|
||||
{
|
||||
foreach (EventList.NoticeEventCondition condition in eventConditions.noticeEventConditions)
|
||||
subpackets.Add(SetEventStatus.buildPacket(playerActorId, actorId, true, 1, condition.conditionName));
|
||||
subpackets.Add(SetEventStatus.BuildPacket(playerActorId, actorId, true, 1, condition.conditionName));
|
||||
}
|
||||
|
||||
if (eventConditions.emoteEventConditions != null)
|
||||
{
|
||||
foreach (EventList.EmoteEventCondition condition in eventConditions.emoteEventConditions)
|
||||
subpackets.Add(SetEventStatus.buildPacket(playerActorId, actorId, true, 3, condition.conditionName));
|
||||
subpackets.Add(SetEventStatus.BuildPacket(playerActorId, actorId, true, 3, condition.conditionName));
|
||||
}
|
||||
|
||||
if (eventConditions.pushWithCircleEventConditions != null)
|
||||
{
|
||||
foreach (EventList.PushCircleEventCondition condition in eventConditions.pushWithCircleEventConditions)
|
||||
subpackets.Add(SetEventStatus.buildPacket(playerActorId, actorId, true, 2, condition.conditionName));
|
||||
subpackets.Add(SetEventStatus.BuildPacket(playerActorId, actorId, true, 2, condition.conditionName));
|
||||
}
|
||||
|
||||
if (eventConditions.pushWithFanEventConditions != null)
|
||||
{
|
||||
foreach (EventList.PushFanEventCondition condition in eventConditions.pushWithFanEventConditions)
|
||||
subpackets.Add(SetEventStatus.buildPacket(playerActorId, actorId, true, 2, condition.conditionName));
|
||||
subpackets.Add(SetEventStatus.BuildPacket(playerActorId, actorId, true, 2, condition.conditionName));
|
||||
}
|
||||
|
||||
if (eventConditions.pushWithBoxEventConditions != null)
|
||||
{
|
||||
foreach (EventList.PushBoxEventCondition condition in eventConditions.pushWithBoxEventConditions)
|
||||
subpackets.Add(SetEventStatus.buildPacket(playerActorId, actorId, true, 2, condition.conditionName));
|
||||
subpackets.Add(SetEventStatus.BuildPacket(playerActorId, actorId, true, 2, condition.conditionName));
|
||||
}
|
||||
|
||||
return BasePacket.createPacket(subpackets, true, false);
|
||||
return BasePacket.CreatePacket(subpackets, true, false);
|
||||
}
|
||||
|
||||
public SubPacket createIsZoneingPacket(uint playerActorId)
|
||||
public SubPacket CreateIsZoneingPacket(uint playerActorId)
|
||||
{
|
||||
return SetActorIsZoningPacket.buildPacket(actorId, playerActorId, false);
|
||||
return SetActorIsZoningPacket.BuildPacket(actorId, playerActorId, false);
|
||||
}
|
||||
|
||||
public virtual SubPacket createScriptBindPacket(uint playerActorId)
|
||||
public virtual SubPacket CreateScriptBindPacket(uint playerActorId)
|
||||
{
|
||||
return ActorInstantiatePacket.buildPacket(actorId, playerActorId, actorName, className, classParams);
|
||||
return ActorInstantiatePacket.BuildPacket(actorId, playerActorId, actorName, className, classParams);
|
||||
}
|
||||
|
||||
public virtual BasePacket getSpawnPackets(uint playerActorId)
|
||||
public virtual BasePacket GetSpawnPackets(uint playerActorId)
|
||||
{
|
||||
return getSpawnPackets(playerActorId, 0x1);
|
||||
return GetSpawnPackets(playerActorId, 0x1);
|
||||
}
|
||||
|
||||
public virtual BasePacket getSpawnPackets(uint playerActorId, uint spawnType)
|
||||
public virtual BasePacket GetSpawnPackets(uint playerActorId, uint spawnType)
|
||||
{
|
||||
List<SubPacket> subpackets = new List<SubPacket>();
|
||||
subpackets.Add(createAddActorPacket(playerActorId, 8));
|
||||
subpackets.AddRange(getEventConditionPackets(playerActorId));
|
||||
subpackets.Add(createSpeedPacket(playerActorId));
|
||||
subpackets.Add(createSpawnPositonPacket(playerActorId, spawnType));
|
||||
subpackets.Add(createNamePacket(playerActorId));
|
||||
subpackets.Add(createStatePacket(playerActorId));
|
||||
subpackets.Add(createIsZoneingPacket(playerActorId));
|
||||
subpackets.Add(createScriptBindPacket(playerActorId));
|
||||
return BasePacket.createPacket(subpackets, true, false);
|
||||
subpackets.Add(CreateAddActorPacket(playerActorId, 8));
|
||||
subpackets.AddRange(GetEventConditionPackets(playerActorId));
|
||||
subpackets.Add(CreateSpeedPacket(playerActorId));
|
||||
subpackets.Add(CreateSpawnPositonPacket(playerActorId, spawnType));
|
||||
subpackets.Add(CreateNamePacket(playerActorId));
|
||||
subpackets.Add(CreateStatePacket(playerActorId));
|
||||
subpackets.Add(CreateIsZoneingPacket(playerActorId));
|
||||
subpackets.Add(CreateScriptBindPacket(playerActorId));
|
||||
return BasePacket.CreatePacket(subpackets, true, false);
|
||||
}
|
||||
|
||||
public virtual BasePacket getInitPackets(uint playerActorId)
|
||||
public virtual BasePacket GetInitPackets(uint playerActorId)
|
||||
{
|
||||
SetActorPropetyPacket initProperties = new SetActorPropetyPacket("/_init");
|
||||
initProperties.addByte(0xE14B0CA8, 1);
|
||||
initProperties.addByte(0x2138FD71, 1);
|
||||
initProperties.addByte(0xFBFBCFB1, 1);
|
||||
initProperties.addTarget();
|
||||
return BasePacket.createPacket(initProperties.buildPacket(playerActorId, actorId), true, false);
|
||||
initProperties.AddByte(0xE14B0CA8, 1);
|
||||
initProperties.AddByte(0x2138FD71, 1);
|
||||
initProperties.AddByte(0xFBFBCFB1, 1);
|
||||
initProperties.AddTarget();
|
||||
return BasePacket.CreatePacket(initProperties.BuildPacket(playerActorId, actorId), true, false);
|
||||
}
|
||||
|
||||
public override bool Equals(Object obj)
|
||||
|
@ -253,50 +253,50 @@ namespace FFXIVClassic_Map_Server.Actors
|
|||
return actorId == actorObj.actorId;
|
||||
}
|
||||
|
||||
public string getName()
|
||||
public string GetName()
|
||||
{
|
||||
return actorName;
|
||||
}
|
||||
|
||||
public string getClassName()
|
||||
public string GetClassName()
|
||||
{
|
||||
return className;
|
||||
}
|
||||
|
||||
public ushort getState()
|
||||
public ushort GetState()
|
||||
{
|
||||
return currentMainState;
|
||||
}
|
||||
|
||||
public List<LuaParam> getLuaParams()
|
||||
public List<LuaParam> GetLuaParams()
|
||||
{
|
||||
return classParams;
|
||||
}
|
||||
|
||||
public void changeState(ushort newState)
|
||||
public void ChangeState(ushort newState)
|
||||
{
|
||||
currentMainState = newState;
|
||||
SubPacket changeStatePacket = SetActorStatePacket.buildPacket(actorId, actorId, newState, currentSubState);
|
||||
SubPacket battleActionPacket = BattleAction1Packet.buildPacket(actorId, actorId);
|
||||
zone.broadcastPacketAroundActor(this, changeStatePacket);
|
||||
zone.broadcastPacketAroundActor(this, battleActionPacket);
|
||||
SubPacket ChangeStatePacket = SetActorStatePacket.BuildPacket(actorId, actorId, newState, currentSubState);
|
||||
SubPacket battleActionPacket = BattleAction1Packet.BuildPacket(actorId, actorId);
|
||||
zone.BroadcastPacketAroundActor(this, ChangeStatePacket);
|
||||
zone.BroadcastPacketAroundActor(this, battleActionPacket);
|
||||
}
|
||||
|
||||
public void changeSpeed(int type, float value)
|
||||
public void ChangeSpeed(int type, float value)
|
||||
{
|
||||
moveSpeeds[type] = value;
|
||||
SubPacket changeSpeedPacket = SetActorSpeedPacket.buildPacket(actorId, actorId, moveSpeeds[0], moveSpeeds[1], moveSpeeds[2]);
|
||||
zone.broadcastPacketAroundActor(this, changeSpeedPacket);
|
||||
SubPacket ChangeSpeedPacket = SetActorSpeedPacket.BuildPacket(actorId, actorId, moveSpeeds[0], moveSpeeds[1], moveSpeeds[2]);
|
||||
zone.BroadcastPacketAroundActor(this, ChangeSpeedPacket);
|
||||
}
|
||||
|
||||
public void changeSpeed(float speedStop, float speedWalk, float speedRun)
|
||||
public void ChangeSpeed(float speedStop, float speedWalk, float speedRun)
|
||||
{
|
||||
moveSpeeds[0] = speedStop;
|
||||
moveSpeeds[1] = speedWalk;
|
||||
moveSpeeds[2] = speedRun;
|
||||
moveSpeeds[3] = speedRun;
|
||||
SubPacket changeSpeedPacket = SetActorSpeedPacket.buildPacket(actorId, actorId, moveSpeeds[0], moveSpeeds[1], moveSpeeds[2]);
|
||||
zone.broadcastPacketAroundActor(this, changeSpeedPacket);
|
||||
SubPacket ChangeSpeedPacket = SetActorSpeedPacket.BuildPacket(actorId, actorId, moveSpeeds[0], moveSpeeds[1], moveSpeeds[2]);
|
||||
zone.BroadcastPacketAroundActor(this, ChangeSpeedPacket);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue