From ae13db97ea770e37450e4e2c1a7919ce98d705a8 Mon Sep 17 00:00:00 2001 From: shennetsind Date: Thu, 28 Nov 2013 13:20:02 -0200 Subject: Follow up fdb6de1aa34086fd4d22ae127437727f556cea3c Modified reflect code so that each reflection source can judge whether to apply or not, necessary for mechanics such as item-bonus reflect triggers even on autoguard while reflect shield does not. Re-added that "reflect shield" overhead display which I mistakenly removed in fdb6de1aa34086fd4d22ae127437727f556cea3c. Added code to refrain damage numbers from overlapping in the client, which would render them illegible. Special Thanks to kyeme, Yommy. http://hercules.ws/board/tracker/issue-7792-safety-wall-reflect-bug-body-relocation-error/ Signed-off-by: shennetsind --- src/map/packets_struct.h | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) (limited to 'src/map/packets_struct.h') diff --git a/src/map/packets_struct.h b/src/map/packets_struct.h index 7e7f8bd87..df90b35a4 100644 --- a/src/map/packets_struct.h +++ b/src/map/packets_struct.h @@ -54,6 +54,11 @@ enum packet_headers { spawn_unit2Type = 0x7c, idle_unit2Type = 0x78, #endif +#if PACKETVER < 20071113 + damageType = 0x8a, +#else + damageType = 0x2e1, +#endif #if PACKETVER < 4 spawn_unitType = 0x79, #elif PACKETVER < 7 @@ -869,6 +874,27 @@ struct packet_graffiti_entry { char msg[80]; } __attribute__((packed)); +struct packet_damage { + short PacketType; + unsigned int GID; + unsigned int targetGID; + unsigned int startTime; + int attackMT; + int attackedMT; +#if PACKETVER < 20071113 + short damage; +#else + int damage; +#endif + short count; + unsigned char action; +#if PACKETVER < 20071113 + short leftDamage; +#else + int leftDamage; +#endif +} __attribute__((packed)); + #pragma pack(pop) #endif /* _PACKETS_STRUCT_H_ */ -- cgit v1.2.3-70-g09d2