At least die Lösung posten?
Beiträge von blackfisch
-
-
Das "Problem" ist ein Feature von Altis Life :p
-
Recht haben beide trotzdem, etwas unnötig viel Code, da die Debug-Abfragen auch in der fn_pickAxeUse gemacht werden

-
-
In der 4.0 ist beides auf Shift + R
C: fn_keyHandler.sqf
Alles anzeigen//Restraining or robbing (Shift + R) case 19: { if(_shift) then {_handled = true;}; if(_shift && playerSide == west && !isNull cursorTarget && cursorTarget isKindOf "Man" && (isPlayer cursorTarget) && (side cursorTarget == civilian) && alive cursorTarget && cursorTarget distance player < 3.5 && !(cursorTarget GVAR "Escorting") && !(cursorTarget GVAR "restrained") && speed cursorTarget < 1) then { [] call life_fnc_restrainAction; }; //Robbing if(_shift && playerSide == civilian && !isNull cursorTarget && cursorTarget isKindOf "Man" && isPlayer cursorTarget && alive cursorTarget && cursorTarget distance player < 4 && speed cursorTarget < 1) then { if((animationState cursorTarget) != "Incapacitated" && (currentWeapon player == RIFLE OR currentWeapon player == PISTOL) && currentWeapon player != "" && !life_knockout && !(player GVAR["restrained",false]) && !life_istazed && !(player GVAR["surrender",false])) then { [cursorTarget] spawn life_fnc_knockoutAction; }; _handled = true; }; }; -
Wait a sec, hab aus der 4.4 genommen...
-
1. Kabelbinder gibt es nicht in Altis Life Vanilla
2. Festnehmen ist drinC: fn_keyHandler.sqf//Restraining (Shift + R) case 19: { if (_shift) then {_handled = true;}; if (_shift && playerSide isEqualTo west && {!isNull cursorObject} && {cursorObject isKindOf "Man"} && {(isPlayer cursorObject)} && {(side cursorObject in [civilian,independent])} && {alive cursorObject} && {cursorObject distance player < 3.5} && {!(cursorObject getVariable "Escorting")} && {!(cursorObject getVariable "restrained")} && {speed cursorObject < 1}) then { [] call life_fnc_restrainAction; }; };3. Ausrauben ist drin
C: fn_setupActions.sqf//Rob person life_actions = life_actions + [player addAction[localize "STR_pAct_RobPerson",life_fnc_robAction,"",0,false,false,"",'!isNull cursorObject && player distance cursorObject < 3.5 && isPlayer cursorObject && animationState cursorObject == "Incapacitated" && !(cursorObject getVariable ["robbed",false]) ']];4. Niederschlagen ist drin
C: fn_keyHandler.sqf//Knock out, this is experimental and yeah... (Shift + G) case 34: { if (_shift) then {_handled = true;}; if (_shift && playerSide isEqualTo civilian && !isNull cursorObject && cursorObject isKindOf "Man" && isPlayer cursorObject && alive cursorObject && cursorObject distance player < 4 && speed cursorObject < 1) then { if ((animationState cursorObject) != "Incapacitated" && (currentWeapon player == primaryWeapon player || currentWeapon player == handgunWeapon player) && currentWeapon player != "" && !life_knockout && !(player getVariable ["restrained",false]) && !life_istazed && !life_isknocked) then { cursorObject] spawn life_fnc_knockoutAction; }; }; };
Eskortieren bin ich mir jetzt nicht einmal mehr zu 100% sicher... aber der Rest auf jeden Fall. -
Korrigiere mich wenn ich falsch liege, aber ist das nicht Standard?
-
Syntax Highlighting: http://www.armaholic.com/page.php?id=8680
Das macht dir den ganzen Kram schön bunt und lesbar
-
Am besten weißt du wie ein Script auszusehen hat und wie der Syntax ist - dann sollte das ganze kein Problem für dich sein das aus einer in mehrere Zeilen zu schreiben

-
kein Ding für den King

-
@GamerTV ich hab dir das ganze mal eben korrigiert...
C
Alles anzeigen//shift+c pioche 4.0 4.3 4.4 case 46: { if(_shift && (!life_action_inUse) && (vehicle player == player) ) then { _item = ""; { if(typeName _x == typeName "") then {_item = _x;} else {_item = configName _x}; _val = ITEM_VALUE(_item); if(_val > 0 ) then { if( _item == "pickaxe" ) then { [] spawn life_fnc_pickAxeUse; }; }; } foreach ("true" configClasses (missionConfigFile >> "VirtualItems")); }; }; -
Alles anzeigen
//shift+c pioche 4.0 4.3 4.4//shift+c pioche 4.0 4.3 4.4
case 46:case 46:
{ {
if(_shift && (!life_action_inUse) && (vehicle player == player) ) thenif(_shift && (!life_action_inUse) && (vehicle player == player) ) then
{{
_item = "";= "";
{{
if(typeName _x == typeName "") then {_item = _x;} else {_item = configName _x};if(typeName _x == typeName "") then {_item = _x;} else {_item = configName _x};
_val = ITEM_VALUE(_item);= ITEM_VALUE(_item);
if(_val > 0 ) thenif(_val > 0 ) then
{{
if( _item == "pickaxe" ) thenif( _item == "pickaxe" ) then
{{
[] spawn life_fnc_pickAxeUse;[] spawn life_fnc_pickAxeUse;
};};
};};
} foreach ("true" configClasses (missionConfigFile >> "VirtualItems"));} foreach ("true" configClasses (missionConfigFile >> "VirtualItems"));
}}
};};
sicher das das richtig ist? sieht sehr falsch aus... überprüf das ganze nochmal bitte! -
Um die KI zu deaktivieren, setzte folgende Zeile in deine description.ext:
disabledAI = 1; -
Hey, du kannst das ganze auch in einen Dialog auslagern und ersparst dir so die zusätzlichen Items:
[RELEASE] Cops\Medics Barrier Placeables - Road cone/barrier placement [Dialogs] - Any - Altis Life RPGlife_bar_limit ist dabei die Variable die angibt, wie viele Objekte pro Person maximal gesetzt werden können (weniger Objekte = weniger benötigte Rechenleistung)
-
Hey Leute, ich bin grade ein bisschen am Verzweifeln und ich finde den Fehler nicht...
Ich wollte eigentlich nur einen Dialog zum Kaufen/Verkaufen von Lizenzen einfügen und stehe grade etwas auf dem Schlauch... soweit ist alles auf 4.4 umgeschrieben, nur der Dialog macht Probleme. Client RPT spuckt aus:ZitatAlles anzeigen14:49:46 Error loading control mpmissions\__CUR_MP.[lexicon]Tanoa[/lexicon]\http://description.ext/LicenseShop/co…itleBackground/
14:49:46 Error loading control mpmissions\__CUR_MP.[lexicon]Tanoa[/lexicon]\http://description.ext/LicenseShop/controls/Mainbackground/
14:49:46 Error loading control mpmissions\__CUR_MP.[lexicon]Tanoa[/lexicon]\http://description.ext/LicenseShop/controls/listbox/
14:49:46 Error loading control mpmissions\__CUR_MP.[lexicon]Tanoa[/lexicon]\http://description.ext/LicenseShop/co…icenseslistbox/
14:49:46 Error loading control mpmissions\__CUR_MP.[lexicon]Tanoa[/lexicon]\http://description.ext/LicenseShop/controls/MyLicenses/
14:49:46 Error loading control mpmissions\__CUR_MP.[lexicon]Tanoa[/lexicon]\http://description.ext/LicenseShop/controls/ShowLicenses/
14:49:46 Error loading control mpmissions\__CUR_MP.[lexicon]Tanoa[/lexicon]\http://description.ext/LicenseShop/controls/buybutton/
14:49:46 Error loading control mpmissions\__CUR_MP.[lexicon]Tanoa[/lexicon]\http://description.ext/LicenseShop/controls/sellButton/Hier die besagte LicenseDialog.hpp mit der Class LicenseShop:
C: LicenseDialog.hpp
Alles anzeigenclass LicenseShop { idd = 5546; name= "life_license_shop"; movingEnable = false; enableSimulation = true; onLoad = "uiNamespace setVariable [""LicenseShop"", _this select 0];"; objects[] = { }; class controls { class RscTitleBackground: Life_RscText { idc = -1; text = "Lizenzen"; //--- ToDo: Localize; x = 4 * GUI_GRID_W + GUI_GRID_X; y = 5 * GUI_GRID_H + GUI_GRID_Y; w = 31 * GUI_GRID_W; h = 1 * GUI_GRID_H; colorBackground[] = {0.18,0.604,0.996,1}; }; class Mainbackground: Life_RscText { idc = -1; x = 4 * GUI_GRID_W + GUI_GRID_X; y = 6.1 * GUI_GRID_H + GUI_GRID_Y; w = 31 * GUI_GRID_W; h = 13 * GUI_GRID_H; colorBackground[] = {0,0,0,0.7}; }; class listbox: Life_RscListBox { idc = 55126; sizeEx = 0.035; x = 4.5 * GUI_GRID_W + GUI_GRID_X; y = 7.5 * GUI_GRID_H + GUI_GRID_Y; w = 12.5 * GUI_GRID_W; h = 10 * GUI_GRID_H; }; class ShowLicenseslistbox: Life_RscListBox { idc = 55131; sizeEx = 0.035; x = 22 * GUI_GRID_W + GUI_GRID_X; y = 7.5 * GUI_GRID_H + GUI_GRID_Y; w = 12.5 * GUI_GRID_W; h = 10 * GUI_GRID_H; }; class MyLicenses: Life_RscText { idc = 55130; text = "Zum Kauf"; //--- ToDo: Localize; x = 7.5 * GUI_GRID_W + GUI_GRID_X; y = 6 * GUI_GRID_H + GUI_GRID_Y; w = 5.5 * GUI_GRID_W; h = 1 * GUI_GRID_H; }; class ShowLicenses: Life_RscText { idc = 55129; text = "Lizenzen"; //--- ToDo: Localize; x = 26 * GUI_GRID_W + GUI_GRID_X; y = 6 * GUI_GRID_H + GUI_GRID_Y; w = 5.5 * GUI_GRID_W; h = 1 * GUI_GRID_H; }; class buybutton: Life_RscButtonMenu { idc = 55127; action = "if( (lbData[55126,lbCurSel (55126)] != """") ) then { [false, false, false, lbData[55126,lbCurSel (55126)]] call life_fnc_buyLicense; closeDialog 0; };"; text = "Kaufen"; //--- ToDo: Localize; x = 14 * GUI_GRID_W + GUI_GRID_X; y = 18 * GUI_GRID_H + GUI_GRID_Y; w = 6 * GUI_GRID_W; h = 1 * GUI_GRID_H; colorText[] = {1,1,1,1}; colorBackground[] = {0,0,0,0.8}; }; class sellButton: Life_RscButtonMenu { idc = 55128; action = "if( (lbData[55131,lbCurSel (55131)] != """") ) then { [false, false, false, lbData[55131,lbCurSel (55131)]] call life_fnc_sellLicense; closeDialog 0; };"; text = "Verkaufen"; //--- ToDo: Localize; x = 20 * GUI_GRID_W + GUI_GRID_X; y = 18 * GUI_GRID_H + GUI_GRID_Y; w = 6 * GUI_GRID_W; h = 1 * GUI_GRID_H; colorText[] = {1,1,1,1}; colorBackground[] = {0,0,0,0.8}; }; }; };Kann mir da jemand grade mal auf die Sprünge helfen? Ich verzweifel langsam daran

-
Kleine Anmerkung meinerseits, du kannst die Lizenzabfrage auch in die "Config_SpawnPoints.hpp" einbauen:
C: Config_SpawnPoints.hpp
Alles anzeigenclass Civilian { class Asyl { displayName = "Asylheim"; spawnMarker = "civ_spawn_asyl"; icon = "\a3\ui_f\data\map\MapControl\watertower_ca.paa"; licenses[] = { { "asyl", false } }; level[] = { "", "", -1 }; }; class Georgetown { displayName = "Georgetown"; spawnMarker = "civ_spawn_1"; icon = "\a3\ui_f\data\map\MapControl\watertower_ca.paa"; licenses[] = { { "asyl", true } }; level[] = { "", "", -1 }; }; };heißt, im Asylheim kann man nur OHNE die Lizenz "asyl" spawnen, in Georgetown nur mit ihr.
-
Dann schau dir an, wie das ganze in Altis Life geregelt ist und wende das ganze auf das Fahrzeug an innerhalb der Modfiles
-
mach mal aus if (_corpse == true) einfach nur if (_corpse) - da ist ein '=' zu viel und bei true kann das weggelassen werden (ja, ich weiß, hab ich dir so gesagt... hatte da Denkfehler
) -