Jump to content
  • 0

Epoch Traders Help please?


Razorman

Question

Hi all,

 

have an epoch server up & running, working very well except for traders.

 

I use navicat to mod the database on the fly & can see the trader data table to add stocks etc.

 

i cant for the life of me figure out how to modify what each individual one sells.

 

The Black Market trader up near the N/E airfield has 0 items for sale, he will trade metals but has nothing else?

 

Also the building supplies trader has no plot poles listed in his for sale menu.

 

Is there an easy way to configure each trader & what he sells?

 

Thanks in advance for any help given.

 

Awsome mod.

 

My server host is vilayer if thats any help.

Link to comment
Share on other sites

23 answers to this question

Recommended Posts

  • 0

I'm also with Vilayer - had to open a ticket for them to look at it. Basically, they didn't update everything in the latest patch...so all the new items weren't added. They've addressed this for me, but I think they added the items to the wrong instance vendors...so they're still working on it. I'd open a support ticket.

 

For adjusting vendor stock, check here for some good info.

 

 

 

 

Link to comment
Share on other sites

  • 0

Thanks, Vilayer are doing a massive update today to the dayz epoch database, suprisingly good support from them when i opened a ticket after posting this, they assure me all will be well later today when completed.

 

Thanks for the tip on stock but i've cracked that one using Navicat, here's hoping all is resolved soon, my server is getting busy & it's only been up for 3 days lol.

Link to comment
Share on other sites

  • 0

Know you have is sorted now but,

 

If you have access to the database and navicat or phpmyadmin just download the epoch server files and run the sql file that is included to update your database on you own next time. Should save you some time and it is the same thing they are doing.

Link to comment
Share on other sites

  • 0

Know you have is sorted now but,

 

If you have access to the database and navicat or phpmyadmin just download the epoch server files and run the sql file that is included to update your database on you own next time. Should save you some time and it is the same thing they are doing.

 

In most cases, I'd agree...but there's actually some issues on the Vilayer side that they're addressing right now. 

Link to comment
Share on other sites

  • 0

Know you have is sorted now but,

 

If you have access to the database and navicat or phpmyadmin just download the epoch server files and run the sql file that is included to update your database on you own next time. Should save you some time and it is the same thing they are doing.

 

 

Thanks for the heads up.

Link to comment
Share on other sites

  • 0

Need a little more help please as vilayer seem to be dragging thier heels on this "Massive update" they told me about, as many of you here seem to know Dayz servers very well.

 

My issue is that my epoch traders dont have the correct items for sale (some) & others have nothing, example:

 

The black market trader in olsha has nothing for sale but will trade metals.

The building supplies trader in Klen is supposed to sell "plot poles" for building but he has none listed or for sale.

Vehicle trader in Bash has no gyro copters for sale.

 

I can access all of my server files through the vilayer portal, so right i think i'll update myself, get the most up to date server_traders.sqf file from github & edit the data, here's the rub, the files are identical & up to date?

 

I've figured out how to update some traders items quantity's using navicat & change player load outs etc but i'm having this annoying last little bug to deal with otherwise the server is running really well & very happy.

 

Any input or help on this one last issue really appreacited.

Link to comment
Share on other sites

  • 0

Thanks MGT, care to ellaborate on exactly how?

 

Appreciate the help.

 

You can create an event in your SQL so that trader items which are out of stock are replenished daily using

CREATE EVENT updateStockDaily
    ON SCHEDULE EVERY 1 DAY
    COMMENT 'Updates out of stock vendors'
    DO
      UPDATE `traders_data` SET qty=10 WHERE qty=0 AND afile<>'trade_any_vehicle' AND afile<>'trade_any_boat';

Also while you're doing that, you can also run this command to remove completly broken cars daily to keep your server running smoothly

CREATE EVENT removeDamagedVehicles
    ON SCHEDULE EVERY 1 DAY
    COMMENT 'Removes damaged vehicles'
    DO
      DELETE FROM `object_data` WHERE Damage = 1;
Link to comment
Share on other sites

  • 0

To remove a specific item from the traders inventory just set the current inventory quantity for that item to 0
 
 
To add custom items to the traders inventory

Adding new items to traders

INSERT INTO `traders_data` (`item`,`qty`,`buy`,`sell`,`order`,`tid`,`afile`) VALUES ('["1Rnd_HE_M203",1]',10,'[4,"ItemGoldBar",1]','[2,"ItemGoldBar",1]',0,60,'trade_items')

item ["classname",type]

qty Number of items in stock

buy or sell [qty,"classname",type]

Use the following as a table for items types in the columns Item, Buy and Sell:

    Weapons = 3
    Vehicles and backpacks = 2
    Magazines = 1 

order Allows override of display order. Typical range is 0 (low priority. Eg: 'Get out') to 6 (high priority. Eg: 'Auto-hover on').

tid This number must match the trader category id found in the mission file server_traders.sqf

afile Use the following types each of these represent a different .sqf file that performs the work:

    trade_items
    trade_weapons
    trade_any_vehicle
    trade_any_boat
    trade_backpacks 
Edited by GucciMane
Link to comment
Share on other sites

  • 0

MGT, appealing directly to you for help please?

 

You guys run an awsome server & have it configured beautifully, i want the same,  ipromise not to poach any of your players, it's just me & some clan mates who want to have our server running with the same parameters.

 

I just need someone to point me at where i change/edit the trader data?

 

I understand about restocking all traders with navicat but i want to edit the items for sale of each one individually and the costs of items, if anyone else can help i will be eternally gratefull, hell i'll even buy you a beer, anyone pleaseeee?

 

Thanks.

Link to comment
Share on other sites

  • 0

Ok so went back to using Navicat to try & update update the database:

 

 

Starting with 1st one Trader items  with "30m_plot_kit" = no issues

& then adding a line to Trader data with

 

[\"30m_plot_kit\",1]', '36', '[6,\"ItemGoldBar10oz\",1]', '[6,\"ItemGoldBar10oz\",1]', '0', '156', 'trade_items');

 

 

= error in mysql?

 

This is the main item missing from my traders sale inventory that i want to fix so people can establish bases & build, you cant even build wire without one currently.

 

 

Sorry to be so green but i'v espent the best part of 10hrs on this today without success, off ta bed now in the hope when i return a good samaritan will have assisted an old man.

 

Thanks

Link to comment
Share on other sites

  • 0

What's wrong with this?
 

INSERT INTO traders_data ('item','qty','buy','sell','order','tid','afile') VALUES ('["UH1Y",2]',5,'[12,"ItemGoldBar10oz",1]','[6,"ItemGoldBar10oz",1]',0,100,'trade_any_vehicle')

Getting this error:

 

SQL Error (1064): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''item','qty','buy','sell','order','tid','afile') VALUES ('["UH1Y",2]',5,'[12,"It' at line 1

 

EDIT: fixed it, the following works:

INSERT INTO `traders_data` VALUES ('4866', '[\"UH1Y_DZ\",2]', '5', '[12,\"ItemGoldBar10oz\",1]', '[6,\"ItemGoldBar10oz\",1]', '0', '100', 'trade_any_vehicle')
Link to comment
Share on other sites

  • 0

You should already have a DB entry for the 30_m_plot_kit so just change the amount of current Inventory or the cost as it is currently set pretty high.

As far as your DB issue, try removing the slashes ( \ )

 

That was the issue, there was no db entry for the plot kit, managed to add it using Navicat & now i'm good & server is perfect at last.

 

Thanks to everyone that gave a shit, no thanks to those that didn't (you know who you are ;)

Link to comment
Share on other sites

  • 0

 

You can create an event in your SQL so that trader items which are out of stock are replenished daily using

CREATE EVENT updateStockDaily
    ON SCHEDULE EVERY 1 DAY
    COMMENT 'Updates out of stock vendors'
    DO
      UPDATE `traders_data` SET qty=10 WHERE qty=0 AND afile<>'trade_any_vehicle' AND afile<>'trade_any_boat';

Also while you're doing that, you can also run this command to remove completly broken cars daily to keep your server running smoothly

CREATE EVENT removeDamagedVehicles
    ON SCHEDULE EVERY 1 DAY
    COMMENT 'Removes damaged vehicles'
    DO
      DELETE FROM `object_data` WHERE Damage = 1;

Where can i find the name for the item trader? i want to restock everything that has 0 in stock to 100 on everything, not just boat and car, everything including aircraft and wholesaler

Link to comment
Share on other sites

  • 0

Where can i find the name for the item trader? i want to restock everything that has 0 in stock to 100 on everything, not just boat and car, everything including aircraft and wholesaler

you can use this to add to everything     UPDATE `Traders_DATA` SET qty=20 WHERE `item` LIKE '%ItemVault%' AND qty=0;   Change the 20 to whatever quantity you like

Link to comment
Share on other sites

  • 0

You can also add this event to auto add stock items daily

 

DROP EVENT IF EXISTS updateStockDaily;
CREATE EVENT updateStockDaily
   ON SCHEDULE EVERY 1 DAY
   COMMENT 'Updates out of stock vendors'
   DO
     UPDATE `Traders_DATA` SET qty=10 WHERE qty=0 AND afile<>'trade_any_vehicle' AND afile<>'trade_any_boat';
;
 

Link to comment
Share on other sites

  • 0

So Im not using Navicat since my one glance at it made it seem like I had to fork over some cash.

 

Ive seen 

 

 UPDATE `Traders_DATA` SET qty=20 WHERE `item` LIKE '%ItemVault%' AND qty=0; 

 

 a ton. And Ive seen people say to add this...

 

Im still just getting my feet wet with this whole thing. Where do I add it again? Also This is something ill have to do daily? unless I set up the event Im reading about. Where could I add that event script ? Sorry like I said, still very new to this, getting the hang of it... slowly.

 

Thanks

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...