Hallo Leute, ich mal wieder lol
Habe da mal eine Frage: Bei mir sind die Toolkits für die Zivilisten permanent, wie mache ich das, das es nur für den ADAC und nicht für die Civs perma ist?
Danke schonmal
Schön, dass du den Weg zu NodeZone.net gefunden hast! Aktuell bist du nicht angemeldet und kannst deshalb nur eingeschränkt auf unsere Community zugreifen. Um alle Funktionen freizuschalten, spannende Inhalte zu entdecken und dich aktiv einzubringen, registriere dich jetzt kostenlos oder melde dich mit deinem Account an.
Hallo Leute, ich mal wieder lol
Habe da mal eine Frage: Bei mir sind die Toolkits für die Zivilisten permanent, wie mache ich das, das es nur für den ADAC und nicht für die Civs perma ist?
Danke schonmal
mal da geschaut fn_repairTruck.sqf
/*
File: fn_repairTruck.sqf
Author: Bryan "Tonic" Boardwine
Modified by: Play Germany
Description:
Main functionality for toolkits, to be revised in later version.
*/
private["_veh","_upp","_ui","_progress","_pgText","_cP","_displayName","_test"];
_veh = cursorTarget;
life_interrupted = false;
if(isNull _veh) exitwith {};
if((_veh isKindOf "Car") OR (_veh isKindOf "Ship") OR (_veh isKindOf "Air")) then
{
if("ToolKit" in (items player)) then
{
life_action_inUse = true;
_displayName = getText(configFile >> "CfgVehicles" >> (typeOf _veh) >> "displayName");
_upp = format[localize "STR_NOTF_Repairing",_displayName];
//Setup our progress bar.
disableSerialization;
5 cutRsc ["life_progress","PLAIN"];
_ui = uiNameSpace getVariable "life_progress";
_progress = _ui displayCtrl 38201;
_pgText = _ui displayCtrl 38202;
_pgText ctrlSetText format["%2 (1%1)...","%",_upp];
_progress progressSetPosition 0.01;
_cP = 0.01;
while{true} do
{
if(animationState player != "Acts_carFixingWheel") then {
player playMoveNow "Acts_carFixingWheel";
};
uiSleep 0.27;
_cP = _cP + 0.01;
_progress progressSetPosition _cP;
_pgText ctrlSetText format["%3 (%1%2)...",round(_cP * 100),"%",_upp];
if(_cP >= 1) exitWith {};
if(!alive player) exitWith {};
if(player != vehicle player) exitWith {};
if(life_interrupted) exitWith {};
};
life_action_inUse = false;
5 cutText ["","PLAIN"];
player playMoveNow "AinvPknlMstpSnonWnonDnon_medic_1";
uiSleep 0.1;
player playActionNow "Stop";
if(life_interrupted) exitWith {life_interrupted = false; titleText[localize "STR_NOTF_ActionCancel","PLAIN"]; life_action_inUse = false;};
if(player != vehicle player) exitWith {titleText[localize "STR_NOTF_RepairingInVehicle","PLAIN"];};
if(playerSide in [civilian,east]) then {player removeItem "ToolKit"}; <<<---- Hier wird das Toolkit gelöscht ;-)
_veh setDamage 0;
titleText[localize "STR_NOTF_RepairedVehicle","PLAIN"];
};
};
Alles anzeigen
hab die Stelle mal markiert
Code Alles anzeigen/* File: fn_repairTruck.sqf Author: Bryan "Tonic" Boardwine Modified by: Play Germany Description: Main functionality for toolkits, to be revised in later version. */ private["_veh","_upp","_ui","_progress","_pgText","_cP","_displayName","_test"]; _veh = cursorTarget; life_interrupted = false; if(isNull _veh) exitwith {}; if((_veh isKindOf "Car") OR (_veh isKindOf "Ship") OR (_veh isKindOf "Air")) then { if("ToolKit" in (items player)) then { life_action_inUse = true; _displayName = getText(configFile >> "CfgVehicles" >> (typeOf _veh) >> "displayName"); _upp = format[localize "STR_NOTF_Repairing",_displayName]; //Setup our progress bar. disableSerialization; 5 cutRsc ["life_progress","PLAIN"]; _ui = uiNameSpace getVariable "life_progress"; _progress = _ui displayCtrl 38201; _pgText = _ui displayCtrl 38202; _pgText ctrlSetText format["%2 (1%1)...","%",_upp]; _progress progressSetPosition 0.01; _cP = 0.01; while{true} do { if(animationState player != "Acts_carFixingWheel") then { player playMoveNow "Acts_carFixingWheel"; }; uiSleep 0.27; _cP = _cP + 0.01; _progress progressSetPosition _cP; _pgText ctrlSetText format["%3 (%1%2)...",round(_cP * 100),"%",_upp]; if(_cP >= 1) exitWith {}; if(!alive player) exitWith {}; if(player != vehicle player) exitWith {}; if(life_interrupted) exitWith {}; }; life_action_inUse = false; 5 cutText ["","PLAIN"]; player playMoveNow "AinvPknlMstpSnonWnonDnon_medic_1"; uiSleep 0.1; player playActionNow "Stop"; if(life_interrupted) exitWith {life_interrupted = false; titleText[localize "STR_NOTF_ActionCancel","PLAIN"]; life_action_inUse = false;}; if(player != vehicle player) exitWith {titleText[localize "STR_NOTF_RepairingInVehicle","PLAIN"];}; if(playerSide in [civilian,east]) then {player removeItem "ToolKit"}; <<<---- Hier wird das Toolkit gelöscht ;-) _veh setDamage 0; titleText[localize "STR_NOTF_RepairedVehicle","PLAIN"]; }; };
hab die Stelle mal markiert
Super danke Euch. Vielen Lieben Dank