Jump to content

[Release] Advanced Trading 2.1 !UPDATED!


Zupa

Recommended Posts

I fixed that and some other bugs with the code, I gave zupa what I fixed so he may have an update for that at some point. I figured I'd let him take a look and decide if he wanted to incorporate the changes.

The main changes were separating out the vision toolbelt items (binoculars, rangefinders, night vision) because if your toolbelt is full, and those slots are filled it would think you had -2 slots available and would prevent all buying. There was also a section where its looking at the total items vs total space but it was using total space after it had been altered, so I added an extra variable to track the original total space determination.

There's also a problem for people who don't use coins that I fixed in there too.

Hey g0thic, would you be willing to share your changes directly with willing individuals? 

I use gold and silver still. I noticed the dialog often says the transaction was completed but shows coins instead of gold. If you access vehicle traders with the advanced menu it still shows vehicles, which confuses players on my server (more so than usual). Wouldn't it be better to simply add a filter to ignore vehicles ? Anyway, the mod is brilliant and I can't wait to see your fixes added. 

 

 

Link to comment
Share on other sites

Hello

Sorry for my bad English

after the patch from g0thic_ice_cream ...thanks for this :-)

The Briefcase bug are always aktiv    ..i do 5 Bc into a Truck then i go trade into the truck  after this i have 10 Bc in my Gear ..... 10Bc into the truck after Trade 20 Bc in my gear and and and

need help

Wallnuss

Link to comment
Share on other sites

Yeah, I can't reproduce that, so I'd need exact reproduction steps. It appears to work fine, except the money received will go to overflow if not enough gear slots. I'm tempted to try and split that between gear and backpack or cancel the trade if not enough slots, but it's just easier for people to switch to coins (and is easier to deal with overall for your players and server). As far as I see, no money ever gets put in your vehicle, so not sure how that is happening to begin with. What you might be seeing is the fact that you're getting overflow and just didn't notice you have more money than appears in your gear. So for instance you only had 2 gear slots, sold 5 briefs worth of stuff, you will only see the 2 briefs added. Once you move stuff out of your gear, the extra 3 will start filling the gear slots as slots become available. It's not actually duplicating briefs/money.

I may or may not try to fix the overflow. It's not my mod so I'm not inclined to spend a whole lot of time on it since it's working OK on my servers :P What I put out at least fixes a lot of the problems with it.

Link to comment
Share on other sites

Hi

1. drive with an Truck to trader into the truck Gear only 2 BC

2. i go to the trader with 1 gold and buy one Tanktrap into the truck

3.after the trading in the truck gear are only one tanktrap no bc

4.in my gear are 4 BC i can repeat this serveral times   i test this on pair server

mfg

wallnuss

Link to comment
Share on other sites

If you turn off "taking money from backpack and vehicles" , it doesn't dupe.. You get the item you purchased, it takes the right money from your inventory, but you get a debug message saying something went wrong with the transaction (obviously it didn't because the item was purchased and the money was taken)...

No duping with those two options turned off, which works for me :D

 

Link to comment
Share on other sites

Oh yeah, found another problem with satchel charges. You can't sell them from gear, and it's also broken in the coin mod.

Basically if you put this in z_at_sellItems.sqf:

        private ["_type","_name"];
            _type = _x select 1;
            _name = _x select 0;
            if (_type == "trade_items") then {_name = configFile >> "CfgMagazines" >> _name;};
            if (_type == "trade_weapons") then {_name = configFile >> "CfgWeapons" >> _name;};
 

Right above _localResult = [player,(_x select 0),1] call BIS_fnc_invRemove;

Then change the above mentioned line to say _localResult = [player,_name,1] call BIS_fnc_invRemove;

Then you can sell satchels again. For some stupid reason BIS_fnc_invRemove doesn't like the classname for satchels. You'll probably have to do the same thing in the script assigned to ZUPA_fnc_removeWeaponsAndMagazinesCargo and  ZUPA_fnc_removeWeaponsAndMagazinesCargo to get it to work from vehicles and backpacks if it's broken there. Haven't tested or changed those two yet...been too busy.

Link to comment
Share on other sites

  • 2 weeks later...

Quick question, is there any possibility you could do a tutorial for people who have never scripted before or at least include pictures of file locations and lines which you've placed the code, im coming from java coding and scripting and need to know how to get advanced trading into a server.

 

Link to comment
Share on other sites

Hello, would really appreciate some advice. I tried installing this trading 2.1 to my epoch 1051 server today, followed the instructions but my server just hangs on the Waiting for Host screen so i had to roll back what i've changed to get it working again. 

I copied the Zupa folder and all files within to my server's mpmissions/epoch 11 chernarus folder (hoping that's correct)

Then i edited the fn_selfactions file that is in my epoch11chernarus/custom folder and added the _buyV... lines

then added the 2 #include lines into my description.ext

After this i have no idea about the antihack thing so that confused me, our server uses the bluephoenix admin tool but i have no clue where to add that 711197 so i left that part out...

i then went into the zupa/advancedTrading folder and edited the config.sql and altered singlecurrency to true (as we are using the coin set up) and i also changed "cashmoney" to "coin" i dont really know about that part tbh it also may be wrong.

Anyway that's my process of what i did but like i say the server hung on waiting for host. Any help please? i'm rather new to this server editing.

Link to comment
Share on other sites

Fozzy, you need to look at your server report to see where the error is at. You probably left out a semicolon, comma or bracket when you made the changes. Another possibility is that you either forgot to repack the mission file or you needed to alter the prefix after you did it. Here is the link for the prefix as some pbo's managers don't automatically do it for you.

https://github.com/vbawol/DayZ-Epoch/issues/914

If you can't find it post your arma2oaserver.rpt here so others can take a look at it.

Link to comment
Share on other sites

19 hours ago, AzttecHD said:

Hello Has anybody had an issue with the Advanced trader not having the same prices as the normal trader and the data base items ?

 

If so can anyone tell me a fix maybe to set the advanced trader to read the normal trader hpp files 

Well Advanced trading doesn't use Database traders it uses config based traders in the mission file.Config Traders #1 they are alot easier to configure and #2 they are alot faster than database trading. I believe you still have database traders enabled some how so you will be getting different prices. You need to use DZE_ConfigTrader = true; if you look around the Epoch Forum i am sure there will be a tutorial on setting up Config Traders :)

Link to comment
Share on other sites

Not heard of one but there may be one. I adjusted the items and prices manually by editing the .hpp files where the data is stored.

 

Edit after thinking about it a bit more I think there is a way to do it from scratch but would probably be easier to just edit the files. I think there was a post about it and maybe even had a video along with it tho i can't seem to find atm.

edit #2 all right I found it 

But with the files already in place it is probably easier to just use find/replace to edit the prices with the stuff already there.


  •  
Link to comment
Share on other sites

On 12/30/2015 at 3:16 AM, AzttecHD said:

yeah i have the traders folder with it all set up that yourl talking about, so im guessing the normal traders just need to be relinked to those files 

 

Yup thats right buddy you just need a file that links your traders to the files you have in your mission file :) I believe the link DaveA linked is correct :)

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
×
×
  • Create New...