Jump to content

Kisvakond

Member
  • Posts

    41
  • Joined

  • Last visited

Posts posted by Kisvakond

  1. Make sure that the fn_keepdoc.sqf is accessable under missionfolder/addons/KeepDocs. It is also important that the fn_keepdoc.sqf is compiled *before* the custom crafting and upgrading script compile.

    Based on what you experience, the function is called but returns nothing. Either it was not found or not compiled before it was called.

  2. EDIT: v0.2 is available for download!
    Please see the changes in the description for the changed instructions relative to v0.1!
    The relevant changes are in Step 3.
    Again, any feedback is welcome! Thank you for trying out my mod!
     
    Hello all,
     
    This is the very first mod I made, so treat it as a baby step. Hope you will find it useful. :D
    Any suggestions or feedback is welcome!
     
    KeepDocs Mod v0.2

    Author: Kisvakond at epochmod.com/forum/ Contact: [email protected]

    A DayZ Epoch mod to keep players' HowTo documents otherwise consumed for crafting/upgrades. Use the DZE_KeepHowTos variable to control whether you like to lose your documents or not.

    DZE_KeepHowTos = true -> keep it

    DZE_KeepHowTos = false -> lose it (default Dayz Epoch feeling)

    Usage: Do your crafting or vehicle upgrade as usual. The document used will remain in your inventory.

    Installation NOTE: Use at you own risk! These instructions are for Epoch 1.0.5.1. For future version, please check the github for updates or contact me if something is out of date!

    Step 1 Download the ZIP from the Github repo

    Step 2 Form the ZIP, extract the 'addons' folder into (your Dayz Epoch Server folder)\Arma 2 Operation Arrowhead\MPMissions\(yourmisson) folder. Or just create the addons\KeepDocs folder and copy the fn_keepDoc.sqf file. If upgrading from v0.1 to v0.2, overwrite the file with the newer from GitHub!

    Step 3 If you already have a custom compiles.sqf, go to step 3c. If you don't have one, get it by extracting one from your dayz_code.pbo.

    a ) Locate dayz_code.pbo at (your Steam folder)\SteamApps\common\Arma 2 Operation Arrowhead\(your Dayz folder e.g. @DayZ_Epoch1051)\addons\

    b ) Use you favourite PBO tool to open and extract dayz_code\init\compiles.sqf. Copy it to your mission folder, mentioned in Step 2.

    c ) With you PBO tool, copy the following files into the addons\KeepDocs folder in your mission folder:

    * dayz_code\actions\player_craftItem.sqf
    * dayz_code\compile\player_upgradeVehicle.sqf.

     

    d ) In your mission folder, open addons\KeepDocs\player_craftItem.sqf and search for the line:

    _inputWeapons = getArray (configFile >> _baseClass >> _item >> "ItemActions" >> _crafting >> "inputweapons");

    After this line, insert: [CHANGE below]

    /* Keep the HowTo document on demand */
    _selectedRecipeInput = [_selectedRecipeInput ] call fnc_keepDoc;

    e ) In your mission folder, open addons\KeepDocs\player_upgradeVehicle.sqf and look for this line:

    _requirementsMagazine = _upgrade select 2;

    After this line, insert: [CHANGE below]

    /* Keep the HowTo document on demand */
    _requirementsMagazine = [_requirementsMagazine ] call fnc_keepDoc;

    Step 4 a) In your copy of compiles.sqf in your mission folder, replace the line:

    player_craftItem = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_craftItem.sqf";

    to

    player_craftItem = compile preprocessFileLineNumbers "addons\KeepDocs\player_craftItem.sqf";

    b ) Then, replace this:

    player_upgradeVehicle = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\player_upgradeVehicle.sqf";

    to

    player_upgradeVehicle = compile preprocessFileLineNumbers "addons\KeepDocs\player_upgradeVehicle.sqf";

    c ) before the line you have changed in step 4a, put this line:

    fnc_keepDoc = compile preprocessFileLineNumbers "addons\KeepDocs\fn_keepDoc.sqf"; /* Addon for custom craft and upgrade functions */

    Step 5 a) In your init.sqf, locate the end of the variables. Look for

    //Load in compiled functions

    Before this line, copy

    /* Set up to keep howto documents after using them. To set back default behaviour (lose documents), set it to false. */
    if(isNil "DZE_KeepHowTos") then {
    DZE_KeepHowTos = true;
    };

    b ) Skip this if you already have a working custom compiles.sqf based on the original one. In the mission's init.sqf (located in the root of your your MPMisson\yourmisson), locate this line:

    call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf" 

    and replace to

    call compile preprocessFileLineNumbers "compiles.sqf"; /* Compile Custom Functions */

    That's all.

    Hope you like it! :D

     

    Kisvakond

  3. Is there anyplace in the files that defines how rare it is to catch one fish over another? I have a user on my server claiming that trout is "10x" more common than tuna. I've added fish markets to my server and would like to price the fish according to their rarity.

     

    Tuna is extremely rare compared to the chance of getting a trout or even a sea bass (catch is coming from randomly picking fom different catch pool arrays). It's interesting though, that when you catch something and keep fishing right after that, you have a better chance for catch multiple fish in a row. :D

     

    Your chances for catch is bigger if you do fishing in a boat and you can even double that chance if it's raining. You can only fish in he sea (script excludes lakes or ponds which I find unrealistic but that's my opinion).

     

    You can increase fishing efficiency (fish per minute hour rate) if multiple dudes are fishing on the same fishing boat.

  4. DZE_SelfTransfuse = true;

    DZE_selfTransfuse_Values = [6000, 10, 180];

     

    Works too.  6000= Amount of blood given, 10= infection chance and 180= Cooldown before using another bloodbags

    Thanks for tip! You have just made me undo the bloodbag mod on my dev server! :D

  5.  

    Who even use that shit xD

     

    Self bloodbag is default in epoch...

     

    just activate it with this:

    DZE_SelfTransfuse           	= true;
    

     

    Another thing good to know is that Krixes self blood bag gives you 10% chance of infection when self transfusing, so the ones looking foir cheap thrills in Dayz, may opt for it for extra realism.

  6. Thanks mate I'll give it a crack when I get home from work.

    Doesn't work at all. Players including myself are all stuck on the loading screen with "waiting for auth" bit....

     

    Fixed it! I'm sorry to say this infistar but the issue is solely based on your anti-hack details below:

    ...

     

    Hope this helped!

     

    Hate to say but I never had Inifistar and I've experienced the issue (in case there were script errors).

  7. It's normal. In CfgMagazines.hpp:

    	class stick_fence_kit: CA_Magazine
    	{
    		scope = 2;
    		count = 1;
    		type = 256;
    		displayName = "Stick Fence";
    		descriptionShort = "Stick Fence: A buildable barrier that can be used to keep zombies out of your camp. They are fairly weak and can be ran over easier.";
    		model = "\z\addons\dayz_epoch\models\supply_crate.p3d";
    		picture = "\z\addons\dayz_epoch\pictures\equip_wooden_crate_ca.paa";
    		weight = 15;
    		class ItemActions
    		{
    			class Build
    			{
    				text = $STR_ACTIONS_BUILD_EPOCH;
    				script = "spawn player_build;";
    				require[] = {"ItemEtool","ItemToolbox"};
    				create = "StickFence_DZ";
    			};
    		};
    	};
    

    As far as one can track back this file (Aug 2013), the Etool was always a must for stick fence.

  8. I've been experiencing this issue frequently on my local dev server, no matter if connecting from the same machine, another machine with a different player UID, or a third computer coming from outside LAN.

    Such problems are coming from scripting issues on the server side or the client side. In case of a script, this problematic script just aborts (not necessarily executing everything before the bad line) and if this happens during connecting, I will have no 3D image. I have read some speculations about AMD video drivers causing this, but I can repro it on the intel/intel machines as well...

    If the problem is in the mission or server side scripts, no one will have video. If the problem is with the client (I got a rebuilt client with own key/signature, so no one can join the server except the testing guys and me), it's only the clients with issues that wont have video.

  9. As we know, howtos gathered by examining documents will be consumed when using them. I dunno how others think but IMO the object of a howto is to REproduce something. I would gladly see the option to keep howtos after crafting/upgrading by default, or at least as a server side setting.

    Based on the dayz_code, currently it's hardwired (in the .hpp files) to be consumed.

    What's your opinion? Would you like to have the option to keep them?

    Let me know if you would be happy with a server mod that sorts this out!

    (I will do it for myself anyway harharhar)

    Cheers

  10. Hello all,

     

    When I re-started playing Dayz Epoch lately (I run a local dev server and started to do mod development), I've noticed that the Chernarus map has some buildings made enterable, others like the hospital, was fully implemented inside. That made me wonder.

     

    How were these modifications made? Did they come with the base ARMA2 OA game via steam update?

     

    There are still lots of building which are 'closed'. Is there a legal/technical way for the community to contribute to 'opening up' the vanilla maps? Is there any tutorials about this?

     

    I've seen some Chernarus maps with HD textures, winter conversions etc. Is there a way for a server to use (-> require) such maps?

     

    Thank you very much in advance!

     

    Best Regards

     

    Kisvakond

  11. no you cant change the dayz_code folder its self or people wont be able to join

    instead you need to move the file to the mission pbo file.

    the weight file is called from in the dayz_code\system\player_monitor.sqf so you will need to move that file along with changing the path in the init.sqf

    Would this method work with other client-side resources like FSMs or the config.cpp of dayz_code?

  12. Yea I was thinking the same thing. PBOManager did the trick. I compiled a pbo and ran the server. It started fine. Thanks for the help dude.

     BI's BinPBO is the most appropriate one, however it's fairly inconvenient to use.

     

    If you re-compress into PBO, always make sure that you set the Addon prefix (PBO manager creates a $PREFIX$ file containing it, although the final PBO do not contain them).

    Failure to do so will cause he mission to miss the files referred in the PBO's (as the base path wil lnot be z\addons\<folder_name>).

     

    It's also important that you should not binarize the PBO, otherwise they will no work.

  13. Hi all,

     

    I've been doing my studies in scripting and I ran into a general issue when copying code from forums or pdfs (which is most of the admins doing).

     

    If you have a line of comment with the // comment in a code snippet you wish to copy, it might be that due to a line wrap, something from the comment line might end up in the beginning of the next line. sometimes the end of the has valid keywords by coincidence and, and there you go, clusterfuck.

     

    I was running into the issue again yesterday with this post:

    ...

    //fnc_usec_selfActions = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\fn_selfActions.sqf"; // Checks which actions for 
    selffnc_usec_selfActions =  compile preprocessFileLineNumbers "fn_selfActions.sqf"; // Checks which custom actions for self
    

    ...

     

    The last word from the comment went in the next line -> selffnc_usec_selfActions instead of fnc_usec_selfActions.

     

    A newline character gone missing in action or inserted by the code snippet frame and you wonder why it failed, although you did everything right and that very same stuff worked for others (displaying the code snippets may be well browser and settings-specific).

    Most tutorials encourage scripters to use the line C++ style comments, although the old-fashioned C-style comment work as well (based on the ARMA2 Scripting Guide by Taurus, it's supported ).

     

    With the /*..*/ comments such an error could have never happened, e.g. in the mentioned example:

    /*fnc_usec_selfActions = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\fn_selfActions.sqf";*/ /* Checks which actions for 
    self*/fnc_usec_selfActions =  compile preprocessFileLineNumbers "fn_selfActions.sqf"; /* Checks which custom actions for self */
    

    In this case the original intent of the coder is visible (what's meant to be comment and what's not) and more error tolerant/defensive, as the compiler is not at the mercy of the newline CRLFs.

    IMHO, most of the time when a copy-paste code is not working or emits side-effects, it's a missing or  re-located newline character ruining the next line of code.

     

    Hopefully no one gets the impression that the problem is having comments (there can't be enough of them). The point is that we should use /*..*/ comments whenever possible.

     

    Thank you for reading! :)

     

    Cheers

     

    Kisvakond

  14. yeah

     

    Ok, I have to accept (for now), that there's no way around Soul's god-mode DLL. I will start to make the steps you made for custom client-side requests.

     

    The custom DLL is backward compatible then, right? So that I can just really replace the DLL and nothing else? My dev server is just vanilla 1.0.5.1 (yet).

×
×
  • Create New...