This site is a testing version, but all data is shared with the live forum.


Raised This Month: $ Target: $400
 0% 

First and last to jump


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
satelitegames
Member
Join Date: Nov 2010
Old 03-26-2012 , 20:02   First and last to jump
Reply With Quote #1

Hello again come asking for help, I would like to know how to get the 1st player who jumped and the last player who jumped.


PHP Code:
#include <amxmodx>
#include <hamsandwich>
#include <fakemeta_util>
#include <cstrike>

#define AUTOR "exolent"
#define VERSAO "1.0"
#define NOME "InDuck"

new g_iMax
new gLastDuckedPlayer 0;

public 
plugin_init() {
    
register_plugin(AUTORVERSAONOME)
    
register_clcmd("say /ulti" "inDuck")
    
g_iMax get_maxplayers()
    
}
public 
InDuckid )
{
    
RegisterHam(Ham_Player_Duck"player""FwdPlayerDuck"1);
}

public 
FwdPlayerDuck(id) {
    
gLastDuckedPlayer id;
    
SetGlow()
}

// ...

SetGlow() {
    
    new 
i
    
for (0<= g_iMaxi++)
    {
        
        if( 
cs_get_user_team) != CS_TEAM_T || !is_user_alive) ) {
            return 
PLUGIN_HANDLED_MAIN
        
}
        if(
gLastDuckedPlayer && is_user_connected(gLastDuckedPlayer)) {
            new 
name[32];
            
get_user_name(gLastDuckedPlayernamecharsmax(name));
            
fm_set_rendering(ikRenderFxGlowShell25000kRenderNormal20)
        }
        
    }


This code above does not work, as I am new about this type of event, I would like help from you guys


Thank you!
__________________




satelitegames is offline
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 03-27-2012 , 05:21   Re: First and last to jump
Reply With Quote #2

Code:
#include <amxmodx> #include <hamsandwich> new First; new Last; public plugin_init()     RegisterHam(Ham_Player_Jump, "player", "OnJump", 1); public OnJump(client) {     if (!First)         First = client;         Last = client; }
hleV is offline
satelitegames
Member
Join Date: Nov 2010
Old 03-27-2012 , 09:08   Re: First and last to jump
Reply With Quote #3

PHP Code:
#include <amxmodx>
#include <hamsandwich>

new First;
new 
Last;

public 
plugin_init()
    
RegisterHam(Ham_Player_Jump"player""OnJump"1);

public 
OnJump(client)
{
    if (!
First)
        
First client;
    
    
Last client;


Hello and how do I turn through a menu, and use the Glow in the last and the first to jump

example:

PHP Code:
#include <amxmodx>

public plugin_init()
{
     
register_clcmd"amx_menu","Menu_jump")
}

public 
Menu_jump(id)
{
     new 
menu menu_create("Jump Menu:""Menu_jump_handler")

     
menu_additem(menu"First Jump""1"0)
     
menu_additem(menu"Last Jump""2"0)

     
menu_setprop(menuMPROP_EXITMEXIT_ALL)
     
menu_display(idmenu0)
}

public 
Menu_jump_handler(idmenuitem)
{
     if (
item == MENU_EXIT)
     {
          
menu_destroy(menu)
          return 
PLUGIN_HANDLED
     
}

     new 
data[6], iName[64]
     new 
accesscallback
     menu_item_getinfo
(menuitemaccessdata,5iName63callback);

     new 
key str_to_num(data)

     switch(
key)
     {
         case 
1:
         {
              
client_print(idprint_chat"First Jump")
              
Menu_jump(id)
              
//...
         
}

         case 
2:
         {
              
client_print(idprint_chat"Last Jump")
              
Menu_jump(id)
              
//...
         
}
     }

     
menu_destroy(menu)
     return 
PLUGIN_HANDLED

I would add a Glow in the last player to jump

thank you
__________________





Last edited by satelitegames; 03-27-2012 at 19:13. Reason: I would add a Glow in the last player to jump
satelitegames is offline
Old 03-29-2012, 09:58
satelitegames
This message has been deleted by Exolent[jNr]. Reason: Don't bump until 2 weeks have passed since last post.
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 11:33.


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