2.0.0 Plugins/KosAcid Projects/Plugin Ports
-
Try with the last platform sdk from ms, switch from debug configuration to active (Release)
-
Look at crash offset
-
HeIIoween wrote:
Look at crash offsetOK…It’s not crash and runtime erroring at Release config so far…BUT…i got problem when enter /help in game.
Here is code…i just copy it condata plugin…:
typedef void (*_UserCmdProc)(uint, const wstring &); struct USERCMD { wchar_t *wszCmd; _UserCmdProc proc; }; USERCMD UserCmds[] = { { L"/buyslot", UserCmd_BuySlot}, }; EXPORT bool UserCmd_Process(uint iClientID, const wstring &wscCmd) { wstring wscCmdLower = ToLower(wscCmd); for(uint i = 0; (i < sizeof(UserCmds)/sizeof(USERCMD)); i++) { if(wscCmdLower.find(ToLower(UserCmds[i].wszCmd)) == 0) { wstring wscParam = L""; if(wscCmd.length() > wcslen(UserCmds[i].wszCmd)) { if(wscCmd[wcslen(UserCmds[i].wszCmd)] != ' ') continue; wscParam = wscCmd.substr(wcslen(UserCmds[i].wszCmd) + 1); } UserCmds[i].proc(iClientID, wscParam); returncode = SKIPPLUGINS_NOFUNCTIONCALL; // we handled the command, return immediatly return true; } } returncode = DEFAULT_RETURNCODE; // we did not handle the command, so let other plugins or FLHook kick in return false; } /////////////////////////////////////////////////////////////////////////////////////////////////////////////// EXPORT void UserCmd_Help(uint iClientID, wstring wscParam) { PrintUserCmdText(iClientID, L"/buyad"); } EXPORT bool ExecuteCommandString_Callback(CCmds* classptr, const wstring &wscCmd) { returncode = DEFAULT_RETURNCODE; return false; } EXPORT void Plugin_Communication_CallBack(PLUGIN_MESSAGE msg, void* data) { returncode = DEFAULT_RETURNCODE; return; } p_PI->lstHooks.push_back(PLUGIN_HOOKINFO((FARPROC*)&UserCmd_Process, PLUGIN_UserCmd_Process, 0)); p_PI->lstHooks.push_back(PLUGIN_HOOKINFO((FARPROC*)&UserCmd_Help, PLUGIN_UserCmd_Help, 0)); p_PI->lstHooks.push_back(PLUGIN_HOOKINFO((FARPROC*)&LoadSettings, PLUGIN_LoadSettings, 0)); p_PI->lstHooks.push_back(PLUGIN_HOOKINFO((FARPROC*)&Plugin_Communication_CallBack, PLUGIN_Plugin_Communication, 0)); p_PI->lstHooks.push_back(PLUGIN_HOOKINFO((FARPROC*)&ExecuteCommandString_Callback, PLUGIN_ExecuteCommandString_Callback, 0)); /buyslot is works good, problem just happen when i enter /help in chat. FLServer will crash after that, and in game, the red connection warning will showup, then after few sec, the /help list shows up, but FLServer already crashed.. Here is demo for the bug: [flash]http://player.youku.com/player.php/sid/XMzE2NzI2NjI4/v.swf[/flash][/i][/i][/i][/i]
-
Try
EXPORT void UserCmd_Help(uint iClientID, const wstring &wscParam) { PrintUserCmdText(iClientID, L"/buyad"); }
P.S. Wow nice mod!
-
Another problem.
Seems there is two FLHook 2.0, one i checked out from TSP SVN, file size 619KB, other one from KosAcid’s repository on SF.net, file size 651KB.
After test…. i think this two version is incompatible… i mean it’s not load each other’s plugin… anybody looked in to it?
I the plugins i used for test, so you can check it yourself.
-
Svn version compiled under 2008 i think, and at Sf.net under 2010.
Install also vc10 x86 redist and vc9 x86 redist then. -
It’s strange, i have VC9E and VC10E installed on my computer, so the redist runtime lib must also installed. but i still cannot make plugins running in both two FLHook in same time.
But… FLHook is not supported vc10 to compile for now right? I failed to use those 2.0 plugin on.
-
Ok, tell me final target of your dance with FLHooks to make clear vision of a problem
-
For vc10 there is small workaround http://forge.the-starport.net/issues/159#note-4 - it is not recommended by W0dk4 but for vc10 plugins it works well.
I do not see any problems yet with vc10 plugins which i’ve ported and choosed from KosAcids repo so while i’m using only vc10 hook and all works well
-
MineControl 1.2 added
-
Done, Thank you Helloween, i just send both two version to that guy and let them choice themself.
Oh, the last one question, that about DSAceServer Plugin? Is it updated to FLHook 2.0 too?
Is the DSAceServer Plugin is the must one for a Discovery Server? If not, they will can use KA FLHook 2.0 and plugins now.
-
NeXoSE wrote:
Done, Thank you Helloween, i just send both two version to that guy and let them choice themself.Oh, the last one question, that about DSAceServer Plugin? Is it updated to FLHook 2.0 too?
Is the DSAceServer Plugin is the must one for a Discovery Server? If not, they will can use KA FLHook 2.0 and plugins now.
No. Cannon ignores me although in Readme.txt of http://forge.the-starport.net/attachments/download/346/flhook_plugin_1.6.1_discovery_release_8July2011.7z there is
The dsacesrv plugin source is available on request. Ask me if you really want it.
So ask Cannon and port yourself
-
Hello,
In the Cloak plugin, option “DropShieldsCloak” does not work.add :
[...] ///bool set_bPreventFireCloak; bool set_bDropShieldsCloak; [...] ///PrintUserCmdText(iClientID, set_wscCloakPrepareMsg); if(set_bDropShieldsCloak){ pub::SpaceObj::DrainShields(iShip); } [...] ///set_bPreventFireCloak = IniGetB(scPluginCfgFile, "General", "PreventFireCloak", false); set_bDropShieldsCloak = IniGetB(scPluginCfgFile, "General", "DropShieldsCloak", false);
-
Dock Restrict doesn’t work. It’ll deny the player docking, but even if you have the proper item to unlock it, it won’t work.
It also doesn’t display dock denied messages. And when it does, it displays the ones I had from 1.61, which were changed. In fact, even deleting any entries from DockRestrict.ini had no effect, it still worked as if there were no changes.
So a lot of things wrong with it in general. -
Thx Starworld - we will take a note.
Try Adoxa’s http://adoxa.3eeweb.com/freelancer/plugins.html#dockkey
Don’t look at “SP only”.
It works well at server-side even if client changed his dock_key.ini - Jeider checked this feature.
-
Alright, that works just fine.