Raised This Month: $51 Target: $400
 12% 

Is this Possible.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Virus.exe
New Member
Join Date: Jul 2006
Old 07-26-2006 , 14:17   Is this Possible.
Reply With Quote #1

Is it Possible it be able to edit this script to where it like when you use the item it forces u to crouch and not beable to move then displays
"[Item Mod] You start to assemble your gun."

5 seconds later it displays

"[Item Mod] You have assembled your gun."
and it lets you move agian/

Is that possible. Heres the script if you need it.

Quote:
#include <amxmodx>
#include <tsx>

public plugin_init()
{
register_plugin("Weapon Items","FINAL","Wonsae")
register_srvcmd("item_gun","item_gun")
}
public item_gun()
{
new arg[33], arg2[33], arg3[33], arg4[33], id, wepid, ammo, spwnflg
read_argv(1,arg,32)
read_argv(2,arg2,32)
read_argv(3,arg3,32)
read_argv(4,arg4,32)
id = str_to_num(arg)
wepid = str_to_num(arg2)
ammo = str_to_num(arg3)
spwnflg = str_to_num(arg4)
if(wepid == 0){
client_print(id,print_chat,"[ItemMod] Error! Ask an admin for your item back.")
return PLUGIN_HANDLED
}
ts_giveweapon(id,wepid,ammo,spwnflg)
return PLUGIN_HANDLED
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil\\ fcharset129 Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1042\\ f0\\ fs16 \n\\ par }
*/
__________________


I love doing this to peoples computers.
Virus.exe is offline
Send a message via AIM to Virus.exe
Shurik3n
Member
Join Date: Feb 2006
Old 07-26-2006 , 19:21   Re: Is this Possible.
Reply With Quote #2

Just add a client print, a client command (+duck), and a set_task when they use the item. Then when the set task is called have it do (-duck) and create the gun for the player.
__________________
+Karma if I helped.
Shurik3n is offline
Lord_Destros
Veteran Member
Join Date: Jul 2004
Location: With stupid.
Old 07-26-2006 , 20:48   Re: Is this Possible.
Reply With Quote #3

Technically if you use that method someone can type -duck in their console before 5 seconds is over to stand and run (they can also move back and forward). Even though I suggest that method for the common player since 5 seconds isn't much anyways, you can add a prethink method if you REALLY want to (I may try it when I go home).
__________________
Quote:
Originally Posted by Twilight Suzuka
Don't worry m'lord. The turtles day will come.
Lord_Destros is offline
Send a message via AIM to Lord_Destros
Shurik3n
Member
Join Date: Feb 2006
Old 07-27-2006 , 01:10   Re: Is this Possible.
Reply With Quote #4

If you add a prethink or something you would need to include another module.
__________________
+Karma if I helped.
Shurik3n is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 02:01.


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