Refactored world server.

This commit is contained in:
Filip Maj 2017-06-27 17:31:17 -04:00
parent 9353f77db0
commit 516564a896
33 changed files with 83 additions and 83 deletions

View file

@ -58,7 +58,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
private const ushort SIZE_GAMEMESSAGE_WITHOUT_ACTOR4 = 0x48;
private const ushort SIZE_GAMEMESSAGE_WITHOUT_ACTOR5 = 0x68;
public static SubPacket BuildPacket(uint sourceId, uint targetId, uint actorId, uint textOwnerActorId, ushort textId, byte log)
public static SubPacket BuildPacket(uint sourceId, uint actorId, uint textOwnerActorId, ushort textId, byte log)
{
byte[] data = new byte[SIZE_GAMEMESSAGE_WITH_ACTOR1 - 0x20];
@ -73,10 +73,10 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
}
}
return new SubPacket(OPCODE_GAMEMESSAGE_WITH_ACTOR1, sourceId, targetId, data);
return new SubPacket(OPCODE_GAMEMESSAGE_WITH_ACTOR1, sourceId, data);
}
public static SubPacket BuildPacket(uint sourceId, uint targetId, uint actorId, uint textOwnerActorId, ushort textId, byte log, List<LuaParam> lParams)
public static SubPacket BuildPacket(uint sourceId, uint actorId, uint textOwnerActorId, ushort textId, byte log, List<LuaParam> lParams)
{
int lParamsSize = findSizeOfParams(lParams);
byte[] data;
@ -121,10 +121,10 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
}
}
return new SubPacket(opcode, sourceId, targetId, data);
return new SubPacket(opcode, sourceId, data);
}
public static SubPacket BuildPacket(uint sourceId, uint targetId, uint textOwnerActorId, ushort textId, string sender, byte log)
public static SubPacket BuildPacket(uint sourceId, uint textOwnerActorId, ushort textId, string sender, byte log)
{
byte[] data = new byte[SIZE_GAMEMESSAGE_WITH_CUSTOM_SENDER1 - 0x20];
@ -139,10 +139,10 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
}
}
return new SubPacket(OPCODE_GAMEMESSAGE_WITH_CUSTOM_SENDER1, sourceId, targetId, data);
return new SubPacket(OPCODE_GAMEMESSAGE_WITH_CUSTOM_SENDER1, sourceId, data);
}
public static SubPacket BuildPacket(uint sourceId, uint targetId, uint textOwnerActorId, ushort textId, string sender, byte log, List<LuaParam> lParams)
public static SubPacket BuildPacket(uint sourceId, uint textOwnerActorId, ushort textId, string sender, byte log, List<LuaParam> lParams)
{
int lParamsSize = findSizeOfParams(lParams);
byte[] data;
@ -187,10 +187,10 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
}
}
return new SubPacket(opcode, sourceId, targetId, data);
return new SubPacket(opcode, sourceId, data);
}
public static SubPacket BuildPacket(uint sourceId, uint targetId, uint textOwnerActorId, ushort textId, uint senderDisplayNameId, byte log)
public static SubPacket BuildPacket(uint sourceId, uint textOwnerActorId, ushort textId, uint senderDisplayNameId, byte log)
{
byte[] data = new byte[SIZE_GAMEMESSAGE_WITH_DISPID_SENDER1 - 0x20];
@ -205,10 +205,10 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
}
}
return new SubPacket(OPCODE_GAMEMESSAGE_WITH_DISPID_SENDER1, sourceId, targetId, data);
return new SubPacket(OPCODE_GAMEMESSAGE_WITH_DISPID_SENDER1, sourceId, data);
}
public static SubPacket BuildPacket(uint sourceId, uint targetId, uint textOwnerActorId, ushort textId, uint senderDisplayNameId, byte log, List<LuaParam> lParams)
public static SubPacket BuildPacket(uint sourceId, uint textOwnerActorId, ushort textId, uint senderDisplayNameId, byte log, List<LuaParam> lParams)
{
int lParamsSize = findSizeOfParams(lParams);
byte[] data;
@ -253,10 +253,10 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
}
}
return new SubPacket(opcode, sourceId, targetId, data);
return new SubPacket(opcode, sourceId, data);
}
public static SubPacket BuildPacket(uint sourceId, uint targetId, uint textOwnerActorId, ushort textId, byte log)
public static SubPacket BuildPacket(uint sourceId, uint textOwnerActorId, ushort textId, byte log)
{
byte[] data = new byte[SIZE_GAMEMESSAGE_WITHOUT_ACTOR1 - 0x20];
@ -270,10 +270,10 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
}
}
return new SubPacket(OPCODE_GAMEMESSAGE_WITHOUT_ACTOR1, sourceId, targetId, data);
return new SubPacket(OPCODE_GAMEMESSAGE_WITHOUT_ACTOR1, sourceId, data);
}
public static SubPacket BuildPacket(uint sourceId, uint targetId, uint textOwnerActorId, ushort textId, byte log, List<LuaParam> lParams)
public static SubPacket BuildPacket(uint sourceId, uint textOwnerActorId, ushort textId, byte log, List<LuaParam> lParams)
{
int lParamsSize = findSizeOfParams(lParams);
byte[] data;
@ -317,7 +317,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
}
}
return new SubPacket(opcode, sourceId, targetId, data);
return new SubPacket(opcode, sourceId, data);
}
private static int findSizeOfParams(List<LuaParam> lParams)

View file

@ -35,7 +35,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, sessionId, sessionId, data);
return new SubPacket(OPCODE, sessionId, data);
}
}
}

View file

@ -49,7 +49,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, playerActorID, playerActorID, data);
return new SubPacket(OPCODE, playerActorID, data);
}
}
}

View file

@ -38,7 +38,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, sessionId, sessionId, data);
return new SubPacket(OPCODE, sessionId, data);
}
}
}

View file

@ -56,7 +56,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, playerActorID, playerActorID, data);
return new SubPacket(OPCODE, playerActorID, data);
}
}
}

View file

@ -31,7 +31,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, playerActorID, playerActorID, data);
return new SubPacket(OPCODE, playerActorID, data);
}
}
}

View file

@ -31,7 +31,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, sessionId, sessionId, data);
return new SubPacket(OPCODE, sessionId, data);
}
}

View file

@ -48,7 +48,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, playerActorID, playerActorID, data);
return new SubPacket(OPCODE, playerActorID, data);
}
}
}

View file

@ -45,7 +45,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, playerActorID, playerActorID, data);
return new SubPacket(OPCODE, playerActorID, data);
}
}
}

View file

@ -45,7 +45,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, playerActorID, playerActorID, data);
return new SubPacket(OPCODE, playerActorID, data);
}
}
}

View file

@ -45,7 +45,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, playerActorID, playerActorID, data);
return new SubPacket(OPCODE, playerActorID, data);
}
}
}

View file

@ -36,7 +36,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
}
return new SubPacket(OPCODE, sessionId, sessionId, data);
return new SubPacket(OPCODE, sessionId, data);
}
}
}

View file

@ -195,14 +195,14 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets.Groups
}
public SubPacket buildPacket(uint playerActorID, uint actorID)
public SubPacket buildPacket(uint playerActorID)
{
binWriter.Seek(0x8, SeekOrigin.Begin);
binWriter.Write((byte)runningByteTotal);
closeStreams();
SubPacket packet = new SubPacket(OPCODE, playerActorID, actorID, data);
SubPacket packet = new SubPacket(OPCODE, playerActorID, data);
return packet;
}

View file

@ -51,7 +51,7 @@ namespace FFXIVClassic_World_Server.Packets.Send.Subpackets
}
}
return new SubPacket(OPCODE, playerActorID, targetID, data);
return new SubPacket(OPCODE, playerActorID, data);
}
}