rodecomp/Source/Contents/JobCodeForItem.h
ragnarok-clanker 27a03ce3ea Decompile 4 functions in Source/Contents/JobCodeForItem.cpp, Source/Contents/JobCodeForItem.h
Batch #6081 by eAthena: 1 byte-identical, 3 confirmed by peer review.

- fn_06464 CJobCodeForItem::InitJobGroups: logic confirmed by peer review
- fn_06465 CJobCodeForItem::InitJobCodes: logic confirmed by peer review
- fn_06466 CJobCodeForItem::Init: byte-identical
- fn_06467 CJobCodeForItem::IsJobAllowed: logic confirmed by peer review

Peer-reviewed-by: ragnarok-clanker, Lumen, Snow
Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
2026-10-30 19:42:25 +00:00

31 lines
847 B
C++

#ifndef RAGNAROK_SOURCE_CONTENTS_JOBCODEFORITEM_H
#define RAGNAROK_SOURCE_CONTENTS_JOBCODEFORITEM_H
#include "Utility/Singleton.h"
#include <map>
#include <set>
class CJobCodeForItem : public Singleton<CJobCodeForItem> {
public:
/* 0004 */ std::map<unsigned int, std::set<int>> m_jobGroups;
/* 000C */ std::map<unsigned long, std::set<int>> m_jobCodes;
template <typename... Groups>
void AddJobCodeFromGroups(unsigned long code, Groups... groups);
template <typename... Jobs>
void AddJobCode(unsigned long code, Jobs... jobs);
template <typename... Jobs>
void AddJobGroup(unsigned int group, Jobs... jobs);
void InitJobGroups();
void InitJobCodes();
void Init();
bool IsJobAllowed(int job, unsigned long code);
};
#if defined(_WIN32) && !defined(_WIN64)
static_assert(sizeof(CJobCodeForItem) == 0x14);
#endif
#endif