Hey Leute,
ich habe auf meinen Server ein paar Drogen Effekte eingefügt, die Effecte funktionieren auch aber nach dem Effekt ist das Z-Menü komplett verbuggt. Ich habe keine Fehler in dem Client & Sever Logs.
Hier sind die Drogen Effekte
Code
/*
----------------------------------------------|
Author: Backer
Description: Effekt on heroin use! If you use to much you get naked and spawn on random positions (markers)
----------------------------------------------|
*/
closeDialog 0;
DrugedMarkers = ["druged1","druged2","druged3","druged4","druged5"] call BIS_fnc_selectRandom;
player setVariable["Druged",true,true];
player allowDamage false;
[player,"Heroin_sound", 46] call life_fnc_globalSound;
_posold = getPos player;
if(life_drug > 0) then {
player setPos [getPos player select 0, getPos player select 1, 20000];
"colorCorrections" ppEffectEnable true;
"colorCorrections"
ppEffectAdjust [1, 1, 0, [0,0,0,0.5], [random 5 - random 5,random 5 -
random 5,random 5 - random 5,random 1], [random 5 - random 5,random 5 -
random 5,random 5 - random 5, random 1]];
"colorCorrections" ppEffectCommit 1;
"chromAberration" ppEffectEnable true;
"chromAberration" ppEffectAdjust [0.01,0.01,true];
"chromAberration" ppEffectCommit 1;
sleep 2.25;
for "_i" from 0 to 23 do {
"colorCorrections" ppEffectEnable true;
"colorCorrections" ppEffectAdjust [1, 1, 0, [0,0,0,0.5], [random 10 -
random 10,random 10 - random 10,random 10 - random 10,random 1], [random
10 - random 10,random 10 - random 10,random 10 - random 10, random 1]];
"colorCorrections" ppEffectCommit 1;
sleep 2.25;
};
"chromAberration" ppEffectEnable false;
"colorCorrections" ppEffectEnable false;
hint "Das war vielleicht mal ein Tripp, BUJAHH";
player setPos _posold;
sleep 5;
};
//3 mal nehmen
if (life_drug > 0.22) then {
titleText [localize "STR_MISC_DrunkBlackOut","BLACK OUT"];
player playMoveNow "Incapacitated";
//titleText[localize "STR_MISC_DrunkBlackOut","BLACK IN"];
sleep 15;
vehicle player setDir 225;vehicle player setVelocity [0, 0, 0]; vehicle player setpos (getmarkerpos DrugedMarkers);
publicVariable "DrugedMarkers";
removeUniform player;removeVest player;
player playMoveNow "AinjPpneMstpSnonWrflDnon_rolltoback";
sleep 10;
titleText[localize "STR_MISC_DrunkBlackOut1","PLAIN"];
player playMoveNow "amovppnemstpsraswrfldnon";
};
player setVariable["Druged",false,true];
player allowDamage true;
Alles anzeigen
Code
/*
----------------------------------------------|
Author: Backer
Description: Effekt on Cocaine use!
----------------------------------------------|
*/
closeDialog 0;
player setVariable["Druged",true,true];
//[player,"Cocaine_sound", 54] call life_fnc_globalSound;
"dynamicBlur" ppEffectEnable true; // enables ppeffect
"dynamicBlur" ppEffectAdjust [0]; // enables normal vision
"dynamicBlur" ppEffectCommit 20; // time it takes to normal
20 fadeSound 1; //fades the sound back to normal
player setDamage (0.2 + (damage player));
"dynamicBlur" ppEffectEnable true; // enables ppeffect
"dynamicBlur" ppEffectAdjust [9]; // intensity of blur
"dynamicBlur" ppEffectCommit 3; // time till vision is fully blurred
enableCamShake true; // enables camera shake
addCamShake [20, 100, 10]; // sets shakevalues
player setFatigue 1; // sets the fatigue to 100%
5 fadeSound 0.1; // fades the sound to 10% in 5 seconds
sleep 50;
"dynamicBlur" ppEffectEnable true; // enables ppeffect
"dynamicBlur" ppEffectAdjust [0]; // enables normal vision
"dynamicBlur" ppEffectCommit 20; // time it takes to normal
20 fadeSound 1; //fades the sound back to normal
player setVariable["Druged",false,true];
Alles anzeigen
Code
/*
----------------------------------------------|
Author: ??? edit by Backer
Description: Effekt on Weed use!
----------------------------------------------|
*/
closeDialog 0;
player setVariable["Druged",true,true];
//[player,"Weed_sound", 31] call life_fnc_globalSound;
_smoke = "SmokeShell" createVehicle position player;
if (vehicle player != player) then {
_smoke attachTo [vehicle player, [-0.6,-1,0]];
} else {
_smoke attachTo [player, [0,0,1]];
};
"chromAberration" ppEffectEnable true;
"radialBlur" ppEffectEnable true;
enableCamShake true;
for "_i" from 0 to 30 do
{
if(life_drug > 0) then {
"chromAberration" ppEffectAdjust [random 0.25,random 0.25,true];
"chromAberration" ppEffectCommit 1;
"radialBlur" ppEffectAdjust [random 0.02,random 0.02,0.15,0.15];
"radialBlur" ppEffectCommit 1;
addcamShake[random 3, 1, random 3];
sleep 1;
};
};
"chromAberration" ppEffectAdjust [0,0,true];
"chromAberration" ppEffectCommit 5;
"radialBlur" ppEffectAdjust [0,0,0,0];
"radialBlur" ppEffectCommit 5;
sleep 6;
"chromAberration" ppEffectEnable false;
"radialBlur" ppEffectEnable false;
resetCamShake;
enableCamShake false;
deleteVehicle _smoke;
player setVariable["Druged",false,true];
Alles anzeigen
Mfg
AmaZiinG