Sign in to follow this  
nikorasu

Code 13

20 posts in this topic

hi all . im a bit noob with the arma 3 server and stuff . yesterday i have put a couple vehicule i have upload from the workshop on my server . i went to the config file and add them in the list and set the price and quality of them. i have put the bikeys in the folder keys of the server. when i go log in and look at the trader . i can see the vehicule but cannot buy them without getting the code 13 contact a admin of the server.. so i contact myself... and now i need to get more explanation.

code 13 (2).png

code 13.png

Share this post


Link to post
Share on other sites

Code 13:
Cannot find suitable position to spawn vehicle

There is no space to spawn the vehicle near the trader.

Do a override for - >  ExileServer_system_trading_network_purchaseVehicleRequest.sqf -> https://pastebin.com/frAKf92S

Example in the file mpmissions\Exile.XZY\config.cpp

class CfgExileCustomCode 
{
    /*
        You can overwrite every single file of our code without touching it.
        To do that, add the function name you want to overwrite plus the 
        path to your custom file here. If you wonder how this works, have a
        look at our bootstrap/fn_preInit.sqf function.

        Simply add the following scheme here:

        <Function Name of Exile> = "<New File Name>";

        Example:

        ExileServer_system_trading_network_purchaseVehicleRequest = "Custom\ExileServer_system_trading_network_purchaseVehicleRequest.sqf";
    */

Then place a helipad near the trader (via Exile 3DEN Plugin ) and define the type of helipad in the "ExileServer_system_trading_network_purchaseVehicleRequest.sqf". I used "Land_HelipadSquare_F"  but there are some different types (even one invisible). The vehicle will spawn on thehelipad (if it's in 50m range)

Edited by El Rabito

Share this post


Link to post
Share on other sites
Advertisement

ok one last thing . do i have to do this to every trader on the map ? im on altis with the normal trader.

Edited by nikorasu

Share this post


Link to post
Share on other sites

No, the stuff i posted replaces the default function for buying a vehicle from trader. You problem was that the server couldn't find a position to spawn your vehicle. Unpack your mission file, add the new function file and add the stuff in the customcode example to your config.cpp and edit your traders (place that helipad near the trader)

Or move the trader to a different spot with more open space to spawn the vehicles.

Edited by El Rabito

Share this post


Link to post
Share on other sites

yeah i notice after reading a second time lol sorry im noob in these thing but its making 2 days im trying to figure out the problem . so like i said on the post before after editing it : do i have to do this to every trader ? im using exile altis with the stock trader.

Share this post


Link to post
Share on other sites
18 minutes ago, nikorasu said:

yeah i notice after reading a second time lol sorry im noob in these thing but its making 2 days im trying to figure out the problem . so like i said on the post before after editing it : do i have to do this to every trader ? im using exile altis with the stock trader.

Just place a visible or invisible helipad near the vehicle traders (ground & air) which have problems to spawn the vehicle (you have to choose one type of helipad and set the name in the file you added ->

 

ExileServer_system_trading_network_purchaseVehicleRequest.sqf
Line 80:

_spawnObject    = "Land_HelipadSquare_F"; // the object you want to use for spawning, can't be a simple object

or

_spawnObject    = "Land_HelipadEmpty_F""; // the object you want to use for spawning, can't be a simple object

 

Edited by El Rabito

Share this post


Link to post
Share on other sites

ok the rest is done but placing the helipad ok i place it but how do you put it in your files now. i mean i place it but do i need to get a code out of it to know is position ?

Share this post


Link to post
Share on other sites

i do use it . but if i look at my  ExileServer_system_trading_network_purchaseVehicleRequest.sqf , theres no line with these kind of command. what i get  for the helipad is :

 

/**
 * Created with Exile Mod 3DEN Plugin
 * www.exilemod.com
 */

ExileRouletteChairs = [];
ExileRouletteChairPositions = [];

// 1 Vehicles
private _vehicles = [
["Land_HelipadEmpty_F", [14554.4, 16865.4, 17.8349], [0, 0.999999, 0.00133721], [-0.00399675, -0.0013372, 0.999991], true]
];

{
    private _vehicle = (_x select 0) createVehicle (_x select 1);
    _vehicle allowDamage false;
    _vehicle setPosWorld (_x select 1);
    _vehicle setVectorDirAndUp [_x select 2, _x select 3];
    _vehicle enableSimulationGlobal (_x select 4);
    _vehicle setVariable ["ExileIsLocked", -1, true];
    
    if (_vehicle isKindOf "Exile_RussianRouletteChair") then
    {
        ExileRouletteChairs pushBack _vehicle;
        ExileRouletteChairPositions pushBack [_x select 1, getDir _vehicle];
    };
}
forEach _vehicles;

// 0 Simple Objects
private _invisibleSelections = ["zasleh", "zasleh2", "box_nato_grenades_sign_f", "box_nato_ammoord_sign_f", "box_nato_support_sign_f"];
private _simpleObjects = [

];

{
    private _simpleObject = createSimpleObject [_x select 0, _x select 1];
    _simpleObject setVectorDirAndUp [_x select 2, _x select 3];
    
    {
        if ((toLower _x) in _invisibleSelections) then 
        {
            _simpleObject hideSelection [_x, true];
        };
    }
    forEach (selectionNames _simpleObject);
}
forEach _simpleObjects;





do i replace all the file with these line ? or i just take a part of this and put it in.

Edited by nikorasu

Share this post


Link to post
Share on other sites
Advertisement

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
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.