Jump to content
  • 0

Gold Only Currency


Flosstradamus

Question

6 answers to this question

Recommended Posts

  • 0

I think I found it epoch.sql I see the prices but its like  INSERT INTO `Traders_DATA` VALUES(5666, '["SUV_Charcoal",2]', 10, '[2,"ItemGoldBar10oz",1]', '[5,"ItemGoldBar",1]', 0, 565, 'trade_any_vehicle'); is the # in front of the gold bar the buy price or sell price?

 

DatabaseID, Item, how many instock, buy price, sell price, order it shows in, traders ID, type of item

Link to comment
Share on other sites

  • 0

Just find any item with the word 'Silver' in the buy or sell column:

SELECT * FROM traders_data WHERE buy LIKE '%Silver%' OR sell LIKE '%Silver%';

And considering you are moving to gold only, you could just do (I haven't tested this, but it SHOULD work):

UPDATE traders_data SET
  buy='[2,"ItemGoldBar",1]',
  sell='[1,"ItemGoldBar",1]'
WHERE
  buy LIKE '%Silver%' OR
  sell LIKE '%Silver%';

Then you can use this query I wrote the other day to check if an item sell price is higher than its buy price, just to confirm.

SELECT
	CASE MID(buy, 5, LENGTH(buy)-8)
		WHEN 'ItemGoldBar' THEN 100*MID(buy, 2, 1)
		WHEN 'ItemGoldBar10oz' THEN 1000*MID(buy, 2, 1)
		WHEN 'ItemBriefcase100oz' THEN 10000*MID(buy, 2, 1)
		WHEN 'ItemSilverBar' THEN 1*MID(buy, 2, 1)
		WHEN 'ItemSilverBar10oz' THEN 10*MID(buy, 2, 1)
		ELSE 0
	END as buy_n,
	CASE MID(sell, 5, LENGTH(sell)-8)
		WHEN 'ItemGoldBar' THEN 100*MID(sell, 2, 1)
		WHEN 'ItemGoldBar10oz' THEN 1000*MID(sell, 2, 1)
		WHEN 'ItemBriefcase100oz' THEN 10000*MID(sell, 2, 1)
		WHEN 'ItemSilverBar' THEN 1*MID(sell, 2, 1)
		WHEN 'ItemSilverBar10oz' THEN 10*MID(sell, 2, 1)
		ELSE 0
	END as sell_n,
traders_data.* FROM dayz.traders_data
HAVING sell_n>buy_n;

Voila

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...