Raised This Month: $ Target: $400
 0% 

connect message script


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
stigma
Senior Member
Join Date: Mar 2005
Location: Denmark
Old 03-25-2005 , 08:51   connect message script
Reply With Quote #1

Well i've tryed to make a script, that would wirte a HUD message to a client when he joins... It goes like this:

Code:
#include <amxmodx> public client_putinserver(id) {   new username[33] get_user_name(id,username,32); } client_connect(id) {   set_hudmessage("255", "0", "0", "1.0", "0.35", "1", "6.0", "12.0", "1", "1", "4")   show_hudmessage("%s has joined the server!", username) } public plugin_init(){   register_plugin("connect","1.0","stigma")   return PLUGIN_CONTINUE }

I got one error:
(Line 4) error 001: expected token: ";", but found "-identifier-"

I hope some on can help me with this.
stigma is offline
Send a message via MSN to stigma Send a message via Skype™ to stigma
knekter
Senior Member
Join Date: Mar 2004
Location: PA
Old 03-25-2005 , 08:59  
Reply With Quote #2

Code:
client_connect(id) {   new UserName[33]   get_user_name(id, UserName, 32)   set_hudmessage(255, 0, 0, 1.0, 0.35, 1, 6.0, 12.0, 1, 1, 4)   show_hudmessage("%s has joined the server!", UserName) } public plugin_init(){   register_plugin("connect","1.0","stigma")   return PLUGIN_CONTINUE }
__________________
More updates for Matrix Mod!
knekter is offline
Send a message via AIM to knekter Send a message via MSN to knekter
stigma
Senior Member
Join Date: Mar 2005
Location: Denmark
Old 03-25-2005 , 09:08  
Reply With Quote #3

Okay, thanks alot!
stigma is offline
Send a message via MSN to stigma Send a message via Skype™ to stigma
stigma
Senior Member
Join Date: Mar 2005
Location: Denmark
Old 03-25-2005 , 09:14  
Reply With Quote #4

Well okay, ive compiled it, and there no errors, but when i join the server, there aint appearing any message? :/ How can that be?
stigma is offline
Send a message via MSN to stigma Send a message via Skype™ to stigma
knekter
Senior Member
Join Date: Mar 2004
Location: PA
Old 03-25-2005 , 09:17   hmm
Reply With Quote #5

Well this shows it when you are connecting. By the time you are actually in the server, the message will have faded away. If you want to see it when you enter use public client_putinserver(id) instead of client_connect(id)
__________________
More updates for Matrix Mod!
knekter is offline
Send a message via AIM to knekter Send a message via MSN to knekter
stigma
Senior Member
Join Date: Mar 2005
Location: Denmark
Old 03-25-2005 , 09:30  
Reply With Quote #6

Hmm, do you have msn messenger? So i could got some impluse help? If you have, then please let me have your mail (:
stigma is offline
Send a message via MSN to stigma Send a message via Skype™ to stigma
stigma
Senior Member
Join Date: Mar 2005
Location: Denmark
Old 03-25-2005 , 09:34  
Reply With Quote #7

Well i've changed the client_connect(id) to client_putinserver(id) - aint working - But shouldent it go like this "public client_putinserver(id)" instead of just "client_putinserver(id)"?[/b]
stigma is offline
Send a message via MSN to stigma Send a message via Skype™ to stigma
v3x
Veteran Member
Join Date: Oct 2004
Location: US
Old 03-25-2005 , 09:35  
Reply With Quote #8

Yep.
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116

I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.
v3x is offline
stigma
Senior Member
Join Date: Mar 2005
Location: Denmark
Old 03-25-2005 , 09:36  
Reply With Quote #9

Ohh dident saw that you already have written public infront of client_putinserver my mistake
stigma is offline
Send a message via MSN to stigma Send a message via Skype™ to stigma
stigma
Senior Member
Join Date: Mar 2005
Location: Denmark
Old 03-25-2005 , 09:38  
Reply With Quote #10

Well i've added the public thing there. Now i get an error with my "show_hudmessage"

(Line 9) Error 035: argument type mismatch (argument 1)
stigma is offline
Send a message via MSN to stigma Send a message via Skype™ to stigma
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 09:59.


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