Day of Defeat Plugins Community
This site is an archive — everything is readable and downloadable, nothing can be posted. Admin

dod_blockexploits10x

by Unknown · 2005-09-30

recovered from the server

From the first post

Recovered from the archived server. This was never posted on the forum, so there is no thread behind it and no author post to quote — the attribution below comes from the plugin's own register_plugin() call where it has one.

Files

dod_blockexploits10x_601.amxx Compiled Plugin 6 KB Download

Decompiled source reconstructed

dod_blockexploits10x_601.amxx was published compiled only. This Pawn was recovered from the bytecode with Lysis — 214 lines. Strings, cvars and the plugin registration survive; local variable names do not. It is an approximation, not the author's file.

// Decompiled from dod_blockexploits10x_601.amxx by Lysis.n// This is RECONSTRUCTED source, not the author's original: withoutn// debug symbols the variable names are lost and control flow isn// rebuilt from bytecode. Treat it as a readable approximation.nnnew g_var108;npublic allow_teamchange(_arg0)n{n	if (0[_arg0] == 1)n	{n		0[_arg0] = 0;n	}n	return 1;n}nnpublic block_alliesrejoin(_arg0)n{n	new var1;n	if (132[_arg0] == 1 && 0[_arg0] == 1)n	{n		if (is_user_bot(_arg0) == 0)n		{n			if (get_cvar_num("dod_blockexploits_log") == 1)n			{n				268[_arg0] = 1;n				log_hacker(_arg0);n			}n			return 1;n		}n		return 1;n	}n	if (task_exists(_arg0, 0))n	{n		remove_task(_arg0, 0);n	}n	0[_arg0] = 0;n	132[_arg0] = 0;n	return 0;n}nnpublic block_autoassign(_arg0)n{n	if (0[_arg0] == 1)n	{n		return 1;n	}n	return 0;n}nnpublic block_axisrejoin(_arg0)n{n	new var1;n	if (132[_arg0] == 2 && 0[_arg0] == 1)n	{n		if (is_user_bot(_arg0) == 0)n		{n			if (get_cvar_num("dod_blockexploits_log") == 1)n			{n				268[_arg0] = 1;n				log_hacker(_arg0);n			}n			return 1;n		}n		return 1;n	}n	if (task_exists(_arg0, 0))n	{n		remove_task(_arg0, 0);n	}n	0[_arg0] = 0;n	132[_arg0] = 0;n	return 0;n}nnpublic block_mgreload(_arg0)n{n	if (entity_get_int(_arg0, 34) & 8192)n	{n		new var4 = 0;n		new var5;n		var5 = dod_get_user_weapon(_arg0, var4, _unused_temp_);n		new var1;n		if (var5 == 21 && var4 != 75)n		{n			client_cmd(_arg0, "-reload");n			if (is_user_bot(_arg0) == 0)n			{n				if (get_cvar_num("dod_blockexploits_log") == 1)n				{n					268[_arg0] = 2;n					log_hacker(_arg0);n				}n			}n			return 0;n		}n		new var2;n		if (var5 == 17 && var4 != 250)n		{n			client_cmd(_arg0, "-reload");n			if (is_user_bot(_arg0) == 0)n			{n				if (get_cvar_num("dod_blockexploits_log") == 1)n				{n					268[_arg0] = 2;n					log_hacker(_arg0);n				}n			}n			return 0;n		}n		new var3;n		if (var5 == 18 && var4 != 150)n		{n			client_cmd(_arg0, "-reload");n			if (is_user_bot(_arg0) == 0)n			{n				if (get_cvar_num("dod_blockexploits_log") == 1)n				{n					268[_arg0] = 2;n					log_hacker(_arg0);n				}n			}n			return 0;n		}n		return 0;n	}n	return 0;n}nnpublic block_pistolzoom(_arg0)n{n	if (!g_var108)n	{n		return 0;n	}n	message_begin(1, g_var108, 2600, _arg0);n	write_byte(0);n	message_end();n	return 0;n}nnpublic block_timercheat(_arg0)n{n	if (get_cvar_num("mp_allowspectators") == 0)n	{n		return 0;n	}n	if (0[_arg0] == 1)n	{n		return 1;n	}n	132[_arg0] = get_user_team(_arg0, {0}, 0);n	0[_arg0] = 1;n	set_task(1097859072, "allow_teamchange", _arg0, {0}, 0, {0}, 0);n	return 0;n}nnpublic block_whitemodel(_arg0)n{n	if (is_user_bot(_arg0) == 0)n	{n		if (get_cvar_num("dod_blockexploits_log") == 1)n		{n			268[_arg0] = 0;n			log_hacker(_arg0);n		}n		return 1;n	}n	return 1;n}nnpublic client_authorized(_arg0)n{n	client_cmd(_arg0, "firstperson");n	0[_arg0] = 0;n	132[_arg0] = 0;n	return 0;n}nnpublic log_hacker(_arg0)n{n	new var1 = 0;n	new var2 = 0;n	new var3 = 0;n	get_user_name(_arg0, var1, 31);n	get_user_authid(_arg0, var2, 31);n	get_user_ip(_arg0, var3, 31, 1);n	log_to_file("dod_blockexploits.log", "[DoD BlockExploits] %s <%s> <%s> has been caught %s!", var1, var2, var3, 400[268[_arg0]]);n	return 1;n}nnpublic plugin_init()n{n	register_plugin("DoD BlockExploits", "1.5", "[RST] FireStorm");n	register_event("CurWeapon", "block_pistolzoom", 996, "1=0", "2=6", "2=9", "2=25");n	register_event("CurWeapon", "block_mgreload", 1172, "1=1", "2=17", "2=18", "2=21");n	g_var108 = get_user_msgid("SetFOV");n	register_clcmd("cls_mortar", "block_whitemodel", -1, {0});n	register_clcmd("cls_germortar", "block_whitemodel", -1, {0});n	register_clcmd("cls_britmortar", "block_whitemodel", -1, {0});n	register_clcmd("jointeam 1", "block_alliesrejoin", -1, {0});n	register_clcmd("jointeam 2", "block_axisrejoin", -1, {0});n	register_clcmd("jointeam 3", "block_timercheat", -1, {0});n	register_clcmd("jointeam 5", "block_autoassign", -1, {0});n	register_cvar("dod_blockexploits_log", 2196, 0, 0);n	return 0;n}nnpublic plugin_modules()n{n	require_module("dodx");n	require_module("engine");n	return 0;n}nn
DoD Plugins Archive · Repository · Old Forum Threads · Maps · Admin · built 14 Sep 2026 00:34 UTC