bool NVSEPlugin_Query(const NVSEInterface * nvse, PluginInfo * info) { info->infoVersion = PluginInfo::kInfoVersion; info->name = NVSE_EXTENDER_NAME; info->version = NVSE_EXTENDER_VER; if (nvse->isEditor ) { if ( nvse->editorVersion != 0x04002060) { _MESSAGE("GECK version not supported: %d", nvse->editorVersion); return false; } else { _MESSAGE("loading extender in editor 1_4_0_518 (%d)", nvse->editorVersion); } } else { if (nvse->runtimeVersion != 0x040020D0) { _MESSAGE("loading extender in unsupported runtime %d", nvse->runtimeVersion); return false; } else { _MESSAGE("loading extender in runtime 1_4_0_525 (%d)", nvse->runtimeVersion); } } return true; }
static void HookMain(void * retAddr) { if(hookInstalled) return; else hookInstalled = true; _MESSAGE("HookMain: thread = %d retaddr = %016I64X", GetCurrentThreadId(), retAddr); std::string runtimePath = GetRuntimePath(); _MESSAGE("runtimePath = %s", runtimePath.c_str()); bool isEditor = false; // check version etc std::string dllSuffix; ProcHookInfo procHookInfo; if(!IdentifyEXE(runtimePath.c_str(), isEditor, &dllSuffix, &procHookInfo)) { _ERROR("unknown exe"); return; } const char * dllPrefix = (isEditor == false) ? "\\skse64_" : "\\skse64_editor_"; g_dllPath = GetRuntimeDirectory() + dllPrefix + dllSuffix + ".dll"; _MESSAGE("dll = %s", g_dllPath.c_str()); LoadLibrary(g_dllPath.c_str()); }
bool Cmd_NX_GetEVFo_Execute(COMMAND_ARGS) { std::string key; char keyName[512]; float fValue = 0; UInt32 iPersist = 0; _MESSAGE("START GetEVFo"); *result = 0; if (ExtractArgs(EXTRACT_ARGS, &keyName)) { if (thisObj) { key = keyName; *((UInt32 *)result) = nvse_ex_evformmap[thisObj->refID][key]; if (IsConsoleMode()) { Console_Print("GetEVFo: %x", *((UInt32 *)result)); } } } _MESSAGE("END GetEVFo"); return true; }
bool OBSEPlugin_Load(const OBSEInterface * obse) { g_pluginHandle = obse->GetPluginHandle(); _MESSAGE("RuntimeEditorIDs Initializing..."); gLog.Indent(); if(!obse->isEditor) { for (int i = 0; i < VTBLTableSize; i++) { UInt32 PatchAddress = g_VTBLTable[i].Address + kTESForm_SetEditorID_VTBLOffset; SafeWrite32(PatchAddress, (UInt32)TESForm_HandleEditorID); _MESSAGE("Patched '%s' VTBL offset 0x%08X", g_VTBLTable[i].Class, PatchAddress); } } obse->SetOpcodeBase(0x2740); // 0x2740 - 0x274F obse->RegisterTypedCommand(&kCommandInfo_GetRuntimeEditorID, kRetnType_String); g_msgIntfc->RegisterListener(g_pluginHandle, "OBSE", OBSEMessageHandler); gLog.Outdent(); _MESSAGE("RuntimeEditorIDs Initialized!\n\n"); return true; }
bool ActorEquipmentOverrider::UnregisterHandler(OverrideHandlerIdentifierT ID) { bool Result = false; if (GetEnabled()) { if (OverrideInProgress == false) { if (ID != ActorEquipmentOverrider::InvalidID && HandlerTable.count(ID)) { HandlerTable.erase(ID); Result = true; } else { _MESSAGE("Couldn't unregister equipment override handler - Invalid ID %d", ID); } } else { _MESSAGE("Attempting to unregister an equipment override handler while an override operation is in progress"); } } return Result; }
bool SKSEPlugin_Query(const SKSEInterface * skse, PluginInfo * info) { // Called by SKSE to learn about this plugin and check that it's safe to load it gLog.OpenRelative(CSIDL_MYDOCUMENTS, "\\My Games\\Skyrim\\SKSE\\SkaarHardcoreMode.log"); gLog.SetPrintLevel(IDebugLog::kLevel_Error); gLog.SetLogLevel(IDebugLog::kLevel_DebugMessage); _MESSAGE("SkaarHardcoreMode"); // populate info structure info->infoVersion = PluginInfo::kInfoVersion; info->name = "SkaarHardcoreMode"; info->version = 1; // store plugin handle so we can identify ourselves later g_pluginHandle = skse->GetPluginHandle(); if(skse->isEditor) { _MESSAGE("loaded in editor, marking as incompatible"); return false; } else if(skse->runtimeVersion != RUNTIME_VERSION_1_9_32_0) { _MESSAGE("unsupported runtime version %08X", skse->runtimeVersion); return false; } // ### do not do anything else in this callback // ### only fill out PluginInfo and return true/false // supported runtime version return true; }
bool BGSSaveLoadManager::LoadGame_Hook(const char * saveName, bool unk1) { #ifdef DEBUG _MESSAGE("Executing BGSSaveLoadManager::LoadGame_Hook. saveName: %s", saveName); #endif FriendLink::PreLoadGame(); g_loadGameLock.Enter(); Serialization::SetSaveName(saveName); PluginManager::Dispatch_Message(0, SKSEMessagingInterface::kMessage_PreLoadGame, (void*)saveName, strlen(saveName), NULL); bool result = CALL_MEMBER_FN(this, LoadGame_HookTarget)(saveName, unk1); PluginManager::Dispatch_Message(0, SKSEMessagingInterface::kMessage_PostLoadGame, (void*)result, 1, NULL); Serialization::SetSaveName(NULL); g_loadGameLock.Leave(); // Clear invalid handles in OnUpdate event registration list UInt32 enableClearRegs = 0; if (GetConfigOption_UInt32("General", "ClearInvalidRegistrations", &enableClearRegs)) { if (enableClearRegs) { UInt32 count = (*g_skyrimVM)->ClearInvalidRegistrations(); if (count > 0) _MESSAGE("ClearInvalidRegistrations: Removed %d invalid OnUpdate registration(s)", count); } } #ifdef DEBUG _MESSAGE("Executed BGSSaveLoadManager::LoadGame_Hook."); #endif return result; }
void HUDManager::Render() { HRESULT hr; IDirect3DDevice9 *Device; Device = GetD3DDevice(); if (!Device) { _MESSAGE("No valid D3D Device."); return; } if(!sprite) { hr=D3DXCreateSprite(Device,&sprite); if (FAILED(hr)||!sprite) { _MESSAGE("Create sprite failed."); return; } } sprite->Begin(0); for(::std::vector<Sprite*>::iterator i=ScreenElementList.begin(); i!=ScreenElementList.end(); i++) { (*i)->Render(sprite); } sprite->End(); return; }
// after a game is loaded, read and apply any persistent global data void ReadGlobals (OBSESerializationInterface* obse, UInt32 dataLen) { _MESSAGE ("Reading globals\n"); while (dataLen > 0) { UInt8 globId; obse->ReadRecordData (&globId, sizeof (globId)); dataLen -= sizeof (globId); switch (globId) { case kOBSEGlobal_MovementSpeedModifier: { double mod; obse->ReadRecordData (&mod, sizeof (mod)); dataLen -= sizeof (mod); ModPlayerMovementSpeed (mod, true); } break; case kOBSEGlobal_SpellEffectivenessModifier: { double mod; obse->ReadRecordData (&mod, sizeof (mod)); dataLen -= sizeof (mod); ModPlayerSpellEffectiveness (mod, true); } break; default: _MESSAGE ("ReadGlobals >> Unexpected global ID %d\n", globId); break; } } }
//==================================================== // ここでプラグイン・インスタンスの初期化処理をする // SKSEPlugin_Query() に相当 //==================================================== virtual bool InitInstance() { // PluginExample.esp が MODリストに無けれれば、プラグインをロードしない if (!Requires("PluginExample.esp")) return false; // SKSEのバージョンが1.7.0未満なら、プラグインをロードしない if (!Requires(kSKSEVersion_1_7_0)) { _MESSAGE("ERROR: your skse version is too old"); return false; } // 各々のインタフェースが古い場合は、プラグインをロードしない if (!Requires(SKSEScaleformInterface::CurrentVersion, SKSEPapyrusInterface::CurrentVersion)) { _MESSAGE("ERROR: interfaces are too old"); return false; } // Requiresの引数は、一度にまとめて指定できる // Requires("PluginExample.esp", kSKSEVersion_1_7_0, SKSEScaleformInterface::kInterfaceVersion, SKSEPapyrusInterface::kInterfaceVersion) // プラグインの名前とバージョンを設定(必要) SetName("example plugin"); SetVersion(1); // インスタンスの初期化に成功 return true; }
bool F4SEPlugin_Query(const F4SEInterface * f4se, PluginInfo * info) { OpenPluginLog(); _MESSAGE(pluginName); // populate info structure info->infoVersion = PluginInfo::kInfoVersion; info->name = "Dump ModInfoList plugin"; info->version = 1; // store plugin handle so we can identify ourselves later g_pluginHandle = f4se->GetPluginHandle(); if(f4se->isEditor) { _MESSAGE("loaded in editor, marking as incompatible"); return false; } else if(f4se->runtimeVersion != RUNTIME_VERSION_1_10_98) { _MESSAGE("unsupported runtime version %08X (expected %08X)", f4se->runtimeVersion, RUNTIME_VERSION_1_10_89); return false; } // ### do not do anything else in this callback // ### only fill out PluginInfo and return true/false // supported runtime version return true; }
static void ExamplePlugin_LoadCallback(void * reserved) { UInt32 type, version, length; ResetData(); char buf[512]; while(g_serialization->GetNextRecordInfo(&type, &version, &length)) { _MESSAGE("record %08X (%.4s) %08X %08X", type, &type, version, length); switch(type) { case 'STR ': g_serialization->ReadRecordData(buf, length); buf[length] = 0; _MESSAGE("got string %s", buf); g_strData = buf; break; case 'ASDF': g_serialization->ReadRecordData(buf, length); buf[length] = 0; _MESSAGE("ASDF chunk = %s", buf); break; default: _MESSAGE("Unknown chunk type $08X", type); } } }
bool Cmd_NX_ClrEVFo_Execute(COMMAND_ARGS) { std::string key = ""; char keyName[512]; int doMatch = 1; _MESSAGE("START ClrEVFl"); *result = 0; if (ExtractArgs(EXTRACT_ARGS, &keyName, &doMatch)) { key = keyName; } if (thisObj) { if (key != "") { nvse_ex_evformmap[thisObj->refID].erase(key); } else { nvse_ex_evfloatmap.clear(); } } _MESSAGE("END ClrEVFl"); return true; }
bool ReadModListFromSaveGame(const char* path) { _MESSAGE("Reading mod list from savegame"); IFileStream savefile; if (!savefile.Open(path)) { _MESSAGE("Couldn't open .ess file when attempting to read plugin list"); return false; } else { static const UInt32 kSaveHeaderSizeOffset = 34; savefile.SetOffset(kSaveHeaderSizeOffset); UInt32 headerSize = savefile.Read32(); savefile.SetOffset(headerSize + kSaveHeaderSizeOffset + sizeof(UInt32)); s_numPreloadMods = savefile.Read8(); char pluginName[0x100]; for (UInt32 i = 0; i < s_numPreloadMods; i++) { UInt8 nameLen = savefile.Read8(); savefile.ReadBuf(pluginName, nameLen); pluginName[nameLen] = 0; _MESSAGE("Save file contains plugin %s", pluginName); s_preloadModRefIDs[i] = (*g_dataHandler)->GetModIndex(pluginName); } savefile.Close(); } return true; }
static bool Cmd_ConScribe_UnregisterLog_Execute(COMMAND_ARGS) { UInt32 DefaultFlag = 0; UInt32 DeleteFlag = 0; char Buffer[kMaxMessageLength]; const char* ModName = ResolveModName(scriptObj); if (Buffer == NULL || ModName == NULL) return true; else if (!ExtractFormatStringArgs(0, Buffer, paramInfo, arg1, opcodeOffsetPtr, scriptObj, eventList, kCommandInfo_UnregisterLog.numParams, &DefaultFlag, &DeleteFlag)) return true; if (!_stricmp(Buffer, "*.*")) { if (!DefaultFlag) { _MESSAGE("Mod '%s' unregistered all of its logs", ModName); LogManager::GetSingleton()->GetModLogData(ModName)->RegisteredLogs.clear(); DeleteFlag = 0; } LogManager::GetSingleton()->SetDefaultLog(ModName, (const char*)NULL); } else LogManager::GetSingleton()->UnregisterLog(ModName, Buffer); if (DeleteFlag) { DeleteFile(std::string(std::string(GET_INI_STRING("RootDirectory")) + "ConScribe Logs\\Per-Mod\\" + std::string(Buffer) + ".log").c_str()); _MESSAGE("Deleted '%s'", Buffer); } return true; }
static bool Cmd_ConScribe_GetRegisteredLogNames_Execute(COMMAND_ARGS) { *result = 0; const char* ModName = ResolveModName(scriptObj); if (ModName == NULL) return true; LogManager::GetSingleton()->RegisterMod(ModName); std::vector<OBSEElement> LogList; for (std::vector<std::string>::const_iterator Itr = LogManager::GetSingleton()->GetModLogData(ModName)->RegisteredLogs.begin(); Itr != LogManager::GetSingleton()->GetModLogData(ModName)->RegisteredLogs.end(); Itr++) { LogList.push_back(Itr->c_str()); } std::map<std::string, OBSEElement> OBSEStringMap; OBSEArray* OBSEVector = ArrayFromStdVector(LogList, scriptObj); OBSEStringMap["default log"] = LogManager::GetSingleton()->GetDefaultLog(ModName); OBSEStringMap["log list"] = OBSEVector; OBSEArray* ResultArray = StringMapFromStdMap(OBSEStringMap, scriptObj); if (!ResultArray) _MESSAGE("Couldn't create array. Passed in script %08x", scriptObj->refID); else if (!g_arrayIntfc->AssignCommandResult(ResultArray, result)) _MESSAGE("Couldn't assign result array. Passed in script %08x", scriptObj->refID); return true; }
bool SKSEPlugin_Query(const SKSEInterface * skse, PluginInfo * info) { gLog.OpenRelative(CSIDL_MYDOCUMENTS, kLogPath); _MESSAGE("EnchantReloadFix SKSE Plugin\nby egocarib\n\n" "{ Fixes player-enchanted items having inflated gold value }\n" "{ and draining higher amounts of charge after game reload }\n"); //Populate plugin info structure info->infoVersion = PluginInfo::kInfoVersion; info->name = "EnchantReloadFix Plugin"; info->version = 1; //Store plugin handle so we can identify ourselves later g_pluginHandle = skse->GetPluginHandle(); if(skse->isEditor) { _MESSAGE("Loaded In Editor, Marking As Incompatible"); return false; } else if(skse->runtimeVersion != RUNTIME_VERSION_1_9_32_0) { _MESSAGE("Unsupported Runtime Version %08X", skse->runtimeVersion); return false; } //Get the serialization interface and query its version g_serialization = (SKSESerializationInterface *)skse->QueryInterface(kInterface_Serialization); if(!g_serialization) { _MESSAGE("Couldn't Get Serialization Interface"); return false; } if(g_serialization->version < SKSESerializationInterface::kVersion) { _MESSAGE("Serialization Interface Too Old (%d Expected %d)", g_serialization->version, SKSESerializationInterface::kVersion); return false; } return true; }
void CommandTable::Init(void) { // read in the console commands g_consoleCommands.SetBaseID(0x0100); g_consoleCommands.Read((CommandInfo *)g_offsetConsoleCommandsStart, (CommandInfo *)g_offsetConsoleCommandsLast); // read in the script commands g_scriptCommands.SetBaseID(0x1000); g_scriptCommands.Read((CommandInfo *)g_offsetScriptCommandsStart, (CommandInfo *)g_offsetScriptCommandsLast); // pad to opcode 0x1400 to give Bethesda lots of room g_scriptCommands.PadTo(kNVSEOpcodeStart); // Add NVSE Commands g_scriptCommands.AddCommandsV1(); #if _DEBUG g_scriptCommands.AddDebugCommands(); #endif // register plugins g_pluginManager.Init(); ApplyPatch(kPatch_ScriptCommands_Start, (UInt32)g_scriptCommands.GetStart()); ApplyPatch(kPatch_ScriptCommands_End, (UInt32)g_scriptCommands.GetEnd()); ApplyPatch(kPatch_ScriptCommands_MaxIdx, g_scriptCommands.GetMaxID()); _MESSAGE("max id = %08X", g_scriptCommands.GetMaxID()); g_scriptCommands.Dump(); _MESSAGE("patched"); }
bool Cmd_NX_ChangeRace_Execute(COMMAND_ARGS) { UInt32 *refResult = NULL; Actor *pActor = NULL; // item we are looking for TESRace *pRace = NULL; // current item from list _MESSAGE("START ChangeRace"); // refResult = (UInt32*)result; if (ExtractArgs(EXTRACT_ARGS, &pActor, &pRace)) { _MESSAGE(" SUCCESS %x %x %x", pActor, pRace, pActor->GetTypeID()); if (pActor) { // _MESSAGE(" Actor is a Character"); // needs a TESRaceForm not TESRace // pActor->race.race = *pRace; } } else { _MESSAGE(" FAIL"); } _MESSAGE("END ChangeRace"); return true; }
void CommandTable::Init(void) { static CommandInfo* kCmdInfo_Unused_1; #if RUNTIME #if RUNTIME_VERSION == RUNTIME_VERSION_1_4_0_525 kCmdInfo_Unused_1 = (CommandInfo*)0x0118E4F8; #elif RUNTIME_VERSION == RUNTIME_VERSION_1_4_0_525ng kCmdInfo_Unused_1 = (CommandInfo*)0x0118E4F8; #else #error #endif #else kCmdInfo_Unused_1 = (CommandInfo*)0x00E9D7A0; #endif // read in the console commands g_consoleCommands.SetBaseID(0x0100); g_consoleCommands.Read((CommandInfo *)g_offsetConsoleCommandsStart, (CommandInfo *)g_offsetConsoleCommandsLast); // read in the script commands g_scriptCommands.SetBaseID(0x1000); g_scriptCommands.Read((CommandInfo *)g_offsetScriptCommandsStart, (CommandInfo *)g_offsetScriptCommandsLast); // blocktype "Unused_1" becomes "Function" UInt16 onUnused_1Opcode = kCmdInfo_Unused_1->opcode; *kCmdInfo_Unused_1 = kCommandInfo_Function; kCmdInfo_Unused_1->opcode = onUnused_1Opcode; // pad to opcode 0x1400 to give Bethesda lots of room g_scriptCommands.PadTo(kNVSEOpcodeStart); // Add NVSE Commands g_scriptCommands.AddCommandsV1(); g_scriptCommands.AddCommandsV3s(); g_scriptCommands.AddCommandsV4(); #if _DEBUG g_scriptCommands.AddDebugCommands(); #endif // register plugins g_pluginManager.Init(); // patch the code ApplyPatch(kPatch_ScriptCommands_Start, (UInt32)g_scriptCommands.GetStart()); ApplyPatch(kPatch_ScriptCommands_End, (UInt32)g_scriptCommands.GetEnd()); ApplyPatch(kPatch_ScriptCommands_MaxIdx, g_scriptCommands.GetMaxID()); ApplyPatchEditorOpCodeDataList(); _MESSAGE("max id = %08X", g_scriptCommands.GetMaxID()); _MESSAGE("console commands"); g_consoleCommands.Dump(); _MESSAGE("script commands"); g_scriptCommands.Dump(); _MESSAGE("patched"); }
bool Cmd_NX_IsUsingSkeleton_Execute(COMMAND_ARGS) { TESActorBase *pActor; char skelName[512]; char actorModel[512]; char *pch = NULL; char *dummy = NULL; char **parts = NULL; int cnt = 0; int idx; _MESSAGE("START IsUsingSkeleton"); *result = 0; if (ExtractArgs(EXTRACT_ARGS, &skelName)) { pActor = DYNAMIC_CAST(thisObj->baseForm, TESForm, TESActorBase); if (pActor) { strcpy_s(actorModel, 512, pActor->model.GetPath()); pch = strtok_s(actorModel, "/\\", &dummy); while (NULL != pch) { parts = (char **) realloc(parts, (cnt + 1) * (sizeof(char*))); parts[cnt] = pch; cnt++; pch = strtok_s(NULL, "/\\", &dummy); } for (idx = 0; idx < cnt; idx++) { _MESSAGE("IDX %d is %s", idx, parts[idx]); } if (cnt >= 2) { _MESSAGE("SIC %s %s is %d", skelName, parts[cnt - 2], _stricmp(skelName, parts[cnt - 2])); if (0 == _stricmp(skelName, parts[cnt - 2])) { *result = 1; } } // Free our memory free(parts); if (IsConsoleMode()) { Console_Print("IsUsingSkeleton %.0f", *result); } } } _MESSAGE("END IsUsingSkeleton %0.0f", *result); return true; }
void Tile::DebugDump() { _MESSAGE("%08X %02X %02X %02X %02X (%s) %08X %08X %08X %08X %s", this, unk04, unk05, unk06, pad07, name.m_data ? name.m_data : "<null>", parent, unk24, unk28, flags, GetType()); gLog.Indent(); if(valueList.numItems) { _MESSAGE("values:"); gLog.Indent(); for(Tile::ValueList::Node * iter = valueList.start; iter; iter = iter->next) { Tile::Value * data = iter->data; if(data) { const char * idStr = StrIDToStr(data->id); if(!idStr) idStr = "<unknown>"; if(data->str.m_data) _MESSAGE("%04X %02X: %s = %s", data->id, data->bIsNum, idStr, data->str.m_data); else _MESSAGE("%04X %02X: %s = %f", data->id, data->bIsNum, idStr, data->num); } } gLog.Outdent(); } if(childList.numItems) { _MESSAGE("children:"); gLog.Indent(); for(Tile::RefList::Node * iter = childList.start; iter; iter = iter->next) { if(iter->data) iter->data->DebugDump(); } gLog.Outdent(); } gLog.Outdent(); }
void EAr_MGEFInfoLib::CompleteInternalSetup() { battleaxeKeyword = papyrusKeyword::GetKeyword(NULL, "WeapTypeBattleaxe"); READY = true; if (CUSTOMLIB) _MESSAGE("User-Defined Custom Effects Loaded Successfully."); else _MESSAGE("Internal effect library loaded successfully."); }
void ObScript_DumpCommands(void) { _MESSAGE("block types:"); DumpCommands(g_blockTypeStart, g_blockTypeEnd); _MESSAGE("console commands"); DumpCommands(g_consoleCommandsStart, g_consoleCommandsEnd); _MESSAGE("script commands"); DumpCommands(g_scriptCommandsStart, g_scriptCommandsEnd); }
HRESULT STDMETHODCALLTYPE OBGEDirect3D9::CreateDevice( UINT Adapter, D3DDEVTYPE DeviceType, HWND hFocusWindow, DWORD BehaviorFlags, D3DPRESENT_PARAMETERS *pPresentationParameters, IDirect3DDevice9 **ppReturnedDeviceInterface) { HRESULT hr; D3DFORMAT asbak; #if 0 /* check if the format isn't possibly really available */ if (MultiSample.Get() && (pPresentationParameters->MultiSampleType == D3DMULTISAMPLE_NONE)) { D3DFORMAT frmt = D3DFMT_UNKNOWN; if (IsHDR()) frmt = D3DFMT_A16B16G16R16F; else frmt = D3DFMT_A8R8G8B8; hr = m_d3d->CheckDeviceMultiSampleType(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, frmt, FALSE, (D3DMULTISAMPLE_TYPE)MultiSample.Get(), NULL); if (SUCCEEDED(hr)) { pPresentationParameters->MultiSampleType = (D3DMULTISAMPLE_TYPE)MultiSample.Get(); pPresentationParameters->MultiSampleQuality = 0; pPresentationParameters->Flags &= ~D3DPRESENTFLAG_LOCKABLE_BACKBUFFER; } } #endif /* replace whatever by INTZ for example if possible */ pPresentationParameters->AutoDepthStencilFormat = GetDepthBufferFormat(m_d3d, asbak = pPresentationParameters->AutoDepthStencilFormat, pPresentationParameters->MultiSampleType); /* try -> fail -> restore */ hr = m_d3d->CreateDevice(Adapter, DeviceType, hFocusWindow, BehaviorFlags, pPresentationParameters, ppReturnedDeviceInterface); if (!SUCCEEDED(hr)) { pPresentationParameters->AutoDepthStencilFormat = asbak; hr = m_d3d->CreateDevice(Adapter, DeviceType, hFocusWindow, BehaviorFlags, pPresentationParameters, ppReturnedDeviceInterface); } _MESSAGE("OD3D9: Device queried from 0x%08x", _ReturnAddress()); _MESSAGE("OD3D9: Queue %d, MS-type %d, MS-quality %d", pPresentationParameters->BackBufferCount, pPresentationParameters->MultiSampleType, pPresentationParameters->MultiSampleQuality); // Return our device if (SUCCEEDED(hr)) *ppReturnedDeviceInterface = new OBGEDirect3DDevice9(this, *ppReturnedDeviceInterface); return hr; }
bool SKSEPlugin_Load(const SKSEInterface * skse) { _MESSAGE("Initializing INI Manager"); g_INIManager->Initialize("Data\\SKSE\\Plugins\\Smart Souls.ini", NULL); SmartenSkyrimSouls(); _MESSAGE("Souls Smartened Successfully!"); return true; }
bool SKSEPlugin_Load(const SKSEInterface * skse) { _MESSAGE("Initializing INI Manager"); FuzRoDohINIManager::Instance.Initialize("Data\\SKSE\\Plugins\\Fuz Ro D'oh.ini", NULL); BollocksBollocksBollocks(); _MESSAGE("Fuz Ro D'oh Initialized!"); return true; }
static void HookWindowThread(void * param) { _MESSAGE("create hook window"); EditorHookWindow * window = new EditorHookWindow; window->PumpEvents(); _MESSAGE("hook window closed"); delete window; }
void MessageHandler(OBSEMessagingInterface::Message* msg) { switch (msg->type) { case OBSEMessagingInterface::kMessage_ExitGame: _MESSAGE("Plugin Example received ExitGame message"); break; case OBSEMessagingInterface::kMessage_ExitToMainMenu: _MESSAGE("Plugin Example received ExitToMainMenu message"); break; case OBSEMessagingInterface::kMessage_PostLoad: _MESSAGE("Plugin Example received PostLoad mesage"); break; case OBSEMessagingInterface::kMessage_LoadGame: case OBSEMessagingInterface::kMessage_SaveGame: _MESSAGE("Plugin Example received save/load message with file path %s", msg->data); break; case OBSEMessagingInterface::kMessage_Precompile: { ScriptBuffer* buffer = (ScriptBuffer*)msg->data; _MESSAGE("Plugin Example received precompile message. Script Text:\n%s", buffer->scriptText); break; } case OBSEMessagingInterface::kMessage_PreLoadGame: _MESSAGE("Plugin Example received pre-loadgame message with file path %s", msg->data); break; case OBSEMessagingInterface::kMessage_ExitGame_Console: _MESSAGE("Plugin Example received quit game from console message"); break; default: _MESSAGE("Plugin Example received unknown message"); break; } }
void SetSaveName(const char * name) { if(name) { _MESSAGE("save name is %s", name); s_savePath = MakeSavePath(name, ".skse"); _MESSAGE("full save path: %s", s_savePath.c_str()); } else { _MESSAGE("cleared save path"); s_savePath.clear(); } }