Jump to content

Need help with addons in PBO


BetterDeadThanZed

Recommended Posts

Using I found out how to set up my map addons in a PBO but I'm having an issue with the addons not showing up. 

 

Here's my server folder structure leading to the PBO:

 

root/@EpochHive/addons/a3_epoch_server_buildings.pbo

 

In the a3_epoch_server_building.pbo I have the following:

 

config.cpp

PboPrefix.txt

buildings (folder)

init (folder)

 

My config,cpp:

class CfgPatches {
	class A3_epoch_building {
		units[] = {};
		weapons[] = {};
		requiredVersion = 0.1;
		requiredAddons[] = {"A3_server_settings"};
	};
};
class CfgFunctions {
	class building {
		class main {
			file = "a3_epoch_server_building\init";
			class init {
				postInit = 1;
			};
		};
	};
};

My PboPrefix.txt:

x\@EpochHive\addons\a3_epoch_server_building

My fn_init.sqf:

diag_log "Loading Custom Buildings";
call compile preprocessFileLineNumbers "x\@EpochHive\addons\a3_epoch_server_building\buildings\cherno_slumville.sqf";

My log shows that the pbo is being loaded and the server is loading custom buildings:

12:50:51 "Loading Custom Buildings"

When I go to where the custom buildings should be, they aren't there. 

 

Now, the one big difference I see is the formatting of the addon. When using Maca's 3D editor and exporting it to sqf, I get a file with this format:

[
    ["Land_cargo_addon02_V1_F",[8578.35,8140.39,0],65.0055,0,0,false]
]

In the topic that I used to create the pbo method, the file looks like this, which I recognize as the format from A2 Epoch:

if (isServer) then {
 
_vehicle_10 = objNull;
if (true) then
{
        _this = createVehicle ["Land_HBarrierBig_F", [23565.727, 18799.27, -1.9073486e-006], [], 0, "CAN_COLLIDE"];
        _vehicle_10 = _this;
        _this setPos [23565.727, 18799.27, -1.9073486e-006];
};

};

So, is it because of the format that my .sqf is in? Is it a path error? If someone could shed some light on this, I'd really appreciate it. Using the method of inserting the addons into the config.cpp is ok, but it doesn't let me put things at angles and I understand the pbo method is supposedly a better way to do it anyway.

Link to comment
Share on other sites

hey,

 

I think it would be easier if you download the a3 editor and this costum pbo to

 

build there what you need, use the "export sqf" button, and use this for the costum pbo.... its very easy :D

 

or use the cpp:

 

do not know exactly what you want to build there, but hope it helps .... the cpp and costum pbo are both on the server side. with the custom pbo you can specify more features, such as set vector and so

Link to comment
Share on other sites

Using maca's 3d editor when you save it or export it, it gives you 2 different layouts. I use the one that has the top and bottom bits :) works fine, might be better ways..

private ["_objs"];
_objs = [
	["placeditem",[00000.0,00000.0,0],180,[[0.,-1,0],[-0,0,1]],false]
];

{
	private ["_obj"];
	_obj = createVehicle [_x select 0, [0,0,0], [], 0, "CAN_COLLIDE"];
	if (_x select 4) then {
		_obj setDir (_x select 2);
		_obj setPos (_x select 1);
	} else {
		_obj setPosATL (_x select 1);
		_obj setVectorDirAndUp (_x select 3);
	};
} foreach _objs;
Link to comment
Share on other sites

hey,

I think it would be easier if you download the a3 editor and this costum pbo to

 

build there what you need, use the "export sqf" button, and use this for the costum pbo.... its very easy :D

 

or use the cpp:

 

do not know exactly what you want to build there, but hope it helps .... the cpp and costum pbo are both on the server side. with the custom pbo you can specify more features, such as set vector and so

 

I do use that editor already. I used the export to sqf but it puts it in the format I posted, not in the format shown in the thread I linked to. I want to use the pbo method because of the ability to use vectors.

Link to comment
Share on other sites

 

Using maca's 3d editor when you save it or export it, it gives you 2 different layouts. I use the one that has the top and bottom bits :) works fine, might be better ways..

private ["_objs"];
_objs = [
	["placeditem",[00000.0,00000.0,0],180,[[0.,-1,0],[-0,0,1]],false]
];

{
	private ["_obj"];
	_obj = createVehicle [_x select 0, [0,0,0], [], 0, "CAN_COLLIDE"];
	if (_x select 4) then {
		_obj setDir (_x select 2);
		_obj setPos (_x select 1);
	} else {
		_obj setPosATL (_x select 1);
		_obj setVectorDirAndUp (_x select 3);
	};
} foreach _objs;

 

When I save or or export it, I don't get anything that looks like that.

Link to comment
Share on other sites

Exporting the sqf from the editor puts it into the file like that, Saving will place it in like OP

 

My problem was that I wasn't looking all the way at the bottom of the exported SQF so I didn't see that other part at the bottom. I have exported the file again and will retest it. Hopefully it was just the format of the sqf that was preventing it from showing up, although I don't understand why there wouldn't be some sort of error in the log saying that the format was wrong.

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
  • Discord

×
×
  • Create New...