AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Suggestions / Requests (https://forums.alliedmods.net/forumdisplay.php?f=12)
-   -   Requesting somone to fix 1337 ninja plugin (https://forums.alliedmods.net/showthread.php?t=29782)

Spanky McNutnut 06-12-2006 14:35

Requesting somone to fix 1337 ninja plugin
 
Hello guys, would some one like to fix this plugin, http://forums.alliedmods.net/showthr...t=17304&page=2

The plugin has lost all support on it :-/

I get errors on it at server start,
Code:

L 03/06/2006 - 06:17:30: Function "cmd_speed" was not found
L 03/06/2006 - 06:17:30: [AMXX] Displaying debug trace (plugin "ninja.amxx")
L 03/06/2006 - 06:17:30: [AMXX] Run time error 19: function not found
L 03/06/2006 - 06:17:30: [AMXX]    [0] ninja.sma::plugin_init (line 20)


If you want here is the source code,
Code:
/******************************************************************** *  AMXMOD X script.                                                 * *                                                                   * *  Ninja Mode: Gives the player ninja mode                          * *  By: B0oGeYm4n                                                    * *  Plugin Command: amx_ninja <Target>                               * *  <a href="http://www.freelance-killers.tk" target="_blank" rel="nofollow noopener">http://www.freelance-killers.tk</a>                                  * *                                                                   * ********************************************************************/ #include <amxmodx> #include <amxmisc> #include <fun> #include <engine> public plugin_init() {     register_plugin("amx_ninja","0.2","B0oGeYm4n")     register_clcmd("amx_ninja","ninja",ADMIN_KICK," <name> - user is turned into a 1337 Ninja")     register_event(" CurWeapon", "cmd_speed", "be", "1=1")     set_task(0.1,"fast",0,"",0,"b")       } public plugin_precache() {     precache_model("models/Katana.mdl")     return PLUGIN_CONTINUE } public ninja(id,level,cid) {     if(!cmd_access(id,level,cid,2))     {         return PLUGIN_HANDLED     }     new arg[32]     read_argv(1,arg,31)     new player = cmd_target(id,arg,1)     if (!player)     {         return PLUGIN_HANDLED     }     set_user_health(player,1337)     set_user_maxspeed(player,999.0)     set_user_footsteps(player,1)     set_user_gravity(player,0.2)     set_user_armor(player,1337)     {         new clip, ammo, wpnid = get_user_weapon(id,clip,ammo)         if (wpnid == CSW_KNIFE) {             entity_set_string(id, EV_SZ_viewmodel, "models/Katana.mdl")         }     }     new name[32]     get_user_name(player,name,31)     client_print(0,print_chat,"[AMXX] %s is now a 1337 Ninja",name)     return PLUGIN_HANDLED }

Thanks alot!

Kensai 06-12-2006 15:01

The error is coming from the Event. "cmd_speed" doesn't exist.

Comment it out should work fine.

Spanky McNutnut 06-12-2006 15:12

So,
Code:
public plugin_init() {     register_plugin("amx_ninja","0.2","B0oGeYm4n")     register_clcmd("amx_ninja","ninja",ADMIN_KICK," <name> - user is turned into a 1337 Ninja")     register_event(" CurWeapon", "cmd_speed", "be", "1=1")     set_task(0.1,"fast",0,"",0,"b")       }

To,
Code:
public plugin_init() {     register_plugin("amx_ninja","0.2","B0oGeYm4n")     register_clcmd("amx_ninja","ninja",ADMIN_KICK," <name> - user is turned into a 1337 Ninja")     //register_event(" CurWeapon", "cmd_speed", "be", "1=1")     set_task(0.1,"fast",0,"",0,"b")       }

??

Kensai 06-12-2006 15:17

That's what I said.

:p

Spanky McNutnut 06-12-2006 16:03

:up: Thx ill test it out

Spanky McNutnut 06-12-2006 16:08

Code:

L 06/12/2006 - 13:06:29: [AMXX] Function is not present (function "fast") (plugin "ninja.amxx")
L 06/12/2006 - 13:06:29: [AMXX] Displaying debug trace (plugin "ninja.amxx")
L 06/12/2006 - 13:06:29: [AMXX] Run time error 10: native error (native "set_task")
L 06/12/2006 - 13:06:29: [AMXX]    [0] ninja.sma::plugin_init (line 21)

O_o

Kensai 06-12-2006 16:41

Code:
set_task(0.1, "fast", id, _, _, "b")

jtp10181 06-12-2006 16:42

it seems that you do not have all the code for this pluing, as quite a few functions are missing from it.

Bo0m! 06-12-2006 17:41

Try this, I got bored and fixed stuff up.

Edit: removed attatchment.

Spanky McNutnut 06-12-2006 19:01

Can you make it so immune admins can do it on themselves?

[Edit] You should also put a command to turn it off O_o


All times are GMT -4. The time now is 23:09.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.