Raised This Month: $ Target: $400
 0% 

Help me please


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
M E R T
Junior Member
Join Date: Jan 2019
Old 01-23-2019 , 11:40   Help me please
Reply With Quote #1

Hello guys please help me..
my have redbull.sma

how to hide say /redbull ??

example: /redbull working, but say how to hidden?

how to add return PLUGIN_HANDLED ?? help me please??
M E R T is offline
deprale
Senior Member
Join Date: Oct 2018
Location: Leeds
Old 01-23-2019 , 11:48   Re: Help me please
Reply With Quote #2

Sourcecode? Hello?
__________________
deprale is offline
M E R T
Junior Member
Join Date: Jan 2019
Old 01-23-2019 , 11:53   Re: Help me please
Reply With Quote #3

/*
* _______ _ _ __ __
* | _____/ | | | | \ \ __ / /
* | | | | | | | | / \ | |
* | | | |____| | | |/ __ \| |
* | | ___ | ______ | | / \ |
* | | |_ | | | | | | / \ |
* | | | | | | | | | | | |
* | |____| | | | | | | | | |
* |_______/ |_| |_| \_/ \_/
*
*
*
* Last Edited: 12-31-07
*
* ============
* Changelog:
* ============
*
* v2.0
* -Added ML
* -Optimized Code
*
* v1.0
* -Initial Release
*
*/

#define VERSION "2.0"

#include <amxmodx>
#include <amxmisc>
#include <fun>
#include <cstrike>

new bool:has_rb[33]
new cost_cvar, lasts_cvar, speed_cvar

public plugin_init()
{
register_plugin("Red Bull",VERSION,"GHW_Chronic")

register_clcmd("say /redbull","say_cmd_handle")
register_clcmd("say_team /redbull","say_cmd_handle")

cost_cvar = register_cvar("RB_Cost","1")
lasts_cvar = register_cvar("RB_Lasts","20.0")
speed_cvar = register_cvar("RB_Speed","999.0")

register_event("CurWeapon","curweap","be")

register_dictionary("GHW_Red_Bull.txt")
}

public curweap(id)
{
if(is_user_alive(id) && has_rb[id])
{
client_cmd(id,"cl_forwardspeed 400;cl_backspeed 400;cl_sidespeed 400")
set_user_maxspeed(id,get_pcvar_float(speed_cv ar))
}
}

public client_connect(id) has_rb[id]=false
public client_disconnect(id) has_rb[id]=false

public say_cmd_handle(id)
{
if(!is_user_alive(id))
{
client_print(id,print_chat,"[RB] %L",id,"MSG_NOBUY_DEAD")
}
else if(has_rb[id])
{
client_print(id,print_chat,"[RB] %L",id,"MSG_NOBUY_HAVE")
}
else if(cs_get_user_money(id)<get_pcvar_num(cost_c var))
{
client_print(id,print_chat,"[RB] %L",id,"MSG_NOBUY_POOR",get_pcvar_num(cost_cv ar))
}
else
{
cs_set_user_money(id,cs_get_user_money(id) - get_pcvar_num(cost_cvar),1)
has_rb[id]=true
set_task(get_pcvar_float(lasts_cvar),"redbull _over",id)
set_task(1.0,"plus_hp",id,"",0,"b")
set_user_gravity(id,0.5)
set_user_maxspeed(id,get_pcvar_float(speed_cv ar))
client_print(id,print_chat,"[RB] %L",id,"MSG_REDBULL1")
client_print(id,print_chat,"[RB] %L",id,"MSG_REDBULL2")
}
}

public plus_hp(id)
{
if(has_rb[id]) set_user_health(id,get_user_health(id)+1)
}

public redbull_over(id)
{
if(is_user_connected(id))
{
has_rb[id]=false
client_print(id,print_chat,"[RB] %L",id,"MSG_REDBULL_OFF")
set_user_gravity(id,1.0)
set_user_maxspeed(id,320.0)
set_user_gravity(id,1.0)
remove_task(id)
}
}
M E R T is offline
CrazY.
Veteran Member
Join Date: May 2015
Location: SP, Brazil
Old 01-23-2019 , 12:37   Re: Help me please
Reply With Quote #4

Put your code between php in order improve its readability.

Quote:
how to add return PLUGIN_HANDLED ?? help me please??
Your question doesn't make any sense to me, you yourself found the solution.

Anyway
Attached Files
File Type: sma Get Plugin or Get Source (redbull.sma - 218 views - 1.9 KB)
__________________









Last edited by CrazY.; 01-23-2019 at 12:38.
CrazY. is offline
M E R T
Junior Member
Join Date: Jan 2019
Old 01-23-2019 , 12:50   Re: Help me please
Reply With Quote #5

thank you very much. Thank you ♥
M E R T is offline
thEsp
BANNED
Join Date: Aug 2017
Old 01-30-2019 , 11:19   Re: Help me please
Reply With Quote #6

You really need to learn English as soon as possible ! Otherwise you'll stay where you are.
thEsp 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 07:34.


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