Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Release Anti Hitmarkers
#1
Hi everyone!

At first sorry for my bad english, i'm swiss.
I would like to release this little plugin i made for my server.
I made it because i hate hitmarkers with the snipers Angel
You can set a list of weapons that will never do hitmarkers, it will always kill the victim.

Add those lines to the sv_config.ini:
Code:
[AntiHitMarkers]
Enabled=1
// 0 or 1
Weapon_list=iw5_msr iw5_l96a1
// Weapons list separated by 1 space

Plugin Csharp source code:
CSHARP Code
  1. using System;
  2.  
  3. using Addon;
  4.  
  5. namespace AntiHitMarkers
  6. {
  7. public class AntiHitMarkers : CPlugin
  8. {
  9. // List of weapons without hitmarkers
  10. private string[] weapon_list;
  11. // Status of the plugin
  12. private string enabled = "0";
  13.  
  14. public override void OnServerLoad()
  15. {
  16. // Get the status of the plugin
  17. enabled = GetServerCFG("AntiHitMarkers", "Enabled", "no_weapon");
  18.  
  19. // If the plugin is enabled
  20. if (enabled == "1")
  21. {
  22. // Get the list of antihitmarkers weapons
  23. string get_weapon_list = GetServerCFG("AntiHitMarkers", "Weapon_list", "no_weapon");
  24. // Split the list by spaces to get an array
  25. weapon_list = get_weapon_list.Split(' ');
  26. }
  27.  
  28. // Print plugin loaded
  29. ServerPrint("Plugin AntiHitMarkers loaded! (enabled => " + enabled + ")");
  30. }
  31.  
  32. public override int OnPlayerDamaged(ServerClient Attacker, ServerClient Victim, String Weapon, int Damage)
  33. {
  34. // If the plugin is enabled
  35. if (enabled == "1")
  36. {
  37. // Loop the weapons list
  38. foreach (string weapon_name in weapon_list)
  39. {
  40. // Control if the weapon is in the weapons list
  41. if (Weapon.Contains(weapon_name))
  42. {
  43. // If damage is lower than the victim's health
  44. if (Damage < Victim.Other.Health)
  45. {
  46. // Set the damage equal to the victim's health
  47. Damage = Victim.Other.Health;
  48. }
  49. // Stop the foreach
  50. break;
  51. }
  52. }
  53. }
  54. // Return the final damage
  55. return Damage;
  56. }
  57. }
  58. }


I'm open for every suggestions or comments.
Have Fun!


Attached Files
.zip   AntiHitMarkers.zip (Size: 2.07 KB / Downloads: 114)
Reply

#2
Really good release indeed. I myself actually like hitmarkers, but for people searching for real hardcore this might be VERY helpful. GJ Awesome
[Image: r212360a129ce9b84444093b6cd2699013a1fbn155.png]
Reply

#3
So instead of preventing any random bullet spam because people see hitmarkers you reward them with insta kill on those weapons? Well, if you like it, you may install that on your server.
Reply

#4
Those weapons will become OP as shit.
Just sayin'
Reply

#5
this does give me an idea for an instagib mod Big Grin
Had a life, Got a modem..
Reply

#6
Hey,

thanks for this plugin by the way.
Its quite useful on a sniperserver but we've encourtered a bug.
At 15000 points at Team Deathmatch, the round wont end, this happens very very rarely (every 40th round?).
Nobody is making damage until you start another map, then everything is working fine again.

Cheers.

EDIT: Sorry, this plugin wasnt the reason of this bug.
[Image: epvp71up3.png]
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  [Release] iSnipe anti hardscope mutant 0 3,271 11-06-2013, 11:27
Last Post: mutant
  Need An Anti Hack Manuadminmod worldclass 2 3,513 10-14-2013, 09:57
Last Post: d0h!
  Searching for Anti HS ExoGamer* 10 6,170 08-08-2013, 12:39
Last Post: aceed
  [Release] Anti-Invisible Name master131 24 20,106 05-02-2013, 14:15
Last Post: .sepultura.
Wink Preview ANTI ZOOMBYE! [HARD] Tony. 9 5,700 03-02-2013, 17:35
Last Post: Nukem
  [Request] MW3 anti TI smasher MADD_DOGG 3 3,008 12-17-2012, 13:52
Last Post: MADD_DOGG
  Mw3 anti-cheat estebespt 18 14,987 12-04-2012, 22:50
Last Post: claudiocorona
  anti-hack ersin_ 8 5,819 10-29-2012, 14:45
Last Post: SuperNovaAO
  [Request] Anti block Plugin | Infected Kasperle 2 2,741 10-06-2012, 18:41
Last Post: DidUknowiPwn
  [Tutorial] Anti-Lag Guide iPaddie 5 4,846 09-28-2012, 18:56
Last Post: JariZ

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.