Jump to content
Benny.

[SP/MP] BeCTI

Recommended Posts

Any warfare will melt a server eventually, however I found that Zerty's where only one or two AOs are active helps a little. Restricting the amount of AI does work well, however, server setup also helps. There are threads and threads on that so I'll not bring that up here.

Try also using the PERF binaries that Dwarden is releasing and the mallocs that Fred41 has brought out to see if they help.

However, even with all that, I do find some AI leaders remaining at base and wonder if it is something to do with the CPS (cycles per second) that drops after a certain time on the server?

Share this post


Link to post
Share on other sites

Try also using the PERF binaries that Dwarden is releasing and the mallocs that Fred41 has brought out to see if they help.

However, even with all that, I do find some AI leaders remaining at base and wonder if it is something to do with the CPS (cycles per second) that drops after a certain time on the server?

Yeah PERF helps a bit regarding server fps, but I've had this "stay at home AI's" problem since 1.10 PERF 6. Fred41's custom tbbmalloc did not help either as it only effects the ram usage. It's BECTI thats causing this problem, even with our new i7 3930k server and stable 49,3 CPS.

Edited by gabberxxl

Share this post


Link to post
Share on other sites
Yeah PERF helps a bit regarding server fps, but I've had this "stay at home AI's" problem since 1.10 PERF 6. Fred41's custom tbbmalloc did not help either as it only effects the ram usage. It's BECTI thats causing this problem, even with our new i7 3930k server and stable 49,3 CPS.

Your not using BECTI you are using someone elses edit of it.

Just a heads up :)

Share this post


Link to post
Share on other sites
Your not using BECTI you are using someone elses edit of it.

Just a heads up :)

Yep, I know and thats why I tried it yesterday with BECTI 0.97 and the same problem appeared after 5 hours server uptime, so I can safely say that it is BECTI.

Share this post


Link to post
Share on other sites

Did some digging today, found the reason behind binoculars causing the reserved variable error on start (and subsequently not appearing in the gear menu) since 1.12 is because BIS added a new command with the exact same name as the binoculars classname. Go figure.

Anyhoo heres a workaround:

link removed, see post #490

First file goes in client > functions > UI and second file goes in common > config > gear

Edited by Sari

Share this post


Link to post
Share on other sites
Did some digging today, found the reason behind binoculars causing the reserved variable error on start (and subsequently not appearing in the gear menu) since 1.12 is because BIS added a new command with the exact same name as the binoculars classname. Go figure.

Anyhoo heres a workaround:

http://www.sendspace.com/file/n523bv

First file goes in client > functions > UI and second file goes in common > config > gear

Thanks Sari I'll use the fix. BTW, I replaced BINOS with range finder as a quick fix a few days ago.

**********

Quick question for you guys, how do I add a couple meters between attached vehicles and helicopters? I'm having some collision issues with the Mohawk and repair trucks and need to separate them a bit.

Thanks!

Share this post


Link to post
Share on other sites

If you use the stock hook menu then client > functions > client_hookvehicle.sqf, line 33 (case (_hooker isKindOf "Air"): {[0,0,-4]};), change the -4 to something that works (lower value = further away). Though I find attachto gets a bit funny with the z axis sometimes, ie if you set the value to -10 and you're hovering less than 10m above (eg 8m) then the vehicle will attach at that distance as opposed to the one you set in the script.

Also I'd consider replacing that hook menu with something a little more traditional (was one of the first things we replaced when we started looking at BECTI, sorry Benny :P), as it is unusable for stick users - when you try and open the menu the chopper just drops out of the sky. Very embarrasing, especially if you're carrying the HQ...

Share this post


Link to post
Share on other sites
If you use the stock hook menu then client > functions > client_hookvehicle.sqf, line 33 (case (_hooker isKindOf "Air"): {[0,0,-4]};), change the -4 to something that works (lower value = further away). Though I find attachto gets a bit funny with the z axis sometimes, ie if you set the value to -10 and you're hovering less than 10m above (eg 8m) then the vehicle will attach at that distance as opposed to the one you set in the script.

Also I'd consider replacing that hook menu with something a little more traditional (was one of the first things we replaced when we started looking at BECTI, sorry Benny :P), as it is unusable for stick users - when you try and open the menu the chopper just drops out of the sky. Very embarrasing, especially if you're carrying the HQ...

Mind sharing what you've done? I'd like to replace the hooking system as well

*********EDIT

Sari I just tried your gear fix and something in it is broken. When I try and equip myself all of the content boxes (rifle, backpack, binos, etc) are empty. I can't equip anything either.

Edited by SpanishSurfer

Share this post


Link to post
Share on other sites
Mind sharing what you've done? I'd like to replace the hooking system as well

*********EDIT

Sari I just tried your gear fix and something in it is broken. When I try and equip myself all of the content boxes (rifle, backpack, binos, etc) are empty. I can't equip anything either.

Yeah sure, not at my desktop right now but I'll sort it later/tomorrow.

The gear fix was working fine for me yesterday, but I've done all my edits from stock 0.97 BECTI and not zertys or whatnot so maybe somethings clashing there. Chances are though its just me being an idiot as per usual...

Can you start the mission, build a barracks, open the gear menu and upload the resulting rpt file please?

Edited by Sari

Share this post


Link to post
Share on other sites

To awser for the AI leaders, I ve already saw that problem ( and with workers too) after some time if the CPS drops to 0. I am guessing it has to do with the scheduler that omit to put the execution of some fsm in the execution stack (maybe precompiled sheduled code is prioritary on the execution). Or maybe the FSM just go stuck for some unknown reason or when the unit respawn maybe sometime the fsm is not started .

And btw, on my edit, both fsm for these units are untouched since i dont use them.

Share this post


Link to post
Share on other sites
To awser for the AI leaders, I ve already saw that problem ( and with workers too) after some time if the CPS drops to 0. I am guessing it has to do with the scheduler that omit to put the execution of some fsm in the execution stack (maybe precompiled sheduled code is prioritary on the execution). Or maybe the FSM just go stuck for some unknown reason or when the unit respawn maybe sometime the fsm is not started .

And btw, on my edit, both fsm for these units are untouched since i dont use them.

Thx for the information. As I switched to the slot of the unresponsive AI leader I saw this on the map:

http://i.imgur.com/bURye78.jpg (412 kB)

The lower left markes says "move" and the middle right marker says "search and destroy". As far as i know the small island at marker #1 is the initial spawn for OPFOR side if the game starts or the group leader is killed. AI will then be teleported to the base.

But the AI cannot move there with their profile set to anything else than infantry.

Share this post


Link to post
Share on other sites

Am having an issue with not being able to save and resume the mission in SP.

Also when re spawning in SP some times it just takes you to the new unit rather than showing you the re spawn UI. (thus you don't have the blue options in your action menu)

TLDR; having issues re spawning and resuming in SP

Am on Dev branch

Share this post


Link to post
Share on other sites

This is an mp mission......host in lan or on a dedi server(better). Saving works but is not recommend.

Share this post


Link to post
Share on other sites
Thx for the information. As I switched to the slot of the unresponsive AI leader I saw this on the map:

http://i.imgur.com/bURye78.jpg (412 kB)

The lower left markes says "move" and the middle right marker says "search and destroy". As far as i know the small island at marker #1 is the initial spawn for OPFOR side if the game starts or the group leader is killed. AI will then be teleported to the base.

But the AI cannot move there with their profile set to anything else than infantry.

Ok so it migth be waypoint related, ill take a look

Share this post


Link to post
Share on other sites

@spanish/everyone

Realised my mistake with the binos/gear thing, I had another edit in there related to something else. Heres the corrected files (I tested with the latest file on your server and it seemed to work ok):

http://www.sendspace.com/file/8xyjt3

@Gabber.

Whilst Zerty is probably right, I left stock 0.97 running with full ai teams on a locked server overnight. The only time I found an AI leader stuck at base was when they didnt have the funds to buy whatever their buy types were set to. However the FPS was higher than i thought it would be after 18 hours of Full AI teams:

http://s8.postimg.org/ncpqoin1x/2014_04_24_00001.jpg

http://s30.postimg.org/raw2jrea9/2014_04_24_00002.jpg

http://s22.postimg.org/kbhk7d6xd/2014_04_24_00004.jpg

edit: forgot the airlift thing. The airlift script we're using originates from the standard airlift in WFBE so ill startoff by saying original credits goto Benny for this:

http://www.sendspace.com/file/97ydec

the module folder goes into the client folder (however it can go anywhere you want as long as you change the appropraite filepaths). Then in common > init > init_commonconstants, you need to add the following at the botton of the Vehicles: Misc section (about line 450):

CTI_VEHICLES_HOOKABLE = ["Car","Motorcycle","Tank","Ship"]; //--- Types of Vehicles 

Finally, in common > functions > common_initializenetvehicle find the following (line 67):

if (typeOf _vehicle in (CTI_VEHICLES_HOOKERS+CTI_VEHICLES_HOOKERS_EX)) then {_vehicle addAction ["<t color='#86F078'>Hook (Main)</t>", "Client\Actions\Action_HookMenu.sqf", "", 99, false, true, "", "alive _target && local _target && _this == driver _target"]};

and replace with:

if (typeOf _vehicle in (CTI_VEHICLES_HOOKERS)) then {
[_vehicle] ExecVM 'Client\Module\ZetaCargo\Zeta_AddAction.sqf'; // A2 Airlift action
};

if (typeOf _vehicle in (CTI_VEHICLES_HOOKERS_EX)) then {
_vehicle addAction ["<t color='#86F078'>Hook (Main)</t>", "Client\Actions\Action_HookMenu.sqf", "", 99, false, true, "", "alive _target && local _target && _this == driver _target"]
};

Edited by Sari

Share this post


Link to post
Share on other sites

I think that this is going Off-topic as this seem to be an issue with BECTI 0.97 Zerty 1.1.9.3 and not with BECTI 0.97.

@Gabber.

Whilst Zerty is probably right, I left stock 0.97 running with full ai teams on a locked server overnight. The only time I found an AI leader stuck at base was when they didnt have the funds to buy whatever their buy types were set to. However the FPS was higher than i thought it would be after 18 hours of Full AI teams:

http://s8.postimg.org/ncpqoin1x/2014_04_24_00001.jpg

http://s30.postimg.org/raw2jrea9/2014_04_24_00002.jpg

http://s22.postimg.org/kbhk7d6xd/2014_04_24_00004.jpg

And this is how it looks with Zertys edit with disabled Strategic Mode after almost 15 hours with 9 enabled AI's

All i did was disabling the unused map connections and HUD informations:

http://i.imgur.com/5PpOsFV.jpg?1 (251 kB)

original SM_Connect.sqf:

/*
Script written by TeeTime dont remove this comment
*/

private ["_base1","_base2","_xdif","_ydif","_xpos","_ypos","_pos","_marker"];

_base1 = _this select 0;
_base2 = _this select 1;
_color = _this select 2;
_offset = _this select 3;

_xdif = (_base1 select 0) - (_base2 select 0);
_ydif = (_base1 select 1) - (_base2 select 1);

_xpos = (_base1 select 0) - _xdif / 2;
_ypos = (_base1 select 1) - _ydif / 2;

_pos	= [_xpos,_ypos,0];
_dir	= atan ( _xdif / _ydif );

_name 	= format ["CM_%1_%2",floor(time),floor(random(1000))];
_type	= "RECTANGLE";

_marker = CreateMarkerLocal [_name, _pos];
_marker setMarkerShapeLocal "RECTANGLE";
_marker setMarkerBrushLocal "Solid";
_marker setMarkerDirLocal _dir;
_marker setMarkerSizeLocal [20, (((_base1 distance _base2)-_offset) / 2) ];
_marker setMarkerColorLocal _color;
_marker setMarkerAlphaLocal 1;

modified SM_Connect.sqf:

/*
Script written by TeeTime dont remove this comment


private ["_base1","_base2","_xdif","_ydif","_xpos","_ypos","_pos","_marker"];

_base1 = _this select 0;
_base2 = _this select 1;
_color = _this select 2;
_offset = _this select 3;

_xdif = (_base1 select 0) - (_base2 select 0);
_ydif = (_base1 select 1) - (_base2 select 1);

_xpos = (_base1 select 0) - _xdif / 2;
_ypos = (_base1 select 1) - _ydif / 2;

_pos	= [_xpos,_ypos,0];
_dir	= atan ( _xdif / _ydif );

_name 	= format ["CM_%1_%2",floor(time),floor(random(1000))];
_type	= "RECTANGLE";

_marker = CreateMarkerLocal [_name, _pos];
_marker setMarkerShapeLocal "RECTANGLE";
_marker setMarkerBrushLocal "Solid";
_marker setMarkerDirLocal _dir;
_marker setMarkerSizeLocal [20, (((_base1 distance _base2)-_offset) / 2) ];
_marker setMarkerColorLocal _color;
_marker setMarkerAlphaLocal 1;
*/

original HUD_launch.sqf:

#define HUD_IDC 15000
#define	HUD_M_MAX	20
#define	HUD_TARG_MAX	100
#define	HUD_TOWN_MAX	10


HUD_GetRevives=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_GetRevive.sqf";
HUD_ShowRevives=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_ShowRevive.sqf";
HUD_GetTowns=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_GetTowns.sqf";
HUD_ShowTowns=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_ShowTowns.sqf";
HUD_GetTargets=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_GetTargets.sqf";
HUD_ShowTargets=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_ShowTargets.sqf";



HUD_UpdateInfo={
_hud=_this;
disableSerialization;
_basic=(_hud displayCtrl(HUD_IDC+1));
_pro=(_hud displayCtrl(HUD_IDC+3));
// capture
_town=((player) call CTI_CO_FNC_GetClosestTown);
if ( player distance _town < CTI_MARKERS_TOWN_AREA_RANGE) then {
	_pro ctrlShow true;
	_pb=(CTI_TOWNS_CAPTURE_VALUE_CEIL - (_town getVariable "cti_town_capture")) / CTI_TOWNS_CAPTURE_VALUE_CEIL ;
	_pro progressSetPosition  _pb ;
} else {
	_pro ctrlShow false;
};
//-------INFO -------

_t="<t size='0.75' align='right'>";
_t= _t+format	["%1  <t color='#00ff00'> $$ </t> <br />",[group player, CTI_P_SideJoined] call CTI_CO_FNC_GetFunds] ;
_t=_t+format	["%1  <t color='#ff0000'><img image='A3\ui_f\data\IGUI\Cfg\Actions\heal_ca.paa'/></t> <br />",ceil( (1- getDammage	player)*100)] ;
if ( (missionNamespace getVariable 'CTI_SM_RADAR')==1 && (count ([CTI_RADAR, ((CTI_P_SideJoined) call CTI_CO_FNC_GetSideStructures)] call CTI_CO_FNC_GetSideStructuresByType) > 0 )) then {
	//_t=_t+"<t underline='true'> Radars:</t><br />";
	_air_c="color='#ffff00'";
	_art_c="color='#ffff00'";
	if (([CTI_P_SideJoined, CTI_UPGRADE_AIRR, 1] call CTI_CO_FNC_HasUpgrade)) then {_air_c="color='#00ff00'";};
	if (([CTI_P_SideJoined, CTI_UPGRADE_ARTR, 1] call CTI_CO_FNC_HasUpgrade)) then {_art_c="color='#00ff00'";};
	if (count SM_Radar_Detected >0 ) then {_air_c="color='#ff0000'";};
	if (count SM_Arty_Detected >0) then {_art_c="color='#ff0000'";};
	_t=_t+"<t size='1.75'><t "+_air_c+"><img image='a3\air_f_gamma\Plane_Fighter_03\Data\UI\map_plane_fighter_03_ca.paa'/></t><t "+_art_c+"><img image='\a3\ui_f\data\gui\cfg\CommunicationMenu\artillery_ca.paa'/></t></t><br />";
};
_t=_t+"<t underline='true'> Active Towns:</t><br />";
{
	_marker = format ["cti_town_marker_%1", _x];

	_icon = switch (getMarkerColor _marker) do
	{
	    case 	"ColorGreen":{ "<t color='#00ff00'><img image='A3\ui_f\data\map\Markers\Military\flag_ca.paa'/></t>" };
	    case 	"ColorBlue":{ "<t color='#0000ff'><img image='A3\ui_f\data\map\Markers\Military\flag_ca.paa'/></t>" };
	    case 	"ColorRed":{ "<t color='#ff0000'><img image='A3\ui_f\data\map\Markers\Military\flag_ca.paa'/></t>" };
	    default { "<t color='#00ff00'><img image='A3\ui_f\data\map\Markers\Military\flag_ca.paa'/></t>"  };
	};
	_t = _t + format ["%1  %2<br />",(_x getVariable "cti_town_name"),_icon	]
} count CTI_P_Active_Towns;
_t=_t+"</t>";
_basic ctrlSetStructuredText	parseText	 _t;
};


HUD_UpdateVehicle={
_hud=_this;
disableSerialization;
_veh=(_hud displayCtrl(HUD_IDC+2));
if (vehicle	player == player ||  {isplayer _x} count crew (vehicle player) <2  ) then{
	_veh ctrlShow	false;
} else {
	_veh ctrlShow	true;
	_text="<t size='0.7'>";
	_d=driver	(vehicle	player);
	if (!isNull	_d && isPlayer	_d) then {_text=_text + 	format	["<img image='Rsc\Pictures\i_driver.paa'/>%1<br />",name _d];};
	_c=commander (vehicle	player);
	if (!isNull	_c && isPlayer	_c) then {_text=_text + 	format	["<img image='Rsc\Pictures\i_commander.paa'/>%1<br />",name _c];};
	_g=gunner (vehicle	player);
	if (!isNull	_g && isPlayer	_g) then {_text=_text + 	format	["<img image='Rsc\Pictures\i_gunner.paa'/>%1<br />",name _g];};
	{
			if (isplayer _x && !(commander (vehicle	player) == _x || driver	(vehicle	player) ==_x || gunner (vehicle	player) ==_x )) then {
				_text=_text + 	format	["<img image='Rsc\Pictures\i_turrets.paa'/>%1<br />",name _x];
			};
	} forEach crew (vehicle	player);
	_text=_text+"</t>";
	_veh ctrlSetStructuredText	parseText	 _text;
};
};



HUD_Revive_frame={
["ReviveFrame", "onEachFrame", "{
 	disableSerialization;
	_hud=uiNamespace getVariable 'HUD';
	[_hud] call HUD_ShowRevives;
}"] call BIS_fnc_addStackedEventHandler;
};
HUD_AddFrameHandler={
["hudFrame", "onEachFrame", "{
 	disableSerialization;
	_hud=uiNamespace getVariable 'HUD';
	[_hud] call HUD_ShowTargets;
	[_hud] call HUD_ShowTowns;
}"] call BIS_fnc_addStackedEventHandler;
};

HUD_RemoveFrameHandler={
["hudFrame", "onEachFrame"] call BIS_fnc_removeStackedEventHandler;
};
/*
0 spawn {
disableSerialization;
_hud=uiNamespace getVariable 'HUD';
while {!CTI_GameOver} do {
	[_hud] call HUD_ShowTargets;
	//[_hud] call HUD_ShowTowns;
	[_hud] call HUD_ShowRevives;
};
};*/

0 call HUD_Revive_frame;

0 spawn {
while {!CTI_GameOver} do {
	waitUntil {HUD_Tactical};
	if HUD_Tactical then {
		HUD_Targets = (0) call HUD_GetTargets;
		HUD_Towns = (0) call HUD_GetTowns;
	};
	sleep 1;
};
};

0 spawn {
while {!CTI_GameOver} do {
		disableSerialization;
		_hud=uiNamespace getVariable 'HUD';
		(_hud) call HUD_UpdateInfo;
		(_hud) call HUD_UpdateVehicle;
		HUD_Revives = (0) call HUD_GetRevives;
		sleep 2;
};
};

modified HUD_launch.sqf

#define HUD_IDC 15000
#define	HUD_M_MAX	20
#define	HUD_TARG_MAX	100
#define	HUD_TOWN_MAX	10


HUD_GetRevives=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_GetRevive.sqf";
HUD_ShowRevives=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_ShowRevive.sqf";
HUD_GetTowns=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_GetTowns.sqf";
HUD_ShowTowns=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_ShowTowns.sqf";
HUD_GetTargets=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_GetTargets.sqf";
HUD_ShowTargets=compile preprocessfilelinenumbers "Addons\Strat_mode\HUD\HUD_ShowTargets.sqf";



HUD_UpdateInfo={
_hud=_this;
disableSerialization;
_basic=(_hud displayCtrl(HUD_IDC+1));
_pro=(_hud displayCtrl(HUD_IDC+3));
// capture
_town=((player) call CTI_CO_FNC_GetClosestTown);
if ( player distance _town < CTI_MARKERS_TOWN_AREA_RANGE) then {
	_pro ctrlShow true;
	_pb=(CTI_TOWNS_CAPTURE_VALUE_CEIL - (_town getVariable "cti_town_capture")) / CTI_TOWNS_CAPTURE_VALUE_CEIL ;
	_pro progressSetPosition  _pb ;
} else {
	_pro ctrlShow false;
};
//-------INFO -------

_t="<t size='0.75' align='right'>";
_t= _t+format	["%1  <t color='#00ff00'> $$ </t> <br />",[group player, CTI_P_SideJoined] call CTI_CO_FNC_GetFunds] ;
_t=_t+format	["%1  <t color='#ff0000'><img image='A3\ui_f\data\IGUI\Cfg\Actions\heal_ca.paa'/></t> <br />",ceil( (1- getDammage	player)*100)] ;
if ( (missionNamespace getVariable 'CTI_SM_RADAR')==1 && (count ([CTI_RADAR, ((CTI_P_SideJoined) call CTI_CO_FNC_GetSideStructures)] call CTI_CO_FNC_GetSideStructuresByType) > 0 )) then {
	//_t=_t+"<t underline='true'> Radars:</t><br />";
	_air_c="color='#ffff00'";
	_art_c="color='#ffff00'";
	if (([CTI_P_SideJoined, CTI_UPGRADE_AIRR, 1] call CTI_CO_FNC_HasUpgrade)) then {_air_c="color='#00ff00'";};
	if (([CTI_P_SideJoined, CTI_UPGRADE_ARTR, 1] call CTI_CO_FNC_HasUpgrade)) then {_art_c="color='#00ff00'";};
	if (count SM_Radar_Detected >0 ) then {_air_c="color='#ff0000'";};
	if (count SM_Arty_Detected >0) then {_art_c="color='#ff0000'";};
	_t=_t+"<t size='1.75'><t "+_air_c+"><img image='a3\air_f_gamma\Plane_Fighter_03\Data\UI\map_plane_fighter_03_ca.paa'/></t><t "+_art_c+"><img image='\a3\ui_f\data\gui\cfg\CommunicationMenu\artillery_ca.paa'/></t></t><br />";
};
_t=_t+"<t underline='true'> </t><br />";
{
	_marker = format ["cti_town_marker_%1", _x];

	_icon = switch (getMarkerColor _marker) do
	{
	    case 	"ColorGreen":{ "<t color='#00ff00'><img image='A3\ui_f\data\map\Markers\Military\flag_ca.paa'/></t>" };
	    case 	"ColorBlue":{ "<t color='#0000ff'><img image='A3\ui_f\data\map\Markers\Military\flag_ca.paa'/></t>" };
	    case 	"ColorRed":{ "<t color='#ff0000'><img image='A3\ui_f\data\map\Markers\Military\flag_ca.paa'/></t>" };
	    default { "<t color='#00ff00'><img image='A3\ui_f\data\map\Markers\Military\flag_ca.paa'/></t>"  };
	};
	_t = _t + format ["%1  %2<br />",(_x getVariable "cti_town_name"),_icon	]
} count CTI_P_Active_Towns;
_t=_t+"</t>";
_basic ctrlSetStructuredText	parseText	 _t;
};


HUD_UpdateVehicle={
_hud=_this;
disableSerialization;
_veh=(_hud displayCtrl(HUD_IDC+2));
if (vehicle	player == player ||  {isplayer _x} count crew (vehicle player) <2  ) then{
	_veh ctrlShow	false;
} else {
	_veh ctrlShow	true;
	_text="<t size='0.7'>";
	_d=driver	(vehicle	player);
	if (!isNull	_d && isPlayer	_d) then {_text=_text + 	format	["<img image='Rsc\Pictures\i_driver.paa'/>%1<br />",name _d];};
	_c=commander (vehicle	player);
	if (!isNull	_c && isPlayer	_c) then {_text=_text + 	format	["<img image='Rsc\Pictures\i_commander.paa'/>%1<br />",name _c];};
	_g=gunner (vehicle	player);
	if (!isNull	_g && isPlayer	_g) then {_text=_text + 	format	["<img image='Rsc\Pictures\i_gunner.paa'/>%1<br />",name _g];};
	{
			if (isplayer _x && !(commander (vehicle	player) == _x || driver	(vehicle	player) ==_x || gunner (vehicle	player) ==_x )) then {
				_text=_text + 	format	["<img image='Rsc\Pictures\i_turrets.paa'/>%1<br />",name _x];
			};
	} forEach crew (vehicle	player);
	_text=_text+"</t>";
	_veh ctrlSetStructuredText	parseText	 _text;
};
};



HUD_Revive_frame={
["ReviveFrame", "onEachFrame", "{
 	disableSerialization;
	_hud=uiNamespace getVariable 'HUD';
	[_hud] call HUD_ShowRevives;
}"] call BIS_fnc_addStackedEventHandler;
};
HUD_AddFrameHandler={
["hudFrame", "onEachFrame", "{
 	disableSerialization;
	_hud=uiNamespace getVariable 'HUD';
	[_hud] call HUD_ShowTargets;
	[_hud] call HUD_ShowTowns;
}"] call BIS_fnc_addStackedEventHandler;
};

HUD_RemoveFrameHandler={
["hudFrame", "onEachFrame"] call BIS_fnc_removeStackedEventHandler;
};
/*
0 spawn {
disableSerialization;
_hud=uiNamespace getVariable 'HUD';
while {!CTI_GameOver} do {
	[_hud] call HUD_ShowTargets;
	//[_hud] call HUD_ShowTowns;
	[_hud] call HUD_ShowRevives;
};
};*/

0 call HUD_Revive_frame;

0 spawn {
while {!CTI_GameOver} do {
	waitUntil {HUD_Tactical};
	if HUD_Tactical then {
		HUD_Targets = (0) call HUD_GetTargets;
		HUD_Towns = (0) call HUD_GetTowns;
	};
	sleep 1;
};
};

0 spawn {
while {!CTI_GameOver} do {
		disableSerialization;
		_hud=uiNamespace getVariable 'HUD';
		(_hud) call HUD_UpdateInfo;
		(_hud) call HUD_UpdateVehicle;
		HUD_Revives = (0) call HUD_GetRevives;
		sleep 2;
};
};

3 AI's are standing in the base doing nothing.

http://i.imgur.com/xCESNkI.jpg (320 kB)

They do have the resources to buy what they need. Even after giving them a simple move order they won't move anywhere.

http://i.imgur.com/a7L9wfC.jpg (400 kB)

http://i.imgur.com/DjZvMla.jpg (382 kB)

http://i.imgur.com/yRMbVOD.jpg?1 (216 kB)

Same applies to OPFOR

Edited by gabberxxl
Off-topic

Share this post


Link to post
Share on other sites

Hi!

I enjoy this mission! I've also played the Benny WarFare Missions in ArmA 2 and I love them. The menus are much better organized in the ArmA III Version.

Questions:

1) Yesterday I played alone on Stratis. I realised that the AI Commander (East) did nothing regarding Base Building, Commanding etc. Is this a known bug? I played on my own dedicated Server, using BECTI 0.97. No additional Addons were used.

2) Is it possible to give the Teams (Squads) different colors and not only blue/red? This would improve the Map Commanding Feature, which is already great.

3) Do AI controlled Squads buy and use vehicles, if they have been assigned with specific roles?

4) Is it planned to implement more ressources besides money? Examlpe: Supply Value like in the ArmA 2 versions.

5) The Upgrade-Feature could be improved imo. More Upgrade-Levels, more possibilities of specification. Like in the ArmA 2 Versions.

6) Are optional Sidemissions planned?

7) When starting the mission in SP Mode (Scenario), I am not able to choose Slot (Commander) and can not edit Parameters.

Thx in advance and if there is a possibility to donate, then please share ;)

Regards.

edit: omg, the units camera feature is awesome. i stopped playing, just watching :cool:

Edited by knollo

Share this post


Link to post
Share on other sites

knollo,

1) Not sure about this, again this is AI teams stuff so we have all that disabled.

2) Are you referring to the map markers? If so I suppose this could be done.

3) Yes, you have to play as commander, open the commanding menu and select "Teams". From here you can define buy types, orders, stances etc for each AI squad.

4) Ive been speaking with Benny and, with his permission, porting various bits from WFBE to BECTI for our server. Been primarily focused on towns (camps, depots, static defenses, banners, unit purchase etc), but a supply system and commander voting is on my longer term todo list. I do intend to post a copy here, but I still have a couple of kinks to work out.

5) This I agree with, but at the same time I feel for the most of it Arma 3 still lacks the assets for a more in depth upgrade tree. however try out zertys mod as that features quite an in depth tree, as well as a host of other features.

6) Right now I'm not sure anyone knows what Bennys intentions are. However i'm sure someone here could have a crack at it!

7) Parameters and lobby/slot screen aren't available in SP. The easiest way around this would be to host this mission a local dedicated server. However if you like SP because of saving your mission progress, you will have to edit the mission itself to set the default slot and parameters (will take a bit of explaining, if you want to go down this route ill drop you a PM or something :) )

Share this post


Link to post
Share on other sites

Hey Sari!

Thanks for your reply.

1) Unfortunatly I always have to play with AI, because nobody of my ArmA-Dudes likes this kind of missions :(

2) This is not that important. The Map Commanding Feature is already really great.

3) Yeah, I know this. But I am not sure, if the AI Squads are really using this. They always move by feet. The don't use the vehicles. It is possible for me to buy vehicles for AI Squads, this works. But Example: They use a Hunter pretty well, but they don't use a Transport Truck. Of course, they drive it, but they don't get in as a squad and move over the map with this vehicle.

4) This is great! I got an idea for a new resource. Besides money and supply points, there could be a third resource called "Humanity points" (or something like that). It refers to the behavior towards the civilians. If you help them (Side Quests) you earn benefits, if you kill civilians you get disadvantages (example: increasing production costs).

5) This sounds great!

6) Yeah! Unfortunatly my mission creating skills are too low in this game for such complex mission like BECTI.

7) Ok, so I always have to play this mission in multiplayer-mode.

Share this post


Link to post
Share on other sites
@spanish/everyone

Realised my mistake with the binos/gear thing, I had another edit in there related to something else. Heres the corrected files (I tested with the latest file on your server and it seemed to work ok):

http://www.sendspace.com/file/8xyjt3

[/php]

Sari, would you mind looking through my files and figuring out what needs to be modified/deleted and what doesn't? I don't understand what you did enough to really pick out what's necessary and what isn't. I also have a few scripts in there that I need to keep gear in supply boxes.

https://drive.google.com/file/d/0B8g5S2eOid7lbXRPSDAwQmJyams/edit?usp=sharing

Thanks bud!

Share this post


Link to post
Share on other sites

Ok, hopefully to make it a bit clearer I'll put the edits directly onto here (I figured those two files would've been largely untouched, but meh.)

Common > Config > Gear > Gear_Config_Set:

Find the line "missionNamespace setVariable [_item, [[_upgrades select _i, _prices select _i], _item_type, _config_type]];" (~line 123). REPLACE this line with the following:

if (_item == "binocular") then { //--- Workaround for "binocular" command causing reserved var errors since 1.12. Sari
missionNamespace setVariable ["binoculars", [[_upgrades select _i, _prices select _i], _item_type, _config_type]];
} else {
missionNamespace setVariable [_item, [[_upgrades select _i, _prices select _i], _item_type, _config_type]];
};		

Client > Functions > UI > Functions_UI_Gear_Menu:

Find the function "CTI_UI_Gear_DisplayShoppingItems" (~line 163), and within find the line "_get = missionNamespace getVariable _x;" (~line 191). Directly after this line ADD the following:

if (_x == "binocular") then {_get = missionNamespace getVariable "Binoculars"}; //--- Workaround for "binocular" command causing reserved var errors since 1.12. Sari

Finally remember to readd binoculars to common > config > gear_east/west and into the default templates in common > init > init_common if you removed them in the first place. With that, Binos *should* be back in the gear menu, *shouldn't* prevent people from saving templates any more and *shouldn't* cause startup errors.

Share this post


Link to post
Share on other sites
Ok, hopefully to make it a bit clearer I'll put the edits directly onto here (I figured those two files would've been largely untouched, but meh.)

Common > Config > Gear > Gear_Config_Set:

Find the line "missionNamespace setVariable [_item, [[_upgrades select _i, _prices select _i], _item_type, _config_type]];" (~line 123). REPLACE this line with the following:

if (_item == "binocular") then { //--- Workaround for "binocular" command causing reserved var errors since 1.12. Sari
missionNamespace setVariable ["binoculars", [[_upgrades select _i, _prices select _i], _item_type, _config_type]];
} else {
missionNamespace setVariable [_item, [[_upgrades select _i, _prices select _i], _item_type, _config_type]];
};		

Client > Functions > UI > Functions_UI_Gear_Menu:

Find the function "CTI_UI_Gear_DisplayShoppingItems" (~line 163), and within find the line "_get = missionNamespace getVariable _x;" (~line 191). Directly after this line ADD the following:

if (_x == "binocular") then {_get = missionNamespace getVariable "Binoculars"}; //--- Workaround for "binocular" command causing reserved var errors since 1.12. Sari

Finally remember to readd binoculars to common > config > gear_east/west and into the default templates in common > init > init_common if you removed them in the first place. With that, Binos *should* be back in the gear menu, *shouldn't* prevent people from saving templates any more and *shouldn't* cause startup errors.

If I removed the binoculars is this even necessary to get gear working again?

BTW I used your (well Benny's) airlift script, thanks it's much better now!

Share this post


Link to post
Share on other sites

what is the diffance from igiload ? to bennys ait lift?

Share this post


Link to post
Share on other sites

IGIload is much more visual and flows much nicer.

I have a question for you master coders. I want to allow all helicopters the ability to airlift however I want to specify what each one is allowed to carry. I found this case statement thanks to BTC Cargo system and wanted to implement it into BECTI. This is what I tried to do but had no success, it seems like it should work with a minor tweak or two that I'm missing:

I replaced CTI_Vehicles_Hookable with this in Init_CommonConstants.sqf


CTI_VEHICLES_HOOKABLE =
{
	_chopper = _this select 0;
	_array   = [];
	switch (typeOf _chopper) do
	{
		//MH9
		case "B_Heli_Light_01_F"     : {_array = ["Motorcycle","ReammoBox","ReammoBox_F","Quadbike_01_base_F","Strategic"];};
		//PO-30
		case "O_Heli_Light_02_F"     : {_array = ["Motorcycle","ReammoBox","ReammoBox_F","Strategic","StaticWeapon","Car","Truck","Wheeled_APC","Ship"];};
		//UH80
		case "B_Heli_Transport_01_F" : {_array = ["Motorcycle","ReammoBox","ReammoBox_F","Strategic","StaticWeapon","Car","Truck","Wheeled_APC","Ship"];};
		//CH49
		case "I_Heli_Transport_02_F" : {_array = ["ReammoBox","ReammoBox_F","Strategic","Car","Motorcycle","Tank","Ship", "Air","Ship"];};

	};
	_array
};

Edited by SpanishSurfer

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×