Raised This Month: $ Target: $400
 0% 

[req fix,idea]simple short code


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
kileedyg
BANNED
Join Date: Dec 2008
Location: Lithuania
Old 04-20-2012 , 05:22   [req fix,idea]simple short code
Reply With Quote #1

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#define adminas ADMIN_KICK
#define seimininkas ADMIN_IMMUNITY
public plugin_init() {
 
register_plugin("whatever","whatever","noone")
 
register_event("HLTV""event_new_round""a""1=0""2=0")
 
register_dictionary("whatever.txt")
 
register_clcmd("say /t""t")
 
register_clcmd("say_team /t""t")
 
register_clcmd("say /ct""ct")
 
register_clcmd("say_team /ct""ct")
 
register_clcmd("say /s""s")
 
register_clcmd("say_team /s""s")
}
public 
event_new_round(id) {
if (
is_user_alive(id)&&get_user_flags(id)&adminas)  
 
client_print(0,print_chat,"%L",LANG_PLAYER,"INFO_ADMIN"// noredamas stebeti pazeidejus rasyk /s
if (is_user_alive(id)&&get_user_flags(id)&seimininkas
 
client_print(0,print_chat,"%L",LANG_PLAYER,"INFO_SEIMINKAS"// //Noredamas pakeisti komanda naudokis /ct jei nori grysti i CT /t jei nori grytsi i T naudokis  /s jei vel nori tapti ziurovu
}
public 
t(id) {
    if(
cs_get_user_team(id) == CS_TEAM_T)
    else if 
seimininkas
    client_print
(id,print_chat,"%L",LANG_PLAYER,"JAU_ESI_T"); // tu jau esi t
    
else 
{
    if(!
is_user_alive(id))
    
cs_set_user_team(id,CS_TEAM_T);
}
    else 
{
    
client_cmd(id,"kill")
    
cs_set_user_team(id,CS_TEAM_T);

}
public 
ct(id) {
    if(
cs_get_user_team(id) == CS_TEAM_CT)
    else if 
seimininkas
    client_print
(id,print_chat,"%L",LANG_PLAYER,"JAU_ESI_CT");  // tu jau esi ct
    
else 
{
        if(!
is_user_alive(id))
        
cs_set_user_team(id,CS_TEAM_CT);
}
    else 
{
        
client_cmd(id,"kill")
        
cs_set_user_team(id,CS_TEAM_CT);
    
}
public 
s(id) {
    if(!
is_user_alive(id))
    else if 
adminas
    cs_set_user_team
(id,CS_TEAM_CT);
    else 
{
    
client_cmd(id,"kill")
    
cs_set_user_team(id,CS_TEAM_SPECTATOR);
}
    else 
client_print(id,print_chat,"%L",LANG_PLAYER,"INFO"); //Noredamas pakeisti komanda naudokis /ct jei nori grysti i CT /t jei nori grytsi i T naudokis  /s jei vel nori tapti ziurovu
}
 
 return 
0;

Can someone fix it please, and one more thing is it possible to respawn using command /t,/ct user defined as adminas only in new round, and leave respawn anytime for user defined as seimininkas?
thankies fellows ,also is it possible to make,example:
PHP Code:
client_print(id,print_chat,"%L %s %L",LANG_PLAYER,seconds,LANG_PLAYER,"Y_W_B_K","seconds")// Text look like -  You will be kicked in %s seconds 
I mean multiple multilang,please give me example

Last edited by kileedyg; 04-20-2012 at 05:35. Reason: another fixez
kileedyg is offline
Send a message via Skype™ to kileedyg
 



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:40.


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