Raised This Month: $51 Target: $400
 12% 

Camera View Menu [Updated 22.06.05]


Post New Thread Reply   
 
Thread Tools Display Modes
Abdou Bn
Member
Join Date: Sep 2019
Old 12-28-2019 , 10:35   Re: Camera View Menu [Updated 22.06.05]
Reply With Quote #51

good work
Abdou Bn is offline
SaraAki
Junior Member
Join Date: Nov 2022
Old Yesterday , 10:44   Re: Camera View Menu [Updated 22.06.05]
Reply With Quote #52

Can this plugin cause lag on server for all players or just for players who is using 3rd person at the moment?
SaraAki is offline
MrPower
Member
Join Date: Feb 2016
Old Yesterday , 11:41   Re: Camera View Menu [Updated 22.06.05]
Reply With Quote #53

Is good cam

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

#define PLUGIN_NAME "Camera"
#define PLUGIN_AUTHOR "author"
#define PLUGIN_VERSION "1.0"

/*-------------------------------------------------------------------------------------------------------------------------------------------------*/

#define TASK_SECRET_MSG        226439

/*-------------------------------------------------------------------------------------------------------------------------------------------------*/

// --| Show mesaju din chat.
new g_cvar_show_msgs;

// --| Tag-ul mesajului din chat.
new const g_szTag[ ] = "Camera";

/*-------------------------------------------------------------------------------------------------------------------------------------------------*/

public plugin_init() 

    
register_plugin(PLUGIN_NAMEPLUGIN_VERSIONPLUGIN_AUTHOR);

    
register_clcmd("say /camera""CameraMenu"); 
    
register_clcmd("say_team /camera""CameraMenu") ;

    
register_clcmd("say /cam""CameraMenu");
    
register_clcmd("say_team /cam""CameraMenu"); 
    
    
g_cvar_show_msgs register_cvar"camera_show_messages""90" );        // la ce interval de timp.0 sa apara mesajele in chat despre Camera
    
    
register_logevent"logevent_RoundStart""1=Round_Start" );


/*-------------------------------------------------------------------------------------------------------------------------------------------------*/

public plugin_precache() 

    
precache_model("models/rpgrocket.mdl"


/*-------------------------------------------------------------------------------------------------------------------------------------------------*/

public CameraMenu(id

    new 
menu menu_create("\r--=== \wCs\r.\yNumeServer\r.\wRO \r===--^n\rADD FAVORIT \w: \wCs\r.\yNumeServer\r.\wRO^n\y-====[\rAvH Menu Camera\y]====-""Camera_handler"); 

    
menu_additem(menu"\y[\rCamera Menu\y] \wCamera Normal \r.""1"0);
    
menu_additem(menu"\y[\rCamera Menu\y] \wCamera 3D \r.""2"0);
    
menu_additem(menu"\y[\rCamera Menu\y] \wCamera TopDown \r.""3"0);
    
menu_additem(menu"\y[\rCamera Menu\y] \wCamera Left \r.""4"0);

    
menu_setprop(menuMPROP_EXITMEXIT_ALL); 
    
menu_display(idmenu0); 


/*-------------------------------------------------------------------------------------------------------------------------------------------------*/

public Camera_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
        {
            
set_view(idCAMERA_NONE)
            
            
ColorChat(id"!t[!g%s!t] !yYou have now taken the camera !t[!gNormala!t] ."g_szTag );
        }
        
        case 
2
        {
            
set_view(idCAMERA_3RDPERSON)
            
            
ColorChat(id"!t[!g%s!t] !yYou have now taken the camera !t[!g3D!t] ."g_szTag );
        }
        
        case 
3
        {
            
set_view(idCAMERA_TOPDOWN)
            
            
ColorChat(id"!t[!g%s!t] !yYou have now taken the camera !t[!gTopDown!t] ."g_szTag );
        }
        
        case 
4
        {
            
set_view(idCAMERA_UPLEFT)
            
            
ColorChat(id"!t[!g%s!t] !yYou have now taken the camera !t[!gLeft!t] ."g_szTag );
        }        
    }
    
    
menu_destroy(menu); 
    return 
PLUGIN_HANDLED


/*-------------------------------------------------------------------------------------------------------------------------------------------------*/

public logevent_RoundStart(     ) 
{
    new 
szPlayers32 ], iNum;
    
get_playersszPlayersiNum"ch" );
    
    for( new 
0iNumi++)    
    {
        if( 
task_existsszPlayers] + TASK_SECRET_MSG ) )
            
remove_taskszPlayers] + TASK_SECRET_MSG );
        
        
set_taskget_pcvar_floatg_cvar_show_msgs ), "task_ShowMessage"szPlayers] + TASK_SECRET_MSG );
    }
}

/*-------------------------------------------------------------------------------------------------------------------------------------------------*/

public task_ShowMessagetaskid 
{
    new 
id taskid TASK_SECRET_MSG;

    
ColorChat(id"!t[!g%s!t] !yPentru a vedea camera !t[!g3D!y,!gLeft!y,!gTopDown!t] !g, !yfoloseste comanda !g/camera !ysau !g/cam !t."g_szTag );

    if( 
task_existstaskid ) )
        
remove_tasktaskid );
}

/*-------------------------------------------------------------------------------------------------------------------------------------------------*/

/*=================================================================================================================*/
/*----------------------------------------------[ ColorChat ]-----------------------------------------*/
/*=================================================================================================================*/

stock ColorChat(const id, const input[], any:...) {
    new 
count 1players[32];
    static 
msg[191];
    
vformat(msg190input3);
    
    
replace_all(msg190"!g""^4"); // verde
    
replace_all(msg190"!y""^1"); // galben/alb/negru
    
replace_all(msg190"!t""^3"); // rosu/albastru/gri
    
    
if(idplayers[0] = id;
    else 
get_players(playerscount"ch"); {
        for(new 
0counti++) {
            if(
is_user_connected(id)) {
                
message_begin(MSG_ONE_UNRELIABLEget_user_msgid("SayText"), _id);
                
write_byte(id);
                
write_string(msg);
                
message_end();
            }
        }
    } 
}

/*=================================================================================================================*/
/*----------------------------------------------[ ColorChat Sfarsit ]---------------------------------*/
/*=================================================================================================================*/

/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1048\\ f0\\ fs16 \n\\ par }
*/ 

Last edited by MrPower; Yesterday at 11:42.
MrPower is offline
georgik57
Veteran Member
Join Date: Oct 2008
Location: 🎧Music World
Old Today , 08:55   Re: Camera View Menu [Updated 22.06.05]
Reply With Quote #54

Quote:
Originally Posted by MrPower View Post
Is good cam
it's actually exactly the same thing except it's a low edit

Quote:
Originally Posted by SaraAki View Post
Can this plugin cause lag on server for all players or just for players who is using 3rd person at the moment?
https://forums.alliedmods.net/showth...26#post2775426
__________________
georgik57 is online now
Send a message via MSN to georgik57 Send a message via Yahoo to georgik57 Send a message via Skype™ to georgik57
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 13:15.


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