Asterix Gaming Guild Logo General XXL XXL 2 Olympic Games XXL Speedrun XXL Romaster Speedrun XXL 2 Speedrun XXL 2 Remaster Speedrun XXL 3 Speedrun Olympic Games Speedrun Retro Other Astérix Games Other Games Modding Media Videos Streams Creative Shack Spoofy Goofs VC-Text Village Gates Introductions UXXL Downloads Wiki Bot Spam Feedback Announcements Patches Tools Resources Caesar's challenge Help Noxus94 SPQR Mr. Rubinstein

#modding

Page: << <  49 / 511  >  >>
TimeUserText
Deleted Userwhere did you find the class names?
Deleted Userdoes the engine have some sort of reflection like unreal engine?
AdrienTDThe class names were the more interesting and ground breaking parts 😃
AdrienTDThere are some class names left in the EXE
AdrienTDAnd that's because the engine has some way to identify classes
AdrienTDWhen the game is started, it will run several code that will register these classes.
AdrienTD
AdrienTDFor example this will call a function that will register the class CKSpeechManager.
AdrienTDThe first two arguments are IDs for this call.
AdrienTDSo the game can refer to a class by their ID, which is the case in the game files.
AdrienTDAlso it associates to the class functions that will create an instance of this class, and functions to destroy ones, which happen to be the same for all classes (DestroyKCL1/2 in the screenshot)
AdrienTDActually, the destructor just calls the virtual destructor from the vft.
AdrienTDAlso all the registered classes are subclasses to a common class. In my XXL inspector I call it KClass: ```C++ struct KClass { virtual void destructor_placeholder() = 0; virtual char isSubclass(int cls) = 0; virtual void unknown1() = 0; #if XXLVER >= 2 virtual void unknown2() = 0; #endif virtual int getClassGroup() = 0; virtual int getClassID() = 0; } ```
Deleted Useryeah it's similar in unreal engine
AdrienTDI have never used Unreal Engine, but nice to learn this.
AdrienTDThe KClass also has virtual functions for saving and loading from KWN files.
AdrienTDSo often KWN files are just files containing serialized instances of these registered classes.
Deleted Userhttps://www.unrealengine.com/en-US/blog/unreal-property-system-reflection
AdrienTDLooks more complicated in Unreal than in XXL 😄
AdrienTDI see Unreal also has names for data members and functions