Batch #10274 by ragnarok-clanker: forced by an admin (3 lower score(s), 9 changed function(s)); checked with 348 compiled unit(s), including every includer of Source/Client/Mode/CGameMode.h, Source/Client/Session.h, Source/UI/Shortcuts/ShortcutCooldowns.h.
46 lines
1.7 KiB
C++
46 lines
1.7 KiB
C++
#ifndef RAGNAROK_SOURCE_UI_SHORTCUTS_SHORTCUTCOOLDOWNS_H
|
|
#define RAGNAROK_SOURCE_UI_SHORTCUTS_SHORTCUTCOOLDOWNS_H
|
|
|
|
#include "UI/Cooldowns/CooldownDrawing.h"
|
|
|
|
#include <cstddef>
|
|
#include <list>
|
|
|
|
struct ShortcutCooldownIcon {
|
|
/* 0000 */ unsigned id;
|
|
/* 0004 */ int slot;
|
|
/* 0008 */ int x;
|
|
/* 000C */ int y;
|
|
};
|
|
|
|
struct ShortcutCooldownRecord {
|
|
/* 0000 */ unsigned id;
|
|
/* 0004 */ std::uint32_t end;
|
|
/* 0008 */ std::uint32_t duration;
|
|
/* 000C */ std::list<CooldownState> main;
|
|
/* 0014 */ std::list<CooldownState> alternate;
|
|
};
|
|
|
|
bool RotateCooldownRows(std::list<ShortcutCooldownRecord>& records, int amount, int bank, int& rotation0, int& rotation1);
|
|
void PaintMainCooldowns(
|
|
std::list<ShortcutCooldownRecord>& records, const std::list<ShortcutCooldownIcon>& icons, int rows, int x, int y, CooldownDrawing& drawing
|
|
);
|
|
void PaintAlternateCooldowns(
|
|
std::list<ShortcutCooldownRecord>& records, const std::list<ShortcutCooldownIcon>& icons, int x, int y, CooldownDrawing& drawing
|
|
);
|
|
|
|
static_assert(sizeof(ShortcutCooldownIcon) == 16);
|
|
#if defined(_WIN32) && !defined(_WIN64)
|
|
static_assert(sizeof(ShortcutCooldownRecord) == 28);
|
|
static_assert(offsetof(ShortcutCooldownIcon, id) == 0x0000);
|
|
static_assert(offsetof(ShortcutCooldownIcon, slot) == 0x0004);
|
|
static_assert(offsetof(ShortcutCooldownIcon, x) == 0x0008);
|
|
static_assert(offsetof(ShortcutCooldownIcon, y) == 0x000C);
|
|
static_assert(offsetof(ShortcutCooldownRecord, id) == 0x0000);
|
|
static_assert(offsetof(ShortcutCooldownRecord, end) == 0x0004);
|
|
static_assert(offsetof(ShortcutCooldownRecord, duration) == 0x0008);
|
|
static_assert(offsetof(ShortcutCooldownRecord, main) == 0x000C);
|
|
static_assert(offsetof(ShortcutCooldownRecord, alternate) == 0x0014);
|
|
#endif
|
|
|
|
#endif
|