AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   message_begin origin? (https://forums.alliedmods.net/showthread.php?t=27377)

organizedKaoS 04-21-2006 04:08

message_begin origin?
 
This is what im using
Code:
message_begin(MSG_ONE, g_iMsgSayText, {0,0,0}, aPlayers[i])

And it writes the message to the chat side.

What do I put for the origin to have it print in the center above the hud round timer.

Or does anyone know where I can find a list of origins for this?

Thanks for any info. :up:

FatalisDK 04-21-2006 04:13

I don't think there is a param to let you say where you want SayText to be printed. Use a hudmessage.

organizedKaoS 04-21-2006 04:15

Quote:

Originally Posted by FatalisDK
I don't think there is a param to let you say where you want SayText to be printed. Use a hudmessage.

Im actually getting tired of using hudmessages. I started using this to clear up the game screen on my server. Is there any way to specify the location of text being printed on the screen?

I know I've seen this on wc3 servers where your status is shown in text above your weapon ammo hud.

FatalisDK 04-21-2006 04:17

Yeah I think I know what you're talking about now, I saw it in diablo mod. It's like print_center but at the bottom?

EDIT: The event is StatusText
Code:

StatusText          byte, string          1: Line Number, 2: Text
This is how diablo mod does it.

Code:
message_begin(MSG_ONE,gmsgStatusText,{0,0,0}, id) write_byte(0) write_string(tpstring) message_end()

organizedKaoS 04-21-2006 04:19

Yes at the bottom. In wc3, theres text above your ammo hud on the lower right.

I basically want to have the text show up center bottom above the round timer hud.

I am using message begin because the text im printing is server info ( fun server ) during rounds and i currently have it printing in green.

Any ideas?

organizedKaoS 04-21-2006 04:26

Quote:

Originally Posted by FatalisDK
Yeah I think I know what you're talking about now, I saw it in diablo mod. It's like print_center but at the bottom?

EDIT: The event is StatusText
Code:

StatusText          byte, string          1: Line Number, 2: Text
This is how diablo mod does it.

Code:
message_begin(MSG_ONE,gmsgStatusText,{0,0,0}, id) write_byte(0) write_string(tpstring) message_end()

Thanks, I'll try this. Is there any info anywhere that can tell where the locations text can be printed using message_begin?

FatalisDK 04-21-2006 04:30

The player option "Center Player Names" affects StatusText, which means not all players would see the message at the bottom of their screens. So I guess StatusText isn't really good for this. You can maybe client_cmd them and set the "Center Player Names" cvar. I have no idea what the actual cvar is though.

If you want to have it above the counter, I guess you could put alot of spaces (not the greatest idea) like so:
Code:

new tpstring[] = "                            asdas"

organizedKaoS 04-21-2006 04:32

Ok...any ideas? I have it correct, its printing green text. I just need to move the text away from the chat area :cry:

I'll check back tomorrow if you have any new info...tired

Greenberet 04-21-2006 04:35

set/show_hudmessage is just a wrapper for the SVC_TEMPENTITY message with TE_TEXTMESSAGE
here is the definition:
Code:
#define TE_TEXTMESSAGE      29 // short 1.2.13 x (-1 = center) // short 1.2.13 y (-1 = center) // byte Effect 0 = fade in/fade out             // 1 is flickery credits             // 2 is write out (training room) // 4 bytes r,g,b,a color1   (text color) // 4 bytes r,g,b,a color2   (effect color) // ushort 8.8 fadein time // ushort 8.8  fadeout time // ushort 8.8 hold time // optional ushort 8.8 fxtime   (time the highlight lags behing the leading text in effect 2) // string text message      (512 chars max sz string)


All times are GMT -4. The time now is 05:00.

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