Raised This Month: $32 Target: $400
 8% 

Request Plugin /help


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Yeoo
Junior Member
Join Date: Nov 2020
Old 05-09-2021 , 09:00   Request Plugin /help
Reply With Quote #1

Hi, I need a /help plugin, what this plugin does ?
When a CT write /help a menu will appear for admins(only Terrorist) with the player/s name.
And if a admin will select the player he will be teleported to the player and the player will get 30 seconds godmode.

I need this plugin for a Basebuilder server so /help command should work only on Prep_time.
I have a similar plugin here but its not what I want, u can use it if its easier for u.
U can take the prep time from this plugin.
THank you

PHP Code:
#include <amxmodx> 
#include <amxmisc> 
#include <engine> 
#include <fakemeta> 
#include <cstrike> 
#include <basebuilder> 

#define SPRITE "sprites/white.spr" 
#define HELPSOUND "misc/bb_help.wav" 

new bool:valuri 
new sprite_white

public 
plugin_init() { 
   
register_plugin("Help System","1.0","MAGNET"
   
register_event("HLTV""rundanoua""a""1=0""2=0"); 
   
register_clcmd("say /ajutor""ajutor"
   
register_clcmd("say /help""ajutor"



public 
plugin_precache() 

   
sprite_white precache_model(SPRITE); 
   
precache_sound(HELPSOUND


public 
bb_prepphase_started() 

   
valuri true 


public 
bb_round_started() 

   
valuri false


public 
rundanoua() 

   
valuri false



public 
ajutor(id


   new 
nick[33]; 
   
get_user_name(idnickcharsmax(nick)); 
    
   if(!
is_user_alive(id)) 
      return 
PLUGIN_HANDLED

   if(
cs_get_user_team(id) != CS_TEAM_CT
   { 
      
ColorChat(id,"^3Trebuie sa fii om, pentru a folosi aceasta comanda!"
      return 
PLUGIN_HANDLED
   } 
    
   if(!
valuri
   { 
      
ColorChat(id,"^3Lipirea nu se poate inca realiza napule"
      return 
PLUGIN_HANDLED
   } 
    
   for(new 
0;i<32;i++) 
   { 
      if(!
is_user_connected(i) || !(get_user_flags(i) & ADMIN_BAN))   continue; 
      
ColorChat(i,"[Help System]^4 Jucatorul ^3 %s ^1 are nevoie de ajutor"nick[id]) 
      
client_cmd(i"spk misc/bb_help.wav"
   } 
   
set_task(1.0"Info"id+32__"b"); 
    
   return 
PLUGIN_CONTINUE




public 
Info(id

   
id-=32
    
   if(!
is_user_alive(id) || !valuri || cs_get_user_team(id) != CS_TEAM_CT
   { 
      
remove_task(id+32); 
      return; 
   } 

   
emit_sound(idCHAN_AUTOHELPSOUNDVOL_NORMATTN_NORM0PITCH_NORM); 
   new 
Float:forigin[3]; 
   
entity_get_vector(idEV_VEC_originforigin); 

   new 
iOrigin[3]; 
   for(new 
i=0;i<3;i++) 
   
iOrigin floatround(forigin); 

   
message_beginMSG_BROADCASTSVC_TEMPENTITYiOrigin ); 
   
write_byteTE_BEAMCYLINDER ); 
   
write_coordiOrigin[0] ); 
   
write_coordiOrigin[1] ); 
   
write_coordiOrigin[2] ); 
   
write_coordiOrigin[0] ); 
   
write_coordiOrigin[1] + 300 ); 
   
write_coordiOrigin[2] + 300 ); 
   
write_shortsprite_white ); 
   
write_byte); // startframe 
   
write_byte); // framerate 
   
write_byte10 ); // life 
   
write_byte10 ); // width 
   
write_byte255 ); // noise 
   
write_byte255 ); // r, g, b 
   
write_byte100 );// r, g, b 
   
write_byte100 ); // r, g, b 
   
write_byte128 ); // brightness 
   
write_byte); // speed 
   
message_end(); 
    



stock ColorChat(const id, const input[], any:...) 

   new 
count 1players[32]; 
   static 
msg[191]; 
   
vformat(msg190input3); 
    
   
replace_all(msg190"^x04""^4"); 
   
replace_all(msg190"^x01""^1"); 
   
replace_all(msg190"^x03""^3"); 
    
   if(
idplayers[0] = id
   else 
get_players(playerscount"ch"); { 
      for(new 
0counti++) { 
         if(
is_user_connected(players)) { 
            
message_begin(MSG_ONE_UNRELIABLEget_user_msgid("SayText"), _players); 
            
write_byte(players); 
            
write_string(msg); 
            
message_end(); 
         } 
      } 
   } 


Last edited by Yeoo; 05-09-2021 at 09:01.
Yeoo is offline
Reply


Thread Tools
Display Modes

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 12:47.


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