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

Updated plugin #349

Merged
merged 3 commits into from Sep 25, 2017

Conversation

Projects
None yet
3 participants
@CrazyHackGUT
Copy link
Contributor

CrazyHackGUT commented Aug 27, 2017

Description

  • Fixed bug when HackingReason menu not cleaned when config reads from scratch.
  • Moved available time lengths to config
  • Small optimize (FormatEx() works faster than Format())

Motivation and Context

Items in the HackingReasonMenu duplicates in menu when plugin rereads the configuration file again.
Also, time length for bans has been hardcoded in the code.

My pull fixes duplicating Hacking Reasons in menu, and adds into config section for Time Bans.

How Has This Been Tested?

I installed plugin on the server. reload him, edit ban time length in config, and reload config. All changes were displayed into game without problems. And hacking reasons not duplicated.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.

CrazyHackGUT added some commits Aug 27, 2017

Updated plugin
- Fixed bug when HackingReason menu not cleaned when config reads from scratch.
- Moved available time lengths to config
- Small optimize (FormatEx() works faster than Format())
}
} else if (strcmp("BanTime", name, false) == 0) {
ConfigState = ConfigStateTime;
}

This comment has been minimized.

@Bara

Bara Aug 27, 2017

Contributor

+Line 2107 same mistake with "tabulation"

This comment has been minimized.

@CrazyHackGUT

CrazyHackGUT Aug 27, 2017

Contributor

Thanks. Fixed.

@@ -738,7 +746,7 @@ public AdminMenu_Ban(Handle:topmenu,
// We are only being displayed, We only need to show the option name
case TopMenuAction_DisplayOption:
{
Format(buffer, maxlength, "%T", "Ban player", param);
FormatEx(buffer, maxlength, "%T", "Ban player", param);

This comment has been minimized.

@CrazyHackGUT

CrazyHackGUT Aug 27, 2017

Contributor

Problems with security in the plugin SourceBans, never was. Or I did not hear about them.

@Groruk Groruk merged commit 3e6a247 into sbpp:v1.x Sep 25, 2017

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment