安装 Steam
登录
|
语言
繁體中文(繁体中文)
日本語(日语)
한국어(韩语)
ไทย(泰语)
български(保加利亚语)
Čeština(捷克语)
Dansk(丹麦语)
Deutsch(德语)
English(英语)
Español-España(西班牙语 - 西班牙)
Español - Latinoamérica(西班牙语 - 拉丁美洲)
Ελληνικά(希腊语)
Français(法语)
Italiano(意大利语)
Bahasa Indonesia(印度尼西亚语)
Magyar(匈牙利语)
Nederlands(荷兰语)
Norsk(挪威语)
Polski(波兰语)
Português(葡萄牙语 - 葡萄牙)
Português-Brasil(葡萄牙语 - 巴西)
Română(罗马尼亚语)
Русский(俄语)
Suomi(芬兰语)
Svenska(瑞典语)
Türkçe(土耳其语)
Tiếng Việt(越南语)
Українська(乌克兰语)
报告翻译问题
I never thought that much about the performance... Thanks for reminding me!
nice mod! I would like to contribute by suggesting some more code optimization:
Since you're using CBA, you can filter out unwanted classes from your XEH. Moreover, I would switch to a "initPost" XEH in the case there are other "HandleDamage" kind EHs applied somewhere (because only the last one returns the damage to apply).
This should work and prevent parachutes to show your custom effects. Please note that the form "addEventHandler ["type", {call myFunction}]" is faster than "addEventHandler ["type", {all my code here}]" and that I assume you implemented functions as suggested above (an alternative could be building your mod by following a CBA template so that your functions would be compiled at their manner).
Going on, when you set your "state" variable you should make its value public by setting the third parameter of setVariable as true (or again with CBA by using CBA_fnc_setVarNet). At the moment you set the variable where the aircraft is local and if there is a pilot change your variable would not exist for the new pilot causing the aircraft to potentially take more damage than the set treshold!
Lastly, you should set a default value when you use getVariable (private _state = _unit getVariable ["FSCL_state", 0];) and you should NOT remoteExec call or spawn since they could be blocked by battleye filters. Instead remoteExec a function (remoteExec is already scheduled when calling for functions, so suspension is allowed as for spawn).
Please consider adding your mod to github even if small in code amount :)
thank you!
'x\fscl\addons\main\functions\script_component.hpp' not found.
I fixed it by copying the script_component.hpp file into the functions folder. However I still receive an error about a misisng file called "XEH_preStart.sqf"