summaryrefslogtreecommitdiff
path: root/src/net/eathena
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/eathena')
-rw-r--r--src/net/eathena/attendancehandler.cpp13
-rw-r--r--src/net/eathena/attendancehandler.h2
-rw-r--r--src/net/eathena/packetsout.inc13
3 files changed, 28 insertions, 0 deletions
diff --git a/src/net/eathena/attendancehandler.cpp b/src/net/eathena/attendancehandler.cpp
index ea53b71ab..538a72fc9 100644
--- a/src/net/eathena/attendancehandler.cpp
+++ b/src/net/eathena/attendancehandler.cpp
@@ -26,6 +26,8 @@
#include "debug.h"
extern int packetVersion;
+extern int packetVersionRe;
+extern int packetVersionMain;
namespace EAthena
{
@@ -48,4 +50,15 @@ void AttendanceHandler::openAttendanceWindow() const
outMsg.writeInt8(5, "window type");
}
+void AttendanceHandler::requestReward() const
+{
+ if (packetVersionRe < 20180307 &&
+ packetVersionMain < 20180404)
+ {
+ return;
+ }
+
+ createOutPacket(CMSG_ATTENDANCE_REWARD);
+}
+
} // namespace EAthena
diff --git a/src/net/eathena/attendancehandler.h b/src/net/eathena/attendancehandler.h
index 458f97db1..99c0d27d2 100644
--- a/src/net/eathena/attendancehandler.h
+++ b/src/net/eathena/attendancehandler.h
@@ -35,6 +35,8 @@ class AttendanceHandler final : public Net::AttendanceHandler
~AttendanceHandler() override final;
void openAttendanceWindow() const override final;
+
+ void requestReward() const override final;
};
} // namespace EAthena
diff --git a/src/net/eathena/packetsout.inc b/src/net/eathena/packetsout.inc
index 174e4571d..32c7bfe9e 100644
--- a/src/net/eathena/packetsout.inc
+++ b/src/net/eathena/packetsout.inc
@@ -332,6 +332,7 @@ packet(CMSG_MAIL2_CLOSE_MAILBOX, 0x0000, 0, nullptr);
packet(CMSG_MAIL2_CANCEL_WRITE_MAIL, 0x0000, 0, nullptr);
packet(CMSG_CLAN_MESSAGE, 0x0000, 0, nullptr);
packet(CMSG_WINDOW_OPEN_REQUEST2, 0x0000, 0, nullptr);
+packet(CMSG_ATTENDANCE_REWARD, 0x0000, 0, nullptr);
#else
// 20040713
if (packetVersion >= 20040713)
@@ -1338,4 +1339,16 @@ if (packetVersion >= 20170419)
packet(CMSG_MAIL2_REFRESH_MAIL_LIST, 0x0ac1, 26, clif->pRodexRefreshMaillist);
}
+// re 20180307
+if (packetVersionRe >= 20180307)
+{
+ packet(CMSG_ATTENDANCE_REWARD, 0x0aef, 2, clif->pAttendanceRewardRequest);
+}
+
+// main 20180404
+if (packetVersionMain >= 20180404)
+{
+ packet(CMSG_ATTENDANCE_REWARD, 0x0aef, 2, clif->pAttendanceRewardRequest);
+}
+
#endif