-
Notifications
You must be signed in to change notification settings - Fork 737
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix(explosives): Selecting a cellphone as an IEDs trigger would throw an error #5963
Conversation
Btw I broke that private thingy 💃 |
@@ -19,6 +19,9 @@ | |||
params ["_unit"]; | |||
TRACE_1("params",_unit); | |||
|
|||
// close cellphone if open | |||
closeDialog 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
runs on all local units
if (_unit == ace_player) then {
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done, thx
private _codeSet = false; | ||
|
||
while {!_codeSet} do { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alternative:
private _code = "";
while {true} do {
_code = [round(random 9999),4] call EFUNC(common,numberToDigitsString);
if (([_code] call FUNC(getSpeedDialExplosive)) isEqualTo []) exitWith {};
};
… an error (#5963) * move code var to outer scope * run closeDialog only for the player
When merged this pull request will:
_code
var to outer scope, close IED not linkable with cellphone #5808