scripts backup

This commit is contained in:
EricPlayZ
2025-03-05 03:34:37 +02:00
parent 65553c05f9
commit 5182263775
12 changed files with 1029 additions and 56498 deletions

View File

@ -1,69 +1,26 @@
import os
import struct
import idc
import idaapi
import idautils
import ida_hexrays
import ida_nalt
import ida_bytes
import ida_ida
import struct
import re
from typing import Optional, Tuple
import cloudpickle
from dataclasses import dataclass, field
from typing import Optional
IDA_NALT_ENCODING = ida_nalt.get_default_encoding_idx(ida_nalt.BPU_1B)
CLASS_TYPES = ("class", "struct", "enum", "union")
FUNC_QUALIFIERS = ("virtual", "static")
# Configuration
INTERNAL_SCRIPT_NAME = "ExportClassToCPPH"
PROJECT_FOLDER = r"D:\PROJECTS\Visual Studio\EGameSDK\EGameSDK\include"
OUTPUT_FOLDER = r"D:\PROJECTS\Visual Studio\EGameSDK\EGameSDK\proxies\engine_x64_rwdi\scripts\generated"
CACHE_FOLDER = r"D:\PROJECTS\Visual Studio\EGameSDK\EGameSDK\proxies\engine_x64_rwdi\scripts\cache"
GENERATE_CLASS_DEFS_MISSING_TYPES = False # Flag to generate full class definitions for missing types, or just forward declare if false
SEARCH_CLASS_DEFS_IN_PROJECT_FOLDER = False # Flag to search for missing class types in the PROJECT_FOLDER
virtualFuncPlaceholderCounter: int = 0 # Counter for placeholder virtual functions
virtualFuncDuplicateCounter: dict[str, int] = {} # Counter for duplicate virtual functions
def PrintMsg(*args):
#ida_kernwin.msg(f"[{INTERNAL_SCRIPT_NAME}] {args}")
print(f"[{INTERNAL_SCRIPT_NAME}] {args}")
# -----------------------------------------------------------------------------
# String and type formatting utilities
# -----------------------------------------------------------------------------
def FixTypeSpacing(type: str) -> str:
"""Fix spacing for pointers/references, commas, and angle brackets."""
type = re.sub(r'\s+([*&])', r'\1', type) # Remove space before '*' or '&'
type = re.sub(r'([*&])(?!\s)', r'\1 ', type) # Ensure '*' or '&' is followed by one space if it's not already.
type = re.sub(r'\s*,\s*', ', ', type) # Ensure comma followed by one space
type = re.sub(r'<\s+', '<', type) # Remove space after '<'
type = re.sub(r'\s+>', '>', type) # Remove space before '>'
type = re.sub(r'\s+', ' ', type) # Collapse multiple spaces
return type.strip()
def CleanType(type: str) -> str:
"""Remove unwanted tokens from a type string, then fix spacing."""
type = re.sub(r'\b(__cdecl|__fastcall|__ptr64|class|struct|enum|union)\b', '', type)
return FixTypeSpacing(type)
def ReplaceIDATypes(type: str) -> str:
"""Replace IDA types with normal ones"""
return type.replace("_QWORD", "uint64_t").replace("__int64", "int64_t").replace("unsigned int", "uint32_t")
def ExtractTypesFromString(types: str) -> list[str]:
"""Extract potential type names from a string."""
# Remove pointer/reference symbols and qualifiers
cleanedTypes: str = types.replace("*", " ").replace("&", " ")
cleanedTypesList: list[str] = re.findall(r"[A-Za-z_][\w:]*", cleanedTypes)
return cleanedTypesList
# -----------------------------------------------------------------------------
# Various class implementations
# -----------------------------------------------------------------------------
idaapi.require("ExportClassToCPPH")
from ExportClassToCPPH import Utils, Config
def reconstruct_ClassName(namespaces, name, namespacedName, fullName, type_str):
# Bypass __init__ by creating a new instance directly.
obj = object.__new__(ClassName)
object.__setattr__(obj, "namespaces", namespaces)
object.__setattr__(obj, "name", name)
object.__setattr__(obj, "namespacedName", namespacedName)
object.__setattr__(obj, "fullName", fullName)
object.__setattr__(obj, "type", type_str)
return obj
@dataclass(frozen=True)
class ClassName:
"""Split a potentially namespaced class name into namespace parts and class name."""
@ -85,12 +42,12 @@ class ClassName:
return
object.__setattr__(self, "fullName", fullName)
types = ExtractTypesFromString(fullName)
types = Utils.ExtractTypesFromString(fullName)
if len(types) > 1:
if (types[0] in CLASS_TYPES):
if (types[0] in Utils.CLASS_TYPES):
object.__setattr__(self, "type", types[0])
fullName = types[1]
elif (len(types) > 2 and types[0] in FUNC_QUALIFIERS and types[1] in CLASS_TYPES):
elif (len(types) > 2 and types[0] in Utils.FUNC_QUALIFIERS and types[1] in Utils.CLASS_TYPES):
object.__setattr__(self, "type", types[1])
fullName = types[2]
else:
@ -104,7 +61,25 @@ class ClassName:
object.__setattr__(self, "namespaces", tuple(parts[:-1]))
object.__setattr__(self, "name", parts[-1])
object.__setattr__(self, "namespacedName", f"{'::'.join(self.namespaces)}::{self.name}")
def __reduce__(self):
return (reconstruct_ClassName, (self.namespaces, self.name, self.namespacedName, self.fullName, self.type))
virtualFuncPlaceholderCounter: int = 0 # Counter for placeholder virtual functions
virtualFuncDuplicateCounter: dict[str, int] = {} # Counter for duplicate virtual functions
def reconstruct_ParsedFunction(fullFuncSig, type, access, returnType, className, funcName, params, const):
# Bypass __init__ by creating a new instance directly.
obj = object.__new__(ParsedFunction)
object.__setattr__(obj, "fullFuncSig", fullFuncSig)
object.__setattr__(obj, "type", type)
object.__setattr__(obj, "access", access)
object.__setattr__(obj, "returnType", returnType)
object.__setattr__(obj, "className", className)
object.__setattr__(obj, "funcName", funcName)
object.__setattr__(obj, "params", params)
object.__setattr__(obj, "const", const)
return obj
@dataclass(frozen=True)
class ParsedFunction:
"""Parse a demangled function signature and return an instance."""
@ -222,15 +197,25 @@ class ParsedFunction:
else:
returnType = remainingInputBeforeParamsParen
if funcName.startswith("~"):
return
if isDuplicateFunc:
if signature not in virtualFuncDuplicateCounter:
virtualFuncDuplicateCounter[signature] = 0
virtualFuncDuplicateCounter[signature] += 1
funcName = f"_{funcName}{virtualFuncDuplicateCounter[signature]}"
type = "func" if not (onlyVirtualFuncs or "virtual" in returnType) else ("basic_vfunc" if isIDAGeneratedType or isIDAGeneratedTypeParsed or isDuplicateFunc else "vfunc")
if onlyVirtualFuncs:
if isIDAGeneratedType or isIDAGeneratedTypeParsed or isDuplicateFunc or "virtual" not in returnType:
type = "basic_vfunc"
else:
type = "vfunc"
else:
if "virtual" not in returnType:
type = "func"
elif isIDAGeneratedType or isIDAGeneratedTypeParsed or isDuplicateFunc:
type = "basic_vfunc"
else:
type = "vfunc"
#type = "func" if not (onlyVirtualFuncs or "virtual" in returnType) else ("basic_vfunc" if isIDAGeneratedType or isIDAGeneratedTypeParsed or isDuplicateFunc else "vfunc")
object.__setattr__(self, "type", type)
object.__setattr__(self, "access", access if access else "public")
object.__setattr__(self, "returnType", ClassName(returnType) if returnType else None)
@ -247,7 +232,18 @@ class ParsedFunction:
object.__setattr__(self, "access", access if access else "public")
object.__setattr__(self, "returnType", ClassName("virtual void"))
object.__setattr__(self, "funcName", f"_StrippedVFunc{virtualFuncPlaceholderCounter}")
def __reduce__(self):
return (reconstruct_ParsedFunction, (self.fullFuncSig, self.type, self.access, self.returnType, self.className, self.funcName, self.params, self.const))
def reconstruct_ParsedClassVar(access, varType, className, varName):
# Bypass __init__ by creating a new instance directly.
obj = object.__new__(ParsedClassVar)
object.__setattr__(obj, "access", access)
object.__setattr__(obj, "varType", varType)
object.__setattr__(obj, "className", className)
object.__setattr__(obj, "varName", varName)
return obj
@dataclass(frozen=True)
class ParsedClassVar:
"""Parse a demangled global class var signature and return an instance."""
@ -257,156 +253,65 @@ class ParsedClassVar:
varName: str = ""
def __init__(self, signature: str):
# Initialize defaults.
object.__setattr__(self, "access", "")
object.__setattr__(self, "varType", None)
object.__setattr__(self, "className", None)
object.__setattr__(self, "varName", "")
signature = signature.strip()
access: str = ""
if signature.startswith("public:"):
access = "public"
elif signature.startswith("protected:"):
access = "protected"
elif signature.startswith("private:"):
access = "private"
signature = signature.removeprefix(f"{access}:").strip()
# Extract access specifier.
access = ""
for kw in ("public:", "protected:", "private:"):
if signature.startswith(kw):
access = kw[:-1] # remove the colon
signature = signature[len(kw):].strip()
break
# Find parameters and const qualifier
paramsOpenParenIndex: int = signature.find('(')
paramsCloseParenIndex: int = signature.rfind(')')
if paramsOpenParenIndex == -1 and paramsCloseParenIndex == -1:
varType: str = ""
classAndVarName: str = ""
className: str = ""
varName: str = ""
# Find the last space outside of angle brackets
lastSpaceIndex: int = -1
lastClassSeparatorIndex: int = -1
templateDepth: int = 0
for i in range(len(signature)):
if signature[i] == '<':
templateDepth += 1
elif signature[i] == '>':
templateDepth -= 1
elif templateDepth == 0 and signature[i] == ' ':
lastSpaceIndex = i
if lastSpaceIndex != -1:
# Split at the last space outside angle brackets
varType = signature[:lastSpaceIndex].strip()
classAndVarName = signature[lastSpaceIndex+1:].strip()
templateDepth = 0
# Find the last class separator outside of angle brackets
for i in range(len(classAndVarName)):
if classAndVarName[i] == '<':
templateDepth += 1
elif classAndVarName[i] == '>':
templateDepth -= 1
elif templateDepth == 0 and classAndVarName[i:i+2] == '::':
lastClassSeparatorIndex = i
if lastClassSeparatorIndex != -1:
className = classAndVarName[:lastClassSeparatorIndex]
varName = classAndVarName[lastClassSeparatorIndex+2:]
else:
className = "::".join(classAndVarName.split("::")[:-1])
varName = classAndVarName.split("::")[-1]
# For class variables, we expect no parameters (i.e. no parentheses).
if signature.find('(') == -1 and signature.rfind(')') == -1:
# Use a backward search to find the last space outside templates.
last_space = Utils.FindLastSpaceOutsideTemplates(signature)
if last_space != -1:
varType = signature[:last_space].strip()
classAndVarName = signature[last_space+1:].strip()
else:
templateDepth = 0
# Find the last class separator outside of angle brackets
for i in range(len(signature)):
if signature[i] == '<':
templateDepth += 1
elif signature[i] == '>':
templateDepth -= 1
elif templateDepth == 0 and signature[i:i+2] == '::':
lastClassSeparatorIndex = i
# If no space, assume there's no varType
varType = ""
classAndVarName = signature
# Find the last "::" separator outside templates.
last_sep = Utils.FindLastClassSeparatorOutsideTemplates(classAndVarName)
if last_sep != -1:
class_name_str = classAndVarName[:last_sep].strip()
var_name = classAndVarName[last_sep+2:].strip()
else:
# Fallback: if there are "::" tokens, split them; otherwise, take entire string as varName.
parts = classAndVarName.split("::")
if len(parts) > 1:
class_name_str = "::".join(parts[:-1]).strip()
var_name = parts[-1].strip()
else:
class_name_str = ""
var_name = classAndVarName.strip()
if lastClassSeparatorIndex != -1:
classAndVarName: str = signature
className: str = classAndVarName[:lastClassSeparatorIndex]
varName: str = classAndVarName[lastClassSeparatorIndex+2:]
object.__setattr__(self, "access", access if access else "public")
object.__setattr__(self, "varType", ClassName(varType) if varType else None)
object.__setattr__(self, "className", ClassName(className) if className else None)
object.__setattr__(self, "varName", varName)
object.__setattr__(self, "className", ClassName(class_name_str) if class_name_str else None)
object.__setattr__(self, "varName", var_name)
return
def __reduce__(self):
return (reconstruct_ParsedClassVar, (self.access, self.varType, self.className, self.varName))
# Global caches
parsedClassVarsByClass: dict[ClassName, list[ParsedClassVar]] = {} # Cache of parsed class vars by class name
parsedVTableFuncsByClass: dict[ClassName, list[ParsedFunction]] = {} # Cache of parsed functions by class name
parsedFuncsByClass: dict[ClassName, list[ParsedFunction]] = {} # Cache of parsed functions by class name
unparsedExportedSigs: list[str] = []
allClassVarsAreParsed = False # Flag to indicate if all class vars have been parsed
allFuncsAreParsed = False # Flag to indicate if all functions have been parsed
processedClasses: set[ClassName] = set() # Track classes we've already processed to avoid recursion
template_class_info = {} # Store information about detected template classes
# -----------------------------------------------------------------------------
# IDA util functions
# -----------------------------------------------------------------------------
def DemangleSig(sig: str) -> str:
return idaapi.demangle_name(sig, idaapi.MNG_LONG_FORM)
def GetMangledTypePrefix(targetClass: ClassName) -> str:
"""
Get the appropriate mangled type prefix for a class name.
For class "X" this would be ".?AVX@@"
For class "NS::X" this would be ".?AVX@NS@@"
For templated classes, best to use get_mangled_name_for_template instead.
"""
if not targetClass.namespaces:
return f".?AV{targetClass.name}@@"
# For namespaced classes, the format is .?AVClassName@Namespace@@
# For nested namespaces, they are separated with @ in reverse order
mangledNamespaces = "@".join(reversed(targetClass.namespaces))
return f".?AV{targetClass.name}@{mangledNamespaces}@@"
# -----------------------------------------------------------------------------
# IDA pattern search utilities
# -----------------------------------------------------------------------------
def BytesToIDAPattern(data: bytes) -> str:
"""Convert bytes to IDA-friendly hex pattern string."""
return " ".join("{:02X}".format(b) for b in data)
def GetSectionInfo(sectionName: str) -> Tuple[int, int]:
"""Get start address and size of a specified section."""
for seg_ea in idautils.Segments():
if idc.get_segm_name(seg_ea) == sectionName:
start = seg_ea
end = idc.get_segm_end(seg_ea)
return start, end - start
return 0, 0
def FindAllPatternsInRange(pattern: str, start: int, size: int) -> list[int]:
"""Find all occurrences of a pattern within a memory range."""
addresses: list[int] = []
ea: int = start
end: int = start + size
while ea < end:
compiledIDAPattern = ida_bytes.compiled_binpat_vec_t()
errorParsingIDAPattern = ida_bytes.parse_binpat_str(compiledIDAPattern, 0, pattern, 16, IDA_NALT_ENCODING)
if errorParsingIDAPattern:
return []
patternAddr: int = ida_bytes.bin_search(ea, end, compiledIDAPattern, ida_bytes.BIN_SEARCH_FORWARD)
if patternAddr == idc.BADADDR:
break
addresses.append(patternAddr)
ea = patternAddr + 8 # advance past found pattern
return addresses
# -----------------------------------------------------------------------------
# RTTI and vtable analysis
@ -425,29 +330,29 @@ def GetVTablePtr(targetClass: ClassName, targetClassRTTIName: str = "") -> int:
# Use provided RTTI name if available (for templates), otherwise generate it
if not targetClassRTTIName:
# Check if this is a templated class
typeDescriptorName: str = GetMangledTypePrefix(targetClass)
typeDescriptorName: str = Utils.GetMangledTypePrefix(targetClass.namespaces, targetClass.name)
else:
# Use the provided RTTI name directly
typeDescriptorName: str = targetClassRTTIName
# Search for the RTTI type descriptor
typeDescriptorBytes: bytes = typeDescriptorName.encode('ascii')
idaPattern: str = BytesToIDAPattern(typeDescriptorBytes)
idaPattern: str = Utils.BytesToIDAPattern(typeDescriptorBytes)
# Search in .rdata
rdataStartAddr, rdataSize = GetSectionInfo(".rdata")
rdataStartAddr, rdataSize = Utils.GetSectionInfo(".rdata")
if not rdataStartAddr:
return 0
# Look for the type descriptor
compiledIDAPattern = ida_bytes.compiled_binpat_vec_t()
errorParsingIDAPattern = ida_bytes.parse_binpat_str(compiledIDAPattern, 0, idaPattern, 16, IDA_NALT_ENCODING)
errorParsingIDAPattern = ida_bytes.parse_binpat_str(compiledIDAPattern, 0, idaPattern, 16, Utils.IDA_NALT_ENCODING)
if errorParsingIDAPattern:
return 0
typeDescriptorPatternAddr: int = ida_bytes.bin_search(rdataStartAddr, ida_ida.cvar.inf.max_ea, compiledIDAPattern, ida_bytes.BIN_SEARCH_FORWARD)
if typeDescriptorPatternAddr == idc.BADADDR:
PrintMsg(f"Type descriptor pattern '{typeDescriptorName}' not found for {targetClass.fullName}.\n")
print(f"Type descriptor pattern '{typeDescriptorName}' not found for {targetClass.fullName}.")
return 0
# Adjust to get RTTI type descriptor
@ -456,10 +361,10 @@ def GetVTablePtr(targetClass: ClassName, targetClassRTTIName: str = "") -> int:
# Compute offset relative to base address
rttiTypeDescriptorOffset: int = rttiTypeDescriptorAddr - baseDLLAddr
rttiTypeDescriptorOffsetBytes: bytes = struct.pack("<I", rttiTypeDescriptorOffset)
rttiTypeDescriptorOffsetPattern: str = BytesToIDAPattern(rttiTypeDescriptorOffsetBytes)
rttiTypeDescriptorOffsetPattern: str = Utils.BytesToIDAPattern(rttiTypeDescriptorOffsetBytes)
# Search for references to this offset
xrefs: list[int] = FindAllPatternsInRange(rttiTypeDescriptorOffsetPattern, rdataStartAddr, rdataSize)
xrefs: list[int] = Utils.FindAllPatternsInRange(rttiTypeDescriptorOffsetPattern, rdataStartAddr, rdataSize)
# Analyze each reference to find the vtable
for xref in xrefs:
@ -475,10 +380,10 @@ def GetVTablePtr(targetClass: ClassName, targetClassRTTIName: str = "") -> int:
# Look for references to the object locator
objectLocatorBytes: bytes = struct.pack("<Q", objectLocatorOffsetAddr)
objectLocatorPattern: str = BytesToIDAPattern(objectLocatorBytes)
objectLocatorPattern: str = Utils.BytesToIDAPattern(objectLocatorBytes)
compiledIDAPattern = ida_bytes.compiled_binpat_vec_t()
errorParsingIDAPattern = ida_bytes.parse_binpat_str(compiledIDAPattern, 0, objectLocatorPattern, 16, IDA_NALT_ENCODING)
errorParsingIDAPattern = ida_bytes.parse_binpat_str(compiledIDAPattern, 0, objectLocatorPattern, 16, Utils.IDA_NALT_ENCODING)
if errorParsingIDAPattern:
continue
@ -493,7 +398,7 @@ def GetVTablePtr(targetClass: ClassName, targetClassRTTIName: str = "") -> int:
return vtableAddr
PrintMsg(f"Failed to locate vtable pointer for {targetClass.fullName}.\n")
print(f"Failed to locate vtable pointer for {targetClass.fullName}.")
return 0
# -----------------------------------------------------------------------------
@ -508,7 +413,7 @@ def CreateParamNamesForVTFunc(parsedFunc: ParsedFunction, skipFirstParam: bool)
# Skip the first parameter (typically the "this" pointer)
if skipFirstParam:
paramsList = paramsList[1:]
paramsList = [FixTypeSpacing(param.strip()) for param in paramsList]
paramsList = [Utils.FixTypeSpacing(param.strip()) for param in paramsList]
paramNames: list[str] = [f"a{i+1}" for i in range(len(paramsList))]
newParams: str = ", ".join(f"{paramType} {paramName}" for paramType, paramName in zip(paramsList, paramNames))
@ -524,42 +429,40 @@ def ExtractParamNames(params: str) -> str:
newParams: str = ", ".join(paramNames)
return newParams
def ComputeUnparsedExportedSigs(demangledExportedSigs: list[str], parsedSigs: list[str]) -> list[str]:
# Join all parsed signatures into one large string.
big_parsed = "\n".join(parsedSigs)
# Then, for each exported signature, check if it appears in the big string.
return [sig for sig in demangledExportedSigs if sig not in big_parsed]
# # Start with a set of all exported signatures.
# unparsed = set(demangledExportedSigs)
# # For each parsed function signature, remove any exported signature that is a substring.
# for ps in parsedSigs:
# # Create a temporary list of matching exported signatures to remove
# toRemove = [sig for sig in unparsed if sig in ps]
# for sig in toRemove:
# unparsed.discard(sig)
# # If the set becomes empty, we can break early.
# if not unparsed:
# break
# return list(unparsed)
def GetDemangledExportedSigs() -> list[str]:
"""
Generate a list of demangled function sigs from IDA's database
Generate a list of demangled function signatures from IDA's database.
Uses a set to avoid duplicate entries.
"""
cachedFilePath = os.path.join(CACHE_FOLDER, "demangled_exported_sigs_cache.txt")
if os.path.exists(cachedFilePath):
try:
with open(cachedFilePath, "r") as cachedFile:
return [line.strip() for line in cachedFile if line.strip()]
except Exception as e:
PrintMsg(f"Error opening '{cachedFilePath}' for reading: {e}\n")
demangledExportedSigsList: list[str] = []
for i in range(idc.get_entry_qty()):
sigs_set = set()
entry_qty = idc.get_entry_qty()
for i in range(entry_qty):
ea: int = idc.get_entry(i)
exportedSig: str = idc.get_func_name(ea) or idc.get_name(ea)
if not exportedSig:
continue
demangledExportedSig: str = DemangleSig(exportedSig)
if not demangledExportedSig:
continue
if demangledExportedSig not in demangledExportedSigsList:
demangledExportedSigsList.append(demangledExportedSig)
os.makedirs(CACHE_FOLDER, exist_ok=True)
try:
with open(cachedFilePath, "w") as cachedFile:
for demangledExportedSig in demangledExportedSigsList:
cachedFile.write(demangledExportedSig + "\n")
except Exception as e:
PrintMsg(f"Error opening '{cachedFilePath}' for writing: {e}\n")
return demangledExportedSigsList
demangledExportedSig: str = Utils.DemangleSig(exportedSig)
if demangledExportedSig and "~" not in demangledExportedSig:
sigs_set.add(demangledExportedSig)
return list(sigs_set)
def GetParsedClassVars(targetClass: Optional[ClassName] = None) -> list[ParsedClassVar]:
"""
@ -567,45 +470,58 @@ def GetParsedClassVars(targetClass: Optional[ClassName] = None) -> list[ParsedCl
If target_class is provided, only return class vars for that class.
Caches results for better performance on subsequent calls.
"""
global parsedClassVarsByClass, allClassVarsAreParsed, parsedFuncsByClass
global parsedClassVarsByClass, allClassVarsAreParsed, parsedFuncsByClass, unparsedExportedSigs
if not allClassVarsAreParsed:
for demangledExportedSig in GetDemangledExportedSigs():
isAlreadyPresentInParsedFuncs: bool = False
for parsedFuncList in list(parsedFuncsByClass.values()):
for parsedFunc in parsedFuncList:
if demangledExportedSig in parsedFunc.fullFuncSig:
isAlreadyPresentInParsedFuncs = True
break
if isAlreadyPresentInParsedFuncs:
break
if isAlreadyPresentInParsedFuncs:
continue
# Attempt to load from cache
if os.path.exists(Config.PARSED_VARS_CACHE_FILENAME):
try:
with open(Config.PARSED_VARS_CACHE_FILENAME, "rb") as cache_file:
parsedClassVarsByClass = cloudpickle.load(cache_file)
allClassVarsAreParsed = True
print(f"Loaded cached class variables from \"{Config.PARSED_VARS_CACHE_FILENAME}\"")
except Exception as e:
print(f"Failed to load cache from \"{Config.PARSED_VARS_CACHE_FILENAME}\": {e}")
# Skip invalid functions
if demangledExportedSig.endswith("::$TSS0") or "::`vftable'" in demangledExportedSig:
continue
# If cache not loaded, parse from unparsed signatures.
if not allClassVarsAreParsed:
# Build the list of unparsed exported signatures only once
if not unparsedExportedSigs:
demangledExportedSigs = GetDemangledExportedSigs()
# Precompute a flat list of all parsed function signatures.
parsedSigs = [pf.fullFuncSig for funcList in parsedFuncsByClass.values() for pf in funcList]
unparsedExportedSigs = ComputeUnparsedExportedSigs(demangledExportedSigs, parsedSigs)
# Use existing unparsedExportedSigs if available; otherwise, generate them.
sigs = unparsedExportedSigs if unparsedExportedSigs else GetDemangledExportedSigs()
parsedClassVar: ParsedClassVar = ParsedClassVar(demangledExportedSig)
if not parsedClassVar.className or not parsedClassVar.varName:
PrintMsg(f"Failed parsing class var sig: \"{demangledExportedSig}\"")
continue
if parsedClassVar.className not in parsedClassVarsByClass:
parsedClassVarsByClass[parsedClassVar.className] = []
parsedClassVarsByClass[parsedClassVar.className].append(parsedClassVar)
allClassVarsAreParsed = True
# Return the requested functions
if not targetClass:
# Return all parsed functions
allClassVars: list[ParsedClassVar] = []
for classVars in parsedClassVarsByClass.values():
allClassVars.extend(classVars)
return allClassVars
for sig in sigs:
# Skip invalid signatures
if sig.endswith("::$TSS0") or "::`vftable'" in sig:
continue
parsedVar = ParsedClassVar(sig)
if not parsedVar.className or not parsedVar.varName:
print(f"Failed parsing class var sig: \"{sig}\"")
continue
parsedClassVarsByClass.setdefault(parsedVar.className, []).append(parsedVar)
allClassVarsAreParsed = True
# Cache the parsed class variables
try:
# Create directory if it doesn't exist
os.makedirs(Config.CACHE_OUTPUT_PATH, exist_ok=True)
with open(Config.PARSED_VARS_CACHE_FILENAME, "wb") as cache_file:
cloudpickle.dump(parsedClassVarsByClass, cache_file)
print(f"Cached class variables to \"{Config.PARSED_VARS_CACHE_FILENAME}\"")
except Exception as e:
print(f"Failed to write cache to \"{Config.PARSED_VARS_CACHE_FILENAME}\": {e}")
# Return all class variables or only those for the target class
if targetClass is None:
return [var for vars_list in parsedClassVarsByClass.values() for var in vars_list]
else:
# Return only functions for the specified class
return parsedClassVarsByClass.get(targetClass, [])
def GetDemangledVTableFuncSigs(targetClass: ClassName, targetClassRTTIName: str = "") -> list[tuple[str, str]]:
@ -615,7 +531,7 @@ def GetDemangledVTableFuncSigs(targetClass: ClassName, targetClassRTTIName: str
"""
vtablePtr: int = GetVTablePtr(targetClass, targetClassRTTIName)
if not vtablePtr:
idaapi.msg(f"Vtable pointer not found for {targetClass.fullName}.\n")
print(f"Vtable pointer not found for {targetClass.fullName}.")
return []
demangledVTableFuncSigsList: list[tuple[str, str]] = []
@ -632,7 +548,7 @@ def GetDemangledVTableFuncSigs(targetClass: ClassName, targetClassRTTIName: str
# Force function decompilation to generate the full function type signature
funcSig: str = idc.get_func_name(ptr)
demangledFuncSig: str = DemangleSig(funcSig)
demangledFuncSig: str = Utils.DemangleSig(funcSig)
demangledFuncSig = demangledFuncSig if demangledFuncSig else funcSig
rawType: str = ""
@ -645,8 +561,7 @@ def GetDemangledVTableFuncSigs(targetClass: ClassName, targetClassRTTIName: str
ida_hexrays.decompile(ptr)
rawType = "IDA_GEN_TYPE " + idc.get_type(ptr)
if (demangledFuncSig, rawType) in demangledVTableFuncSigsList:
demangledFuncSig = "DUPLICATE_FUNC " + demangledFuncSig# if not rawType else demangledFuncSig
#rawType = "DUPLICATE_FUNC " + rawType if rawType else rawType
demangledFuncSig = "DUPLICATE_FUNC " + demangledFuncSig
demangledVTableFuncSigsList.append((demangledFuncSig, rawType))
ea += 8
@ -687,37 +602,48 @@ def GetParsedVTableFuncs(targetClass: ClassName) -> list[ParsedFunction]:
def GetParsedFuncs(targetClass: Optional[ClassName] = None) -> list[ParsedFunction]:
"""
Collect and parse all function signatures from the IDA database.
If target_class is provided, only return functions for that class.
Caches results for better performance on subsequent calls.
If targetClass is provided, only return functions for that class.
Caches results in a file for better performance on subsequent calls.
Also builds a list of unparsed exported signatures for later use.
"""
global parsedFuncsByClass, allFuncsAreParsed
if not allFuncsAreParsed:
for demangledFuncSig in GetDemangledExportedSigs():
# Skip invalid functions
if demangledFuncSig.endswith("::$TSS0") or "::`vftable'" in demangledFuncSig:
continue
global parsedFuncsByClass, allFuncsAreParsed, unparsedExportedSigs
parsedFunc: ParsedFunction = ParsedFunction(demangledFuncSig, False)
if not parsedFunc.type or not parsedFunc.className:
PrintMsg(f"Failed parsing func sig: \"{demangledFuncSig}\"")
continue
if parsedFunc.className not in parsedFuncsByClass:
parsedFuncsByClass[parsedFunc.className] = []
parsedFuncsByClass[parsedFunc.className].append(parsedFunc)
allFuncsAreParsed = True
# Return the requested functions
if not targetClass:
# Return all parsed functions
allFuncs: list[ParsedFunction] = []
for funcs in parsedFuncsByClass.values():
allFuncs.extend(funcs)
return allFuncs
# Attempt to load cache if we haven't parsed everything yet.
if not allFuncsAreParsed:
if os.path.exists(Config.PARSED_FUNCS_CACHE_FILENAME):
try:
with open(Config.PARSED_FUNCS_CACHE_FILENAME, "rb") as cache_file:
breakpoint()
parsedFuncsByClass = cloudpickle.load(cache_file)
allFuncsAreParsed = True
print(f"Loaded cached parsed functions from \"{Config.PARSED_FUNCS_CACHE_FILENAME}\"")
except Exception as e:
print(f"Failed to load cache from \"{Config.PARSED_FUNCS_CACHE_FILENAME}\": {e}")
# If no cache was loaded, parse the signatures
if not allFuncsAreParsed:
demangledExportedSigs = GetDemangledExportedSigs()
for demangledFuncSig in demangledExportedSigs:
# Skip known invalid functions
if demangledFuncSig.endswith("::$TSS0") or "::`vftable'" in demangledFuncSig:
continue
parsedFunc: ParsedFunction = ParsedFunction(demangledFuncSig, False)
if not parsedFunc.type or not parsedFunc.className:
print(f"Failed parsing func sig: \"{demangledFuncSig}\"")
continue
parsedFuncsByClass.setdefault(parsedFunc.className, []).append(parsedFunc)
allFuncsAreParsed = True
try:
os.makedirs(Config.CACHE_OUTPUT_PATH, exist_ok=True)
with open(Config.PARSED_FUNCS_CACHE_FILENAME, "wb") as cache_file:
cloudpickle.dump(parsedFuncsByClass, cache_file)
print(f"Cached parsed functions to \"{Config.PARSED_FUNCS_CACHE_FILENAME}\"")
except Exception as e:
print(f"Failed to write cache to \"{Config.PARSED_FUNCS_CACHE_FILENAME}\": {e}")
# Return functions based on targetClass if specified
if targetClass is None:
return [pf for funcList in parsedFuncsByClass.values() for pf in funcList]
else:
# Return only functions for the specified class
return parsedFuncsByClass.get(targetClass, [])
# -----------------------------------------------------------------------------
@ -736,13 +662,13 @@ def GenerateClassVarCode(classVar: ParsedClassVar, cleanedTypes: bool = True) ->
currentAccess = classVar.access
if classVar.varType:
varType: str = ReplaceIDATypes(classVar.varType.fullName)
varType = CleanType(varType) if cleanedTypes else classVar.varType.fullName
varType: str = Utils.ReplaceIDATypes(classVar.varType.fullName)
varType = Utils.CleanType(varType) if cleanedTypes else classVar.varType.fullName
if varType:
varType += " "
varType = "GAME_IMPORT " + varType
else:
varType: str = ""
varType = "GAME_IMPORT " + varType
classVarSig: str = f"{varType}{classVar.varName}"
return f"{access}{classVarSig};"
@ -761,8 +687,8 @@ def GenerateClassFuncCode(func: ParsedFunction, cleanedTypes: bool = True, vtFun
stripped_vfunc: str = " = 0" if func.type == "stripped_vfunc" else ""
if func.returnType:
returnType: str = ReplaceIDATypes(func.returnType.fullName)
returnType = CleanType(returnType) if cleanedTypes else func.returnType.fullName
returnType: str = Utils.ReplaceIDATypes(func.returnType.fullName)
returnType = Utils.CleanType(returnType) if cleanedTypes else func.returnType.fullName
if returnType:
if func.type == "basic_vfunc":
returnType = returnType.removeprefix("virtual").strip()
@ -774,8 +700,8 @@ def GenerateClassFuncCode(func: ParsedFunction, cleanedTypes: bool = True, vtFun
returnType = "GAME_IMPORT " + returnType
if func.params:
params: str = ReplaceIDATypes(func.params)
params = CleanType(params) if cleanedTypes else func.params
params: str = Utils.ReplaceIDATypes(func.params)
params = Utils.CleanType(params) if cleanedTypes else func.params
if params == "void":
params = ""
else:
@ -819,13 +745,13 @@ def GenerateClassDefinition(targetClass: ClassName, allParsedClassVarsAndFuncs:
if not firstVarOrFuncAccess:
firstVarOrFuncAccess = classVar.access
classLines.append(GenerateClassVarCode(classVar, cleanedTypes))
if allParsedClassVarsAndFuncs[0] and allParsedClassVarsAndFuncs[1] and allParsedClassVarsAndFuncs[2]:
if allParsedClassVarsAndFuncs[0] and (allParsedClassVarsAndFuncs[1] or allParsedClassVarsAndFuncs[2]):
classLines.append("")
for index, vTableFunc in enumerate(allParsedClassVarsAndFuncs[1]):
if not firstVarOrFuncAccess:
firstVarOrFuncAccess = vTableFunc.access
classLines.append(GenerateClassFuncCode(vTableFunc, cleanedTypes, index))
if allParsedClassVarsAndFuncs[0] and allParsedClassVarsAndFuncs[1] and allParsedClassVarsAndFuncs[2]:
if (allParsedClassVarsAndFuncs[0] or allParsedClassVarsAndFuncs[1]) and allParsedClassVarsAndFuncs[2]:
classLines.append("")
for func in allParsedClassVarsAndFuncs[2]:
if not firstVarOrFuncAccess:
@ -864,20 +790,21 @@ def GenerateHeaderCode(targetClass: ClassName, allParsedClassVarsAndFuncs: tuple
def GetAllParsedClassVarsAndFuncs(targetClass: ClassName) -> tuple[list[ParsedClassVar], list[ParsedFunction], list[ParsedFunction]]:
parsedVTableClassFuncs: list[ParsedFunction] = GetParsedVTableFuncs(targetClass)
if not parsedVTableClassFuncs:
PrintMsg(f"No matching VTable function signatures were found for {targetClass.fullName}.\n")
print(f"No matching VTable function signatures were found for {targetClass.fullName}.")
parsedClassFuncs: list[ParsedFunction] = GetParsedFuncs(targetClass)
if not parsedClassFuncs:
PrintMsg(f"No matching function signatures were found for {targetClass.fullName}.\n")
print(f"No matching function signatures were found for {targetClass.fullName}.")
parsedClassVars: list[ParsedClassVar] = GetParsedClassVars(targetClass)
if not parsedClassVars:
PrintMsg(f"No matching class var signatures were found for {targetClass.fullName}.\n")
print(f"No matching class var signatures were found for {targetClass.fullName}.")
# Get non-vtable methods
vTableFuncsSet: set[str] = {pf.fullFuncSig for pf in parsedVTableClassFuncs}
finalParsedClassFuncs: list[ParsedFunction] = [
parsedFunc for parsedFunc in parsedClassFuncs
if parsedFunc not in parsedVTableClassFuncs
if parsedFunc.fullFuncSig not in vTableFuncsSet
]
return (parsedClassVars, parsedVTableClassFuncs, finalParsedClassFuncs)
@ -886,7 +813,7 @@ def WriteHeaderToFile(targetClass: ClassName, headerCode: str, fileName: str = "
if targetClass.namespaces:
# Create folder structure for namespaces
classFolderPath: str = os.path.join(*targetClass.namespaces)
outputFolderPath: str = os.path.join(OUTPUT_FOLDER, classFolderPath)
outputFolderPath: str = os.path.join(Config.HEADER_OUTPUT_PATH, classFolderPath)
# Create directory if it doesn't exist
os.makedirs(outputFolderPath, exist_ok=True)
@ -897,16 +824,16 @@ def WriteHeaderToFile(targetClass: ClassName, headerCode: str, fileName: str = "
# No namespace, just save in current directory
outputFilePath: str = f"{targetClass.name}.h" if not fileName else fileName
outputFilePath: str = os.path.join(OUTPUT_FOLDER, outputFilePath)
outputFilePath: str = os.path.join(Config.HEADER_OUTPUT_PATH, outputFilePath)
try:
with open(outputFilePath, 'w') as headerFile:
headerFile.write(headerCode)
PrintMsg(f"Header file '{outputFilePath}' created successfully.\n")
print(f"Header file '{outputFilePath}' created successfully.")
return True
except Exception as e:
PrintMsg(f"Error writing header file '{outputFilePath}': {e}\n")
print(f"Error writing header file '{outputFilePath}': {e}")
return False
def ExportClassHeader(targetClass: ClassName):
@ -914,16 +841,11 @@ def ExportClassHeader(targetClass: ClassName):
Generate and save a C++ header file for the target class.
For namespaced classes, creates appropriate folder structure.
"""
global processedClasses
processedClasses = set()
# Add the target class to processed classes to prevent recursion
processedClasses.add(targetClass)
allParsedClassVarsAndFuncs: tuple[list[ParsedClassVar], list[ParsedFunction], list[ParsedFunction]] = GetAllParsedClassVarsAndFuncs(targetClass)
headerCode: str = GenerateHeaderCode(targetClass, allParsedClassVarsAndFuncs)
if not headerCode:
PrintMsg(f"No functions were found for class {targetClass.fullName}, therefore will not generate.")
print(f"No functions were found for class {targetClass.fullName}, therefore will not generate.")
return
WriteHeaderToFile(targetClass, headerCode)
@ -934,12 +856,13 @@ def Main():
"""Main entry point for the script."""
# Ask user for target class
#targetClass = ida_kernwin.ask_str("IModelObject", 0, "Enter target class name (supports namespaces and templates):")
targetClassName: str = "CModelObject"
targetClassName: str = "CLevel"
if not targetClassName:
PrintMsg("No target class specified. Aborting.\n")
print("No target class specified. Aborting.")
return
targetClass: ClassName = ClassName(targetClassName)
breakpoint()
ExportClassHeader(targetClass)
# -----------------------------------------------------------------------------
@ -955,19 +878,19 @@ class ExportClassToCPPH(idaapi.plugin_t):
wanted_hotkey = "Shift-F"
def init(self):
PrintMsg(f"Initializing \"{self.wanted_name}\" Plugin\n")
print(f"Initializing \"{self.wanted_name}\" Plugin")
return idaapi.PLUGIN_OK
def run(self, arg):
PrintMsg(f"Running \"{self.wanted_name}\" Plugin\n")
print(f"Running \"{self.wanted_name}\" Plugin")
Main()
def term(self):
PrintMsg(f"Terminating \"{self.wanted_name}\" Plugin\n")
print(f"Terminating \"{self.wanted_name}\" Plugin")
pass
def PLUGIN_ENTRY():
idaapi.msg(f"Creating \"Export Class to C++ Header\" Plugin entry\n")
idaapi.msg(f"Creating \"Export Class to C++ Header\" Plugin entry")
return ExportClassToCPPH()
if __name__ == "__main__":

View File

@ -0,0 +1,9 @@
import os
INTERNAL_SCRIPT_NAME = "ExportClassToCPPH"
PROJECT_PATH = r"D:\PROJECTS\Visual Studio\EGameSDK\EGameSDK\include"
OUTPUT_PATH = r"D:\PROJECTS\Visual Studio\EGameSDK\EGameSDK\proxies\engine_x64_rwdi\scripts"
HEADER_OUTPUT_PATH = os.path.join(OUTPUT_PATH, "generated")
CACHE_OUTPUT_PATH = os.path.join(OUTPUT_PATH, "cache")
PARSED_VARS_CACHE_FILENAME = os.path.join(CACHE_OUTPUT_PATH, "parsedClassVarsByClass.cache")
PARSED_FUNCS_CACHE_FILENAME = os.path.join(CACHE_OUTPUT_PATH, "parsedFuncsByClass.cache")

View File

@ -0,0 +1,127 @@
import re
from typing import Tuple
import ida_nalt
import ida_bytes
import idaapi
import idautils
import idc
IDA_NALT_ENCODING = ida_nalt.get_default_encoding_idx(ida_nalt.BPU_1B)
CLASS_TYPES = ("class", "struct", "enum", "union")
FUNC_QUALIFIERS = ("virtual", "static")
# def PrintMsg(*args):
# print(f"[{Config.INTERNAL_SCRIPT_NAME}] {args}")
def FixTypeSpacing(type: str) -> str:
"""Fix spacing for pointers/references, commas, and angle brackets."""
type = re.sub(r'\s+([*&])', r'\1', type) # Remove space before '*' or '&'
type = re.sub(r'([*&])(?!\s)', r'\1 ', type) # Ensure '*' or '&' is followed by one space if it's not already.
type = re.sub(r'\s*,\s*', ', ', type) # Ensure comma followed by one space
type = re.sub(r'<\s+', '<', type) # Remove space after '<'
type = re.sub(r'\s+>', '>', type) # Remove space before '>'
type = re.sub(r'\s+', ' ', type) # Collapse multiple spaces
return type.strip()
def CleanType(type: str) -> str:
"""Remove unwanted tokens from a type string, then fix spacing."""
type = re.sub(r'\b(__cdecl|__fastcall|__ptr64|class|struct|enum|union)\b', '', type)
return FixTypeSpacing(type)
def ReplaceIDATypes(type: str) -> str:
"""Replace IDA types with normal ones"""
return type.replace("_QWORD", "uint64_t").replace("__int64", "int64_t").replace("unsigned int", "uint32_t")
def ExtractTypesFromString(types: str) -> list[str]:
"""Extract potential type names from a string."""
# Remove pointer/reference symbols and qualifiers
cleanedTypes: str = types.replace("*", " ").replace("&", " ")
cleanedTypesList: list[str] = re.findall(r"[A-Za-z_][\w:]*", cleanedTypes)
return cleanedTypesList
def FindLastSpaceOutsideTemplates(s: str) -> int:
"""Return the index of the last space in s that is not inside '<' and '>'."""
depth = 0
for i in range(len(s) - 1, -1, -1):
ch = s[i]
if ch == '>':
depth += 1
elif ch == '<':
depth -= 1
elif depth == 0 and ch == ' ':
return i
return -1
def FindLastClassSeparatorOutsideTemplates(s: str) -> int:
"""Return the index of the last occurrence of "::" in s that is not inside '<' and '>'."""
depth = 0
# iterate backwards, but check for two-character substring
for i in range(len(s) - 1, -1, -1):
if s[i] == '>':
depth += 1
elif s[i] == '<':
depth -= 1
# Only if we're not inside a template.
if depth == 0 and i > 0 and s[i-1:i+1] == "::":
return i - 1 # return the index of the first colon
return -1
# -----------------------------------------------------------------------------
# IDA util functions
# -----------------------------------------------------------------------------
def DemangleSig(sig: str) -> str:
return idaapi.demangle_name(sig, idaapi.MNG_LONG_FORM)
def GetMangledTypePrefix(namespaces: tuple[str], className: str) -> str:
"""
Get the appropriate mangled type prefix for a class name.
For class "X" this would be ".?AVX@@"
For class "NS::X" this would be ".?AVX@NS@@"
For templated classes, best to use get_mangled_name_for_template instead.
"""
if not namespaces:
return f".?AV{className}@@"
# For namespaced classes, the format is .?AVClassName@Namespace@@
# For nested namespaces, they are separated with @ in reverse order
mangledNamespaces = "@".join(reversed(namespaces))
return f".?AV{className}@{mangledNamespaces}@@"
# -----------------------------------------------------------------------------
# IDA pattern search utilities
# -----------------------------------------------------------------------------
def BytesToIDAPattern(data: bytes) -> str:
"""Convert bytes to IDA-friendly hex pattern string."""
return " ".join("{:02X}".format(b) for b in data)
def GetSectionInfo(sectionName: str) -> Tuple[int, int]:
"""Get start address and size of a specified section."""
for seg_ea in idautils.Segments():
if idc.get_segm_name(seg_ea) == sectionName:
start = seg_ea
end = idc.get_segm_end(seg_ea)
return start, end - start
return 0, 0
def FindAllPatternsInRange(pattern: str, start: int, size: int) -> list[int]:
"""Find all occurrences of a pattern within a memory range."""
addresses: list[int] = []
ea: int = start
end: int = start + size
while ea < end:
compiledIDAPattern = ida_bytes.compiled_binpat_vec_t()
errorParsingIDAPattern = ida_bytes.parse_binpat_str(compiledIDAPattern, 0, pattern, 16, IDA_NALT_ENCODING)
if errorParsingIDAPattern:
return []
patternAddr: int = ida_bytes.bin_search(ea, end, compiledIDAPattern, ida_bytes.BIN_SEARCH_FORWARD)
if patternAddr == idc.BADADDR:
break
addresses.append(patternAddr)
ea = patternAddr + 8 # advance past found pattern
return addresses

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,225 @@
#pragma once
#include <EGSDK\Imports.h>
class CLevel {
#pragma region GENERATED by ExportClassToCPPH.py
public:
VIRTUAL_CALL(0, __int64 __fastcall, sub_7E9B40, (__int64 a1, unsigned __int8 a2), a1, a2);
VIRTUAL_CALL(1, IObject *__fastcall, sub_AFCDB0, (char a1), a1);
GAME_IMPORT virtual class CRTTI const * GetRTTI() const;
VIRTUAL_CALL(3, __int64, sub_B122A0, ());
VIRTUAL_CALL(4, struct MED::SModelOutfitGroup const *, unassigned, ());
VIRTUAL_CALL(5, struct MED::SModelOutfitGroup const *, _unassigned1, ());
protected:
VIRTUAL_CALL(6, class gui::CPackage *, ToCPackage, ());
public:
VIRTUAL_CALL(7, class gui::CPackage *, _ToCPackage1, ());
VIRTUAL_CALL(8, __int64, RunUnitTests, ());
VIRTUAL_CALL(9, __int64, _RunUnitTests1, ());
GAME_IMPORT virtual void GetPrivateObjects(class ttl::list<class IGSObject *, class ttl::allocator> *, bool, bool);
GAME_IMPORT virtual void DestroyPrivateObjects();
VIRTUAL_CALL(12, struct MED::SModelOutfitGroup const *, _unassigned2, ());
GAME_IMPORT virtual void GetAllObjects(class ttl::vector<class IGSObject *, class ttl::vector_allocators::heap_allocator<class IGSObject *>, 1> &, bool);
GAME_IMPORT virtual void GetAllObjects(class ttl::set<class CRTTIObject *, struct ttl::less<class CRTTIObject *>, class ttl::allocator> &, class ttl::set<class CRTTIObject *, struct ttl::less<class CRTTIObject *>, class ttl::allocator> &, bool, class std::optional<class ttl::function_ref<bool (class CRTTIObject *)>>);
VIRTUAL_CALL(15, bool, updateRttiParams, ());
VIRTUAL_CALL(16, void __fastcall, SetPlatform, ());
GAME_IMPORT virtual char const * GetString(char const *) const;
VIRTUAL_CALL(18, __int64 __fastcall, sub_17D7D0, ());
VIRTUAL_CALL(19, char __fastcall, sub_15DDB0, ());
VIRTUAL_CALL(20, __int64 __fastcall, sub_80A6F0, ());
VIRTUAL_CALL(21, struct MED::SModelOutfitGroup const *, _unassigned3, ());
VIRTUAL_CALL(22, void __fastcall, _SetPlatform1, ());
GAME_IMPORT virtual class Uid const & GetUid() const;
VIRTUAL_CALL(24, bool, _updateRttiParams1, ());
VIRTUAL_CALL(25, bool, _updateRttiParams2, ());
VIRTUAL_CALL(26, bool, _updateRttiParams3, ());
VIRTUAL_CALL(27, bool, _updateRttiParams4, ());
VIRTUAL_CALL(28, bool, _updateRttiParams5, ());
VIRTUAL_CALL(29, bool, _updateRttiParams6, ());
VIRTUAL_CALL(30, bool, _updateRttiParams7, ());
VIRTUAL_CALL(31, bool, _updateRttiParams8, ());
VIRTUAL_CALL(32, bool, _updateRttiParams9, ());
GAME_IMPORT virtual void CallVoidMethod(char const *, ...);
GAME_IMPORT virtual class cbs::msg::IMessagePipeSet const & GetMessagePipeSet() const;
VIRTUAL_CALL(35, __int64, _RunUnitTests2, ());
VIRTUAL_CALL(36, struct MED::SModelOutfitGroup const *, _unassigned4, ());
VIRTUAL_CALL(37, struct MED::SModelOutfitGroup const *, _unassigned5, ());
VIRTUAL_CALL(38, struct MED::SModelOutfitGroup const *, _unassigned6, ());
VIRTUAL_CALL(39, struct MED::SModelOutfitGroup const *, _unassigned7, ());
GAME_IMPORT virtual class cbs::prop::IPropertySet const & GetPropertySet() const;
VIRTUAL_CALL(41, void __fastcall, _SetPlatform2, ());
VIRTUAL_CALL(42, __int64, _RunUnitTests3, ());
GAME_IMPORT virtual bool LoadField(class CRTTIField const *, unsigned char, class fs::ifile &, class IPtrResolver &, bool);
GAME_IMPORT virtual void LoadFields(class dom::IReader::Object const &, class IPtrResolver &, bool, bool (*)(char const *, class CRTTIObject *));
GAME_IMPORT virtual void LoadFields(class ITextDeserializer &, class IPtrResolver &, bool);
GAME_IMPORT virtual void LoadFields(class fs::ifile &, class IPtrResolver &, bool);
GAME_IMPORT virtual void SaveFields(class dom::IWriter &, enum ERTTIFlags, bool) const;
GAME_IMPORT virtual int ToBufferReplicated(char *, int);
GAME_IMPORT virtual int FromBufferReplicated(char *, int);
GAME_IMPORT virtual int GetBufferReplicatedDataSize();
VIRTUAL_CALL(51, void __fastcall, _SetPlatform3, ());
VIRTUAL_CALL(52, char __fastcall, sub_1816B0, (const struct CRTTIField* a1), a1);
GAME_IMPORT virtual bool CopyFields(class CRTTIObject const *, bool);
GAME_IMPORT virtual bool CopyPointerFields(class CRTTIObject const *);
GAME_IMPORT virtual bool ExchangePointerFields(class CRTTIObject *);
VIRTUAL_CALL(56, __int64 __fastcall, sub_7F8D70, (int a1), a1);
VIRTUAL_CALL(57, __int64 __fastcall, sub_7F8F70, (__int64 a1), a1);
VIRTUAL_CALL(58, __int64, _RunUnitTests4, ());
GAME_IMPORT virtual struct SRttiNetPointer GetNetPointer() const;
VIRTUAL_CALL(60, __int64, _RunUnitTests5, ());
GAME_IMPORT virtual class ttl::string_base<char> GetDebugDescription() const;
VIRTUAL_CALL(62, __int64 __fastcall, sub_B005E0, (_DWORD* a1), a1);
VIRTUAL_CALL(63, __int64 __fastcall, sub_7E92C0, ());
VIRTUAL_CALL(64, __int64 __fastcall, sub_8092F0, ());
VIRTUAL_CALL(65, bool, _updateRttiParams10, ());
VIRTUAL_CALL(66, static bool, ValidateVec4, (class IGSObject const *, class vec4 const &), *, &);
VIRTUAL_CALL(67, __int64 __fastcall, sub_806BC0, ());
GAME_IMPORT virtual class ttl::string_base<char> ValueToString(class CRTTIObject * const &) const;
VIRTUAL_CALL(69, char __fastcall, sub_15DD80, ());
VIRTUAL_CALL(70, void __fastcall, sub_17D770, (struct CRTTIField* a1, bool a2), a1, a2);
VIRTUAL_CALL(71, bool, _updateRttiParams11, ());
GAME_IMPORT virtual bool OnFieldChanged2(class CRTTIField const *, bool);
VIRTUAL_CALL(73, __int64 __fastcall, sub_173040, ());
VIRTUAL_CALL(74, char const *, GetMethodName, ());
VIRTUAL_CALL(75, _QWORD *__fastcall, sub_8343A0, (__int64 a1), a1);
VIRTUAL_CALL(76, bool, _updateRttiParams12, ());
VIRTUAL_CALL(77, char __fastcall, sub_81DA90, (__int64 a1), a1);
VIRTUAL_CALL(78, bool, _updateRttiParams13, ());
VIRTUAL_CALL(79, bool __fastcall, sub_81DA10, ());
VIRTUAL_CALL(80, __int64, _RunUnitTests6, ());
VIRTUAL_CALL(81, __int64, _RunUnitTests7, ());
VIRTUAL_CALL(82, static void, RegisterSTTI, (class CRTTI *), *);
GAME_IMPORT virtual void Query(class IBaseValidator &, class ttl::vector<class CRTTIObject *, class ttl::vector_allocators::heap_allocator<class CRTTIObject *>, 1> &) const;
VIRTUAL_CALL(84, bool __fastcall, sub_15DE90, ());
GAME_IMPORT virtual bool SelectObjectEditor(bool);
GAME_IMPORT virtual bool HideObjectEditor(bool);
VIRTUAL_CALL(87, char __fastcall, sub_15E050, ());
VIRTUAL_CALL(88, static void, _RegisterSTTI1, (class CRTTI* a1), a1);
VIRTUAL_CALL(89, __int64 __fastcall, sub_7ED0C0, (__int64 a1), a1);
VIRTUAL_CALL(90, __int64 __fastcall, sub_7F4540, ());
VIRTUAL_CALL(91, __int64 __fastcall, sub_B1E130, (__int64 a1, unsigned int a2), a1, a2);
VIRTUAL_CALL(92, char __fastcall, sub_B1E1C0, (__int64* a1, __int64 a2, unsigned int a3), a1, a2, a3);
VIRTUAL_CALL(93, _QWORD *__fastcall, sub_131260, (__int64* a1, int a2, int a3, __int64 a4, struct CRTTI* a5), a1, a2, a3, a4, a5);
VIRTUAL_CALL(94, void __fastcall, sub_B30960, (struct gui::CActionNode* a1), a1);
VIRTUAL_CALL(95, __int64 __fastcall, sub_7F0310, ());
VIRTUAL_CALL(96, __int64 __fastcall, GsDriverEntry_0, ());
VIRTUAL_CALL(97, void __fastcall, _SetPlatform4, ());
VIRTUAL_CALL(98, void __fastcall, sub_B1C6E0, (struct CGSObject* a1), a1);
VIRTUAL_CALL(99, __int64 __fastcall, sub_80C420, (__int64 a1), a1);
VIRTUAL_CALL(100, int __fastcall, sub_B04E70, ());
VIRTUAL_CALL(101, __int64 __fastcall, sub_7E9230, (__int64 a1), a1);
VIRTUAL_CALL(102, __int64 __fastcall, sub_7E8D70, (__int64 a1), a1);
VIRTUAL_CALL(103, __int64 __fastcall, sub_7E91C0, ());
VIRTUAL_CALL(104, __int64 __fastcall, sub_B02400, ());
VIRTUAL_CALL(105, __int64 __fastcall, sub_7F89A0, ());
VIRTUAL_CALL(106, char __fastcall, sub_7F97C0, (__int64 a1, _QWORD* a2, _DWORD* a3), a1, a2, a3);
VIRTUAL_CALL(107, char __fastcall, sub_8130B0, (__int64 a1), a1);
VIRTUAL_CALL(108, char __fastcall, sub_813020, (_QWORD* * a1), a1);
VIRTUAL_CALL(109, _QWORD *__fastcall, sub_806400, (_QWORD* a1), a1);
VIRTUAL_CALL(110, __int64 __fastcall, sub_831710, (__int64 a1), a1);
VIRTUAL_CALL(111, __int64 __fastcall, sub_8316D0, (__int64 a1), a1);
VIRTUAL_CALL(112, void __fastcall, sub_8261B0, (__int64 a1), a1);
VIRTUAL_CALL(113, void __fastcall, sub_8260E0, (_BYTE* a1), a1);
VIRTUAL_CALL(114, unsigned __int64 __fastcall, sub_834570, (char a1), a1);
VIRTUAL_CALL(115, __int64 __fastcall, sub_8341B0, (__int64 a1), a1);
VIRTUAL_CALL(116, __int64 __fastcall, sub_833F80, (__int64 a1, __int64 a2), a1, a2);
VIRTUAL_CALL(117, unsigned __int64 *__fastcall, sub_B120A0, (unsigned __int64* a1, char a2), a1, a2);
VIRTUAL_CALL(118, _QWORD *__fastcall, sub_802EE0, (_QWORD* a1), a1);
VIRTUAL_CALL(119, __int64 __fastcall, sub_834400, ());
VIRTUAL_CALL(120, void __fastcall, sub_8262B0, (_BYTE* a1), a1);
VIRTUAL_CALL(121, __int64 __fastcall, sub_831870, (__int64 a1), a1);
VIRTUAL_CALL(122, __int64 __fastcall, sub_7E92E0, ());
VIRTUAL_CALL(123, __int64 __fastcall, sub_7E93C0, ());
VIRTUAL_CALL(124, __int64 __fastcall, sub_7E9390, ());
VIRTUAL_CALL(125, __int64 __fastcall, sub_7E93F0, ());
VIRTUAL_CALL(126, __int64 __fastcall, sub_7E9340, ());
VIRTUAL_CALL(127, __int64 __fastcall, sub_7E93E0, ());
VIRTUAL_CALL(128, __int64 __fastcall, sub_7E9330, ());
VIRTUAL_CALL(129, __int64 __fastcall, sub_7E93D0, ());
VIRTUAL_CALL(130, __int64 __fastcall, sub_7E9320, ());
VIRTUAL_CALL(131, __int64 __fastcall, sub_7E92F0, ());
VIRTUAL_CALL(132, __int64 __fastcall, sub_7E92D0, ());
VIRTUAL_CALL(133, __int64 __fastcall, sub_7E93A0, ());
VIRTUAL_CALL(134, __int64 __fastcall, sub_7E9400, ());
VIRTUAL_CALL(135, __int64 __fastcall, sub_7E9410, ());
VIRTUAL_CALL(136, __int64 __fastcall, sub_7E9420, ());
VIRTUAL_CALL(137, __int64 __fastcall, sub_7E9350, ());
VIRTUAL_CALL(138, __int64 __fastcall, sub_7E9360, ());
VIRTUAL_CALL(139, __int64 __fastcall, sub_7E9380, ());
VIRTUAL_CALL(140, __int64 __fastcall, sub_7E9370, ());
VIRTUAL_CALL(141, __int64 __fastcall, sub_7E9300, ());
VIRTUAL_CALL(142, __int64 __fastcall, sub_7E9310, ());
VIRTUAL_CALL(143, __int64 __fastcall, sub_7E93B0, ());
VIRTUAL_CALL(144, bool __fastcall, sub_811980, ());
VIRTUAL_CALL(145, _QWORD *__fastcall, sub_7FE950, (_QWORD* a1), a1);
VIRTUAL_CALL(146, __int64 __fastcall, sub_B17A80, ());
VIRTUAL_CALL(147, __int64 __fastcall, _sub_B17A801, ());
VIRTUAL_CALL(148, void __fastcall, _SetPlatform5, ());
VIRTUAL_CALL(149, void __fastcall, _SetPlatform6, ());
VIRTUAL_CALL(150, void __fastcall, _SetPlatform7, ());
VIRTUAL_CALL(151, void __fastcall, _SetPlatform8, ());
VIRTUAL_CALL(152, void __fastcall, sub_B1D5B0, (_QWORD* a1), a1);
VIRTUAL_CALL(153, __int64 __fastcall, sub_B317B0, (_QWORD* a1), a1);
VIRTUAL_CALL(154, const char *__fastcall, sub_B17360, ());
VIRTUAL_CALL(155, void __fastcall, sub_B173B0, (MED::DebugPanel::Assets* a1), a1);
VIRTUAL_CALL(156, __int64 __fastcall, sub_B34690, ());
VIRTUAL_CALL(157, __int64 __fastcall, sub_B34990, ());
VIRTUAL_CALL(158, __int64 __fastcall, sub_B01150, (__int64 a1, float a2, float a3, float a4, int a5, int a6, char a7), a1, a2, a3, a4, a5, a6, a7);
VIRTUAL_CALL(159, _DWORD *__fastcall, sub_B31E40, (int* a1), a1);
VIRTUAL_CALL(160, __int64 __fastcall, sub_B17F00, (__int64 a1), a1);
VIRTUAL_CALL(161, __int64 __fastcall, sub_B22340, ());
VIRTUAL_CALL(162, void __fastcall, sub_B24B20, (__int64 a1), a1);
VIRTUAL_CALL(163, __int64 __fastcall, sub_AFCF70, ());
VIRTUAL_CALL(164, __int64 __fastcall, sub_B21770, (__int64 a1), a1);
VIRTUAL_CALL(165, void __fastcall, _SetPlatform9, ());
VIRTUAL_CALL(166, __int64 __fastcall, sub_B30870, (unsigned __int8 a1), a1);
VIRTUAL_CALL(167, void __fastcall, sub_B1A6E0, ());
VIRTUAL_CALL(168, __int64 __fastcall, sub_B05C30, ());
VIRTUAL_CALL(169, void __fastcall, _SetPlatform10, ());
VIRTUAL_CALL(170, void __fastcall, sub_B1A730, ());
VIRTUAL_CALL(171, __int64 __fastcall, sub_B1D370, ());
VIRTUAL_CALL(172, void __fastcall, sub_AFF1C0, (char a1), a1);
VIRTUAL_CALL(173, __int64 __fastcall, sub_B04C10, ());
VIRTUAL_CALL(174, void __fastcall, sub_B1A090, ());
VIRTUAL_CALL(175, void *__fastcall, sub_B1C680, ());
VIRTUAL_CALL(176, __int64 __fastcall, sub_B11210, ());
VIRTUAL_CALL(177, __int64 __fastcall, sub_B124D0, ());
VIRTUAL_CALL(178, __int64 __fastcall, sub_B12290, ());
VIRTUAL_CALL(179, bool __fastcall, sub_B1D230, ());
VIRTUAL_CALL(180, __int64, sub_B15DE0, ());
VIRTUAL_CALL(181, void __fastcall, sub_B31F30, (float a1), a1);
VIRTUAL_CALL(182, float __fastcall, sub_B183D0, ());
VIRTUAL_CALL(183, __int64 __fastcall, sub_B22310, (__int64 a1), a1);
VIRTUAL_CALL(184, __int64 __fastcall, sub_B22130, ());
VIRTUAL_CALL(185, void __fastcall, _SetPlatform11, ());
VIRTUAL_CALL(186, char __fastcall, sub_B2B0A0, (__int64 a1), a1);
VIRTUAL_CALL(187, void __fastcall, sub_B30B40, (unsigned __int64 a1), a1);
VIRTUAL_CALL(188, void __fastcall, sub_B30F90, (__int64 a1), a1);
VIRTUAL_CALL(189, unsigned __int64 *, sub_B03FE0, (unsigned __int64* a1, char* a2, ... a3), a1, a2, a3);
VIRTUAL_CALL(190, __int64 __fastcall, sub_B15200, (int a1), a1);
VIRTUAL_CALL(191, unsigned __int64 *__fastcall, sub_B13DC0, (unsigned __int64* a1), a1);
VIRTUAL_CALL(192, __int64 __fastcall, sub_B144B0, (__int64 a1), a1);
VIRTUAL_CALL(193, physics_spec_walk *__fastcall, sub_B13DF0, (physics_spec_walk* a1), a1);
VIRTUAL_CALL(194, __int64 __fastcall, sub_B111F0, ());
VIRTUAL_CALL(195, __int64 __fastcall, sub_B22040, ());
VIRTUAL_CALL(196, __int64 __fastcall, sub_B220F0, ());
VIRTUAL_CALL(197, _DWORD *__fastcall, sub_B0C760, ());
VIRTUAL_CALL(198, __int64, sub_B0D030, ());
VIRTUAL_CALL(199, __int64 __fastcall, sub_B0D040, ());
VIRTUAL_CALL(200, __int64 __fastcall, sub_B221D0, ());
VIRTUAL_CALL(201, void __fastcall, sub_B222C0, ());
VIRTUAL_CALL(202, _QWORD *__fastcall, sub_B02D00, ());
VIRTUAL_CALL(203, __int64 __fastcall, sub_B28550, (char a1, __int64 a2, __int64 a3, SExtCollInfo* a4), a1, a2, a3, a4);
VIRTUAL_CALL(204, bool __fastcall, sub_B281E0, (char a1, __int64 a2, __int64 a3, __int64 a4), a1, a2, a3, a4);
VIRTUAL_CALL(205, unsigned int __fastcall, sub_B21210, (char a1, __int64 a2, __int64 a3, MED::SModelOutfitItems* a4, __int64 a5), a1, a2, a3, a4, a5);
VIRTUAL_CALL(206, __int64 __fastcall, sub_B07AE0, (char a1, unsigned int* a2, __int64 a3, __int64 a4, __int128* a5, char a6), a1, a2, a3, a4, a5, a6);
VIRTUAL_CALL(207, void __fastcall, sub_B07DD0, (char a1, __int64 a2, __int64 a3, __int64 a4, __int128* a5), a1, a2, a3, a4, a5);
VIRTUAL_CALL(208, void __fastcall, sub_AFD490, (__int64 a1, char a2), a1, a2);
VIRTUAL_CALL(209, __int64 __fastcall, sub_B2C870, (__int64 a1), a1);
VIRTUAL_CALL(210, __int64 __fastcall, sub_B2F0B0, (__int64* a1), a1);
VIRTUAL_CALL(211, __int64 __fastcall, sub_B2ECF0, (__int64 a1), a1);
VIRTUAL_CALL(212, unsigned __int64 *__fastcall, sub_B16F10, (unsigned __int64* a1), a1);
VIRTUAL_CALL(213, void __fastcall, _SetPlatform12, ());
VIRTUAL_CALL(214, float __fastcall, sub_B3EDC0, ());
#pragma endregion
};

View File

@ -0,0 +1,225 @@
#pragma once
#include <EGSDK\Imports.h>
class CLevel {
#pragma region GENERATED by ExportClassToCPPH.py
public:
VIRTUAL_CALL(0, int64_t, sub_7E9B40, (int64_t a1, unsigned __int8 a2), a1, a2);
VIRTUAL_CALL(1, IObject*, sub_AFCDB0, (char a1), a1);
GAME_IMPORT virtual CRTTI const* GetRTTI() const;
VIRTUAL_CALL(3, int64_t, sub_B122A0, ());
VIRTUAL_CALL(4, MED::SModelOutfitGroup const*, unassigned, ());
VIRTUAL_CALL(5, MED::SModelOutfitGroup const*, _unassigned1, ());
protected:
VIRTUAL_CALL(6, gui::CPackage*, ToCPackage, ());
public:
VIRTUAL_CALL(7, gui::CPackage*, _ToCPackage1, ());
VIRTUAL_CALL(8, int64_t, RunUnitTests, ());
VIRTUAL_CALL(9, int64_t, _RunUnitTests1, ());
GAME_IMPORT virtual void GetPrivateObjects(ttl::list<IGSObject*, ttl::allocator>*, bool, bool);
GAME_IMPORT virtual void DestroyPrivateObjects();
VIRTUAL_CALL(12, MED::SModelOutfitGroup const*, _unassigned2, ());
GAME_IMPORT virtual void GetAllObjects(ttl::vector<IGSObject*, ttl::vector_allocators::heap_allocator<IGSObject*>, 1>&, bool);
GAME_IMPORT virtual void GetAllObjects(ttl::set<CRTTIObject*, ttl::less<CRTTIObject*>, ttl::allocator>&, ttl::set<CRTTIObject*, ttl::less<CRTTIObject*>, ttl::allocator>&, bool, std::optional<ttl::function_ref<bool ( CRTTIObject* )>>);
VIRTUAL_CALL(15, bool, updateRttiParams, ());
VIRTUAL_CALL(16, void, SetPlatform, ());
GAME_IMPORT virtual char const* GetString(char const*) const;
VIRTUAL_CALL(18, int64_t, sub_17D7D0, ());
VIRTUAL_CALL(19, char, sub_15DDB0, ());
VIRTUAL_CALL(20, int64_t, sub_80A6F0, ());
VIRTUAL_CALL(21, MED::SModelOutfitGroup const*, _unassigned3, ());
VIRTUAL_CALL(22, void, _SetPlatform1, ());
GAME_IMPORT virtual Uid const& GetUid() const;
VIRTUAL_CALL(24, bool, _updateRttiParams1, ());
VIRTUAL_CALL(25, bool, _updateRttiParams2, ());
VIRTUAL_CALL(26, bool, _updateRttiParams3, ());
VIRTUAL_CALL(27, bool, _updateRttiParams4, ());
VIRTUAL_CALL(28, bool, _updateRttiParams5, ());
VIRTUAL_CALL(29, bool, _updateRttiParams6, ());
VIRTUAL_CALL(30, bool, _updateRttiParams7, ());
VIRTUAL_CALL(31, bool, _updateRttiParams8, ());
VIRTUAL_CALL(32, bool, _updateRttiParams9, ());
GAME_IMPORT virtual void CallVoidMethod(char const*, ...);
GAME_IMPORT virtual cbs::msg::IMessagePipeSet const& GetMessagePipeSet() const;
VIRTUAL_CALL(35, int64_t, _RunUnitTests2, ());
VIRTUAL_CALL(36, MED::SModelOutfitGroup const*, _unassigned4, ());
VIRTUAL_CALL(37, MED::SModelOutfitGroup const*, _unassigned5, ());
VIRTUAL_CALL(38, MED::SModelOutfitGroup const*, _unassigned6, ());
VIRTUAL_CALL(39, MED::SModelOutfitGroup const*, _unassigned7, ());
GAME_IMPORT virtual cbs::prop::IPropertySet const& GetPropertySet() const;
VIRTUAL_CALL(41, void, _SetPlatform2, ());
VIRTUAL_CALL(42, int64_t, _RunUnitTests3, ());
GAME_IMPORT virtual bool LoadField(CRTTIField const*, unsigned char, fs::ifile&, IPtrResolver&, bool);
GAME_IMPORT virtual void LoadFields(dom::IReader::Object const&, IPtrResolver&, bool, bool (* )(char const*, CRTTIObject* ));
GAME_IMPORT virtual void LoadFields(ITextDeserializer&, IPtrResolver&, bool);
GAME_IMPORT virtual void LoadFields(fs::ifile&, IPtrResolver&, bool);
GAME_IMPORT virtual void SaveFields(dom::IWriter&, ERTTIFlags, bool) const;
GAME_IMPORT virtual int ToBufferReplicated(char*, int);
GAME_IMPORT virtual int FromBufferReplicated(char*, int);
GAME_IMPORT virtual int GetBufferReplicatedDataSize();
VIRTUAL_CALL(51, void, _SetPlatform3, ());
VIRTUAL_CALL(52, char, sub_1816B0, (const CRTTIField* a1), a1);
GAME_IMPORT virtual bool CopyFields(CRTTIObject const*, bool);
GAME_IMPORT virtual bool CopyPointerFields(CRTTIObject const*);
GAME_IMPORT virtual bool ExchangePointerFields(CRTTIObject*);
VIRTUAL_CALL(56, int64_t, sub_7F8D70, (int a1), a1);
VIRTUAL_CALL(57, int64_t, sub_7F8F70, (int64_t a1), a1);
VIRTUAL_CALL(58, int64_t, _RunUnitTests4, ());
GAME_IMPORT virtual SRttiNetPointer GetNetPointer() const;
VIRTUAL_CALL(60, int64_t, _RunUnitTests5, ());
GAME_IMPORT virtual ttl::string_base<char> GetDebugDescription() const;
VIRTUAL_CALL(62, int64_t, sub_B005E0, (_DWORD* a1), a1);
VIRTUAL_CALL(63, int64_t, sub_7E92C0, ());
VIRTUAL_CALL(64, int64_t, sub_8092F0, ());
VIRTUAL_CALL(65, bool, _updateRttiParams10, ());
VIRTUAL_CALL(66, static bool, ValidateVec4, (IGSObject const*, vec4 const&), const*, const&);
VIRTUAL_CALL(67, int64_t, sub_806BC0, ());
GAME_IMPORT virtual ttl::string_base<char> ValueToString(CRTTIObject* const&) const;
VIRTUAL_CALL(69, char, sub_15DD80, ());
VIRTUAL_CALL(70, void, sub_17D770, (CRTTIField* a1, bool a2), a1, a2);
VIRTUAL_CALL(71, bool, _updateRttiParams11, ());
GAME_IMPORT virtual bool OnFieldChanged2(CRTTIField const*, bool);
VIRTUAL_CALL(73, int64_t, sub_173040, ());
VIRTUAL_CALL(74, char const*, GetMethodName, ());
VIRTUAL_CALL(75, uint64_t*, sub_8343A0, (int64_t a1), a1);
VIRTUAL_CALL(76, bool, _updateRttiParams12, ());
VIRTUAL_CALL(77, char, sub_81DA90, (int64_t a1), a1);
VIRTUAL_CALL(78, bool, _updateRttiParams13, ());
VIRTUAL_CALL(79, bool, sub_81DA10, ());
VIRTUAL_CALL(80, int64_t, _RunUnitTests6, ());
VIRTUAL_CALL(81, int64_t, _RunUnitTests7, ());
VIRTUAL_CALL(82, static void, RegisterSTTI, (CRTTI*), CRTTI*);
GAME_IMPORT virtual void Query(IBaseValidator&, ttl::vector<CRTTIObject*, ttl::vector_allocators::heap_allocator<CRTTIObject*>, 1>&) const;
VIRTUAL_CALL(84, bool, sub_15DE90, ());
GAME_IMPORT virtual bool SelectObjectEditor(bool);
GAME_IMPORT virtual bool HideObjectEditor(bool);
VIRTUAL_CALL(87, char, sub_15E050, ());
VIRTUAL_CALL(88, static void, _RegisterSTTI1, (CRTTI* a1), a1);
VIRTUAL_CALL(89, int64_t, sub_7ED0C0, (int64_t a1), a1);
VIRTUAL_CALL(90, int64_t, sub_7F4540, ());
VIRTUAL_CALL(91, int64_t, sub_B1E130, (int64_t a1, uint32_t a2), a1, a2);
VIRTUAL_CALL(92, char, sub_B1E1C0, (int64_t* a1, int64_t a2, uint32_t a3), a1, a2, a3);
VIRTUAL_CALL(93, uint64_t*, sub_131260, (int64_t* a1, int a2, int a3, int64_t a4, CRTTI* a5), a1, a2, a3, a4, a5);
VIRTUAL_CALL(94, void, sub_B30960, (gui::CActionNode* a1), a1);
VIRTUAL_CALL(95, int64_t, sub_7F0310, ());
VIRTUAL_CALL(96, int64_t, GsDriverEntry_0, ());
VIRTUAL_CALL(97, void, _SetPlatform4, ());
VIRTUAL_CALL(98, void, sub_B1C6E0, (CGSObject* a1), a1);
VIRTUAL_CALL(99, int64_t, sub_80C420, (int64_t a1), a1);
VIRTUAL_CALL(100, int, sub_B04E70, ());
VIRTUAL_CALL(101, int64_t, sub_7E9230, (int64_t a1), a1);
VIRTUAL_CALL(102, int64_t, sub_7E8D70, (int64_t a1), a1);
VIRTUAL_CALL(103, int64_t, sub_7E91C0, ());
VIRTUAL_CALL(104, int64_t, sub_B02400, ());
VIRTUAL_CALL(105, int64_t, sub_7F89A0, ());
VIRTUAL_CALL(106, char, sub_7F97C0, (int64_t a1, uint64_t* a2, _DWORD* a3), a1, a2, a3);
VIRTUAL_CALL(107, char, sub_8130B0, (int64_t a1), a1);
VIRTUAL_CALL(108, char, sub_813020, (uint64_t* * a1), a1);
VIRTUAL_CALL(109, uint64_t*, sub_806400, (uint64_t* a1), a1);
VIRTUAL_CALL(110, int64_t, sub_831710, (int64_t a1), a1);
VIRTUAL_CALL(111, int64_t, sub_8316D0, (int64_t a1), a1);
VIRTUAL_CALL(112, void, sub_8261B0, (int64_t a1), a1);
VIRTUAL_CALL(113, void, sub_8260E0, (_BYTE* a1), a1);
VIRTUAL_CALL(114, uint32_t64_t, sub_834570, (char a1), a1);
VIRTUAL_CALL(115, int64_t, sub_8341B0, (int64_t a1), a1);
VIRTUAL_CALL(116, int64_t, sub_833F80, (int64_t a1, int64_t a2), a1, a2);
VIRTUAL_CALL(117, uint32_t64_t*, sub_B120A0, (uint32_t64_t* a1, char a2), a1, a2);
VIRTUAL_CALL(118, uint64_t*, sub_802EE0, (uint64_t* a1), a1);
VIRTUAL_CALL(119, int64_t, sub_834400, ());
VIRTUAL_CALL(120, void, sub_8262B0, (_BYTE* a1), a1);
VIRTUAL_CALL(121, int64_t, sub_831870, (int64_t a1), a1);
VIRTUAL_CALL(122, int64_t, sub_7E92E0, ());
VIRTUAL_CALL(123, int64_t, sub_7E93C0, ());
VIRTUAL_CALL(124, int64_t, sub_7E9390, ());
VIRTUAL_CALL(125, int64_t, sub_7E93F0, ());
VIRTUAL_CALL(126, int64_t, sub_7E9340, ());
VIRTUAL_CALL(127, int64_t, sub_7E93E0, ());
VIRTUAL_CALL(128, int64_t, sub_7E9330, ());
VIRTUAL_CALL(129, int64_t, sub_7E93D0, ());
VIRTUAL_CALL(130, int64_t, sub_7E9320, ());
VIRTUAL_CALL(131, int64_t, sub_7E92F0, ());
VIRTUAL_CALL(132, int64_t, sub_7E92D0, ());
VIRTUAL_CALL(133, int64_t, sub_7E93A0, ());
VIRTUAL_CALL(134, int64_t, sub_7E9400, ());
VIRTUAL_CALL(135, int64_t, sub_7E9410, ());
VIRTUAL_CALL(136, int64_t, sub_7E9420, ());
VIRTUAL_CALL(137, int64_t, sub_7E9350, ());
VIRTUAL_CALL(138, int64_t, sub_7E9360, ());
VIRTUAL_CALL(139, int64_t, sub_7E9380, ());
VIRTUAL_CALL(140, int64_t, sub_7E9370, ());
VIRTUAL_CALL(141, int64_t, sub_7E9300, ());
VIRTUAL_CALL(142, int64_t, sub_7E9310, ());
VIRTUAL_CALL(143, int64_t, sub_7E93B0, ());
VIRTUAL_CALL(144, bool, sub_811980, ());
VIRTUAL_CALL(145, uint64_t*, sub_7FE950, (uint64_t* a1), a1);
VIRTUAL_CALL(146, int64_t, sub_B17A80, ());
VIRTUAL_CALL(147, int64_t, _sub_B17A801, ());
VIRTUAL_CALL(148, void, _SetPlatform5, ());
VIRTUAL_CALL(149, void, _SetPlatform6, ());
VIRTUAL_CALL(150, void, _SetPlatform7, ());
VIRTUAL_CALL(151, void, _SetPlatform8, ());
VIRTUAL_CALL(152, void, sub_B1D5B0, (uint64_t* a1), a1);
VIRTUAL_CALL(153, int64_t, sub_B317B0, (uint64_t* a1), a1);
VIRTUAL_CALL(154, const char*, sub_B17360, ());
VIRTUAL_CALL(155, void, sub_B173B0, (MED::DebugPanel::Assets* a1), a1);
VIRTUAL_CALL(156, int64_t, sub_B34690, ());
VIRTUAL_CALL(157, int64_t, sub_B34990, ());
VIRTUAL_CALL(158, int64_t, sub_B01150, (int64_t a1, float a2, float a3, float a4, int a5, int a6, char a7), a1, a2, a3, a4, a5, a6, a7);
VIRTUAL_CALL(159, _DWORD*, sub_B31E40, (int* a1), a1);
VIRTUAL_CALL(160, int64_t, sub_B17F00, (int64_t a1), a1);
VIRTUAL_CALL(161, int64_t, sub_B22340, ());
VIRTUAL_CALL(162, void, sub_B24B20, (int64_t a1), a1);
VIRTUAL_CALL(163, int64_t, sub_AFCF70, ());
VIRTUAL_CALL(164, int64_t, sub_B21770, (int64_t a1), a1);
VIRTUAL_CALL(165, void, _SetPlatform9, ());
VIRTUAL_CALL(166, int64_t, sub_B30870, (unsigned __int8 a1), a1);
VIRTUAL_CALL(167, void, sub_B1A6E0, ());
VIRTUAL_CALL(168, int64_t, sub_B05C30, ());
VIRTUAL_CALL(169, void, _SetPlatform10, ());
VIRTUAL_CALL(170, void, sub_B1A730, ());
VIRTUAL_CALL(171, int64_t, sub_B1D370, ());
VIRTUAL_CALL(172, void, sub_AFF1C0, (char a1), a1);
VIRTUAL_CALL(173, int64_t, sub_B04C10, ());
VIRTUAL_CALL(174, void, sub_B1A090, ());
VIRTUAL_CALL(175, void*, sub_B1C680, ());
VIRTUAL_CALL(176, int64_t, sub_B11210, ());
VIRTUAL_CALL(177, int64_t, sub_B124D0, ());
VIRTUAL_CALL(178, int64_t, sub_B12290, ());
VIRTUAL_CALL(179, bool, sub_B1D230, ());
VIRTUAL_CALL(180, int64_t, sub_B15DE0, ());
VIRTUAL_CALL(181, void, sub_B31F30, (float a1), a1);
VIRTUAL_CALL(182, float, sub_B183D0, ());
VIRTUAL_CALL(183, int64_t, sub_B22310, (int64_t a1), a1);
VIRTUAL_CALL(184, int64_t, sub_B22130, ());
VIRTUAL_CALL(185, void, _SetPlatform11, ());
VIRTUAL_CALL(186, char, sub_B2B0A0, (int64_t a1), a1);
VIRTUAL_CALL(187, void, sub_B30B40, (uint32_t64_t a1), a1);
VIRTUAL_CALL(188, void, sub_B30F90, (int64_t a1), a1);
VIRTUAL_CALL(189, uint32_t64_t*, sub_B03FE0, (uint32_t64_t* a1, char* a2, ... a3), a1, a2, a3);
VIRTUAL_CALL(190, int64_t, sub_B15200, (int a1), a1);
VIRTUAL_CALL(191, uint32_t64_t*, sub_B13DC0, (uint32_t64_t* a1), a1);
VIRTUAL_CALL(192, int64_t, sub_B144B0, (int64_t a1), a1);
VIRTUAL_CALL(193, physics_spec_walk*, sub_B13DF0, (physics_spec_walk* a1), a1);
VIRTUAL_CALL(194, int64_t, sub_B111F0, ());
VIRTUAL_CALL(195, int64_t, sub_B22040, ());
VIRTUAL_CALL(196, int64_t, sub_B220F0, ());
VIRTUAL_CALL(197, _DWORD*, sub_B0C760, ());
VIRTUAL_CALL(198, int64_t, sub_B0D030, ());
VIRTUAL_CALL(199, int64_t, sub_B0D040, ());
VIRTUAL_CALL(200, int64_t, sub_B221D0, ());
VIRTUAL_CALL(201, void, sub_B222C0, ());
VIRTUAL_CALL(202, uint64_t*, sub_B02D00, ());
VIRTUAL_CALL(203, int64_t, sub_B28550, (char a1, int64_t a2, int64_t a3, SExtCollInfo* a4), a1, a2, a3, a4);
VIRTUAL_CALL(204, bool, sub_B281E0, (char a1, int64_t a2, int64_t a3, int64_t a4), a1, a2, a3, a4);
VIRTUAL_CALL(205, uint32_t, sub_B21210, (char a1, int64_t a2, int64_t a3, MED::SModelOutfitItems* a4, int64_t a5), a1, a2, a3, a4, a5);
VIRTUAL_CALL(206, int64_t, sub_B07AE0, (char a1, uint32_t* a2, int64_t a3, int64_t a4, __int128* a5, char a6), a1, a2, a3, a4, a5, a6);
VIRTUAL_CALL(207, void, sub_B07DD0, (char a1, int64_t a2, int64_t a3, int64_t a4, __int128* a5), a1, a2, a3, a4, a5);
VIRTUAL_CALL(208, void, sub_AFD490, (int64_t a1, char a2), a1, a2);
VIRTUAL_CALL(209, int64_t, sub_B2C870, (int64_t a1), a1);
VIRTUAL_CALL(210, int64_t, sub_B2F0B0, (int64_t* a1), a1);
VIRTUAL_CALL(211, int64_t, sub_B2ECF0, (int64_t a1), a1);
VIRTUAL_CALL(212, uint32_t64_t*, sub_B16F10, (uint32_t64_t* a1), a1);
VIRTUAL_CALL(213, void, _SetPlatform12, ());
VIRTUAL_CALL(214, float, sub_B3EDC0, ());
#pragma endregion
};

View File

@ -3,31 +3,15 @@
class CModelObject {
#pragma region GENERATED by ExportClassToCPPH.py
public:
static bool __INTERNAL_crtti_fields_initialized_field;
static class rtti::Type & m_RTTI;
static class vec4 s_BoxColor;
static class vec4 s_HighlightedColor;
static class vec4 s_LockedBoxColor;
static bool s_RenderCollisionHulls;
static bool s_RenderFaces;
static float s_RenderHullEdgesDistance2;
static float s_RenderHullsDistance2;
static bool s_RenderTraceHulls;
static bool sm_AnimLoadBlocked;
protected:
static unsigned char near * sm_aMessageBuffer;
static int sm_nMessageBufferContent;
public:
VIRTUAL_CALL(0, __int64 __fastcall, sub_7E9B40, (__int64 a1, unsigned __int8 a2), a1, a2);
VIRTUAL_CALL(1, CModelObject *__fastcall, sub_663A40, (char a1), a1);
GAME_IMPORT virtual class CRTTI const * GetRTTI() const;
GAME_IMPORT virtual class CRTTI const * GetEngineRTTI() const;
GAME_IMPORT struct MED::SModelOutfitGroup const * unassigned() const;
VIRTUAL_CALL(4, struct MED::SModelOutfitGroup const *, unassigned, ());
VIRTUAL_CALL(5, struct MED::SModelOutfitGroup const *, _unassigned1, ());
protected:
GAME_IMPORT class gui::CPackage * ToCPackage() const;
VIRTUAL_CALL(6, class gui::CPackage *, ToCPackage, ());
public:
VIRTUAL_CALL(7, class gui::CPackage *, _ToCPackage1, ());
VIRTUAL_CALL(8, __int64, RunUnitTests, ());
@ -37,7 +21,7 @@ public:
VIRTUAL_CALL(12, struct MED::SModelOutfitGroup const *, _unassigned2, ());
GAME_IMPORT virtual void GetAllObjects(class ttl::vector<class IGSObject *, class ttl::vector_allocators::heap_allocator<class IGSObject *>, 1> &, bool);
GAME_IMPORT virtual void GetAllObjects(class ttl::set<class CRTTIObject *, struct ttl::less<class CRTTIObject *>, class ttl::allocator> &, class ttl::set<class CRTTIObject *, struct ttl::less<class CRTTIObject *>, class ttl::allocator> &, bool, class std::optional<class ttl::function_ref<bool (class CRTTIObject *)>>);
GAME_IMPORT bool updateRttiParams();
VIRTUAL_CALL(15, bool, updateRttiParams, ());
VIRTUAL_CALL(16, void __fastcall, SetPlatform, ());
GAME_IMPORT virtual char const * GetString(char const *) const;
VIRTUAL_CALL(18, __int64 __fastcall, sub_17D7D0, ());
@ -88,7 +72,7 @@ public:
VIRTUAL_CALL(63, __int64 __fastcall, sub_7E92C0, ());
VIRTUAL_CALL(64, __int64 __fastcall, sub_8092F0, ());
VIRTUAL_CALL(65, bool, _updateRttiParams10, ());
GAME_IMPORT static bool ValidateVec4(class IGSObject const *, class vec4 const &);
VIRTUAL_CALL(66, static bool, ValidateVec4, (class IGSObject const *, class vec4 const &), *, &);
VIRTUAL_CALL(67, __int64 __fastcall, sub_806BC0, ());
GAME_IMPORT virtual class ttl::string_base<char> ValueToString(class CRTTIObject * const &) const;
VIRTUAL_CALL(69, char __fastcall, sub_15DD80, ());
@ -96,7 +80,7 @@ public:
VIRTUAL_CALL(71, bool, _updateRttiParams11, ());
GAME_IMPORT virtual bool OnFieldChanged2(class CRTTIField const *, bool);
VIRTUAL_CALL(73, __int64 __fastcall, sub_173040, ());
GAME_IMPORT char const * GetMethodName() const;
VIRTUAL_CALL(74, char const *, GetMethodName, ());
VIRTUAL_CALL(75, _QWORD *__fastcall, sub_8343A0, (__int64 a1), a1);
VIRTUAL_CALL(76, bool, _updateRttiParams12, ());
VIRTUAL_CALL(77, char __fastcall, sub_81DA90, (__int64 a1), a1);
@ -177,7 +161,7 @@ public:
GAME_IMPORT virtual void EnableRenderingRayTracing(bool);
GAME_IMPORT virtual void EnableExtentsRendering(bool);
GAME_IMPORT virtual void EnableExtentOnlyRendering(bool);
GAME_IMPORT static enum COFlags::TYPE GetDefaultCOFlags();
VIRTUAL_CALL(153, static enum COFlags::TYPE, GetDefaultCOFlags, ());
GAME_IMPORT virtual void SetLodCoarseObjectHierarchy(bool);
GAME_IMPORT virtual void OnObjectMoved(unsigned char, enum FOnObjectMovedPropagate::FLAGS);
GAME_IMPORT virtual void OnChildMoved(unsigned char);
@ -253,189 +237,8 @@ public:
GAME_IMPORT virtual void AttachChildToMeshElement(class CControlObject *, class CHierarchyElement *, bool);
GAME_IMPORT virtual class extents const & GetExtentsInWorld();
GAME_IMPORT virtual void EnableCollisionHullRendering(bool);
GAME_IMPORT bool RendersCollisionHull() const;
VIRTUAL_CALL(227, bool, RendersCollisionHull, ());
GAME_IMPORT virtual void DebugRenderElementBoxes();
GAME_IMPORT virtual class aabb const & GetAABBExtents();
protected:
GAME_IMPORT CModelObject(class IModelObject *);
public:
GAME_IMPORT void AdjustVBlendElementsToExtents();
GAME_IMPORT unsigned char AnimCalculateLod(class CBaseCamera *);
GAME_IMPORT void AnimCalculateLod();
GAME_IMPORT class ttl::string_base<char> AnimGetFileName(class ttl::string_base<char> const &);
GAME_IMPORT unsigned char AnimGetLod() const;
GAME_IMPORT class Anim::IPoseElement const * AnimGetModelObjectMorphPoseElement() const;
GAME_IMPORT class Anim::IPoseElement const * AnimGetModelObjectPoseElement() const;
GAME_IMPORT float AnimGetTimeDelta() const;
GAME_IMPORT bool AnimLoadState(class CSGChunk *);
GAME_IMPORT void AnimRegisterUpdate();
GAME_IMPORT bool AnimSaveState(class CSGChunk *);
GAME_IMPORT void AnimSetLod(unsigned char);
GAME_IMPORT void AnimSetTimeDelta(float);
GAME_IMPORT virtual void AnimUpdate_PostUpdateAnimPhase2_msync();
GAME_IMPORT virtual void AnimUpdate_PreUpdateAnim();
GAME_IMPORT virtual void AnimUpdate_UpdateHierarchyLegacy();
GAME_IMPORT unsigned int AttachAudioEvent(int, class ttl::string_base<char> const &, struct Audio::SAudioEventExtraData const *, class vec3 const &);
GAME_IMPORT static void BlockAnimLoad(bool);
GAME_IMPORT bool CharacterPresetExists(class ttl::string_base<char> const &) const;
GAME_IMPORT bool CheckSurfaceFlagsEditor(unsigned int) const;
GAME_IMPORT static void CleanMessageBufferContent();
GAME_IMPORT void ClearMeshFlagsEditor(unsigned int);
GAME_IMPORT void CopyElementsPosition(class CModelObject *);
GAME_IMPORT virtual class ttl::string_const<char> Debug_GetName() const;
GAME_IMPORT void DisableAnimUpdate(unsigned int);
GAME_IMPORT class CMeshElement * GetElementEditor(unsigned int) const;
GAME_IMPORT void EnableAnimUpdate(unsigned int);
GAME_IMPORT void ExecuteAnimActions(int, int, struct TAnimId, void const *, unsigned int);
GAME_IMPORT void ExtractAllFacesEditor(class ttl::vectorm<98, class vec3, class ttl::vector_allocators::heap_allocator<class vec3>, 0> &, class ttl::vectorm<98, int, class ttl::vector_allocators::heap_allocator<int>, 2> &, class ttl::vectorm<98, int, class ttl::vector_allocators::heap_allocator<int>, 2> &, class ttl::vectorm<98, int, class ttl::vector_allocators::heap_allocator<int>, 2> &, enum ECollTree::TYPE) const;
GAME_IMPORT void ExtractAllPrimitivesEditor(class ttl::vectorm<98, struct ICollTreePrimitiveGeom const *, class ttl::vector_allocators::heap_allocator<struct ICollTreePrimitiveGeom const *>, 1> &, class ttl::vectorm<98, int, class ttl::vector_allocators::heap_allocator<int>, 2> &, enum ECollTree::TYPE) const;
GAME_IMPORT int FindElement(unsigned int);
GAME_IMPORT int FindElement(char const *);
GAME_IMPORT virtual int FindElementAnim(char const *);
GAME_IMPORT int FindElementByLowercaseName(char const *);
GAME_IMPORT int FindElementEditor(char const *);
GAME_IMPORT int FindElementOrBoneElement(char const *);
GAME_IMPORT class IMaterial * FindMaterial(class ttl::string_base<char> const &) const;
GAME_IMPORT class CMeshElement * FindMeshElement(char const *);
GAME_IMPORT class CMeshElement * FindMeshElementEditor(char const *);
GAME_IMPORT void ForceUpdateAnimations();
GAME_IMPORT virtual class mtx34 * GetAnimLocalMatricesConteiner();
GAME_IMPORT virtual int GetAnimLod(unsigned int) const;
GAME_IMPORT virtual int GetAnimLod() const;
GAME_IMPORT class vec3 GetBoneDirVector(enum EBones::TYPE);
GAME_IMPORT enum EBones::TYPE GetBoneIDFromMeshElem(int);
GAME_IMPORT class vec3 GetBoneJointPos(enum EBones::TYPE);
GAME_IMPORT class vec3 GetBonePerpVector(enum EBones::TYPE);
GAME_IMPORT char const * GetCharacterPreset(unsigned int) const;
GAME_IMPORT int GetChildrenNumElementsEditor(unsigned int) const;
GAME_IMPORT static enum ECollTree::TYPE GetDebugRenderGeometryHullType();
GAME_IMPORT union LodDissolves::SState GetDissolveState() const;
GAME_IMPORT char const * GetElementName(unsigned int) const;
GAME_IMPORT class extents GetElementReferenceExtents(int);
GAME_IMPORT enum EntityID GetElementTypeEditor(unsigned int) const;
GAME_IMPORT class CMeshElement * GetElementsEditor();
GAME_IMPORT class CMesh const * GetEmbeddedMesh() const;
GAME_IMPORT char GetForcedAnimLod() const;
GAME_IMPORT class CHierarchyElement & HElement(unsigned int);
GAME_IMPORT class CHierarchyElement * GetHElementsEditor();
GAME_IMPORT void GetInvWorldMatrixEditor(unsigned int, class mtx34 &);
GAME_IMPORT class mtx34 const & GetLocalMatrixEditor(unsigned int);
GAME_IMPORT float GetLodDissolveStep() const;
GAME_IMPORT bool GetMOFlag(unsigned char) const;
GAME_IMPORT class IMaterial * GetMaterial(unsigned int) const;
GAME_IMPORT class IMaterial * GetMaterialEditor(unsigned int) const;
GAME_IMPORT void GetMaterialSlotNamesEditor(unsigned int, char const * &, char const * &) const;
GAME_IMPORT void GetMaterialsEditor(class ttl::vector<class IMaterial *, class ttl::vector_allocators::heap_allocator<class IMaterial *>, 1> *, enum CModelObject::EMaterialsList) const;
GAME_IMPORT void GetMaterialsEditor(class CMeshElement const *, class ttl::set<class IMaterial *, struct ttl::less<class IMaterial *>, class ttl::allocator> &) const;
GAME_IMPORT class vec4 const & GetMeshAttribute(unsigned int) const;
GAME_IMPORT class mtx34 const & GetMeshAttributeMtx(unsigned int) const;
GAME_IMPORT unsigned int GetMeshAttributesCount() const;
GAME_IMPORT class vec4 const & GetMeshColor(unsigned int) const;
GAME_IMPORT void GetMeshElementsMatrices(class ttl::vector<class mtx34, class ttl::vector_allocators::heap_allocator<class mtx34>, 0> &) const;
GAME_IMPORT unsigned int GetMeshElementsMatricesCount() const;
GAME_IMPORT void GetMeshElementsState(unsigned char *, unsigned int const *, unsigned int);
GAME_IMPORT unsigned int GetMeshElementsStateSize(unsigned int);
GAME_IMPORT class IMeshFile const * GetMeshFileEditor() const;
GAME_IMPORT unsigned int GetMeshFlagsEditor(unsigned int) const;
GAME_IMPORT unsigned int GetMeshFlagsAll() const;
GAME_IMPORT char const * GetMeshName() const;
GAME_IMPORT class ttl::string_const<char> GetMeshNameConst() const;
GAME_IMPORT class CTexture * GetMeshTexture(unsigned int) const;
GAME_IMPORT __int64 GetMustHaveTags() const;
GAME_IMPORT __int64 GetMustNotHaveTags() const;
GAME_IMPORT static class CRTTI * GetSTTI();
GAME_IMPORT int GetNumElementsEditor() const;
GAME_IMPORT unsigned int GetNumFaces(enum ECollTree::TYPE) const;
GAME_IMPORT unsigned int GetNumFacesEditor(enum ECollTree::TYPE) const;
GAME_IMPORT unsigned int GetNumMaterialSlotsEditor() const;
GAME_IMPORT unsigned int GetNumPrimitives(enum ECollTree::TYPE) const;
GAME_IMPORT unsigned int GetNumPrimitivesEditor(enum ECollTree::TYPE) const;
GAME_IMPORT unsigned int GetNumSurfaceParams() const;
GAME_IMPORT unsigned int GetNumSurfaceParamsEditor() const;
GAME_IMPORT unsigned int GetNumVertices(enum ECollTree::TYPE) const;
GAME_IMPORT unsigned int GetNumVerticesEditor(enum ECollTree::TYPE) const;
GAME_IMPORT struct CModelObject::ObservedData GetObservedData();
GAME_IMPORT char const * GetPathNameEditor() const;
GAME_IMPORT int GetSeed() const;
GAME_IMPORT char const * GetSkin() const;
GAME_IMPORT char const * GetSkinName() const;
GAME_IMPORT class ttl::string_const<char> GetSkinNameConst() const;
GAME_IMPORT struct SSurfParams * GetSurfaceParams() const;
GAME_IMPORT struct SSurfParams * GetSurfaceParamsEditor() const;
GAME_IMPORT unsigned char GetTraceCollisionType() const;
GAME_IMPORT bool GetValidSkinsEditor(class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &, class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &) const;
GAME_IMPORT class mtx34 const & GetWorldMatrixEditor(unsigned int);
GAME_IMPORT bool HasMeshElement(class CMeshElement const *) const;
GAME_IMPORT bool HideElement(unsigned int);
GAME_IMPORT void HideInHierarchy(class CHierarchyElement *, bool, bool);
GAME_IMPORT bool InitMesh(char const *, int);
GAME_IMPORT void InitializeMesh();
GAME_IMPORT virtual bool IsAnimUpdateEnabled(unsigned int) const;
GAME_IMPORT virtual bool IsAnimatorValid(class Anim::IPoseAnimator const *) const;
GAME_IMPORT bool IsBiped() const;
GAME_IMPORT void MT_GetAllWeights(class ttl::vector<float, class ttl::vector_allocators::heap_allocator<float>, 2> &);
GAME_IMPORT unsigned int MT_GetCount() const;
GAME_IMPORT void MT_ResetWeights();
GAME_IMPORT void MT_SetAllWeights(class ttl::vector<float, class ttl::vector_allocators::heap_allocator<float>, 2> const &);
GAME_IMPORT float MT_WeightGet(unsigned int);
GAME_IMPORT float MT_WeightGetEditor(unsigned int);
GAME_IMPORT void MT_WeightSet(unsigned int, float);
GAME_IMPORT void MT_WeightSetEditor(unsigned int, float);
GAME_IMPORT void MoveElementBoxSide(int, int, float);
GAME_IMPORT void MoveElementBoxSides(int, float, float, float, float, float, float);
GAME_IMPORT virtual void OnAnimationPlayed();
GAME_IMPORT unsigned int PlayAudioEvent(class ttl::string_base<char> const &, struct Audio::SAudioEventExtraData const *, class vec3 const &, class vec3 const &);
GAME_IMPORT unsigned int PlayAudioEvent(unsigned int, struct Audio::SAudioEventExtraDataID const *, class vec3 const &, class vec3 const &);
GAME_IMPORT void PostUpdateAnim();
GAME_IMPORT void PreUpdateAnim();
GAME_IMPORT bool RaytraceEditor(class mtx34 const &, class mtx34 const &, class vec3 const &, class vec3 &, struct SExtCollInfo *);
GAME_IMPORT bool RaytraceElementExtents(class vec3 const &, class vec3 &, struct SExtCollInfo *, bool);
GAME_IMPORT void RecalculateBoundVolume();
GAME_IMPORT static void RegisterSTTI(class CRTTI *);
GAME_IMPORT void RenderElementBoxes();
GAME_IMPORT void ReplaceMaterial(class IMeshFile const *, char const *, char const *, bool);
GAME_IMPORT void RestoreAnimationUpdateAbility(bool const &, class ttl::vector<bool, class ttl::vector_allocators::heap_allocator<bool>, 8> const &);
GAME_IMPORT virtual void SendAnimEvents(class ttl::span<struct AnimEventInfo const, 4294967295>);
GAME_IMPORT void SetAudioEventSwitch(unsigned int, class ttl::string_base<char> const &, class ttl::string_base<char> const &);
GAME_IMPORT bool SetCharacter(char const *, char const *);
GAME_IMPORT bool SetCharacterEditor(char const *, char const *);
GAME_IMPORT void SetDissolveState(union LodDissolves::SState, bool);
GAME_IMPORT void SetDontApplyAnim(bool);
GAME_IMPORT void SetElementExtents(int, class vec3 const &, class vec3 const &);
GAME_IMPORT void SetForcedAnimLod(char);
GAME_IMPORT void SetForcedLOD(int);
GAME_IMPORT void SetInitializeMesh(bool);
GAME_IMPORT void SetLodDissolveStep(float);
GAME_IMPORT void SetMOFlag(unsigned char, bool);
GAME_IMPORT void SetMeshAttribute(unsigned int, class vec4 const &);
GAME_IMPORT void SetMeshAttributeMtx(unsigned int, class mtx34 const &);
GAME_IMPORT void SetMeshColor(unsigned int, class vec4 const &);
GAME_IMPORT bool SetMeshElementsMatrices(class ttl::vector<class mtx34, class ttl::vector_allocators::heap_allocator<class mtx34>, 0> const &);
GAME_IMPORT void SetMeshElementsState(unsigned char const *, unsigned int const *, unsigned int, bool, bool);
GAME_IMPORT void SetMeshFlagsEditor(unsigned int);
GAME_IMPORT void SetMeshFlagsAll(unsigned int);
GAME_IMPORT void SetMeshTexture(unsigned int, class CTexture *);
GAME_IMPORT void SetMustHaveTags(__int64);
GAME_IMPORT void SetMustNotHaveTags(__int64);
GAME_IMPORT void SetRenderElementBoxes(bool, int, int);
GAME_IMPORT void SetSeed(int);
GAME_IMPORT bool SetSkin(char const *, __int64, __int64, unsigned int, bool, bool);
GAME_IMPORT bool SetSkinEditor(char const *, __int64, __int64, unsigned int);
GAME_IMPORT void SetSkinName(class ttl::string_const<char>);
GAME_IMPORT void SetTraceCollisionType(unsigned char);
GAME_IMPORT bool ShouldApplyAnim() const;
GAME_IMPORT bool ShouldInitializeMesh() const;
GAME_IMPORT bool SkinExists(class ttl::string_base<char> const &) const;
GAME_IMPORT void StopAnimAction(int, struct TAnimId, void const *, float);
GAME_IMPORT class IModelObject const * ToIModelObject() const;
GAME_IMPORT bool UnhideElement(unsigned int);
GAME_IMPORT void UnlockAnimationUpdateAbility(bool &, class ttl::vector<bool, class ttl::vector_allocators::heap_allocator<bool>, 8> &);
private:
GAME_IMPORT static class CRTTI * __INTERNAL_crtti_factory();
GAME_IMPORT static bool __INTERNAL_crtti_fields_initialized_function();
GAME_IMPORT static class rtti::Type & __INTERNAL_type_factory();
public:
GAME_IMPORT static class rtti::Type & typeinfo();
#pragma endregion
};

View File

@ -3,31 +3,15 @@
class CModelObject {
#pragma region GENERATED by ExportClassToCPPH.py
public:
static bool __INTERNAL_crtti_fields_initialized_field;
static rtti::Type& m_RTTI;
static vec4 s_BoxColor;
static vec4 s_HighlightedColor;
static vec4 s_LockedBoxColor;
static bool s_RenderCollisionHulls;
static bool s_RenderFaces;
static float s_RenderHullEdgesDistance2;
static float s_RenderHullsDistance2;
static bool s_RenderTraceHulls;
static bool sm_AnimLoadBlocked;
protected:
static unsigned char near* sm_aMessageBuffer;
static int sm_nMessageBufferContent;
public:
VIRTUAL_CALL(0, int64_t, sub_7E9B40, (int64_t a1, unsigned __int8 a2), a1, a2);
VIRTUAL_CALL(1, CModelObject*, sub_663A40, (char a1), a1);
GAME_IMPORT virtual CRTTI const* GetRTTI() const;
GAME_IMPORT virtual CRTTI const* GetEngineRTTI() const;
GAME_IMPORT MED::SModelOutfitGroup const* unassigned() const;
VIRTUAL_CALL(4, MED::SModelOutfitGroup const*, unassigned, ());
VIRTUAL_CALL(5, MED::SModelOutfitGroup const*, _unassigned1, ());
protected:
GAME_IMPORT gui::CPackage* ToCPackage() const;
VIRTUAL_CALL(6, gui::CPackage*, ToCPackage, ());
public:
VIRTUAL_CALL(7, gui::CPackage*, _ToCPackage1, ());
VIRTUAL_CALL(8, int64_t, RunUnitTests, ());
@ -37,7 +21,7 @@ public:
VIRTUAL_CALL(12, MED::SModelOutfitGroup const*, _unassigned2, ());
GAME_IMPORT virtual void GetAllObjects(ttl::vector<IGSObject*, ttl::vector_allocators::heap_allocator<IGSObject*>, 1>&, bool);
GAME_IMPORT virtual void GetAllObjects(ttl::set<CRTTIObject*, ttl::less<CRTTIObject*>, ttl::allocator>&, ttl::set<CRTTIObject*, ttl::less<CRTTIObject*>, ttl::allocator>&, bool, std::optional<ttl::function_ref<bool ( CRTTIObject* )>>);
GAME_IMPORT bool updateRttiParams();
VIRTUAL_CALL(15, bool, updateRttiParams, ());
VIRTUAL_CALL(16, void, SetPlatform, ());
GAME_IMPORT virtual char const* GetString(char const*) const;
VIRTUAL_CALL(18, int64_t, sub_17D7D0, ());
@ -88,7 +72,7 @@ public:
VIRTUAL_CALL(63, int64_t, sub_7E92C0, ());
VIRTUAL_CALL(64, int64_t, sub_8092F0, ());
VIRTUAL_CALL(65, bool, _updateRttiParams10, ());
GAME_IMPORT static bool ValidateVec4(IGSObject const*, vec4 const&);
VIRTUAL_CALL(66, static bool, ValidateVec4, (IGSObject const*, vec4 const&), const*, const&);
VIRTUAL_CALL(67, int64_t, sub_806BC0, ());
GAME_IMPORT virtual ttl::string_base<char> ValueToString(CRTTIObject* const&) const;
VIRTUAL_CALL(69, char, sub_15DD80, ());
@ -96,7 +80,7 @@ public:
VIRTUAL_CALL(71, bool, _updateRttiParams11, ());
GAME_IMPORT virtual bool OnFieldChanged2(CRTTIField const*, bool);
VIRTUAL_CALL(73, int64_t, sub_173040, ());
GAME_IMPORT char const* GetMethodName() const;
VIRTUAL_CALL(74, char const*, GetMethodName, ());
VIRTUAL_CALL(75, uint64_t*, sub_8343A0, (int64_t a1), a1);
VIRTUAL_CALL(76, bool, _updateRttiParams12, ());
VIRTUAL_CALL(77, char, sub_81DA90, (int64_t a1), a1);
@ -177,7 +161,7 @@ public:
GAME_IMPORT virtual void EnableRenderingRayTracing(bool);
GAME_IMPORT virtual void EnableExtentsRendering(bool);
GAME_IMPORT virtual void EnableExtentOnlyRendering(bool);
GAME_IMPORT static COFlags::TYPE GetDefaultCOFlags();
VIRTUAL_CALL(153, static COFlags::TYPE, GetDefaultCOFlags, ());
GAME_IMPORT virtual void SetLodCoarseObjectHierarchy(bool);
GAME_IMPORT virtual void OnObjectMoved(unsigned char, FOnObjectMovedPropagate::FLAGS);
GAME_IMPORT virtual void OnChildMoved(unsigned char);
@ -253,189 +237,8 @@ public:
GAME_IMPORT virtual void AttachChildToMeshElement(CControlObject*, CHierarchyElement*, bool);
GAME_IMPORT virtual extents const& GetExtentsInWorld();
GAME_IMPORT virtual void EnableCollisionHullRendering(bool);
GAME_IMPORT bool RendersCollisionHull() const;
VIRTUAL_CALL(227, bool, RendersCollisionHull, ());
GAME_IMPORT virtual void DebugRenderElementBoxes();
GAME_IMPORT virtual aabb const& GetAABBExtents();
protected:
GAME_IMPORT CModelObject(IModelObject*);
public:
GAME_IMPORT void AdjustVBlendElementsToExtents();
GAME_IMPORT unsigned char AnimCalculateLod(CBaseCamera*);
GAME_IMPORT void AnimCalculateLod();
GAME_IMPORT ttl::string_base<char> AnimGetFileName(ttl::string_base<char> const&);
GAME_IMPORT unsigned char AnimGetLod() const;
GAME_IMPORT Anim::IPoseElement const* AnimGetModelObjectMorphPoseElement() const;
GAME_IMPORT Anim::IPoseElement const* AnimGetModelObjectPoseElement() const;
GAME_IMPORT float AnimGetTimeDelta() const;
GAME_IMPORT bool AnimLoadState(CSGChunk*);
GAME_IMPORT void AnimRegisterUpdate();
GAME_IMPORT bool AnimSaveState(CSGChunk*);
GAME_IMPORT void AnimSetLod(unsigned char);
GAME_IMPORT void AnimSetTimeDelta(float);
GAME_IMPORT virtual void AnimUpdate_PostUpdateAnimPhase2_msync();
GAME_IMPORT virtual void AnimUpdate_PreUpdateAnim();
GAME_IMPORT virtual void AnimUpdate_UpdateHierarchyLegacy();
GAME_IMPORT uint32_t AttachAudioEvent(int, ttl::string_base<char> const&, Audio::SAudioEventExtraData const*, vec3 const&);
GAME_IMPORT static void BlockAnimLoad(bool);
GAME_IMPORT bool CharacterPresetExists(ttl::string_base<char> const&) const;
GAME_IMPORT bool CheckSurfaceFlagsEditor(uint32_t) const;
GAME_IMPORT static void CleanMessageBufferContent();
GAME_IMPORT void ClearMeshFlagsEditor(uint32_t);
GAME_IMPORT void CopyElementsPosition(CModelObject*);
GAME_IMPORT virtual ttl::string_const<char> Debug_GetName() const;
GAME_IMPORT void DisableAnimUpdate(uint32_t);
GAME_IMPORT CMeshElement* GetElementEditor(uint32_t) const;
GAME_IMPORT void EnableAnimUpdate(uint32_t);
GAME_IMPORT void ExecuteAnimActions(int, int, TAnimId, void const*, uint32_t);
GAME_IMPORT void ExtractAllFacesEditor(ttl::vectorm<98, vec3, ttl::vector_allocators::heap_allocator<vec3>, 0>&, ttl::vectorm<98, int, ttl::vector_allocators::heap_allocator<int>, 2>&, ttl::vectorm<98, int, ttl::vector_allocators::heap_allocator<int>, 2>&, ttl::vectorm<98, int, ttl::vector_allocators::heap_allocator<int>, 2>&, ECollTree::TYPE) const;
GAME_IMPORT void ExtractAllPrimitivesEditor(ttl::vectorm<98, ICollTreePrimitiveGeom const*, ttl::vector_allocators::heap_allocator<ICollTreePrimitiveGeom const*>, 1>&, ttl::vectorm<98, int, ttl::vector_allocators::heap_allocator<int>, 2>&, ECollTree::TYPE) const;
GAME_IMPORT int FindElement(uint32_t);
GAME_IMPORT int FindElement(char const*);
GAME_IMPORT virtual int FindElementAnim(char const*);
GAME_IMPORT int FindElementByLowercaseName(char const*);
GAME_IMPORT int FindElementEditor(char const*);
GAME_IMPORT int FindElementOrBoneElement(char const*);
GAME_IMPORT IMaterial* FindMaterial(ttl::string_base<char> const&) const;
GAME_IMPORT CMeshElement* FindMeshElement(char const*);
GAME_IMPORT CMeshElement* FindMeshElementEditor(char const*);
GAME_IMPORT void ForceUpdateAnimations();
GAME_IMPORT virtual mtx34* GetAnimLocalMatricesConteiner();
GAME_IMPORT virtual int GetAnimLod(uint32_t) const;
GAME_IMPORT virtual int GetAnimLod() const;
GAME_IMPORT vec3 GetBoneDirVector(EBones::TYPE);
GAME_IMPORT EBones::TYPE GetBoneIDFromMeshElem(int);
GAME_IMPORT vec3 GetBoneJointPos(EBones::TYPE);
GAME_IMPORT vec3 GetBonePerpVector(EBones::TYPE);
GAME_IMPORT char const* GetCharacterPreset(uint32_t) const;
GAME_IMPORT int GetChildrenNumElementsEditor(uint32_t) const;
GAME_IMPORT static ECollTree::TYPE GetDebugRenderGeometryHullType();
GAME_IMPORT LodDissolves::SState GetDissolveState() const;
GAME_IMPORT char const* GetElementName(uint32_t) const;
GAME_IMPORT extents GetElementReferenceExtents(int);
GAME_IMPORT EntityID GetElementTypeEditor(uint32_t) const;
GAME_IMPORT CMeshElement* GetElementsEditor();
GAME_IMPORT CMesh const* GetEmbeddedMesh() const;
GAME_IMPORT char GetForcedAnimLod() const;
GAME_IMPORT CHierarchyElement& HElement(uint32_t);
GAME_IMPORT CHierarchyElement* GetHElementsEditor();
GAME_IMPORT void GetInvWorldMatrixEditor(uint32_t, mtx34&);
GAME_IMPORT mtx34 const& GetLocalMatrixEditor(uint32_t);
GAME_IMPORT float GetLodDissolveStep() const;
GAME_IMPORT bool GetMOFlag(unsigned char) const;
GAME_IMPORT IMaterial* GetMaterial(uint32_t) const;
GAME_IMPORT IMaterial* GetMaterialEditor(uint32_t) const;
GAME_IMPORT void GetMaterialSlotNamesEditor(uint32_t, char const* &, char const* &) const;
GAME_IMPORT void GetMaterialsEditor(ttl::vector<IMaterial*, ttl::vector_allocators::heap_allocator<IMaterial*>, 1>*, CModelObject::EMaterialsList) const;
GAME_IMPORT void GetMaterialsEditor(CMeshElement const*, ttl::set<IMaterial*, ttl::less<IMaterial*>, ttl::allocator>&) const;
GAME_IMPORT vec4 const& GetMeshAttribute(uint32_t) const;
GAME_IMPORT mtx34 const& GetMeshAttributeMtx(uint32_t) const;
GAME_IMPORT uint32_t GetMeshAttributesCount() const;
GAME_IMPORT vec4 const& GetMeshColor(uint32_t) const;
GAME_IMPORT void GetMeshElementsMatrices(ttl::vector<mtx34, ttl::vector_allocators::heap_allocator<mtx34>, 0>&) const;
GAME_IMPORT uint32_t GetMeshElementsMatricesCount() const;
GAME_IMPORT void GetMeshElementsState(unsigned char*, uint32_t const*, uint32_t);
GAME_IMPORT uint32_t GetMeshElementsStateSize(uint32_t);
GAME_IMPORT IMeshFile const* GetMeshFileEditor() const;
GAME_IMPORT uint32_t GetMeshFlagsEditor(uint32_t) const;
GAME_IMPORT uint32_t GetMeshFlagsAll() const;
GAME_IMPORT char const* GetMeshName() const;
GAME_IMPORT ttl::string_const<char> GetMeshNameConst() const;
GAME_IMPORT CTexture* GetMeshTexture(uint32_t) const;
GAME_IMPORT int64_t GetMustHaveTags() const;
GAME_IMPORT int64_t GetMustNotHaveTags() const;
GAME_IMPORT static CRTTI* GetSTTI();
GAME_IMPORT int GetNumElementsEditor() const;
GAME_IMPORT uint32_t GetNumFaces(ECollTree::TYPE) const;
GAME_IMPORT uint32_t GetNumFacesEditor(ECollTree::TYPE) const;
GAME_IMPORT uint32_t GetNumMaterialSlotsEditor() const;
GAME_IMPORT uint32_t GetNumPrimitives(ECollTree::TYPE) const;
GAME_IMPORT uint32_t GetNumPrimitivesEditor(ECollTree::TYPE) const;
GAME_IMPORT uint32_t GetNumSurfaceParams() const;
GAME_IMPORT uint32_t GetNumSurfaceParamsEditor() const;
GAME_IMPORT uint32_t GetNumVertices(ECollTree::TYPE) const;
GAME_IMPORT uint32_t GetNumVerticesEditor(ECollTree::TYPE) const;
GAME_IMPORT CModelObject::ObservedData GetObservedData();
GAME_IMPORT char const* GetPathNameEditor() const;
GAME_IMPORT int GetSeed() const;
GAME_IMPORT char const* GetSkin() const;
GAME_IMPORT char const* GetSkinName() const;
GAME_IMPORT ttl::string_const<char> GetSkinNameConst() const;
GAME_IMPORT SSurfParams* GetSurfaceParams() const;
GAME_IMPORT SSurfParams* GetSurfaceParamsEditor() const;
GAME_IMPORT unsigned char GetTraceCollisionType() const;
GAME_IMPORT bool GetValidSkinsEditor(ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&, ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&) const;
GAME_IMPORT mtx34 const& GetWorldMatrixEditor(uint32_t);
GAME_IMPORT bool HasMeshElement(CMeshElement const*) const;
GAME_IMPORT bool HideElement(uint32_t);
GAME_IMPORT void HideInHierarchy(CHierarchyElement*, bool, bool);
GAME_IMPORT bool InitMesh(char const*, int);
GAME_IMPORT void InitializeMesh();
GAME_IMPORT virtual bool IsAnimUpdateEnabled(uint32_t) const;
GAME_IMPORT virtual bool IsAnimatorValid(Anim::IPoseAnimator const*) const;
GAME_IMPORT bool IsBiped() const;
GAME_IMPORT void MT_GetAllWeights(ttl::vector<float, ttl::vector_allocators::heap_allocator<float>, 2>&);
GAME_IMPORT uint32_t MT_GetCount() const;
GAME_IMPORT void MT_ResetWeights();
GAME_IMPORT void MT_SetAllWeights(ttl::vector<float, ttl::vector_allocators::heap_allocator<float>, 2> const&);
GAME_IMPORT float MT_WeightGet(uint32_t);
GAME_IMPORT float MT_WeightGetEditor(uint32_t);
GAME_IMPORT void MT_WeightSet(uint32_t, float);
GAME_IMPORT void MT_WeightSetEditor(uint32_t, float);
GAME_IMPORT void MoveElementBoxSide(int, int, float);
GAME_IMPORT void MoveElementBoxSides(int, float, float, float, float, float, float);
GAME_IMPORT virtual void OnAnimationPlayed();
GAME_IMPORT uint32_t PlayAudioEvent(ttl::string_base<char> const&, Audio::SAudioEventExtraData const*, vec3 const&, vec3 const&);
GAME_IMPORT uint32_t PlayAudioEvent(uint32_t, Audio::SAudioEventExtraDataID const*, vec3 const&, vec3 const&);
GAME_IMPORT void PostUpdateAnim();
GAME_IMPORT void PreUpdateAnim();
GAME_IMPORT bool RaytraceEditor(mtx34 const&, mtx34 const&, vec3 const&, vec3&, SExtCollInfo*);
GAME_IMPORT bool RaytraceElementExtents(vec3 const&, vec3&, SExtCollInfo*, bool);
GAME_IMPORT void RecalculateBoundVolume();
GAME_IMPORT static void RegisterSTTI(CRTTI*);
GAME_IMPORT void RenderElementBoxes();
GAME_IMPORT void ReplaceMaterial(IMeshFile const*, char const*, char const*, bool);
GAME_IMPORT void RestoreAnimationUpdateAbility(bool const&, ttl::vector<bool, ttl::vector_allocators::heap_allocator<bool>, 8> const&);
GAME_IMPORT virtual void SendAnimEvents(ttl::span<AnimEventInfo const, 4294967295>);
GAME_IMPORT void SetAudioEventSwitch(uint32_t, ttl::string_base<char> const&, ttl::string_base<char> const&);
GAME_IMPORT bool SetCharacter(char const*, char const*);
GAME_IMPORT bool SetCharacterEditor(char const*, char const*);
GAME_IMPORT void SetDissolveState(LodDissolves::SState, bool);
GAME_IMPORT void SetDontApplyAnim(bool);
GAME_IMPORT void SetElementExtents(int, vec3 const&, vec3 const&);
GAME_IMPORT void SetForcedAnimLod(char);
GAME_IMPORT void SetForcedLOD(int);
GAME_IMPORT void SetInitializeMesh(bool);
GAME_IMPORT void SetLodDissolveStep(float);
GAME_IMPORT void SetMOFlag(unsigned char, bool);
GAME_IMPORT void SetMeshAttribute(uint32_t, vec4 const&);
GAME_IMPORT void SetMeshAttributeMtx(uint32_t, mtx34 const&);
GAME_IMPORT void SetMeshColor(uint32_t, vec4 const&);
GAME_IMPORT bool SetMeshElementsMatrices(ttl::vector<mtx34, ttl::vector_allocators::heap_allocator<mtx34>, 0> const&);
GAME_IMPORT void SetMeshElementsState(unsigned char const*, uint32_t const*, uint32_t, bool, bool);
GAME_IMPORT void SetMeshFlagsEditor(uint32_t);
GAME_IMPORT void SetMeshFlagsAll(uint32_t);
GAME_IMPORT void SetMeshTexture(uint32_t, CTexture*);
GAME_IMPORT void SetMustHaveTags(int64_t);
GAME_IMPORT void SetMustNotHaveTags(int64_t);
GAME_IMPORT void SetRenderElementBoxes(bool, int, int);
GAME_IMPORT void SetSeed(int);
GAME_IMPORT bool SetSkin(char const*, int64_t, int64_t, uint32_t, bool, bool);
GAME_IMPORT bool SetSkinEditor(char const*, int64_t, int64_t, uint32_t);
GAME_IMPORT void SetSkinName(ttl::string_const<char>);
GAME_IMPORT void SetTraceCollisionType(unsigned char);
GAME_IMPORT bool ShouldApplyAnim() const;
GAME_IMPORT bool ShouldInitializeMesh() const;
GAME_IMPORT bool SkinExists(ttl::string_base<char> const&) const;
GAME_IMPORT void StopAnimAction(int, TAnimId, void const*, float);
GAME_IMPORT IModelObject const* ToIModelObject() const;
GAME_IMPORT bool UnhideElement(uint32_t);
GAME_IMPORT void UnlockAnimationUpdateAbility(bool&, ttl::vector<bool, ttl::vector_allocators::heap_allocator<bool>, 8>&);
private:
GAME_IMPORT static CRTTI* __INTERNAL_crtti_factory();
GAME_IMPORT static bool __INTERNAL_crtti_fields_initialized_function();
GAME_IMPORT static rtti::Type& __INTERNAL_type_factory();
public:
GAME_IMPORT static rtti::Type& typeinfo();
#pragma endregion
};

View File

@ -2,6 +2,7 @@
#include <EGSDK\Imports.h>
class IModelObject {
#pragma region GENERATED by ExportClassToCPPH.py
public:
VIRTUAL_CALL(0, _QWORD *__fastcall, sub_1203B0, (char a1), a1);
GAME_IMPORT virtual class IAnimBind const * GetAnimBind() const;
@ -11,7 +12,7 @@ public:
GAME_IMPORT virtual struct TAnimId GetAnimationId(class ttl::string_const<char>, bool) const;
GAME_IMPORT virtual float GetAnimLength(struct TAnimId) const;
GAME_IMPORT virtual float GetAnimLength(class ttl::string_base<char> const &) const;
GAME_IMPORT float odb_GetLoadTime(struct RLROD_Batch *);
VIRTUAL_CALL(8, float, odb_GetLoadTime, (struct RLROD_Batch *), *);
GAME_IMPORT virtual class mtx34 const & GetWorldXform() const;
GAME_IMPORT virtual int GetElementIndex(char const *) const;
GAME_IMPORT virtual class ttl::string_base<char> GetElementName(int) const;
@ -154,105 +155,103 @@ public:
VIRTUAL_CALL(146, void __fastcall, _SetPlatform3, ());
GAME_IMPORT virtual bool GetMeshDataForSimpleObjectsEditor(class ttl::string_base<char> *, class ttl::string_base<char> *, __int64 *, __int64 *, int *);
VIRTUAL_CALL(148, __int64, _RunUnitTests1, ());
GAME_IMPORT class ttl::list<struct SCommandParam, class ttl::allocator>::const_reverse_iterator rend() const;
VIRTUAL_CALL(149, class ttl::list<struct SCommandParam, class ttl::allocator>::const_reverse_iterator, rend, ());
protected:
GAME_IMPORT IModelObject();
public:
GAME_IMPORT IModelObject(class IModelObject const &);
protected:
GAME_IMPORT ~IModelObject();
public:
GAME_IMPORT void AdjustExtentsToAllElements(bool, bool);
GAME_IMPORT class Anim::IPoseElement const * AnimGetMeshPoseElement() const;
GAME_IMPORT class Anim::IPoseElement const * AnimGetModelObjectMorphPoseElement() const;
GAME_IMPORT class Anim::IPoseElement const * AnimGetModelObjectPoseElement() const;
GAME_IMPORT bool AnimReInit(class ttl::string_base<char> const &);
GAME_IMPORT static void CollectMeshSkins(class ttl::string_base<char> const &, bool, class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &);
GAME_IMPORT void CollectUsedTextures(class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &);
GAME_IMPORT void CopyElementsPosition(class IModelObject *);
GAME_IMPORT void DumpAnims();
GAME_IMPORT bool EnableElementPhysics(int, bool, bool);
GAME_IMPORT void EnableHierarchySerialization(bool);
GAME_IMPORT void EnableRenderingRayTracing(bool);
GAME_IMPORT void EnableRenderingScene(bool);
GAME_IMPORT void EnableRenderingShadows(bool);
GAME_IMPORT void EnableUpdateExtents(bool);
GAME_IMPORT class aabb const & GetAABBExtents() const;
GAME_IMPORT void GetAnimationNames(class ttl::map<class ttl::string_base<char>, struct TAnimId, struct ttl::less<class ttl::string_base<char>>, class ttl::allocator> &);
GAME_IMPORT static enum COFlags::TYPE GetDefaultCOFlags();
GAME_IMPORT int GetCurrentLOD() const;
GAME_IMPORT union LodDissolves::SState GetCurrentLodState() const;
GAME_IMPORT char GetForcedAnimLod() const;
GAME_IMPORT float GetLodDissolveStep() const;
GAME_IMPORT void GetMeshElementsMatrices(class ttl::vector<class mtx34, class ttl::vector_allocators::heap_allocator<class mtx34>, 0> &) const;
GAME_IMPORT unsigned int GetMeshElementsMatricesCount() const;
GAME_IMPORT int GetMeshElementsState(class ttl::vector<unsigned char, class ttl::vector_allocators::heap_allocator<unsigned char>, 8> &, class ttl::vector<int, class ttl::vector_allocators::heap_allocator<int>, 2> const &) const;
GAME_IMPORT int GetMeshElementsStateSize(class ttl::vector<int, class ttl::vector_allocators::heap_allocator<int>, 2> const &) const;
GAME_IMPORT float GetMeshLodDistance(int) const;
GAME_IMPORT struct SMeshVisibilityParams const * GetMeshVisibilityParams() const;
GAME_IMPORT IModelObject(class IModelObject const &);
GAME_IMPORT float GetMeshVisibilityRange();
GAME_IMPORT static class IModelObject * GetModelObject(class IGSObject *);
GAME_IMPORT static class IModelObject * GetModelObject(class cbs::CEntity const *);
GAME_IMPORT static class IModelObject const * GetModelObject(class IGSObject const *);
GAME_IMPORT unsigned int GetNumCollisionHullFaces() const;
GAME_IMPORT bool SkinExists(class ttl::string_base<char> const &);
GAME_IMPORT int GetCurrentLOD() const;
GAME_IMPORT void SetExtentsLocal(class extents const &);
GAME_IMPORT unsigned int GetMeshElementsMatricesCount() const;
GAME_IMPORT char GetForcedAnimLod() const;
GAME_IMPORT unsigned int GetNumCollisionHullPrimitives() const;
GAME_IMPORT unsigned int GetNumCollisionHullVertices() const;
GAME_IMPORT unsigned int GetNumSurfaceParams() const;
GAME_IMPORT unsigned int GetNumTraceHullFaces() const;
GAME_IMPORT unsigned int GetNumTraceHullPrimitives() const;
GAME_IMPORT unsigned int GetNumTraceHullVertices() const;
GAME_IMPORT class ttl::string_const<char> GetSkin() const;
GAME_IMPORT static __int64 GetSkinTagsFromStr(char const *);
GAME_IMPORT struct SSurfParams * GetSurfaceParams() const;
GAME_IMPORT int GetTraceCollType() const;
GAME_IMPORT bool GetValidSkinsEditor(class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &, class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &) const;
GAME_IMPORT void MoveElementBoxSides(int, float, float, float, float, float, float);
GAME_IMPORT bool SetSkinNoCharacterPreset();
GAME_IMPORT void SetBestGeomLods();
GAME_IMPORT bool IsElementPhysicsEnabled(int);
GAME_IMPORT bool IsDefaultMeshLoaded();
GAME_IMPORT void SetLodDissolveStep(float);
GAME_IMPORT static class IModelObject const * GetModelObject(class IGSObject const *);
GAME_IMPORT union LodDissolves::SState GetCurrentLodState() const;
GAME_IMPORT static class IModelObject * GetModelObject(class cbs::CEntity const *);
GAME_IMPORT int GetMeshElementsStateSize(class ttl::vector<int, class ttl::vector_allocators::heap_allocator<int>, 2> const &) const;
GAME_IMPORT bool EnableElementPhysics(int, bool, bool);
private:
GAME_IMPORT bool IsElementIDValid(int) const;
public:
GAME_IMPORT bool IsElementPhysicsEnabled(int);
GAME_IMPORT bool IsObjectDissolved() const;
GAME_IMPORT void LoadMesh(bool);
GAME_IMPORT void LoadMeshElements(class ISGChunk *);
GAME_IMPORT int MT_GetCount();
GAME_IMPORT char const * MT_GetName(unsigned int);
GAME_IMPORT float MT_WeightGet(unsigned int);
GAME_IMPORT static bool MeshAndSkinExists(class ttl::string_base<char> const &, class ttl::string_base<char> const &);
GAME_IMPORT static bool MeshExist(class ttl::string_base<char> const &);
GAME_IMPORT void MeshUseDefaultVisibilityParameters();
GAME_IMPORT void MoveElementBoxSide(int, int, float);
GAME_IMPORT void MoveElementBoxSides(int, class vec3 const &, class vec3 const &);
GAME_IMPORT void MoveElementBoxSides(int, float, float, float, float, float, float);
GAME_IMPORT bool RaytestMe(class vec3 const &, class vec3 &, unsigned short, bool, unsigned short);
GAME_IMPORT bool RaytraceMe(struct SCollision *, class vec3 const &, class vec3 &, unsigned short, bool, unsigned short);
GAME_IMPORT bool ReplaceMaterial(class ttl::string_base<char> const &, class ttl::string_base<char> const &);
GAME_IMPORT void ResetBoneAndDescendantsToReferenceFrame(int);
GAME_IMPORT void ResetBonesExtentsToReferenceFrame();
GAME_IMPORT void ResetBonesToReferenceFrame(bool);
GAME_IMPORT void ResetElementsDescendantsToReferenceFrame(int);
GAME_IMPORT void SaveMeshElements(class ISGChunk *);
GAME_IMPORT void SetBestGeomLods();
GAME_IMPORT void SetDontApplyAnim(bool);
GAME_IMPORT void SetExtentsLocal(class extents const &);
GAME_IMPORT void SetForcedAnimLod(char);
GAME_IMPORT void SetLodDissolveStep(float);
GAME_IMPORT void SetLodStateForSpawnedObjects(union LodDissolves::SState);
GAME_IMPORT void SetMeshCullSizeEnable(bool);
GAME_IMPORT bool SetMeshElementsMatrices(class ttl::vector<class mtx34, class ttl::vector_allocators::heap_allocator<class mtx34>, 0> const &);
GAME_IMPORT int SetMeshElementsState(class ttl::vector<unsigned char, class ttl::vector_allocators::heap_allocator<unsigned char>, 8> const &, class ttl::vector<int, class ttl::vector_allocators::heap_allocator<int>, 2> const &, bool, bool);
GAME_IMPORT void SetMeshLodDistance(int, float);
GAME_IMPORT void SetMeshVisibilityRange(float);
GAME_IMPORT bool SetSkin();
GAME_IMPORT bool SetSkinNoCharacterPreset();
GAME_IMPORT void SetTraceCollType(int);
GAME_IMPORT bool ShouldApplyAnim() const;
GAME_IMPORT void ShowCollisionHull(bool);
GAME_IMPORT void ShowElementBox(class ttl::string_base<char> const &);
GAME_IMPORT void ShowElementBoxes(bool);
GAME_IMPORT void ShowElementBoxesFrom(class ttl::string_base<char> const &);
GAME_IMPORT void ResetBonesExtentsToReferenceFrame();
GAME_IMPORT void EnableHierarchySerialization(bool);
GAME_IMPORT void ShowElementBoxesFromTo(class ttl::string_base<char> const &, class ttl::string_base<char> const &);
GAME_IMPORT bool RaytestMe(class vec3 const &, class vec3 &, unsigned short, bool, unsigned short);
GAME_IMPORT static void CollectMeshSkins(class ttl::string_base<char> const &, bool, class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &);
GAME_IMPORT void GetMeshElementsMatrices(class ttl::vector<class mtx34, class ttl::vector_allocators::heap_allocator<class mtx34>, 0> &) const;
GAME_IMPORT bool AnimReInit(class ttl::string_base<char> const &);
GAME_IMPORT void SetLodStateForSpawnedObjects(union LodDissolves::SState);
GAME_IMPORT unsigned int GetNumSurfaceParams() const;
GAME_IMPORT void EnableUpdateExtents(bool);
GAME_IMPORT void ShowElementBox(class ttl::string_base<char> const &);
GAME_IMPORT void ShowElementBoxesTo(class ttl::string_base<char> const &);
GAME_IMPORT void LoadMesh(bool);
GAME_IMPORT static enum COFlags::TYPE GetDefaultCOFlags();
GAME_IMPORT void LoadMeshElements(class ISGChunk *);
GAME_IMPORT static __int64 GetSkinTagsFromStr(char const *);
GAME_IMPORT void ShowExtents(bool);
GAME_IMPORT bool SkinExists(class ttl::string_base<char> const &);
GAME_IMPORT char const * MT_GetName(unsigned int);
GAME_IMPORT void SetMeshLodDistance(int, float);
GAME_IMPORT bool ReplaceMaterial(class ttl::string_base<char> const &, class ttl::string_base<char> const &);
GAME_IMPORT void SetTraceCollType(int);
GAME_IMPORT void DumpAnims();
GAME_IMPORT unsigned int GetNumCollisionHullFaces() const;
GAME_IMPORT unsigned int GetNumTraceHullPrimitives() const;
GAME_IMPORT void EnableRenderingRayTracing(bool);
GAME_IMPORT static bool MeshExist(class ttl::string_base<char> const &);
GAME_IMPORT void AdjustExtentsToAllElements(bool, bool);
GAME_IMPORT void SetMeshCullSizeEnable(bool);
GAME_IMPORT float GetLodDissolveStep() const;
GAME_IMPORT int GetTraceCollType() const;
GAME_IMPORT float GetMeshLodDistance(int) const;
GAME_IMPORT void SetDontApplyAnim(bool);
GAME_IMPORT int SetMeshElementsState(class ttl::vector<unsigned char, class ttl::vector_allocators::heap_allocator<unsigned char>, 8> const &, class ttl::vector<int, class ttl::vector_allocators::heap_allocator<int>, 2> const &, bool, bool);
GAME_IMPORT struct SSurfParams * GetSurfaceParams() const;
GAME_IMPORT bool IsObjectDissolved() const;
GAME_IMPORT void CollectUsedTextures(class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &);
GAME_IMPORT void SetMeshVisibilityRange(float);
GAME_IMPORT unsigned int GetNumCollisionHullVertices() const;
GAME_IMPORT void SetForcedAnimLod(char);
GAME_IMPORT class aabb const & GetAABBExtents() const;
GAME_IMPORT class Anim::IPoseElement const * AnimGetMeshPoseElement() const;
GAME_IMPORT int MT_GetCount();
GAME_IMPORT void EnableRenderingShadows(bool);
GAME_IMPORT bool SetSkin();
GAME_IMPORT unsigned int GetNumTraceHullFaces() const;
GAME_IMPORT void ResetElementsDescendantsToReferenceFrame(int);
GAME_IMPORT void MoveElementBoxSides(int, class vec3 const &, class vec3 const &);
GAME_IMPORT void GetAnimationNames(class ttl::map<class ttl::string_base<char>, struct TAnimId, struct ttl::less<class ttl::string_base<char>>, class ttl::allocator> &);
GAME_IMPORT void ShowCollisionHull(bool);
GAME_IMPORT void SaveMeshElements(class ISGChunk *);
GAME_IMPORT class Anim::IPoseElement const * AnimGetModelObjectMorphPoseElement() const;
GAME_IMPORT int GetMeshElementsState(class ttl::vector<unsigned char, class ttl::vector_allocators::heap_allocator<unsigned char>, 8> &, class ttl::vector<int, class ttl::vector_allocators::heap_allocator<int>, 2> const &) const;
GAME_IMPORT void CopyElementsPosition(class IModelObject *);
GAME_IMPORT class ttl::string_const<char> GetSkin() const;
GAME_IMPORT void ResetBoneAndDescendantsToReferenceFrame(int);
protected:
GAME_IMPORT IModelObject();
public:
GAME_IMPORT void ShowElementBoxes(bool);
GAME_IMPORT bool SetMeshElementsMatrices(class ttl::vector<class mtx34, class ttl::vector_allocators::heap_allocator<class mtx34>, 0> const &);
GAME_IMPORT void MoveElementBoxSide(int, int, float);
GAME_IMPORT unsigned int GetNumTraceHullVertices() const;
GAME_IMPORT float MT_WeightGet(unsigned int);
GAME_IMPORT static class IModelObject * GetModelObject(class IGSObject *);
GAME_IMPORT class Anim::IPoseElement const * AnimGetModelObjectPoseElement() const;
GAME_IMPORT struct SMeshVisibilityParams const * GetMeshVisibilityParams() const;
GAME_IMPORT bool ShouldApplyAnim() const;
GAME_IMPORT bool RaytraceMe(struct SCollision *, class vec3 const &, class vec3 &, unsigned short, bool, unsigned short);
GAME_IMPORT bool GetValidSkinsEditor(class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &, class ttl::vector<class ttl::string_base<char>, class ttl::vector_allocators::heap_allocator<class ttl::string_base<char>>, 1> &) const;
GAME_IMPORT static bool MeshAndSkinExists(class ttl::string_base<char> const &, class ttl::string_base<char> const &);
GAME_IMPORT void ResetBonesToReferenceFrame(bool);
#pragma endregion
};

View File

@ -2,6 +2,7 @@
#include <EGSDK\Imports.h>
class IModelObject {
#pragma region GENERATED by ExportClassToCPPH.py
public:
VIRTUAL_CALL(0, uint64_t*, sub_1203B0, (char a1), a1);
GAME_IMPORT virtual IAnimBind const* GetAnimBind() const;
@ -11,7 +12,7 @@ public:
GAME_IMPORT virtual TAnimId GetAnimationId(ttl::string_const<char>, bool) const;
GAME_IMPORT virtual float GetAnimLength(TAnimId) const;
GAME_IMPORT virtual float GetAnimLength(ttl::string_base<char> const&) const;
GAME_IMPORT float odb_GetLoadTime(RLROD_Batch*);
VIRTUAL_CALL(8, float, odb_GetLoadTime, (RLROD_Batch*), RLROD_Batch*);
GAME_IMPORT virtual mtx34 const& GetWorldXform() const;
GAME_IMPORT virtual int GetElementIndex(char const*) const;
GAME_IMPORT virtual ttl::string_base<char> GetElementName(int) const;
@ -154,105 +155,103 @@ public:
VIRTUAL_CALL(146, void, _SetPlatform3, ());
GAME_IMPORT virtual bool GetMeshDataForSimpleObjectsEditor(ttl::string_base<char>*, ttl::string_base<char>*, int64_t*, int64_t*, int*);
VIRTUAL_CALL(148, int64_t, _RunUnitTests1, ());
GAME_IMPORT ttl::list<SCommandParam, ttl::allocator>::const_reverse_iterator rend() const;
VIRTUAL_CALL(149, ttl::list<SCommandParam, ttl::allocator>::const_reverse_iterator, rend, ());
protected:
GAME_IMPORT IModelObject();
public:
GAME_IMPORT IModelObject(IModelObject const&);
protected:
GAME_IMPORT ~IModelObject();
public:
GAME_IMPORT void AdjustExtentsToAllElements(bool, bool);
GAME_IMPORT Anim::IPoseElement const* AnimGetMeshPoseElement() const;
GAME_IMPORT Anim::IPoseElement const* AnimGetModelObjectMorphPoseElement() const;
GAME_IMPORT Anim::IPoseElement const* AnimGetModelObjectPoseElement() const;
GAME_IMPORT bool AnimReInit(ttl::string_base<char> const&);
GAME_IMPORT static void CollectMeshSkins(ttl::string_base<char> const&, bool, ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&);
GAME_IMPORT void CollectUsedTextures(ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&);
GAME_IMPORT void CopyElementsPosition(IModelObject*);
GAME_IMPORT void DumpAnims();
GAME_IMPORT bool EnableElementPhysics(int, bool, bool);
GAME_IMPORT void EnableHierarchySerialization(bool);
GAME_IMPORT void EnableRenderingRayTracing(bool);
GAME_IMPORT void EnableRenderingScene(bool);
GAME_IMPORT void EnableRenderingShadows(bool);
GAME_IMPORT void EnableUpdateExtents(bool);
GAME_IMPORT aabb const& GetAABBExtents() const;
GAME_IMPORT void GetAnimationNames(ttl::map<ttl::string_base<char>, TAnimId, ttl::less<ttl::string_base<char>>, ttl::allocator>&);
GAME_IMPORT static COFlags::TYPE GetDefaultCOFlags();
GAME_IMPORT int GetCurrentLOD() const;
GAME_IMPORT LodDissolves::SState GetCurrentLodState() const;
GAME_IMPORT char GetForcedAnimLod() const;
GAME_IMPORT float GetLodDissolveStep() const;
GAME_IMPORT void GetMeshElementsMatrices(ttl::vector<mtx34, ttl::vector_allocators::heap_allocator<mtx34>, 0>&) const;
GAME_IMPORT uint32_t GetMeshElementsMatricesCount() const;
GAME_IMPORT int GetMeshElementsState(ttl::vector<unsigned char, ttl::vector_allocators::heap_allocator<unsigned char>, 8>&, ttl::vector<int, ttl::vector_allocators::heap_allocator<int>, 2> const&) const;
GAME_IMPORT int GetMeshElementsStateSize(ttl::vector<int, ttl::vector_allocators::heap_allocator<int>, 2> const&) const;
GAME_IMPORT float GetMeshLodDistance(int) const;
GAME_IMPORT SMeshVisibilityParams const* GetMeshVisibilityParams() const;
GAME_IMPORT IModelObject(IModelObject const&);
GAME_IMPORT float GetMeshVisibilityRange();
GAME_IMPORT static IModelObject* GetModelObject(IGSObject*);
GAME_IMPORT static IModelObject* GetModelObject(cbs::CEntity const*);
GAME_IMPORT static IModelObject const* GetModelObject(IGSObject const*);
GAME_IMPORT uint32_t GetNumCollisionHullFaces() const;
GAME_IMPORT bool SkinExists(ttl::string_base<char> const&);
GAME_IMPORT int GetCurrentLOD() const;
GAME_IMPORT void SetExtentsLocal(extents const&);
GAME_IMPORT uint32_t GetMeshElementsMatricesCount() const;
GAME_IMPORT char GetForcedAnimLod() const;
GAME_IMPORT uint32_t GetNumCollisionHullPrimitives() const;
GAME_IMPORT uint32_t GetNumCollisionHullVertices() const;
GAME_IMPORT uint32_t GetNumSurfaceParams() const;
GAME_IMPORT uint32_t GetNumTraceHullFaces() const;
GAME_IMPORT uint32_t GetNumTraceHullPrimitives() const;
GAME_IMPORT uint32_t GetNumTraceHullVertices() const;
GAME_IMPORT ttl::string_const<char> GetSkin() const;
GAME_IMPORT static int64_t GetSkinTagsFromStr(char const*);
GAME_IMPORT SSurfParams* GetSurfaceParams() const;
GAME_IMPORT int GetTraceCollType() const;
GAME_IMPORT bool GetValidSkinsEditor(ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&, ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&) const;
GAME_IMPORT void MoveElementBoxSides(int, float, float, float, float, float, float);
GAME_IMPORT bool SetSkinNoCharacterPreset();
GAME_IMPORT void SetBestGeomLods();
GAME_IMPORT bool IsElementPhysicsEnabled(int);
GAME_IMPORT bool IsDefaultMeshLoaded();
GAME_IMPORT void SetLodDissolveStep(float);
GAME_IMPORT static IModelObject const* GetModelObject(IGSObject const*);
GAME_IMPORT LodDissolves::SState GetCurrentLodState() const;
GAME_IMPORT static IModelObject* GetModelObject(cbs::CEntity const*);
GAME_IMPORT int GetMeshElementsStateSize(ttl::vector<int, ttl::vector_allocators::heap_allocator<int>, 2> const&) const;
GAME_IMPORT bool EnableElementPhysics(int, bool, bool);
private:
GAME_IMPORT bool IsElementIDValid(int) const;
public:
GAME_IMPORT bool IsElementPhysicsEnabled(int);
GAME_IMPORT bool IsObjectDissolved() const;
GAME_IMPORT void LoadMesh(bool);
GAME_IMPORT void LoadMeshElements(ISGChunk*);
GAME_IMPORT int MT_GetCount();
GAME_IMPORT char const* MT_GetName(uint32_t);
GAME_IMPORT float MT_WeightGet(uint32_t);
GAME_IMPORT static bool MeshAndSkinExists(ttl::string_base<char> const&, ttl::string_base<char> const&);
GAME_IMPORT static bool MeshExist(ttl::string_base<char> const&);
GAME_IMPORT void MeshUseDefaultVisibilityParameters();
GAME_IMPORT void MoveElementBoxSide(int, int, float);
GAME_IMPORT void MoveElementBoxSides(int, vec3 const&, vec3 const&);
GAME_IMPORT void MoveElementBoxSides(int, float, float, float, float, float, float);
GAME_IMPORT bool RaytestMe(vec3 const&, vec3&, unsigned short, bool, unsigned short);
GAME_IMPORT bool RaytraceMe(SCollision*, vec3 const&, vec3&, unsigned short, bool, unsigned short);
GAME_IMPORT bool ReplaceMaterial(ttl::string_base<char> const&, ttl::string_base<char> const&);
GAME_IMPORT void ResetBoneAndDescendantsToReferenceFrame(int);
GAME_IMPORT void ResetBonesExtentsToReferenceFrame();
GAME_IMPORT void ResetBonesToReferenceFrame(bool);
GAME_IMPORT void ResetElementsDescendantsToReferenceFrame(int);
GAME_IMPORT void SaveMeshElements(ISGChunk*);
GAME_IMPORT void SetBestGeomLods();
GAME_IMPORT void SetDontApplyAnim(bool);
GAME_IMPORT void SetExtentsLocal(extents const&);
GAME_IMPORT void SetForcedAnimLod(char);
GAME_IMPORT void SetLodDissolveStep(float);
GAME_IMPORT void SetLodStateForSpawnedObjects(LodDissolves::SState);
GAME_IMPORT void SetMeshCullSizeEnable(bool);
GAME_IMPORT bool SetMeshElementsMatrices(ttl::vector<mtx34, ttl::vector_allocators::heap_allocator<mtx34>, 0> const&);
GAME_IMPORT int SetMeshElementsState(ttl::vector<unsigned char, ttl::vector_allocators::heap_allocator<unsigned char>, 8> const&, ttl::vector<int, ttl::vector_allocators::heap_allocator<int>, 2> const&, bool, bool);
GAME_IMPORT void SetMeshLodDistance(int, float);
GAME_IMPORT void SetMeshVisibilityRange(float);
GAME_IMPORT bool SetSkin();
GAME_IMPORT bool SetSkinNoCharacterPreset();
GAME_IMPORT void SetTraceCollType(int);
GAME_IMPORT bool ShouldApplyAnim() const;
GAME_IMPORT void ShowCollisionHull(bool);
GAME_IMPORT void ShowElementBox(ttl::string_base<char> const&);
GAME_IMPORT void ShowElementBoxes(bool);
GAME_IMPORT void ShowElementBoxesFrom(ttl::string_base<char> const&);
GAME_IMPORT void ResetBonesExtentsToReferenceFrame();
GAME_IMPORT void EnableHierarchySerialization(bool);
GAME_IMPORT void ShowElementBoxesFromTo(ttl::string_base<char> const&, ttl::string_base<char> const&);
GAME_IMPORT bool RaytestMe(vec3 const&, vec3&, unsigned short, bool, unsigned short);
GAME_IMPORT static void CollectMeshSkins(ttl::string_base<char> const&, bool, ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&);
GAME_IMPORT void GetMeshElementsMatrices(ttl::vector<mtx34, ttl::vector_allocators::heap_allocator<mtx34>, 0>&) const;
GAME_IMPORT bool AnimReInit(ttl::string_base<char> const&);
GAME_IMPORT void SetLodStateForSpawnedObjects(LodDissolves::SState);
GAME_IMPORT uint32_t GetNumSurfaceParams() const;
GAME_IMPORT void EnableUpdateExtents(bool);
GAME_IMPORT void ShowElementBox(ttl::string_base<char> const&);
GAME_IMPORT void ShowElementBoxesTo(ttl::string_base<char> const&);
GAME_IMPORT void LoadMesh(bool);
GAME_IMPORT static COFlags::TYPE GetDefaultCOFlags();
GAME_IMPORT void LoadMeshElements(ISGChunk*);
GAME_IMPORT static int64_t GetSkinTagsFromStr(char const*);
GAME_IMPORT void ShowExtents(bool);
GAME_IMPORT bool SkinExists(ttl::string_base<char> const&);
GAME_IMPORT char const* MT_GetName(uint32_t);
GAME_IMPORT void SetMeshLodDistance(int, float);
GAME_IMPORT bool ReplaceMaterial(ttl::string_base<char> const&, ttl::string_base<char> const&);
GAME_IMPORT void SetTraceCollType(int);
GAME_IMPORT void DumpAnims();
GAME_IMPORT uint32_t GetNumCollisionHullFaces() const;
GAME_IMPORT uint32_t GetNumTraceHullPrimitives() const;
GAME_IMPORT void EnableRenderingRayTracing(bool);
GAME_IMPORT static bool MeshExist(ttl::string_base<char> const&);
GAME_IMPORT void AdjustExtentsToAllElements(bool, bool);
GAME_IMPORT void SetMeshCullSizeEnable(bool);
GAME_IMPORT float GetLodDissolveStep() const;
GAME_IMPORT int GetTraceCollType() const;
GAME_IMPORT float GetMeshLodDistance(int) const;
GAME_IMPORT void SetDontApplyAnim(bool);
GAME_IMPORT int SetMeshElementsState(ttl::vector<unsigned char, ttl::vector_allocators::heap_allocator<unsigned char>, 8> const&, ttl::vector<int, ttl::vector_allocators::heap_allocator<int>, 2> const&, bool, bool);
GAME_IMPORT SSurfParams* GetSurfaceParams() const;
GAME_IMPORT bool IsObjectDissolved() const;
GAME_IMPORT void CollectUsedTextures(ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&);
GAME_IMPORT void SetMeshVisibilityRange(float);
GAME_IMPORT uint32_t GetNumCollisionHullVertices() const;
GAME_IMPORT void SetForcedAnimLod(char);
GAME_IMPORT aabb const& GetAABBExtents() const;
GAME_IMPORT Anim::IPoseElement const* AnimGetMeshPoseElement() const;
GAME_IMPORT int MT_GetCount();
GAME_IMPORT void EnableRenderingShadows(bool);
GAME_IMPORT bool SetSkin();
GAME_IMPORT uint32_t GetNumTraceHullFaces() const;
GAME_IMPORT void ResetElementsDescendantsToReferenceFrame(int);
GAME_IMPORT void MoveElementBoxSides(int, vec3 const&, vec3 const&);
GAME_IMPORT void GetAnimationNames(ttl::map<ttl::string_base<char>, TAnimId, ttl::less<ttl::string_base<char>>, ttl::allocator>&);
GAME_IMPORT void ShowCollisionHull(bool);
GAME_IMPORT void SaveMeshElements(ISGChunk*);
GAME_IMPORT Anim::IPoseElement const* AnimGetModelObjectMorphPoseElement() const;
GAME_IMPORT int GetMeshElementsState(ttl::vector<unsigned char, ttl::vector_allocators::heap_allocator<unsigned char>, 8>&, ttl::vector<int, ttl::vector_allocators::heap_allocator<int>, 2> const&) const;
GAME_IMPORT void CopyElementsPosition(IModelObject*);
GAME_IMPORT ttl::string_const<char> GetSkin() const;
GAME_IMPORT void ResetBoneAndDescendantsToReferenceFrame(int);
protected:
GAME_IMPORT IModelObject();
public:
GAME_IMPORT void ShowElementBoxes(bool);
GAME_IMPORT bool SetMeshElementsMatrices(ttl::vector<mtx34, ttl::vector_allocators::heap_allocator<mtx34>, 0> const&);
GAME_IMPORT void MoveElementBoxSide(int, int, float);
GAME_IMPORT uint32_t GetNumTraceHullVertices() const;
GAME_IMPORT float MT_WeightGet(uint32_t);
GAME_IMPORT static IModelObject* GetModelObject(IGSObject*);
GAME_IMPORT Anim::IPoseElement const* AnimGetModelObjectPoseElement() const;
GAME_IMPORT SMeshVisibilityParams const* GetMeshVisibilityParams() const;
GAME_IMPORT bool ShouldApplyAnim() const;
GAME_IMPORT bool RaytraceMe(SCollision*, vec3 const&, vec3&, unsigned short, bool, unsigned short);
GAME_IMPORT bool GetValidSkinsEditor(ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&, ttl::vector<ttl::string_base<char>, ttl::vector_allocators::heap_allocator<ttl::string_base<char>>, 1>&) const;
GAME_IMPORT static bool MeshAndSkinExists(ttl::string_base<char> const&, ttl::string_base<char> const&);
GAME_IMPORT void ResetBonesToReferenceFrame(bool);
#pragma endregion
};