Raised This Month: $ Target: $400
 0% 

write own inc's


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
One
Veteran Member
Join Date: Oct 2008
Location: Hardstyle-eSports.de
Old 03-05-2010 , 04:23   Re: get users info
Reply With Quote #4

sry for push or dubble post.

i tried to check it in csdm or zp inc but couldnt find anything which can help me.

main plugin/test1.amxx
PHP Code:
#include <amxmodx>
#include <fun>
#include <hamsandwich>
#include <cstrike>
#include <jail_manager>

#define TASK_PLAYERFREE 1000

new g_tempid,g_MaxPlayers,g_leach_cvar,bool:g_player_is_leader[33],iPlayers32 ], iNum,g_printed,we_have_a_leader,gVoteMenu,
gVotes[2],gVoting,g_delay,g_percent,bool:g_Vote_Player[33],g_voted,g_free_vote,g_its_freeday,g_rounds,g_had_freeround,can_vote,
g_vote_round_number,g_let_be_freeday,g_vote_canceled,g_vip_admin,g_show_votes,g_welcomed[33],admin_gave_freeday,g_welcome_menu


public plugin_natives( ) 
{     
    
register_native"is_player_leader""_is_player_leader"); 

public 
bool:_is_player_leaderiPluginiParams 
{     
    return 
g_player_is_leaderget_param) ]; 

inc file =
PHP Code:
#if defined _jail_manager_included
    #endinput
#endif
#define _jail_manager_included

native is_player_leader( const id ); 
sub-plugin/test2.amxx
PHP Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <amxmisc>
#include <jail_manager>

#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"


public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_clcmd("say a","function")
    
// Add your code here...
}
public function( 
id )
{
    if( 
is_player_leaderid ) )
    {
        
// player is leader
        
client_print(id,print_chat,"jaaaaaaaaaa")
    }
    else
    {
        
// not leader
        
client_print(id,print_chat,"neiiiiiiiiiiiin")
    }

error :
PHP Code:
L 03/05/2010 10:18:25Start of error session.
L 03/05/2010 10:18:25Info (map "de_dust2") (file "addons/amxmodx/logs/error_20100305.log")
L 03/05/2010 10:18:25Wrong style of dynamic native
L 03
/05/2010 10:18:25: [AMXXDisplaying debug trace (plugin "test1.amxx")
L 03/05/2010 10:18:25: [AMXXRun time error 10native error (native "get_param")
L 03/05/2010 10:18:25: [AMXX]    [0test1.sma::_is_player_leader (line 19)
L 03/05/2010 10:18:25Unhandled dynamic native error 
i tried to search and found more topics like http://forums.alliedmods.net/showthread.php?t=118049 but the same resault. (all are the same )
__________________
One is offline
Send a message via ICQ to One Send a message via AIM to One Send a message via MSN to One Send a message via Yahoo to One Send a message via Skype™ to One
 



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 08:46.


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