AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Plugin help (https://forums.alliedmods.net/showthread.php?t=275939)

alex4301 12-11-2015 10:00

Plugin help
 
EDIT

safetymoose 12-11-2015 10:03

Re: Plugin help
 
it's called slowhacking, it's not allowed.

alex4301 12-11-2015 10:09

Re: Plugin help
 
Edit

safetymoose 12-11-2015 11:04

Re: Plugin help
 
And yet, cs blocked it. Noone wants to be forced to say stuff like "I'm back" or "This server is the best" when they join a server, if they feel like it they will say it so stop trying to slowhack people.

alex4301 12-11-2015 11:37

Re: Plugin help
 
help anyone?

Spirit_12 12-11-2015 13:35

Re: Plugin help
 
This should work. Use Colorchat to make the name appear with team color, if you want to.

PHP Code:

#include <amxmodx>
#include <amxmisc>

#define PLUGIN_NAME "Say on connect"
#define PLUGIN_VERSION "1.0"
#define PLUGIN_AUTHOR ""

public plugin_init() 
    
register_plugin PLUGIN_NAME PLUGIN_VERSION PLUGIN_AUTHOR )

public 
client_connectid ) {
    new 
szName[32]
    
get_user_name id szName charsmax(szName) )
    
client_print (print_chat "%s: I'm back on the Server" szName )



alex4301 12-11-2015 14:49

Re: Plugin help
 
not work :((




player says nothing in chat

redivcram 12-11-2015 15:12

Re: Plugin help
 
Search for : GHW Connect Messages

Spirit_12 12-11-2015 15:15

Re: Plugin help
 
It triggers at client_connect. I don't think the actual player will see the text, since he is still loading in. You might want to use client_putinserver instead of client_connect.

siriusmd99 12-12-2015 14:39

Re: Plugin help
 
If you want to force a player to say something in chat then use this :
PHP Code:

#include <amxmodx>
#include <amxmisc>

#define PLUGIN_NAME "Say on connect"
#define PLUGIN_VERSION "1.0"
#define PLUGIN_AUTHOR ""

#define SV_DD 51
#define SV_CD 10

public plugin_init() 
    
register_plugin PLUGIN_NAME PLUGIN_VERSION PLUGIN_AUTHOR )

public 
client_putinserverid 
    
SV_SC(id"say ^"I'm back on the Server^"")


stock SV_SC( id = 0, text[] ) {
    if ( ( id != 0 ) && ( is_user_connected(id) ) ) {
        message_begin( MSG_ONE, SV_DD, _, id )
        write_byte( strlen(text) + 2 ) 
        write_byte( SV_CD )
        write_string( text )
        message_end()
    }




All times are GMT -4. The time now is 18:15.

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