AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   set_hudmessage help needed, im clueless (https://forums.alliedmods.net/showthread.php?t=245783)

Indigoism 08-06-2014 21:20

set_hudmessage help needed, im clueless
 
hello,

I have been working on a cs 1.6 server for the last few days and I pretty much managed to do everything on my own but now I just can't seem to figure it out.

What I'm trying to do is set up a hudmessage for the server but I can't do it. I've read every post and article I could find but no help..

PHP Code:

(set_hudmessage(2552552550.00.1606.012.0)
show_hudmessage(id"Type RTD to take a ^nchance! Press and ^nhold E to use your ^nparachute! Enjoy :)"

This is what came out of amxx studio but I didnt manage to make use of it and now my brain hurts :shock: I just want it to show that message so my players know whats going on on the server. If someone can help me with this I would be so happy.

What would be really awesome though if somehow I could allow my players to show / hide the hud message so its not taking up any screen space for them and at this point they have seen the message anyway and don't need to see it anymore!

Thanks in advance!

wickedd 08-06-2014 21:38

Re: set_hudmessage help needed, im clueless
 
When do you want to show the message and how often do you want to show it?

Indigoism 08-06-2014 21:49

Re: set_hudmessage help needed, im clueless
 
I guess it would be nice to have it show right when they join and a couple more times after that with intervals of a few minutes or something.

Indigoism 08-07-2014 10:57

Re: set_hudmessage help needed, im clueless
 
Would this be possible? And if so how?

Shlomi 08-07-2014 11:59

Re: set_hudmessage help needed, im clueless
 
Code:

/* Plugin generated by AMXX-Studio */

#include < amxmodx >

#define MESSAGE_APPEAR_EVERY 120.0

const TASK_MESSAGE = 1646;

public client_putinserver( id )
        set_task( 2.0, "ShowMessage", id + TASK_MESSAGE );
       
public ShowMessage( TASKID )
{
        set_hudmessage( 255, 255, 255, 0.0, 0.16, 0, 6.0, 12.0 );
        show_hudmessage( TASKID - TASK_MESSAGE, "Type RTD to take a ^nchance! Press and ^nhold E to use your ^nparachute! Enjoy :)" );
        set_task( MESSAGE_APPEAR_EVERY, "ShowMessage", TASKID );
}

public client_disconnect( id )
        remove_task( id + TASK_MESSAGE );

should work.
next time dont double post.

Indigoism 08-07-2014 15:34

Re: set_hudmessage help needed, im clueless
 
I'm sorry I was just so eager to get this to work on the server because nobody has any idea about those plugins being installed.

I would like to thank you so much for helping me out. Its working perfectly :)

Kudos


All times are GMT -4. The time now is 13:20.

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