Jump to content

[Release] HS Blackmarket 1.6 | 'New' Trader System | Special Trader | Blackmarket


Suppe

Recommended Posts

  • 1 month later...

Hello there..

I'm trying to get this to the action menu. It works by //ing out the addaction and add this to the CfgActionMenu_target.hpp:

 

class blackmarket
{
    condition = "dyna_cursorTargetType isEqualTo 'I_G_resistanceLeader_F' && alive dyna_cursorTarget";
    action = "createDialog 'HS_trader_dialog';call HS_trader_menu;";
    icon = "x\addons\a3_epoch_code\Data\UI\buttons\group_requests_ca.paa";
    tooltip = "Blackmarket Trader";
};

 

But somehow no items are showing up. Someone has an idea what I forgot to add ?

Link to comment
Share on other sites

Works great for me @TarabasThanks very much :ph34r:

You didn't remove too much of the addaction section did you? Should just comment like this:

// Client stuff...
if(hasInterface)then{
	diag_log "[HSBlackmarket]: Client waiting for Trader ...";
	waitUntil {sleep 1;(!isNil "HSPV_HSBlackmarket")};
//	{
//		_x addAction ["<img size='1.5'image='\a3\Ui_f\data\gui\Rsc\RscDisplayArcadeMap\icon_layout_ca.paa'/> <t color='#0096ff'>HS Trader Menu</t>",
//		{
//			/*
//			systemChat "WARNING:";
//			systemChat "This trader is NOT finished yet ...";
//			systemChat "... you might loose items and / or crypto trading here!";
//			*/
//			HS_SWITCH = false;
//			createDialog "HS_trader_dialog";
//			call HS_trader_menu;
//		},_x, -9, true, true, "", "player distance _target < 5"];
//	}forEach HSPV_HSBlackmarket;
	HSPV_HSBlackmarket = nil;
	call compile preprocessFileLineNumbers "trader\tradermenu.sqf";
	diag_log "[HSBlackmarket]: Client Done ...";
};

After that and adding your CfgActionMenu change it works great!

Link to comment
Share on other sites

Oh yes.. it just needed time to load aswell. now it's shown and all buyable.

I didn't notice that it took so long as it was in addAction before.

 

Edit:

That's strange.. I need to switch between buy and sell everytime after switch back from lobby to game. Think it's maybe not because of loadingtime.

Link to comment
Share on other sites

@BenQ

here's my HALV_takegive_crypto.sqf

@He-Man posted a fix for this awhile ago mate (see below)

  Reveal hidden contents

 

Link to comment
Share on other sites

  • 3 months later...
  On 6/26/2015 at 10:52 AM, flow0815 said:

Hi,

 

first let me say that i love this great plugin. My question: got a kick for selling a boat. Logfile says:

26.06.2015 12:43:49: PLAYER (IP:2304) UID- Value Restriction #0 "HSPV_traderrequest" = boat, often nicknamed 'Rubber Duck', is a lightweight boat constructed from tubes containing pressurized gas. Inflatables typically come in lengths between 2 to 7 meters. Due to their speed, weight and portability, inflatable boats are used in diverse roles such as lifeguard and rescue boats and even more often in the military as a landing craft.","\A3\boat_F\Boat_Transport_01\data\UI\Boat_Transport_01_CA.paa","","",b848eb00# 1815001: boat_transport_01_f.p3d REMOTE]],B Alpha 1-1:1 (PLAYER) REMOTE,1]

But i have in my publicvar.txt already pasted:

!=HSPV_traderrequest

I wonder how i can exlude this. Are there any placeholders which includes everything after "HSPV_traderrequest" ?

 

Thank you

Expand  

Hi guys did anyone find a answer for this looked through only saw someone say they remove the boat. 

I have noticed (for me anyway) that it is the jetski that causes me to get kicked PubliVar #0 - Its when I buy this i get the kick I can buy all other boats, I see that there were 2 jetski's so i removed one at a time but either still gives the kick. this is the kick:

  Reveal hidden contents

my BE file:

  Reveal hidden contents


 

On a different note can the spawn point distance on a trader be changed ? - if where  

Thanks

 

MegaZ

Link to comment
Share on other sites

I'm really glad this script exists! I have some noob questions:

My init.sqf didn't exist in my epoch.Altis.pbo so I added it and added the init variables to it, what do the traders show up on the map as?

I'm not seeing the traders on the map?

EDIT:

I found out that the description.ext information has been moved to: #include "epoch_config\sandbox_config.hpp" in version 1.2, so I copied the config into there and now I'm getting Battleye Kick Restriction #32

 

EDIT:

 

I've since solved the restrictions on the server by editing the battleye kick restrictions from 5 to 1, but now the Crypto exchange between the traders and myself are not editing the crypto I have in the game, if I sell something to the trader it doesn't take my Crypto and if I buy something it doesn't deduct the crypto.

 

Link to comment
Share on other sites

  On 7/21/2018 at 2:05 AM, BlackhatEspeed said:

I'm really glad this script exists! I have some noob questions:

My init.sqf didn't exist in my epoch.Altis.pbo so I added it and added the init variables to it, what do the traders show up on the map as?

I'm not seeing the traders on the map?

EDIT:

I found out that the description.ext information has been moved to: #include "epoch_config\sandbox_config.hpp" in version 1.2, so I copied the config into there and now I'm getting Battleye Kick Restriction #32

 

EDIT:

 

I've since solved the restrictions on the server by editing the battleye kick restrictions from 5 to 1, but now the Crypto exchange between the traders and myself are not editing the crypto I have in the game, if I sell something to the trader it doesn't take my Crypto and if I buy something it doesn't deduct the crypto.

 

Expand  

page 38 post 7 have you done this

 

MegaZ

Link to comment
Share on other sites

  • 2 weeks later...

Has anyone seen this error before:

18:54:05 Error in expression <_libtxt,_pic,_BIStype select 0,_BIStype select 1];
_return
};

_config = "HSPric>
18:54:05   Error position: <select 1];
_return
};

_config = "HSPric>
18:54:05   Error Zero divisor
18:54:05 File mpmissions\__CUR_MP.Australia\trader\tradermenu.sqf, line 21

 

 

tradermenu.sqf

  Reveal hidden contents

saw the post on page 35 but mine is different.

This shows when i have error logging on in arma

thanks MegaZ

 

Link to comment
Share on other sites

Yes... it means that you have a item in HSPricing that either does not exist or there is a typo in the classname. I run a debug version of tradermenu.sqf to find these when I make a new HSPricing. Basically copy tradermenu.sqf to tradermenu-prod.sqf and create a new tradermenu with this code: 

  Reveal hidden contents

Upload the new mission PBO. Then log into the server. In your client RPT (in C:/Users/<username>/AppData/ARMA3) you will see a list of the trader items and you'll be able to see the item that causes the glitch...

When you have finished, move this version to tradermenu-debug.sqf for use in the future and move the tradermenu-prod.sqf back as tradermenu.sqf

(Yes, I will produce a version that can be used for both with a flag in the settings file but I did this ages ago as a one-off check that has proved very useful over the years)

Link to comment
Share on other sites

  On 8/7/2018 at 2:46 PM, Grahame said:

Yes... it means that you have a item in HSPricing that either does not exist or there is a typo in the classname. I run a debug version of tradermenu.sqf to find these when I make a new HSPricing. Basically copy tradermenu.sqf to tradermenu-prod.sqf and create a new tradermenu with this code: 

  Reveal hidden contents

Upload the new mission PBO. Then log into the server. In your client RPT (in C:/Users/<username>/AppData/ARMA3) you will see a list of the trader items and you'll be able to see the item that causes the glitch...

When you have finished, move this version to tradermenu-debug.sqf for use in the future and move the tradermenu-prod.sqf back as tradermenu.sqf

(Yes, I will produce a version that can be used for both with a flag in the settings file but I did this ages ago as a one-off check that has proved very useful over the years)

Expand  

Thanks Graham, had 5 items that were causing the problem, Removed them and now all good thanks 

MegaZ

Link to comment
Share on other sites

	// Launchers
	class launch_NLAW_F {price = 400;};
	class launch_RPG32_F {price = 400;};
	class launch_B_Titan_F {price = 400;};
	class launch_I_Titan_F {price = 400;};
	class launch_O_Titan_F {price = 400;};
	class launch_Titan_F {price = 400;};
	class launch_B_Titan_short_F {price = 400;};
	class launch_I_Titan_short_F {price = 400;};
	class launch_O_Titan_short_F {price = 400;};
	class launch_Titan_short_F {price = 400;};
    class NLAW_F {price = 40;};
	class RPG32_F {price = 40;};
	class RPG32_HE_F {price = 40;};
	class Titan_AA {price = 40;};
	class Titan_AT {price = 40;};
	class Titan_AP {price = 40;};

I added this to the trader and everything is working great, thanks.

But now I'm getting battleye kicks, is there anyway to easily fix this?

 

04.08.2018 21:58:43:  - #0 "Laserdesignator" 2:2994 B_TacticalPack_mcamo
10.08.2018 20:57:58:  - #0 "H_HelmetB" 2:26359 NetworkMessageCreateHelicopterRTD
10.08.2018 22:20:49: - #0 "H_HelmetB" 14:1645 GroundWeaponHolder
12.08.2018 03:17:44:  - #0 "H_MilCap_mcamo" 23:41 GroundWeaponHolder
12.08.2018 04:16:44: - #0 "H_MilCap_mcamo" 27:20 WeaponHolderSimulated
12.08.2018 05:00:38:  - #0 "Laserdesignator" 2:24330 Supply150
12.08.2018 05:56:45: - #0 "H_MilCap_mcamo" 32:116 GroundWeaponHolder
12.08.2018 18:59:03: - #0 "Laserdesignator" 10:4 B_Carryall_cbr

 #0 "Laserdesignator" 2:9380 Supply30
12.08.2018 23:13:15: #0 "H_HelmetB" 2:9395 B_Kitbag_cbr
12.08.2018 23:29:45:  - #0 "Laserdesignator" 2:10307 B_Kitbag_cbr
13.08.2018 00:29:49:  - #0 "H_HelmetB" 34:25 B_Kitbag_cbr
14.08.2018 09:12:10:  - #0 "launch_RPG32_F" 3:265 WeaponHolderSimulated

 

any idea why these errors are kicking people from addweaponcargo?

 

Link to comment
Share on other sites

Hi getting a few trades that are not paying the correct amount out when selling items see below:

Im using just Blackmarket trades normal traders are off I have 6 at set locations and 1 random spawn.

  Reveal hidden contents

Blue is the price i receive red is pricing as it should be in Pricing.hpp

Rpt Log from one issue

  Reveal hidden contents

and section of pricing.hpp

  Reveal hidden contents

Anyone else have these issues or know what i need to do to fix ?

Thanks

MegaZ

 

EDIT

I think I found the answer: in this part of the script - it reduces the price if vehicle sold is damaged.

  Reveal hidden contents

 

Link to comment
Share on other sites

  • 3 weeks later...

@Grahame @Tarabas 
Thanks for the code above to switch to dyna menu.

I think the issue you experienced isn't load time but this:

  Reveal hidden contents

Spams about 1,600 times in the client report then everything works fine and doesn't spam again that session. Unsure of any other knock on effects so far.

Any ideas on how to fix the error though?

Thanks

Link to comment
Share on other sites

  On 2/8/2018 at 5:49 AM, BenQ said:
Kind time of days all. Help or assist please with a problem: the Trader does not give me dzheng for sale. I found error, but how to fix it, I do not know. Here is the code from RPT:
8:47:19 Error in expression <';
_vars = _player getVariable ['VARS', [] + EPOCH_defaultVars_SEPXVar];
_curcrypt =>
 8:47:19 Error position: <+ EPOCH_defaultVars_SEPXVar];
_curcrypt =>
 8:47:19 Error +: Type code, Expected Number, Array, String, Not a Number
 8:47:19 File mpmissions \ __ cur_mp.Altis \ trader \ HALV_takegive_crypto.sqf, line 22
 8:47:19 Error in expression <';
_vars = _player getVariable ['VARS', [] + EPOCH_defaultVars_SEPXVar];
_curcrypt =>
 8:47:19 Error position: <+ EPOCH_defaultVars_SEPXVar];
_curcrypt =>

 

Expand  

it appears that there is an error in HSPricing from what I can see. Is there anything just above the line in your .RPT that includes mpmission? most config errors are shown there. Look for these lines in your .RPT.

17:55:02 Starting mission:
17:55:02  Mission file: epoch (__cur_mp)
17:55:02  Mission world: Altis
17:55:02  Mission directory: mpmissions\__cur_mp.Altis\

Link to comment
Share on other sites

  On 4/10/2016 at 11:34 AM, He-Man said:

Hmm, for me this seems to be ok, but you also have to change: 

[['effectCrypto',_newcrypt],(owner _player)]call EPOCH_sendPublicVariableClient;

because, Epoch is not using publicvariableeventhandler anymore.

Try this:

  Reveal hidden contents

 

Expand  

Hello,

I was also having trouble with the BM traders selling for free and not giving crypto on sales. This is my HALV_takegive_crypto.sqf

    _player = _this select 0;
    _nr = _this select 1;
    _cIndex = EPOCH_customVars find "Crypto";
    _vars = _player getVariable["VARS", call EPOCH_defaultVars_SEPXVar];
    _current_crypto = _vars select _cIndex;
    _current_cryptoRaw = _current_crypto;
    _playerCryptoLimit = EPOCH_customVarLimits select _cIndex;
    _playerCryptoLimit params ["_playerCryptoLimitMax","_playerCryptoLimitMin"];
    _current_crypto = ((_current_cryptoRaw + _nr) min _playerCryptoLimitMax) max   _playerCryptoLimitMin;
    _current_crypto remoteExec ['EPOCH_effectCrypto',(owner _player)];
    _vars set[_cIndex, _current_crypto];
    _player setVariable["VARS", _vars];

 

The trader sells/buys with no crypto exchange.

execVM "trader\init.sqf";
execVM "trader\HALV_takegive_crypto_init.sqf";
execVM "trader\resetvehicleammo.sqf";
 

are in my init.sqf. I might be misunderstanding the conversation on duplicate sqf calls but i was certain all these do something different.

 

Thanks

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