Raised This Month: $ Target: $400
 0% 

[Requset] plugin special round


Post New Thread Reply   
 
Thread Tools Display Modes
arvEL.
Senior Member
Join Date: Dec 2014
Location: Iraq
Old 01-18-2015 , 14:24   Re: [Requset] plugin special round
Reply With Quote #11

Quote:
Originally Posted by Eviatar Mor View Post
did u try do in chat /spr ? or amx_sprmenu in console?
yes i try it , but not working
arvEL. is offline
Send a message via Skype™ to arvEL.
arvEL.
Senior Member
Join Date: Dec 2014
Location: Iraq
Old 01-18-2015 , 15:08   Re: [Requset] plugin special round
Reply With Quote #12

Quote:
Originally Posted by RateX View Post

PHP Code:
/* Plugin generated by AMXX-Studio */

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

#define PLUGIN "AWP Round"
#define VERSION "1.0"
#define AUTHOR "S.M"

#define LIGHTS "e"

new g_cvar
new g_nextround_awp false
new g_awpround false

public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_event("HLTV""Event_NewRound""a""1=0""2=0")
    
register_clcmd("amx_round_awp""round_trigger"ADMIN_KICK)
    
g_cvar register_cvar("amx_round_awp_next""1")// 0 = AWP round start immidiately, 1 = next round
    
register_logevent("logevent_round_end"2"1=Round_End")
    
register_event("CurWeapon""CurWeapon""be""1=1")
}
public 
Event_NewRound()
{
    if(
g_nextround_awp)
    {
        
g_nextround_awp false
        do_awpround
    
}
}
public 
round_trigger(id)
{
    new 
szname[32]
    
get_user_name(idsznamecharsmax(szname))
    if(
get_pcvar_num(g_cvar) == 1)
    {
        
g_nextround_awp true
        client_print
(0print_chat"ADMIN: %s started AWP Round on next round!"szname)
    }
    if(
get_pcvar_num(g_cvar) == 0)
    {
        
client_print(0print_chat"ADMIN: %s started AWP Round!"szname)
        
do_awpround
    
}
}
public 
do_awpround()
{
    
g_awpround true
    set_lights
(LIGHTS)
    new 
players[32], num
    get_players
(playersnum"c")
    for(new 
1<= numi++)
    {
        
strip_user_weapons(players[i])
        
give_item(players[i], "weapon_knife")
        
give_item(players[i], "weapon_awp")
    }
}
public 
CurWeapon(id)
{
    if(
g_awpround)
    {
        new 
weapon read_data(2)
        if(
weapon != CSW_AWP && weapon != CSW_KNIFE)
        {
            
strip_user_weapons(id)
            
give_item(id"weapon_knife")
            
give_item(id"weapon_awp")
        }
    }
}
public 
logevent_round_end()
{
    if(
g_awpround)
    {
        
g_awpround false
        set_lights
("#OFF")
    }

DONE! bro thx
but can you add HUD_Message
when you start the round a message appears on the top HUD_MESSAGE

AWP Round Started!!!
arvEL. is offline
Send a message via Skype™ to arvEL.
popeye10
Senior Member
Join Date: May 2014
Location: Navi Mumbai (India)
Old 01-18-2015 , 15:34   Re: [Requset] plugin special round
Reply With Quote #13


PHP Code:
public round_trigger(id)
{
    new 
szname[32]
    
get_user_name(idsznamecharsmax(szname))
    if(
get_pcvar_num(g_cvar) == 1)
    {
        
g_nextround_awp true
        client_print
(0print_chat"ADMIN: %s started AWP Round on next round!"szname)
    }
    if(
get_pcvar_num(g_cvar) == 0)
    {
        
set_hudmessage(02000, -1.00.2001.01.00.10.213
        
show_hudmessage(0"AWP Round Started!!!")
        
client_print(0print_chat"ADMIN: %s started AWP Round!"szname)
        
do_awpround
    
}

__________________

Last edited by popeye10; 01-18-2015 at 16:27.
popeye10 is offline
arvEL.
Senior Member
Join Date: Dec 2014
Location: Iraq
Old 01-18-2015 , 15:39   Re: [Requset] plugin special round
Reply With Quote #14

Quote:
Originally Posted by popeye10 View Post

PHP Code:
public round_trigger(id)
{
    new 
szname[32]
    
get_user_name(idsznamecharsmax(szname))
    if(
get_pcvar_num(g_cvar) == 1)
    {
        
g_nextround_awp true
        client_print
(0print_chat"ADMIN: %s started AWP Round on next round!"szname)
    }
    if(
get_pcvar_num(g_cvar) == 0)
    {
        
set_hudmessage(02000, -1.00.2001.01.00.10.213
        
show_hudmessage(0"AWP Round Started!!!")
        
client_print(0print_chat"ADMIN: %s started AWP Round!"szname)
        
do_awpround
    
}

thx bro but he working
i moded it see full code
PHP Code:
/* Plugin generated by AMXX-Studio */

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

#define PLUGIN "AWP Round"
#define VERSION "1.0"
#define AUTHOR "S.M"

#define LIGHTS "b"

new g_cvar
new g_nextround_awp false
new g_awpround false

const Float:HUD_EVENT_X = -1.0
const Float:HUD_EVENT_Y 0.17

public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_event("HLTV""Event_NewRound""a""1=0""2=0")
    
register_clcmd("c_awp""round_trigger"ADMIN_KICK)
    
g_cvar register_cvar("amx_round_awp_next""1")// 0 = AWP round start immidiately, 1 = next round
    
register_logevent("logevent_round_end"2"1=Round_End")
    
register_event("CurWeapon""CurWeapon""be""1=1")

}
public 
Event_NewRound()
{
    if(
g_nextround_awp)
    {
        
g_nextround_awp false
        do_awpround
    
}
}
public 
round_trigger(id)
{

    new 
szname[32]
    
get_user_name(idsznamecharsmax(szname))
    if(
get_pcvar_num(g_cvar) == 1)
    {

        
g_nextround_awp true
        ColorChat
(0GREY"^1[ADMIN] ^4%s^1: started ^3special forces ^1mode on next round."szname)
    }
    if(
get_pcvar_num(g_cvar) == 0)
    {

           
ColorChat(0GREY"^1[ADMIN] ^4%s^1: started ^3special forces ^1mode on next round."szname)
         
do_awpround
    
}
}

public 
do_awpround()
{
    
set_hudmessage(2025520HUD_EVENT_XHUD_EVENT_Y10.05.01.01.0, -1)
    
show_hudmessage(0"AWP Round Started!!!")
    
g_awpround true
    set_lights
(LIGHTS)
    new 
players[32], num
    get_players
(playersnum"c")
    
    for(new 
1<= numi++)

    {
        
strip_user_weapons(players[i])
        
give_item(players[i], "weapon_knife")
        
give_item(players[i], "weapon_awp")
    }
    
}
public 
CurWeapon(id)
{
    if(
g_awpround)
        {
        new 
weapon read_data(2)
        if(
weapon != CSW_AWP && weapon != CSW_KNIFE)
        
        {
            
strip_user_weapons(id)
            
give_item(id"weapon_knife")
            
give_item(id"weapon_awp")
        }
    }
    
}
public 
logevent_round_end()
{
    if(
g_awpround)
    {
        
g_awpround false
        set_lights
("#OFF")
    }


Last edited by arvEL.; 01-18-2015 at 16:25.
arvEL. is offline
Send a message via Skype™ to arvEL.
popeye10
Senior Member
Join Date: May 2014
Location: Navi Mumbai (India)
Old 01-18-2015 , 16:29   Re: [Requset] plugin special round
Reply With Quote #15

__________________
popeye10 is offline
Shiina.Mashiro
Senior Member
Join Date: Sep 2014
Location: Vietnam
Old 01-19-2015 , 00:33   Re: [Requset] plugin special round
Reply With Quote #16

Quote:
Originally Posted by arvEL. View Post
thx man but he have error in compile



can you help me

sorry bro, my bad, they fixed my error
__________________
Shiina.Mashiro is offline
arvEL.
Senior Member
Join Date: Dec 2014
Location: Iraq
Old 01-19-2015 , 07:40   Re: [Requset] plugin special round
Reply With Quote #17

Quote:
Originally Posted by Shiina.Mashiro View Post
sorry bro, my bad, they fixed my error
bro can you fix this plugin and add this options
i want change sky in this round for black sky
ex:


and add fog + snow in map in this round

Last edited by arvEL.; 01-19-2015 at 07:41.
arvEL. is offline
Send a message via Skype™ to arvEL.
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 04:41.


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