FLHook Plugin Version

no description available
69 Topics 557 Posts
  • Looking for "Manufacturing" plugin/script

    Locked
    8
    0 Votes
    8 Posts
    9k Views

    I’ve been thinking about a possible file format.

    [Manufacture]
    ship = nicknames of ships capable of creating this item
    input = nickname and quantity (default of 1) of required item
    input = repeated as necessary
    output = nickname and quantity (default of 1) of resulting item

    An artificial example:

    input = hydrogen, 2
    input = oxygen
    output = water

    I’d expect the command would create as much as it can by default, specifying a limit if you don’t want to use everything up. So if you have 20 hydrogen and 20 oxygen, /create water would create 10 water, but /create water 1 would just create the one; /create water hydrogen 10 creates five.

    Why restrict it to commodities? You could take two “single-barreled” guns and combine them to create a single “double-barreled” gun.

    Maybe I should stop reading Starport until I finish what I’m already doing… 😄

  • Looking for someone….interested

    Locked
    6
    0 Votes
    6 Posts
    8k Views

    @HazardFN:

    Biocross has plugin functionality which allows you to create a GUI extension of FLHook - .NET languages only though :(, if you are interested in making your killboard plugin with some GUI based options and features then don’t hesitate to ask me about making plugins for Biocross - I need to build up a library of plugins to expand on it’s FLHook functionality as it is.

    If not mate then no worries, hope to see your plugin up soon.

    @HazardFN
    Actually, I don’t know how to programming with .Net framework. sorry.

    @tai
    I have a php project for a private flboard server long before, finished for a mod team at february. And this is my first php project, so it suck. You can download it HERE, this will let you know what php can do for FLServer(with flboardplugin).

  • 0 Votes
    8 Posts
    9k Views

    all is default, and strange, when i change Debug (Win32) to Release (Win32) and build project, it will working normally….what happen?

    <visualstudioproject<br>ProjectType=“Visual C++”
    Version=“7.10”
    Name=“My Plugin For FLHook”
    ProjectGUID=“{01DE3D3D-0DA2-447E-8C03-B2A2FB03A0F5}”
    RootNamespace=“My Plugin For FLHook”
    Keyword=“Win32Proj”>
    <platforms><platform<br>Name=“Win32”/></platform<br></platforms>
    <configurations><configuration<br>Name=“Debug|Win32”
    OutputDirectory=“Debug”
    IntermediateDirectory=“Debug”
    ConfigurationType=“2”
    UseOfMFC=“0”
    CharacterSet=“2”>
    <tool<br>Name=“VCCLCompilerTool”
    Optimization=“0”
    PreprocessorDefinitions=“WIN32;_DEBUG;_WINDOWS;_USRDLL;FLHOOKWEBFRONTPLUGIN_EXPORTS”
    MinimalRebuild=“TRUE”
    BasicRuntimeChecks=“3”
    RuntimeLibrary=“1”
    UsePrecompiledHeader=“0”
    WarningLevel=“3”
    Detect64BitPortabilityProblems=“TRUE”
    DebugInformationFormat=“4”/>
    <tool<br>Name=“VCCustomBuildTool”/>
    <tool<br>Name=“VCLinkerTool”
    AdditionalDependencies=“./libs/FLHook.lib ./libs/server.lib ./libs/common.lib ./libs/remoteclient.lib ./libs/dalib.lib”
    OutputFile=“G:\Games\Freelancer\EXE\flhook_plugins\dlls\Plugin.dll”
    LinkIncremental=“2”
    GenerateDebugInformation=“TRUE”
    ProgramDatabaseFile=“$(OutDir)/Plugin.pdb”
    SubSystem=“2”
    ImportLibrary=“$(OutDir)/Plugin.lib”
    TargetMachine=“1”/>
    <tool<br>Name=“VCMIDLTool”/>
    <tool<br>Name=“VCPostBuildEventTool”/>
    <tool<br>Name=“VCPreBuildEventTool”/>
    <tool<br>Name=“VCPreLinkEventTool”/>
    <tool<br>Name=“VCResourceCompilerTool”/>
    <tool<br>Name=“VCWebServiceProxyGeneratorTool”/>
    <tool<br>Name=“VCXMLDataGeneratorTool”/>
    <tool<br>Name=“VCWebDeploymentTool”/>
    <tool<br>Name=“VCManagedWrapperGeneratorTool”/>
    <tool<br>Name=“VCAuxiliaryManagedWrapperGeneratorTool”/>

    <configuration<br>Name=“Release|Win32”
    OutputDirectory=“Release”
    IntermediateDirectory=“Release”
    ConfigurationType=“2”
    UseOfMFC=“0”
    CharacterSet=“2”>
    <tool<br>Name=“VCCLCompilerTool”
    PreprocessorDefinitions=“WIN32;NDEBUG;_WINDOWS;_USRDLL;PLUGIN_EXPORTS”
    RuntimeLibrary=“2”
    UsePrecompiledHeader=“0”
    WarningLevel=“3”
    Detect64BitPortabilityProblems=“TRUE”
    DebugInformationFormat=“3”/>
    <tool<br>Name=“VCCustomBuildTool”/>
    <tool<br>Name=“VCLinkerTool”
    AdditionalDependencies=“./libs/FLHook.lib ./libs/server.lib ./libs/common.lib ./libs/remoteclient.lib ./libs/dalib.lib”
    OutputFile=“$(OutDir)/Plugin.dll”
    LinkIncremental=“1”
    GenerateDebugInformation=“TRUE”
    SubSystem=“2”
    OptimizeReferences=“2”
    EnableCOMDATFolding=“2”
    ImportLibrary=“$(OutDir)/Plugin.lib”
    TargetMachine=“1”/>
    <tool<br>Name=“VCMIDLTool”/>
    <tool<br>Name=“VCPostBuildEventTool”/>
    <tool<br>Name=“VCPreBuildEventTool”/>
    <tool<br>Name=“VCPreLinkEventTool”/>
    <tool<br>Name=“VCResourceCompilerTool”/>
    <tool<br>Name=“VCWebServiceProxyGeneratorTool”/>
    <tool<br>Name=“VCXMLDataGeneratorTool”/>
    <tool<br>Name=“VCWebDeploymentTool”/>
    <tool<br>Name=“VCManagedWrapperGeneratorTool”/>
    <tool<br>Name=“VCAuxiliaryManagedWrapperGeneratorTool”/></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></configuration<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></tool<br></configuration<br></configurations></visualstudioproject<br>

  • Autobuy in version 1.6.0

    Locked
    8
    0 Votes
    8 Posts
    8k Views

    thank you guys

  • Re: Restart Plugin

    Locked
    4
    0 Votes
    4 Posts
    8k Views

    Thanks, I’ll try that… 🙂
    Your an Outcast fan as well Cannon?
    Hehe…Corsairs are losers… 😛

  • Changing the account directory path

    Locked
    4
    0 Votes
    4 Posts
    6k Views

    Hey, look at that. Thanks Cannon, this could be useful. =D

  • FLHook's admin commands

    Locked
    10
    0 Votes
    10 Posts
    14k Views

    I haven’t yet had time to do it but ^^ thx anyway 🙂

  • Do these plugins exist?

    Locked
    8
    0 Votes
    8 Posts
    9k Views

    Sorry for not replying earlier.

    this is great news thanks

  • Anticheat plugin Ignores the admin flhook file

    Locked
    2
    0 Votes
    2 Posts
    5k Views

    ;D
    No cheating 4 admins with that plugin afaik.
    Mit dem Plugin dürfen halt auch Admins nicht cheaten
    (soweit ich mich erinnere).

  • Other Programming Languages

    Locked
    3
    0 Votes
    3 Posts
    5k Views

    You could try exporting functions as cdecl…

  • M0tah FLhook 1.6.0 plugin?

    Locked
    5
    0 Votes
    5 Posts
    7k Views

    Well, just by how the plugin version works it’s going to be less efficient than having a FLHook that has the features natively implemented. In a native implementation, all of the code that’s in callback functions is in one function, allowing the compiler to optimize the code more. However, with plugins all the code for different features is contained in seperate functions, which makes the code more organized but less efficient.

  • Plugin

    Locked
    2
    0 Votes
    2 Posts
    5k Views

    You can basically remove everything except the DLLMain function (and in that function, you can also remove everything).
    What you should keep are the definitions and header files.

  • HkRename in version 1.6.0

    Locked
    3
    0 Votes
    3 Posts
    5k Views

    It turns out that HkRename doesn’t work properly if the starting base is not Manhattan - the call to Server.CreateNewCharacter fails. Those mysterious numbers in the SCreateCharacterInfo structure do change when a different starting location is used. I’ve got a fix for this problem.

    If any one wants a copy of the patched flhook.dll let me know and I’ll make it available.

    Here’s the patched lines in the rename function. It’s a bit hacky but it works for me…

    ... SCreateCharacterInfo newcharinfo; wcsncpy(newcharinfo.wszCharname, wscNewCharname.c_str(), 23); // CHANGE STARTS HERE newcharinfo.iNickName = CreateID(IniGetS("..\\DATA\\CHARACTERS\\newcharacter.ini","Faction","nickname","new_player").c_str()); newcharinfo.iBase = CreateID(IniGetS("..\\DATA\\CHARACTERS\\newcharacter.ini","Faction","base", "Li01_01_Base").c_str()); newcharinfo.iPackage = CreateID(IniGetS("..\\DATA\\CHARACTERS\\newcharacter.ini","Faction","Package","ge_fighter").c_str()); newcharinfo.iPilot = CreateID(IniGetS("..\\DATA\\CHARACTERS\\newcharacter.ini","Faction","Pilot","trent").c_str()); // CHANGE ENDS HERE // Fill struct with valid data (though it isnt used it is needed) newcharinfo.iDunno[4] = 65536; ...

    Here’s the SCreateCharacterInfo structure and the full rename function…

    struct SCreateCharacterInfo { wchar_t wszCharname[23]; uint iNickName; // From [Faction] section of newcharacter.ini uint iBase;  // From [Faction] section of newcharacter.ini uint iPackage; // From [Faction] section of newcharacter.ini uint iPilot; // From [Faction] section of newcharacter.ini uint iDunno[96]; }; HK_ERROR HkRename(wstring wscCharname, wstring wscNewCharname, bool bOnlyDelete) { HK_GET_CLIENTID(iClientID, wscCharname); if((iClientID == -1) && !HkGetAccountByCharname(wscCharname)) return HKE_CHAR_DOES_NOT_EXIST; if(!bOnlyDelete && HkGetAccountByCharname(wscNewCharname)) return HKE_CHARNAME_ALREADY_EXISTS; if(!bOnlyDelete && (wscNewCharname.length() > 23)) return HKE_CHARNAME_TOO_LONG; if(!bOnlyDelete && !wscNewCharname.length()) return HKE_CHARNAME_TOO_SHORT; CAccount *acc; wstring wscOldCharname; if(iClientID != -1) { acc = Players.FindAccountFromClientID(iClientID); wscOldCharname = Players.GetActiveCharacterName(iClientID); } else { wscOldCharname = wscCharname; acc = HkGetAccountByCharname(wscCharname); } wstring wscAccountDirname; HkGetAccountDirName(acc, wscAccountDirname); wstring wscNewFilename; HkGetCharFileName(wscNewCharname, wscNewFilename); wstring wscOldFilename; HkGetCharFileName(wscOldCharname, wscOldFilename); string scNewCharfilePath = scAcctPath + wstos(wscAccountDirname) + "\\" + wstos(wscNewFilename) + ".fl"; string scOldCharfilePath = scAcctPath + wstos(wscAccountDirname) + "\\" + wstos(wscOldFilename) + ".fl"; if(bOnlyDelete) { // delete character flstr *str = CreateWString(wscOldCharname.c_str()); HkLockAccountAccess(acc, true); // also kicks player on this account Players.DeleteCharacterFromName(*str); HkUnlockAccountAccess(acc); FreeWString(str); return HKE_OK; } HkLockAccountAccess(acc, true); // kick player if online HkUnlockAccountAccess(acc); // Copy existing char file into tmp string scTmpPath = scOldCharfilePath+".tmp"; DeleteFile(scTmpPath.c_str()); CopyFile(scOldCharfilePath.c_str(), scTmpPath.c_str(), FALSE); // Delete existing char otherwise a rename of the char in slot 5 fails. flstr *str = CreateWString(wscOldCharname.c_str()); Players.DeleteCharacterFromName(*str); FreeWString(str); // Emulate char create SLoginInfo logindata; wcsncpy(logindata.wszAccount, HkGetAccountID(acc).c_str(), 36); Players.login(logindata, Players.GetMaxPlayerCount()+1); SCreateCharacterInfo newcharinfo; wcsncpy(newcharinfo.wszCharname, wscNewCharname.c_str(), 23); newcharinfo.iNickName = CreateID(IniGetS("..\\DATA\\CHARACTERS\\newcharacter.ini","Faction","nickname","").c_str()); newcharinfo.iBase = CreateID(IniGetS("..\\DATA\\CHARACTERS\\newcharacter.ini","Faction","base", "").c_str()); newcharinfo.iPackage = CreateID(IniGetS("..\\DATA\\CHARACTERS\\newcharacter.ini","Faction","Package","").c_str()); newcharinfo.iPilot = CreateID(IniGetS("..\\DATA\\CHARACTERS\\newcharacter.ini","Faction","Pilot","").c_str()); // Fill struct with valid data (though it isnt used it is needed) newcharinfo.iDunno[4] = 65536; newcharinfo.iDunno[5] = 65538; newcharinfo.iDunno[6] = 0; newcharinfo.iDunno[7] = 1058642330; newcharinfo.iDunno[8] = 3206125978; newcharinfo.iDunno[9] = 65537; newcharinfo.iDunno[10] = 0; newcharinfo.iDunno[11] = 3206125978; newcharinfo.iDunno[12] = 65539; newcharinfo.iDunno[13] = 65540; newcharinfo.iDunno[14] = 65536; newcharinfo.iDunno[15] = 65538; Server.CreateNewCharacter(newcharinfo, Players.GetMaxPlayerCount()+1); HkSaveChar(wscNewCharname); Players.logout(Players.GetMaxPlayerCount()+1); // Decode the backup of the old char and overwrite the new char file if(!flc_decode(scTmpPath.c_str(), scNewCharfilePath.c_str())) { // file wasn't encoded, thus simply rename it DeleteFile(scNewCharfilePath.c_str()); // just to get sure... CopyFile(scTmpPath.c_str(), scNewCharfilePath.c_str(), FALSE); } DeleteFile(scTmpPath.c_str()); // Update the char name in the new char file. // Add a space to the value so the ini file line looks like " <key>= <value>" // otherwise Ioncross Server Operator can't decode the file correctly string scValue = " "; for(uint i = 0; (i < wscNewCharname.length()); i++) { char cHiByte = wscNewCharname[i] >> 8; char cLoByte = wscNewCharname[i] & 0xFF; char szBuf[8]; sprintf(szBuf, "%02X%02X", ((uint)cHiByte) & 0xFF, ((uint)cLoByte) & 0xFF); scValue += szBuf; } IniWrite(scNewCharfilePath, "Player", "Name", scValue); // Re-encode the char file if needed. if (!set_bDisableCharfileEncryption) if (!flc_encode(scNewCharfilePath.c_str(),scNewCharfilePath.c_str())) return HKE_COULD_NOT_ENCODE_CHARFILE; return HKE_OK; } [/i][/i]</value></key>
  • Problem about Anit Cheat Mod

    Locked
    6
    0 Votes
    6 Posts
    7k Views

    i think you just forgot to add the anticheat info in the FLhook.ini and modify them, that should fix all but the alt tab killing….idk how to fix that and would like to know.

  • FLhook 1.6.0 Plugin Issues

    Locked
    2
    0 Votes
    2 Posts
    5k Views

    All of those are caused by the anticheat plugin, I will have a look at it soon hopefully.

  • Other question: Ids_name To "Friendly Name"

    Locked
    29
    0 Votes
    29 Posts
    22k Views

    @Nieckey:

    I think that, you give me a wrong place to add your code.

    I can’t use your code because those code isn’t add in ResString files.

    May you can tell me how like M0tah ? ;D

  • Send HTTP request?

    Locked
    7
    0 Votes
    7 Posts
    7k Views

    Thanks for reply, i has successful post HTTP request via libcurl.dll, and looks slow http will not lag the server ;D

  • Locking up on startup

    Locked
    1
    0 Votes
    1 Posts
    4k Views
    No one has replied
  • FLHook.h mistake?

    Locked
    2
    0 Votes
    2 Posts
    5k Views

    Of course, thx for spotting the mistake.

    I wanted to re-do the sdk files anyways so I think I will release new sdk package soon.

  • FLHook doesn't start with flserver (1.5.9.)

    Locked
    3
    0 Votes
    3 Posts
    7k Views

    Thanks for kicking my butt, worked… 😉