Jump to content
  • 0

Custom trader cities


BetterDeadThanZed

Question

This post started as a request for information on how add traders. The question was answered, so I thought I'd update my original post with instructions on how to do this:

 

It is easier to add traders if you don't want them to have their own inventory. This tutorial will start with explaining how to add traders and have them use the same database data/inventory as other traders.

 

Using the 3D editor, create a trader city. Place units at the locations where you want to have the traders standing. I am not going to explain how to use the 3D editor. You should already know how to do that.

Open server_traders.sqf for reference and keep it open.

Open mission.sqf and add an entry for your first new trader:

_unit_13001 = objNull;
if (true) then
{
  _this = createAgent ["GUE_Soldier_1", [2550.658, 8326.5928, 2.3534577], [], 0, "CAN_COLLIDE"];
  _unit_13001 = _this;
  _this setDir 114.59087;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;  ";
  _this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0;_this enableSimulation false;};

_unit_#### can be a unique number not being used anywhere else in mission.sqf

 

"createAgent" should match one of the traders in the server_traders.sqf file. For example:

// Ammunition Neutral P
menu_BAF_Soldier_AMG_W = [
[["Assault Rifle Ammo",480],["Light Machine Gun Ammo",481],["Pistol Ammo",484],["Shotguns and Single-shot Ammo",573],["Sniper Rifle Ammo",482],["Submachine Gun Ammo",483]],
[],
"neutral"
];

This is a neutral ammunition trader. You can select "BAF_Soldier_AMG_W" and put it in the above mission.sqf file:

_this = createAgent ["BAF_Soldier_AMG_W", [2550.658, 8326.5928, 2.3534577], [], 0, "CAN_COLLIDE"];

Change the coordinates above with the coordinates from the new trader city you created. Also change these lines:

_unit_13001 = _this;
_this setDir 114.59087;

_unit matches the _unit number you chose above and setDir is in the mission file from the trader city you created.

 

What this does is spawns a trader with the classname "BAF_Soldier_AMG_W"", which the server recognizes is the neutral ammo trader as defined in the server_traders.sqf file. Please note that I pulled this from a Panthera server_traders.sqf so yours might be different.

 

After you've added all the traders this way, feel free to copy over the other items, such as tents, boxes, etc that you created in the mission you created in the 3D editor. Place all of this above the "processInitCommands;" commands at the bottom of the server's mission.sqf.

 

Creating traders with their own inventory

 

If you want to create unique traders that do not use the inventory of an existing trader, you need to do a little more.

 

After adding the tents, boxes, etc that make up your new trader city, and adding the traders as above, you perform the following steps.

 

In server_traders.sqf, you have to add the trader. It has to use a unique classname not being used by any other trader and it can not be used by any AI that you have on the server. If, for example, you use the same classname for this new trader as that of a bandit AI in your mission system, when you come across a dead bandit, you will get a trader prompt on your scroll menu!

 

For my example, I will use "Fiona". She is a trader I added to my Napf and Panthera servers that sells and buys rare food and drinks. This is what I added to server_traders.sqf:

// Rare Food and Drinks
menu_RU_Damsel5 = [
[["Rare Food/Drinks",700]],
[],
"neutral"
];

I used the model "RU_Damsel5". When you bring up the menu, it says "Rare Food/Drinks" and it uses trader ID 700. Whatever model you use, it needs to be added to the top of server_traders.sqf:

serverTraders = ["Tanny_PMC","BAF_Soldier_AMG_W","BAF_Soldier_AAA_DDPM","CZ_Special_Forces_MG_DES_EP1","Damsel5","GUE_Commander","GUE_Woodlander1","GUE_Woodlander3","GUE_Soldier_Sab","GUE_Soldier_Pilot","GUE_Soldier_2","Soldier_PMC","Citizen2_EP1","Rita_Ensler_EP1","RU_Farmwife1","US_Soldier_Medic_EP1","USMC_Soldier_TL","USMC_SoldierS_Engineer","UN_CDF_Soldier_AAT_EP1","ValentinaVictim","UN_CDF_Soldier_MG_EP1","GUE_Soldier_1","FR_Corpsman","GUE_Soldier_AR","Dr_Hladik_EP1","RU_Villager1","Reynolds_PMC","RU_Damsel5"];

In your database, you have to add the trader:

REPLACE INTO `server_traders` (`id`, `classname`, `instance`, `status`, `static`, `desc`) VALUES (700, 'RU_Damsel5', 24, 'friendly', NULL, 'Fionas Pub');

Then you have add the items the new trader will stock:

REPLACE INTO `traders_data` (`id`, `item`, `qty`, `buy`, `sell`, `order`, `tid`, `afile`) VALUES (7589, '["ItemSodaRabbit",1]', 1000, '[6,"ItemGoldBar",1]', '[3,"ItemGoldBar",1]', 0, 700, 'trade_items');

This adds the item "ItemSodaRabbit" with a quantity of 1000, selling for 6oz gold, buying for 3oz gold, to trader ID #700.

 

I hope that helps everyone! Let me know if you have questions. Thank you for everyone that answered the original post I made which led me to making this new post!

Link to comment
Share on other sites

Recommended Posts

  • 0

i added new trader's city a Moglievka.

 

I placed 2 vendor there. One selling vehicules and other one selling toolbelt, building supplies, vehicles parts and new group of item Construction.

 

Here is how i did:

 

 

PS: Sorry but i'm newbee on dayz modding server by i wanna contribute for the community. So it's my 2 cents.

 

 

1- Unpack your mission pbo and open your server_trader.sqf

Found your last vendor the:" // Black market vendor" and just add the 2 new vendor after him:

 

...

***];
// Black market
menu_GUE_Woodlander2 = [
[["Black Market Ammo",527],["Black Market Weapons",526],["Explosives",529]],
[],
"neutral"
];***
// Nouveau Trader Moglievka
menu_Woodlander3 = [
[["Building Supplies",662],["Toolbelt Items",663],["Vehicle Parts",664],["Construction",694]],
[],
"neutral"
];
// Nouveau trader Moglievka 2
menu_RU_Profiteer4 = [
[["Bikes and ATV",650],["Buses and Vans",651],["Cargo Trucks",653],["Compact Cars",652],["Economy Cars",654],["Fuel Trucks",655],["Luxury Cars",656],["Microcars",657],["Military Unarmed",658],["Trucks",659],["Used Cars",660],["Utility Vehicles",661]],
[],
"neutral"
];

 

- Save your change and close it.

 

 

2- Open you mission.sqm on you mission.pbo unpacked and fine the latest objects on the end of the files.

Just add this after the _vehicles_812 = objNull ( what is my latest objects on it before modifing it)

 

***_vehicle_812 = objNull;
if (true) then
{
_this = createVehicle ["PowGen_Big", [6318.1919, 7806.4321], [], 0, "CAN_COLLIDE"];
_vehicle_812 = _this;
_this setDir -414.08893;
_this setPos [6318.1919, 7806.4321];
};***

 

_vehicle_813 = objNull;
if (true) then
{
_this = createVehicle ["Land_BagFenceRound", [6295.6436, 7804.3223], [], 0, "CAN_COLLIDE"];
_vehicle_813 = _this;
_this setDir 128.79018;
_this setPos [6295.6436, 7804.3223];
};

 

_unit_999 = objNull;
if (true) then
{
_this = _group_1 createUnit ["Woodlander3", [7636.2031, 5191.9253], [], 0, "CAN_COLLIDE"];
_unit_999 = _this;
_this setDir 185.62813;
_this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;";
_this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0;_this enableSimulation false;
};

 

_vehicle_0 = objNull;
if (true) then
{
_this = createVehicle ["Land_Market_stalls_02_EP1", [7633.1758, 5194.1187], [], 0, "CAN_COLLIDE"];
_vehicle_0 = _this;
_this setDir 6.1341724;
_this setPos [7633.1758, 5194.1187];
};

 

_vehicle_1 = objNull;
if (true) then
{
_this = createVehicle ["Land_Fire_barrel", [7639.3662, 5188.4014, 1.5258789e-005], [], 0, "CAN_COLLIDE"];
_vehicle_1 = _this;
_this setDir -16.501688;
_this setPos [7639.3662, 5188.4014, 1.5258789e-005];
};

 

_vehicle_3 = objNull;
if (true) then
{
_this = createVehicle ["Misc_palletsfoiled", [7644.9155, 5189.8936, 1.5258789e-005], [], 0, "CAN_COLLIDE"];
_vehicle_3 = _this;
_this setDir -49.309704;
_this setPos [7644.9155, 5189.8936, 1.5258789e-005];
};

 

_vehicle_4 = objNull;
if (true) then
{
_this = createVehicle ["Land_Misc_IronPipes_EP1", [7623.8223, 5192.5967], [], 0, "CAN_COLLIDE"];
_vehicle_4 = _this;
_this setDir -55.737324;
_this setPos [7623.8223, 5192.5967];
};

 

_vehicle_6 = objNull;
if (true) then
{
_this = createVehicle ["Land_transport_crates_EP1", [7621.6816, 5163.3999, -4.5776367e-005], [], 0, "CAN_COLLIDE"];
_vehicle_6 = _this;
_this setDir -78.60524;
_this setPos [7621.6816, 5163.3999, -4.5776367e-005];
};

 

_vehicle_8 = objNull;
if (true) then
{
_this = createVehicle ["Land_Market_shelter_EP1", [7683.4927, 5206.0688, -3.0517578e-005], [], 0, "CAN_COLLIDE"];
_vehicle_8 = _this;
_this setDir -135.01883;
_this setPos [7683.4927, 5206.0688, -3.0517578e-005];
};

 

_vehicle_9 = objNull;
if (true) then
{
_this = createVehicle ["Misc_TyreHeapEP1", [7686.2246, 5203.2573, -0.00012207031], [], 0, "CAN_COLLIDE"];
_vehicle_9 = _this;
_this setDir -10.083812;
_this setPos [7686.2246, 5203.2573, -0.00012207031];
};

 

_vehicle_10 = objNull;
if (true) then
{
_this = createVehicle ["Land_Bench_EP1", [7679.8403, 5211.2144, -0.00015258789], [], 0, "CAN_COLLIDE"];
_vehicle_10 = _this;
_this setDir 40.694752;
_this setPos [7679.8403, 5211.2144, -0.00015258789];
};

 

_vehicle_11 = objNull;
if (true) then
{
_this = createVehicle ["Land_Blankets_EP1", [7685.5791, 5206.5449, -7.6293945e-005], [], 0, "CAN_COLLIDE"];
_vehicle_11 = _this;
_this setDir -11.176004;
_this setPos [7685.5791, 5206.5449, -7.6293945e-005];
};

 

_vehicle_13 = objNull;
if (true) then
{
_this = createVehicle ["LADAWreck", [7688.7358, 5200.7188, -1.5258789e-005], [], 0, "CAN_COLLIDE"];
_vehicle_13 = _this;
_this setDir 135.07458;
_this setPos [7688.7358, 5200.7188, -1.5258789e-005];
};

 

_vehicle_15 = objNull;
if (true) then
{
_this = createVehicle ["RoadBarrier_long", [7691.8657, 5198.6182], [], 0, "CAN_COLLIDE"];
_vehicle_15 = _this;
_this setDir -31.112467;
_this setPos [7691.8657, 5198.6182];
};

 

_vehicle_16 = objNull;
if (true) then
{
_this = createVehicle ["SignM_FARP_Winchester_EP1", [7617.8877, 5160.4131], [], 0, "CAN_COLLIDE"];
_vehicle_16 = _this;
_this setDir 183.93924;
_this setPos [7617.8877, 5160.4131];
};

 

_vehicle_17 = objNull;
if (true) then
{
_this = createVehicle ["Red_Light_Blinking_EP1", [7622.0205, 5165.3843, -1.5258789e-005], [], 0, "CAN_COLLIDE"];
_vehicle_17 = _this;
_this setDir -51.56937;
_this setPos [7622.0205, 5165.3843, -1.5258789e-005];
};

 

_unit_998 = objNull;
if (true) then
{
_this = _group_1 createUnit ["Profiteer4", [7683.7109, 5207.6807], [], 0, "CAN_COLLIDE"];
_unit_998 = _this;
_this setDir 217.03709;
_this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;";
_this setUnitAbility 0.60000002;
_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0;_this enableSimulation false;
};

 

processInitCommands;

 

 

- save your file and close it.

 

 

3- Now for adding marker on the new trader city:

Open your mission.sqm in your unpacked mission.pbo and found latest object in your marker line ( my last marker was

line 1291 : class item16

And paste this one:

 

***  class Item16
  {
   position[]={12944.227,210.19823,12766.889};
   name="HeroTrader";
   text="MARCHAND HERO";
   type="mil_dot";
   colorName="ColorBlue";
  };***

  class Item17
  {
   position[]={7639.3662,1.5258789,5188.4014};
   name="Nouveau Trader";
   text="Moglievka trader's city";
   type="mil_circle";
   colorName="ColorBlack";
  };

  };

 

Now go on the class Markers line and add one more to the items=17 then it will becomes items=18 and will look like:

 

 class Markers
 {
  items=18;
  class Item0
  {
   position[]={7839.6055,381.33774,8414.7324};
   name="center";
   type="Empty";

...

 

Save you file and close it...

 

That's done, you have now a new trader city at moglievka. All you need now is pack your mission.pbo and upload it to your server. restart it and have fun for you kids...

 

 

 

 

 

 

PS: i wanted to make it more simply by adding directly my updated files but I tryed to attach the files and it seem i cannot ( not authorized).

Between i'm french speaker, i hope i'll be understable enought.

 

Long life to epoch and DayZ, it was my 2 cents...

Next time if you care to know how adding new item to this new item group " Construction" on this vendor i ll explain to you how to do it.

 

 

 

 

 

Link to comment
Share on other sites

  • 0

I just got around to creating some new traders. They are located on the coast and sell a few basic items, which includes bikes/ATV's/Motorcycles. When someone buys one of these, the money is taken but the vehicles don't spawn. Other items work fine. The player even gets the key. What am I missing to allow vehicle to spawn at the traders?

Link to comment
Share on other sites

  • 0

Do you have a HeliHEmpty spot for the vehicle to spawn?

 

Example:

_vehicle_44 = objNull;
if (true) then
{
  _this = createVehicle ["HeliHEmpty", [10930.29, 639.62091, 3.9100647e-005], [], 0, "CAN_COLLIDE"];
  _vehicle_44 = _this;
  _this setDir -145.48572;
  _this setPos [10930.29, 639.62091, 3.9100647e-005];
};
Link to comment
Share on other sites

  • 0

 

Do you have a HeliHEmpty spot for the vehicle to spawn?

 

Example:

_vehicle_44 = objNull;
if (true) then
{
  _this = createVehicle ["HeliHEmpty", [10930.29, 639.62091, 3.9100647e-005], [], 0, "CAN_COLLIDE"];
  _vehicle_44 = _this;
  _this setDir -145.48572;
  _this setPos [10930.29, 639.62091, 3.9100647e-005];
};

 

No, I don't. Does the trader look for that within a certain range?

Link to comment
Share on other sites

  • 0

maybe? ,  I've placed one about 100 meters from the new aircraft dealer I put into the NWAF and no matter what it insists on spawning the aircraft within 30ish meters of the dealer..  then a vehicle placement I did at about 50 meters from the trader works like a charm...   so long story short? I guess I don't have an answer to that...

Link to comment
Share on other sites

  • 0

So can you change the altitude that the trader character is at so that they, for instance, can be standing on an upper floor in a building?  If I try saving the character in Arma editor on an upper floor, after I save it the character is back on the ground level.  Do I just have to change the last number in the location string in the mission file to raise them higher?  Or does that just not work?  If it does work, I'm assuming that's the easiest or only way to do it?

Link to comment
Share on other sites

  • 0

Place the unit in the editor, then save the file. It will give the exact coordinates.

 

So yes, you can have a trader anywhere you want, including a 2nd floor or even on a roof (wholesaler in taviana for example).

Thanks cen.  I figured since, when you save the file it puts the AI back on ground level, that was the elevation it was saving to.  Nice, that'll work then.

 

Another question though.  We're in the process of moving our server to Napf and I don't like where some of the traders are placed, so I'm going to move them.  However, I was wondering if I could remove the added props(h barriers, trader stands, etc.)  Would that just be in the same trader config file?  I need to install Navicat yet. XD

Link to comment
Share on other sites

  • 0

All of the added "buildings/objects" for the trader cities are found in the dayz_server.pbo, specifically dayz_server\mission\DayZ_Epoch_24.Napf\mission.sqf.

 

You can get the .beidi file as well and re-do everything in the editor if you'd like, then just replace the mission.sqf with your own:

 

https://github.com/vbawol/DayZ-Epoch/tree/master/TraderCitySources/NAPFtradercities.Napf

Link to comment
Share on other sites

  • 0

Place the unit in the editor, then save the file. It will give the exact coordinates.

 

So yes, you can have a trader anywhere you want, including a 2nd floor or even on a roof (wholesaler in taviana for example).

Ok, so we tried this and it still insists on putting the trader on the ground(in this situation with only his head sticking through the bottom floor).  Has anyone else been able to get a trader to spawn above ground at a higher elevation, like on a second floor of a building?

 

All of the added "buildings/objects" for the trader cities are found in the dayz_server.pbo, specifically dayz_server\mission\DayZ_Epoch_24.Napf\mission.sqf.

 

You can get the .beidi file as well and re-do everything in the editor if you'd like, then just replace the mission.sqf with your own:

 

https://github.com/vbawol/DayZ-Epoch/tree/master/TraderCitySources/NAPFtradercities.Napf

This is something I've been hung up on for a couple days.  I didn't really understand the difference between the beidi and sqf, or what each were used for specifically.  I've always dealt with the sqf file.  I'm guessing the beidi is used to load a mission into the editor?

 

So, I tried putting the trader beidi from the epoch github in its own folder in my missions folder with all the other missions I have saved, just named the folder "test.Napf", opened up the editor and went to load it and it won't appear in the list.  How are you supposed to load the beidi file?

Link to comment
Share on other sites

  • 0

Each map has a bunch of unused traders that could easily be added onto any map.

Inventory would already be in place, just reference your Epoch.SQF file.

Hi,  Was reading your remark but could use a little more info if possible.   So I have Chernarus map and have "a bunch of unused traders"  

 

Where are these traders lurking?

 

thanks in advance

Link to comment
Share on other sites

  • 0

Hi,  Was reading your remark but could use a little more info if possible.   So I have Chernarus map and have "a bunch of unused traders"  

 

Where are these traders lurking?

 

thanks in advance

I believe most of the information is in the Epoch.sql, like Wesley said.

https://github.com/vbawol/DayZ-Epoch/blob/master/Server%20Files/SQL/epoch.sql

 

If you scroll down you'll see a good bit of other traders.

 

 

Each map has a bunch of unused traders that could easily be added onto any map.

Inventory would already be in place, just reference your Epoch.SQF file.

 

Yeah, I noticed that while digging through the github a couple days ago.  I wanted to go in and remove the stuff around the trader cities though.  Someone told me I have to pull the SQL from another PBO and pair it with the beidi in order to load it into the editor?

Link to comment
Share on other sites

  • 0

I don't know why but my traders just appear. I've done the whole database part, added the traders to my server_traders and added them in my mission.sqf. Still no luck.

Here is what I added in the end of my mission.sqf:


_unit_133 = objNull;
if (true) then
{
  _this = _group_1 createUnit ["TK_CIV_Takistani05_EP1", [3326.1707, 3917.2815, 1.5258789e-005], [], 0, "CAN_COLLIDE"];
  _unit_133 = _this;
  _this setDir 18;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;";
  _this setUnitAbility 0.60000002;
  _this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0;_this enableSimulation false;
};

_unit_134 = objNull;
if (true) then
{
  _this = _group_1 createUnit ["TK_CIV_Takistani06_EP1", [3330.3152, 3917.7178, 1.5258789e-005], [], 0, "CAN_COLLIDE"];
  _unit_134 = _this;
    _this setDir 18;
  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;";
  _this setUnitAbility 0.60000002;
  _this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0;_this enableSimulation false;
};

processInitCommands;

Any ideas?

Link to comment
Share on other sites

  • 0

I don't know why but my traders just appear. I've done the whole database part, added the traders to my server_traders and added them in my mission.sqf. Still no luck.

Pretty sure you should take the grouping out and change createUnit to createAgent. Here's my cheat sheet:

Remove all lines proceding first _unit_ defining a trader.

Remove any playable _unit_ (i.e. if (true) then {setPlayable _this;} ;)

In _this= line, replace _group_x createUnit with createAgent.

After _this setDir line, insert following(this can be set in editor or through BEIDI file):

_this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;";

Replace the if (false) statement line with the following:

_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0;_this enableSimulation false;

Make sure if statement is closed with closing bracket and semicolon.

Remove any post processing commands after the map content lines unless you are editing primary server SQF file, then only leave processInitCommands;

Link to comment
Share on other sites

  • 0

I almost have this nailed down, much credit to this thread for the progress that I have made so far. I can get my trader to spawn in exactly where I want him at, I have my custom marker on the map, and the sensor set up to turn on god mode. When I add the units class I'd to the list in server_traders.sqf, I am able to get "Trader Menu" on mouse over. However, when I add the "menu_classID" definitions I lose "Trader Menu" on every trader on the server. I assume that it is because of the missing link to the database for the trader, but when I put him in the database, still no dice. I think that it is because of the instance ID. Napf is instance 24 as far as the mission file is concerned, but there are no traders showing that ID in the database and if I use 24, it's still broken. AWOL's Airfield is in there at instance ID 6, that doesn't work either. I noticed in server_traders.sqf that it says instance 17 in there. I'm about to try that now. If it works, I'll post a complete guide on what I did, since most of them are incomplete/outdated.

Link to comment
Share on other sites

  • 0

--edit: Forgot to mention that this is on Napf and that all of the traders menus are going to be custom.

--edit 2: found my deeps after some sleep. :P Showing corrections in code.

Tried using instance 17 in the database, still no luck. I'm so worn out on this right now, I may just be missing something simple. Here's what I've done so far:

mission.sqf - previous trader was _unit_263:

//Home Depot_unit_264 = objNull;if (true) then{  _this = createAgent ["CIV_EuroMan02_EP1", [4272.54,9729.95,0.267], [], 0, "CAN_COLLIDE"];  _unit_264 = _this;  _this setDir 251;  _this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;  ";  _this setUnitAbility 0.60000002;_this allowDammage false; _this disableAI 'FSM'; _this disableAI 'MOVE'; _this disableAI 'AUTOTARGET'; _this disableAI 'TARGET'; _this setBehaviour 'CARELESS'; _this forceSpeed 0;_this enableSimulation false;};//End Home DepotprocessInitCommands;
--------------------------------

mission.sqm:

Changed "class Markers { items=23;" to "class Markers { items=24;" - shortened to 1 line to save space

Added:

//Begin Home Depotclass Item23{position[]={4272.54,0.267,9729.95};name="HomeDepot";text="Home Depot";type="mil_dot";colorName="ColorBlack";};//End Home Depot};
Changed "class Sensors { items=10;" to "class Sensors { items=11;" - shortened to 1 line to save space

Added:

//Begin Home Depotclass Item10{position[]={4272.54,0.267,9729.95};activationBy="ANY";repeating=1;interruptable=1;age="UNKNOWN";name="HomeDepot";expCond="(player distance HomeDepot) < 50;";expActiv="TitleText[""Now Entering Home Depot"",""PLAIN DOWN""]; canbuild = false;";expDesactiv="TitleText[""Now Leaving Home Depot"",""PLAIN DOWN""]; canbuild = true;";class Effects{};};//End Home Depot
-----------------------------------

server_traders.sqf

First two lines with the skin of my new trader at the end:

// DayZ Epoch TRADERS for 17serverTraders = ["Tanny_PMC","Graves","US_Delta_Force_AR_EP1","GUE_Commander","Damsel3","Soldier_MG_PKM_PMC","GUE_Worker2","GUE_Woodlander2","RUS_Soldier2","Drake_Light","GUE_Woodlander3","Soldier_GL_PMC","GUE_Villager3","CIV_EuroWoman01_EP1","Dr_Annie_Baker_EP1","RUS_Commander","Damsel5","TK_Special_Forces_MG_EP1","TK_Special_Forces_EP1","Ins_Soldier_AR","Ins_Lopotev","Ins_Worker2","Ins_Woodlander3","Dr_Hladik_EP1","pook_Doc_Bell47","Ins_Woodlander2","CIV_EuroMan02_EP1"];
Added at the end:

//Home Depotmenu_CIV_EuroMan02_EP1 = [[["Building Parts",693],["Construction Tools",694]["Pre-Built Kits",695]][],"neutral"
[];
Correction: Left out "[];" at the end.

-------------------------------------

In the database:

dayz_epoch

-server_traders:

ID      Classname            Instance     Status     Static        Desc177  CIV_EuroMan02_EP1          17        neutral                Home Depot
-trader_tids:

ID         Name              Trader693    Builiding Parts        177694    Building Tools         177695    Pre-Built Kits         177
-traders_data - just added one item per menu for testing

id: 7599item: ["ItemComboLock",1]qty: 50buy: [3,"ItemGoldBar10oz",1]sell:[1,"ItemGoldBar10oz",1]order: 0tid: 693afile: trade_items id: 7600item: ["workbench_kit",1]qty: 50buy: [1,"ItemGoldBar",1]sell:[5,"ItemSilverBar10oz",1]order: 0tid: 694afile: trade_items id: 7601item: ["cinder_wall_kit",1]qty: 50buy: [1,"ItemGoldBar10oz",1]sell:[5,"ItemGoldBar",1]order: 0tid: 695afile: trade_items
Correction: Left out the markup around my item class names.

Any help would be greatly appreciated as I would love to write a good guide on how to do this as there seems to be a severe lack of information about it at the moment. Also, so the people on my server can spend less time crafting, and more time building!

Link to comment
Share on other sites

  • 0

BetterDeadThanZed, do you know if it's possible to have traders accessible via UID instead of humanity. 

 

For example, can I make a custom trader that my donators and my donators only can access? 

 

I know I can make a dome and allow only specific UIDs into that dome, which is something I am trying to avoid. 

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