
Postanowiłem trochę przerobić skrypt:
Pytania mam 3:
- czasem helikopter wybucha, czasem elegancko upada - i jest zdatny do użytku (silnik nie startuje, ale działko działa :P). Czy tak powinno być? (Przepraszam za lamerskie pytanie :()
- jak zrobić, aby helikopter rzadziej wybuchał? Gdzie zmienić dane?
- które linijki mogę wyeliminować? Skrypt wziąłem z add-on'u ah64d, więc był trochę rozporcjowany...
Z góry dziękuję za odpowiedź.
_ah64d = _this select 0
#loop
~0.001
_amountdamage=getdammage _ah64d
?(_amountdamage<= 0.1): goto "quit"
?(_amountdamage>= 0.25 and _amountdamage<= 0.5): goto "randomMARG"
?(_amountdamage>= 0.5 and _amountdamage<= 0.75): goto "randomFAIL"
?(_amountdamage>= 0.75): goto "randomFIRE"
#randomMARG
_num = random 10
?(_num < 1) : _ah64d setobjecttexture [62, "\fz_ah64d\tex\ah64mfdsts.paa"] and goto "quit"
?(_num < 2) : _ah64d setobjecttexture [64, "\fz_ah64d\tex\ah64mfdsts.paa"] and [_ah64d] exec "\fz_ah64d\scripting\lemarg.sqs" and goto "quit"
?(_num < 3) : _ah64d setobjecttexture [66, "\fz_ah64d\tex\ah64mfdsts.paa"] and [_ah64d] exec "\fz_ah64d\scripting\remarg.sqs" and goto "quit"
?(_num < 4) : _ah64d setobjecttexture [68, "\fz_ah64d\tex\ah64mfdsts.paa"] and [_ah64d] exec "\fz_ah64d\scripting\rtrmarg.sqs" and goto "quit"
?(_num < 5) : _ah64d setobjecttexture [70, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d vehiclechat "Tail Rotor Damaged" and [_ah64d] exec "\fz_ah64d\scripting\trmarg.sqs" and goto "quit"
?(_num < 6) : _ah64d setobjecttexture [72, "\fz_ah64d\tex\ah64mfdsts.paa"] and goto "quit"
?(_num < 7) : _ah64d setobjecttexture [74, "\fz_ah64d\tex\ah64mfdsts.paa"] and goto "quit"
?(_num < 8) : _ah64d setobjecttexture [76, "\fz_ah64d\tex\ah64mfdsts.paa"] and goto "quit"
?(_num < 9) : _ah64d setobjecttexture [78, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d vehiclechat "Oil pressure high" and goto "quit"
?(_num < 10) : _ah64d setobjecttexture [80, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d vehiclechat "Hydraulic pressure high" and goto "quit"
goto "quit"
#randomFAIL
_num = random 10
?(_num < 1) : _ah64d setobjecttexture [61, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [62, ""] and goto "quit"
?(_num < 2) : _ah64d setobjecttexture [63, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [64, ""] and [_ah64d] exec "\fz_ah64d\scripting\lefail.sqs" and _ah64d vehiclechat "Left Engine Failure" and goto "quit"
?(_num < 3) : _ah64d setobjecttexture [65, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [66, ""] and [_ah64d] exec "\fz_ah64d\scripting\refail.sqs" and _ah64d vehiclechat "Right Engine Failure" and goto "quit"
?(_num < 4) : _ah64d setobjecttexture [67, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [68, ""] and _ah64d vehiclechat "Rotor Failure" and _ah64d setfuel 0 and goto "quit"
?(_num < 5) : _ah64d setobjecttexture [69, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [70, ""] and _ah64d vehiclechat "Tail Rotor Failure" and [_ah64d] exec "\fz_ah64d\scripting\trfail.sqs" and goto "quit"
?(_num < 6) : _ah64d setobjecttexture [71, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [72, ""] and [_ah64d] exec "\fz_ah64d\scripting\hpdmg.sqs" and goto "quit"
?(_num < 7) : _ah64d setobjecttexture [73, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [74, ""] and [_ah64d] exec "\fz_ah64d\scripting\hpdmg.sqs" and goto "quit"
?(_num < 8) : _ah64d setobjecttexture [75, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [76, ""] and _ah64d removeweapon "fz_m230a" and _ah64d vehiclechat "Cannon Failure" and goto "quit"
?(_num < 9) : _ah64d setobjecttexture [77, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [78, ""] and _ah64d vehiclechat "Oil pressure low" and goto "quit"
?(_num < 10) : _ah64d setobjecttexture [79, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [80, ""] and _ah64d vehiclechat "Hydraulic pressure low" and goto "quit"
goto "quit"
#randomFIRE
_num = random 12
?(_num < 1) : _ah64d setobjecttexture [61, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [62, ""] and goto "quit"
?(_num < 2) : _ah64d setobjecttexture [63, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [64, ""] and [_ah64d] exec "\fz_ah64d\scripting\lefail.sqs" and _ah64d vehiclechat "Left Engine Failure" and goto "quit"
?(_num < 3) : _ah64d setobjecttexture [65, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [66, ""] and [_ah64d] exec "\fz_ah64d\scripting\refail.sqs" and _ah64d vehiclechat "Right Engine Failure" and goto "quit"
?(_num < 4) : _ah64d setobjecttexture [67, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [68, ""] and _ah64d vehiclechat "Rotor Failure" and _ah64d setfuel 0 and goto "quit"
?(_num < 5) : _ah64d setobjecttexture [69, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [70, ""] and _ah64d vehiclechat "Tail Rotor Failure" and [_ah64d] exec "\fz_ah64d\scripting\trfail.sqs" and goto "quit"
?(_num < 6) : _ah64d setobjecttexture [71, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [72, ""] and [_ah64d] exec "\fz_ah64d\scripting\hpdmg.sqs" and goto "quit"
?(_num < 7) : _ah64d setobjecttexture [73, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [74, ""] and [_ah64d] exec "\fz_ah64d\scripting\hpdmg.sqs" and goto "quit"
?(_num < 8) : _ah64d setobjecttexture [75, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [76, ""] and _ah64d removeweapon "fz_m230a" and _ah64d vehiclechat "Cannon Failure" and goto "quit"
?(_num < 9) : _ah64d setobjecttexture [77, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [78, ""] and _ah64d vehiclechat "Oil pressure low" and goto "quit"
?(_num < 10) : _ah64d setobjecttexture [79, "\fz_ah64d\tex\ah64mfdsts.paa"] and _ah64d setobjecttexture [80, ""] and _ah64d vehiclechat "Hydraulic pressure low" and goto "quit"
?(_num < 11) : [_ah64d] exec "\fz_ah64d\scripting\lefire.sqs" and goto "quit"
?(_num < 12) : [_ah64d] exec "\fz_ah64d\scripting\refire.sqs" and goto "quit"
goto "quit"
#quit
exit
Pytania mam 3:
- czasem helikopter wybucha, czasem elegancko upada - i jest zdatny do użytku (silnik nie startuje, ale działko działa :P). Czy tak powinno być? (Przepraszam za lamerskie pytanie :()
- jak zrobić, aby helikopter rzadziej wybuchał? Gdzie zmienić dane?
- które linijki mogę wyeliminować? Skrypt wziąłem z add-on'u ah64d, więc był trochę rozporcjowany...
Z góry dziękuję za odpowiedź.