Jump to content

[Tutorial] Overpoch - Custom traders, all weapons/ammo/vehicles in menus


Recommended Posts

  On 2/22/2015 at 12:53 PM, cheech said:

Hello all,

 

i have followed all steps, my Traders spawn correct, but the menus were empty.

 

My RPT is here http://pastebin.com/1N6BDRnR

 

any help please?

 

thanks

RPT looks clean, you most likely have a typo in SQL code, double check your database. Also check your hive log, it should tell you if there are any errors in database.

Link to comment
Share on other sites

Oh nice, the developer sir himself ! :D

 

Thanks for your very fast response!

 

I have upped my server_traders.sqf here: http://pastebin.com/0sRyGnzC

 

the mission.sqf here http://pastebin.com/JE5RHP1p

 

and some sql pics here.

 

i cant find the error...

 

here is my hiveExt.log  nothing special in my opinion...  http://pastebin.com/eKcWsr7k

 

28bxuhc.jpg

3134u0y.jpg

2rc530o.jpg

 

2w1s09x.jpg

i5uct5.jpg

Link to comment
Share on other sites

everything looks clean so far, can you:

 

1) reset hive log, log into game and wait a minute so it finishes loading objects from DB, then Open trader menu and post a log from there. There's a chance error won't show up until you ask for it.

2) Logout in front of trader and remove Antihack temporarily (simply comment out init line in your dayz_server). Then check again without AH running, just to throw AH out of equation.

3) Check original traders if they still have the menu loading. Just for the scale.

4) Change trader skin to something that is not Overwatch based. There has been 2 people reporting this being an issue.

 

It's quite simple the way this works, a selfacions function is run every 0.5 seconds to check ton of things. One of those things is a unit in front of you. If unit is detected, game will check its skin. If skin is found in server_traders file, it will read array of TIDs. When player clicks addaction to trade, a database is then queried, the menu you select (ammo, weapons, vehicles) tells what TID to use as a filter. Everything that matches the filter will be read from database and shown in that menu. If list is big, it might take a while for items to appear, especially when reading over network not on a local machine (one of reasons people switches to cfg traders, where menus are read from mission file that people download, so almost instant).

Link to comment
Share on other sites

here you go raymix,  1)  http://pastebin.com/AxShZu9R

 

more to come...

 

2) cant logout in front of trader, cause  it says i am at trader zone

 

dont really know how to disable infistar AH, cause the gtxgaming hoster has its own infistar, i can see something in the missions  init.sqf

 

the dayz_server is in a .pbo

 

3) original traders work perfect

 

4) i have tried 3 other skins during the day... all the same.  but now i choose one from epoch....wait

 

 

 

have changed skins to Camo1_DZ     same....no items in the menus...

 

 i have renamed the infistar folder with files, now restart, we´ll see what happens^^

Link to comment
Share on other sites

I meant to logout close to trader, so you don't have to walk too far for a simple test, my bad :)

Other than that, everything else checks out, looks clean. Last hive log you posted shows stuff alright, does not mention any overpoch stuff tho, which is weird.

Link to comment
Share on other sites

lol, if you have this line, you are running config traders, which explains why database was not used:

 

init.sqf

DZE_ConfigTrader = true;

This is not a bad thing tho. You can set it to false for shits and giggles to see your traders work from database you created. I'd suggest you stick with config traders instead, bro.

I updated in this thread with my old server configs, that should save you few hours of pain. Enjoy!

Link to comment
Share on other sites

hehe,  that was funny... ^^  sure the items all appear now :D

 

troubleshooting the whole day, only because my hoster has setup the custom traders..funny :-)

 

but ok, its interesting.

 

thank you very much sir for helping me the whole sunday!

 

and i will check your updated 3rd post tommorow then :-)

 

 

do i have to remove something i have added in the database, if i choose your config traders,  or will all still stays there?  cause the traders_data is now around 1.8MiB

 

thanks alot, 

 

have a nice evening bro :-)

 

 

cheers

 

Cheech Marin ;-)

Link to comment
Share on other sites

You should keep your DB small if sticking with config traders, so yea - remove stuff you added.

If you end up using database, then you might want to remove .hpp files to reduce size on mission file.

 

All good, have a nice evening, you too!

Link to comment
Share on other sites

raymix, is there an option how to disable those 14000  messages in the HiveExt.log ?

 

e.g.

  Reveal hidden contents

:2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:

2015-02-25 17:31:10 HiveExt: [information] Result: [11474,["M4A1_Aim",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11475,["M4A1_Aim_camo",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11476,["M4A1_AIM_SD_camo",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11477,["M4A1_HWS_GL",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11478,["M4A1_HWS_GL_camo",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11479,["M4A1_HWS_GL_SD_Camo",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11480,["M4A1_RCO_GL",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11481,["M4A3_CCO_EP1",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11482,["M4A3_RCO_GL_EP1",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11483,["M4SPR",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11484,["M60A4_EP1",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11485,["M621",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:
2015-02-25 17:31:10 HiveExt: [information] Result: [11486,["M68",3],10,[2,"ItemBriefcase100oz",1],[1,"ItemGoldBar10oz",1],0,800,"trade_weapons"]
2015-02-25 17:31:10 HiveExt: [Debug] Original params: |CHILD:399:800:|
2015-02-25 17:31:10 HiveExt: [information] Method: 399 Params: 800:

 

i really dont have a clue to get a nice working hiveext.log     i can choose between those 2 parameter  Level and Console level   where i can put in trace, debug, information, notice, warning, error, critical, fatal, none

 

can u tell me which pair works the best?

 

thanxx :-)

Link to comment
Share on other sites

No, that's intended, and seeing those messages is a good thing (it means everything works). I am pretty sure you can disable logging, but not sure if you can scope them. so it could be on or off, that's it. On top of that I don't think hive logs are persistent, as far as I remember a new one is created after server restart with a new name.

You shouldn't worry about hive logs at all, most of the times if something goes bad, they stop at error and won't continue, so you can go from there. Your best friend is still RPT log. I would advise keeping that one clean instead.

Personally, I would normally stop server, delete RPT log and then start a fresh one. Since I am also quite familiar with SQF, I would go trough all syntax errors and fix them in scripts, then resume with clean logs from there again. But all of this is still optional and personal preference... kinda like an OCD if you will.

Link to comment
Share on other sites

How is the unit number derived for a custom trader? 1337 was the last number that I used simply because it worked for the custom gem trader that I added. If I add a unit in the editor it uses a low unit number like 2. I tried adding a new custom trader tonight and it does not appear in the game. I used _unit_1338 and then tried 2000. Nothing worked.

 

_unit_1337 = objNull;
if (true) then
{
_this = createAgent ["RU_Villager1", [7382.0156, 7459.6587, -0.022578919], [], 0, "CAN_COLLIDE"];
_unit_1337 = _this;

Link to comment
Share on other sites

it doesn't matter what unit it is, the whole file was generated from an editor and that's the output, not very clean, but it works.

In fact the whole code is garbage, you can remove local vars that represent units and it will still work, it is simply used by editor to refer back to a unit to be able to edit/delete it, it is irrelevant for what we do here. Nobody really cares and just goes with the flow, lol.

 

Something like this would work just fine and make more sense. If required, this way you can store unit into an array and pass it on to a function or whatever:

_unitOverNineThousand = objNull; //this defines empty var to avoid RPT errors
_unitOverNineThousand = createAgent ["Winter_SOF_DA1b", [6296.33,7803.79,0], [], 0, "CAN_COLLIDE"]; //and this creates unit and fills that empty variable
_unitOverNineThousand setDir 310; //this and rest of crap below simply adjusts unit values in properties
_unitOverNineThousand setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;"; //oh and this can be used for some seriously cool shit
_unitOverNineThousand setUnitAbility 0.60000002;
_unitOverNineThousand allowDammage false; _this disableAI 'FSM'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0;

Looking at your villager dude, should be fine if you copy/pasted the code (If you look at code I just posted, you will see I did not use IF statement or brackets) ... this means, your issue might be:

1) use 0 for Z axis to plant the dude exactly on a terrain, there is absolutely no need to sink your guy in a ground or random nonsense numbers like you have.... so  [7382.0156, 7459.6587, 0] is as good as it gets.

2) since you are using an IF statement which is always true, you might be missing an ending bracket due to typo. Which means, if you cut and paste your dude's code at the beginning of the file, all of your AI units will bug out and won't load... because of that missing bracket.

Link to comment
Share on other sites

I found my mistake. This is the output from the editor:

 

  Reveal hidden contents

_unit_2 = objNull;


if (true) then
{
_this = _group_0 createUnit ["RU_Damsel4", [10591.77, 14083.106, 1.9073486e-005], [], 0, "CAN_COLLIDE"];
_unit_2 = _this;
_this setDir -86.932022;
_this setUnitAbility 0.60000002;
if (true) then {_group_0 selectLeader _this;};
if (true) then {selectPlayer _this;};
};

 

createUnit should be changed to createAgent to spawn a trader. After I changed that it worked fine. Thanks for your reply raymix. :)

Link to comment
Share on other sites

  • 1 year later...
  On 3/31/2016 at 4:53 AM, my_name_sucks said:

I'm pretty sure I have done everything correctly but when I get in game the trader I placed doesn't have the option of opening a trader menu, does anyone know how to fix this?

Thanks.

Expand  

Double check skin name, make sure it's right, single typo will break the action menu.

Link to comment
Share on other sites

  On 3/31/2016 at 11:16 PM, my_name_sucks said:

Couldn't find any typos regarding the skin name, anything else I can check for?

Expand  

I've had this problem too and it had to do with the NPC model I was using. There is a list of working NPC models around here somewhere but I can't seem to find it.

Anyways, when I've had this problem that there's no option for trader I find that right clicking on the trader usually makes the option appear.

Hope it helps.

I found the list:

  Reveal hidden contents

 

Link to comment
Share on other sites

  On 3/31/2016 at 11:56 PM, Hux said:

I've had this problem too and it had to do with the NPC model I was using. There is a list of working NPC models around here somewhere but I can't seem to find it.

Anyways, when I've had this problem that there's no option for trader I find that right clicking on the trader usually makes the option appear.

Hope it helps.

Expand  

I changed the class of the trader, it still doesn't work but when I scroll on it I can see its name which wasn't happening for the one I was originally using

Link to comment
Share on other sites

  On 4/1/2016 at 12:32 AM, my_name_sucks said:

I changed the class of the trader, it still doesn't work but when I scroll on it I can see its name which wasn't happening for the one I was originally using

Expand  

In that case you'll need to check syntax for any errors you've added in fn_selfActions.sqf. It's one of most widely modified files and is responsible for action menu to appear. Best thing to do, probably, would be starting with a clean file just to get traders to work, then work out what went wrong with your current file if you're not very SQF literate yet, so to say.

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
×
×
  • Create New...