Skip to content
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 RPT issue in PFH main Loop #171

Merged
merged 3 commits into from
Oct 10, 2015
Merged

Fix RPT issue in PFH main Loop #171

merged 3 commits into from
Oct 10, 2015

Conversation

jokoho48
Copy link
Member

@jokoho48 jokoho48 commented Oct 9, 2015

No description provided.

@@ -26,7 +26,9 @@ Author:

params ["_publicHandle"];
private "_handle";
if (isNil "_publicHandle" || (_publicHandle < 0)) exitWith {}; // Nil/no handle, nil action
if ((isNil "_publicHandle" || (_publicHandle < 0)) && {(count GVAR(PFHhandles)) < _publicHandle}) exitWith { // Nil/no handle, nil action or handle is larger than Public Handle Array
WARNING("PFH ID allready Removed or handle Not Exist or handle is smaller than 0");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PFH ID already removed or handle does not exist or handle is smaller than 0

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd go with Invalid or not existing PFH ID.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's even better.

@jokoho48
Copy link
Member Author

ok i and @jonpas tested it no issues found

@jonpas
Copy link
Member

jonpas commented Oct 10, 2015

👍

@ViperMaul ViperMaul added this to the 2.1 milestone Oct 10, 2015
ViperMaul added a commit that referenced this pull request Oct 10, 2015
fix RTP issue in PFH main Loop
@ViperMaul ViperMaul merged commit 7a2a3f3 into CBATeam:master Oct 10, 2015
@@ -25,8 +25,12 @@ Author:
#include "script_component.hpp"

params ["_publicHandle"];

if (isNil "_publicHandle" || {(_publicHandle < 0)} || {!((count GVAR(PFHhandles)) >= _publicHandle)}) exitWith { // Nil/no handle, nil action or handle is larger than Public Handle Array
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be {(count GVAR(PFHhandles) <= _publicHandle)}?

If the count is 0, and the _publicHandle is 0, you want it to be true and exit.

@ViperMaul
Copy link
Contributor

@PabstMirror @jokoho48
Let's make a new pull request and make that change. This PR is already merged.

@ViperMaul ViperMaul modified the milestones: 2.1.1, 2.1 Oct 10, 2015
@ViperMaul ViperMaul changed the title fix RTP issue in PFH main Loop Fix RPT issue in PFH main Loop Oct 11, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants