Emilie217 Posted April 27, 2014 Share Posted April 27, 2014 (edited) bump. after much messing around, I was able to create a plugin, compile it and "install" it to skyrim.It logs its loading phase (well, at least I know it's running) but skse->QueryInterface fails and so I'm unable to register my functions. I did define _PPAPI but it seems SKSE doesn't quite "catch" that. The SKSE log file says it didn't recognize "kInterface_Papyrus" which would only happen if _PPAPI was undefined. So I'm guessing there's no way to define _PPAPI for the skse.dll. You can only define it for your own dll.However, you guys (2 last posts before mine) seem to be able to run plugins.How did you manage that? I looked in the SKSE dll and no, the #ifdef _PPAPI stuff isn't commented.I don't want to comment it either since I'd have to distribute a new version of skse along with my plugin which I do not want to do. Edit : Found it. You have to use version 1.7.0 or higher for _PPAPI to be active. Works wonders now. Edited April 28, 2014 by Emilie217 Link to comment Share on other sites More sharing options...
ElectricVersion Posted March 25, 2015 Share Posted March 25, 2015 I'm having a problem with the code posted by eventHandler - I filled in the missing bits and modified it a bit and I'm getting these errors: Error 1 error LNK2001: unresolved external symbol "void __cdecl FormHeap_Free(void *)" (?FormHeap_Free@@YAXPAX@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 2 error LNK2001: unresolved external symbol "void __cdecl UnpackValue<unsigned long>(unsigned long *,class VMValue *)" (??$UnpackValue@K@@YAXPAKPAVVMValue@@@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 3 error LNK2001: unresolved external symbol "void * __cdecl FormHeap_Allocate(unsigned long)" (?FormHeap_Allocate@@YAPAXK@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 4 error LNK2001: unresolved external symbol "void * __cdecl UnpackHandle(class VMValue *,unsigned long)" (?UnpackHandle@@YAPAXPAVVMValue@@K@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 5 error LNK2001: unresolved external symbol "unsigned long __cdecl GetTypeID<unsigned long>(class VMClassRegistry *)" (??$GetTypeID@K@@YAKPAVVMClassRegistry@@@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 6 error LNK2001: unresolved external symbol "unsigned long __cdecl GetTypeID<void>(class VMClassRegistry *)" (??$GetTypeID@X@@YAKPAVVMClassRegistry@@@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 7 error LNK1120: 6 unresolved externals C:\Users\student\Desktop\skse_1_07_01\src\skse\Release\plugin_example.dll plugin_example Is this code outdated, or did I just mess something up? Link to comment Share on other sites More sharing options...
NeoH4x0r Posted November 22, 2015 Share Posted November 22, 2015 (edited) I'm having a problem with the code posted by eventHandler - I filled in the missing bits and modified it a bit and I'm getting these errors: Error 1 error LNK2001: unresolved external symbol "void __cdecl FormHeap_Free(void *)" (?FormHeap_Free@@YAXPAX@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 2 error LNK2001: unresolved external symbol "void __cdecl UnpackValue<unsigned long>(unsigned long *,class VMValue *)" (??$UnpackValue@K@@YAXPAKPAVVMValue@@@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 3 error LNK2001: unresolved external symbol "void * __cdecl FormHeap_Allocate(unsigned long)" (?FormHeap_Allocate@@YAPAXK@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 4 error LNK2001: unresolved external symbol "void * __cdecl UnpackHandle(class VMValue *,unsigned long)" (?UnpackHandle@@YAPAXPAVVMValue@@K@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 5 error LNK2001: unresolved external symbol "unsigned long __cdecl GetTypeID<unsigned long>(class VMClassRegistry *)" (??$GetTypeID@K@@YAKPAVVMClassRegistry@@@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 6 error LNK2001: unresolved external symbol "unsigned long __cdecl GetTypeID<void>(class VMClassRegistry *)" (??$GetTypeID@X@@YAKPAVVMClassRegistry@@@Z) C:\Users\student\Desktop\skse_1_07_01\src\skse\plugin_example\main.obj plugin_example Error 7 error LNK1120: 6 unresolved externals C:\Users\student\Desktop\skse_1_07_01\src\skse\Release\plugin_example.dll plugin_example Is this code outdated, or did I just mess something up? I got those errors as well ... when I was creating a plugin my self. The problem is that you do not have .lib file to link against. Right click on the skse project in visual studio (and choose Properties) to open the project properties.Under 'Configuration Properties' -- click 'General'. You should see 'Configuration Type' ...change it from 'Dynamic Library (.dll)' to 'Static Library (.lib)' Now when that is done...open the project properties for your plugin's project file (again right-click on it in solution explorer).When it is open click on 'Common Propeties' in the tree, then 'Framework and References'If you do not see a refense to skse then cick 'add new reference' ..... simply select the skse project and click ok. Re-compile/Re-build the project, a .lib file will be built and you should not get anymore link errors. ---------------------------------------------Honestly, the skse team should release an export definition file (or decorated the classes/types as __declspec(dllexport)).If they did that then a .lib file would be generated when the project was built -- and you would not have to create a static library. Althought, I can see why they don't ... they expect you to do everything through the plugin api. Edited November 22, 2015 by NeoH4x0r Link to comment Share on other sites More sharing options...
zombifiedgrass Posted December 20, 2015 Share Posted December 20, 2015 (edited) OMG thank you NeoH4x0r, i've been spending the last 6 months learning c++ and building a plugin for my A level project but I would never have been able to complete it if it wasn't for that comment!!!! BTW, do you know what the steam_boot project that is unavailable in the latest skse version and dinput.h is acknowledged by skse when i rebuild it. Edited December 20, 2015 by zombifiedgrass Link to comment Share on other sites More sharing options...
NeoH4x0r Posted January 8, 2016 Share Posted January 8, 2016 (edited) OMG thank you NeoH4x0r, i've been spending the last 6 months learning c++ and building a plugin for my A level project but I would never have been able to complete it if it wasn't for that comment!!!! BTW, do you know what the steam_boot project that is unavailable in the latest skse version and dinput.h is acknowledged by skse when i rebuild it.I don't know what steam_boot was for (I guess it what something internal to th dev team to they forgot to remove it from the project).You could just remove it from the project list -- as far as i know it is not required to build skse or a plugin. Also I'm not sure what you are asking in regards to dinput.h...If you are getting errors related to dinput.h (it might possible that you do not have the proper includes setup for Direct X)You would at must need to install the DirectX SDK (https://www.microsoft.com/en-us/download/details.aspx?id=6812). You may even need to add the include paths/library paths to point to the installed include/lib folders, Edited January 8, 2016 by NeoH4x0r Link to comment Share on other sites More sharing options...
Doege Posted August 24, 2016 Share Posted August 24, 2016 (edited) I can compile the sample project at work with fresh install of Visual studio community on my Windows 7 machine. At home however, with Windows 10, fresh install of same, the sample plugin project does not compile. Edited August 24, 2016 by Doege Link to comment Share on other sites More sharing options...
Recommended Posts