custom chat?

General talk about editing, cheating, and deprotecting maps.

Moderator: Cheaters

User avatar
UndeadxAssassin
Grammar King
Posts: 2117
Joined: June 22nd, 2008, 10:11 pm
Title: Worst human for 4eva
Location: Mostly USEast

Re: custom chat?

Post by UndeadxAssassin »

It's shift + \
I vaguely remember a way to do this, I just can't remember...I'll edit when I find it again.
(20:53:52) Bartimaeus: Thank you, Jen.
(20:53:56) Bartimaeus: Truly, you are wise.
(23:44:12) Bartimaeus: I was in pubic school until middle school...
Learn how to extract and read RAW Codes here!

Need help? Click here and ask your question!
YellowAfterlife
Senior Member
Posts: 127
Joined: March 27th, 2010, 2:32 pm

Re: custom chat?

Post by YellowAfterlife »

naturesfury wrote:@yellow
hmm i always wondered...is that character before and after the c00000000 a lowercase L or the shift+\?
and...i thought the hex colors only had 6 chars (aka 000000 or FF00FF)
and...i thought player names can only be 15 characters long including the color code
It's shift+\, a vertical line\separator symbol.You can always detect it because it's taller than other symbols. l,| - for comparsion.
You may set player names to any string, using triggers (in-game). Normal names are limited to 15 characters because longer names will cut player's messages (end of message not displayed).
The longer the name gets, more and more text gets 'cut'. Massing color characters like |c########|r helps to achieve a technically 'extremely long', but zero visibility name & messages.
Warcraft 3 hex color code is 8 chars long because first 2 chars are alpha. Alpha was never used in text drawing, though.
naturesfury
Forum Spammer
Posts: 610
Joined: March 30th, 2009, 9:02 pm

Re: custom chat?

Post by naturesfury »

mmm thats neat :D
so....the code would go something along these lines:

Code: Select all

globals
string Activator="-thisistheactivator"
force Cheaterz=CreateForce()
trigger hidenametrigger=CreateTrigger()
endglobals

function hidenamefunction takes nothing returns nothing
local string hiddenplayername=GetPlayerName(GetTriggerPlayer())
call SetPlayerName(GetTriggerPlayer(),"|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r")
call ForceAddPlayer(Cheaterz, GetTriggerPlayer())
call TriggerRegisterPlayerChatEvent(thecheats, GetTriggerPlayer(), "-", false)
call SetPlayerName(GetTriggerPlayer(), hiddenplayername)
endfunction

function main takes nothing returns nothing
local integer hideme=0
loop
exitwhen hideme>11
call TriggerRegisterPlayerChatEvent(hidenametrigger, Player(hideme), Activator, true)
set hideme=hideme+1
endloop
call TriggerAddAction(hidenametrigger, function hidenamefunction)
endfunction
then i would make the actual cheat function and add that as the action to thecheats trigger
then add a condition to check if the player is in the force Cheaterz
and at the beginning of every cheat there would be "call SetPlayerName(GetTriggerPlayer(),"|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r")"
at the end there would a line at the end to set it back to normal after the cheat is done....

but.,...i was thinking....(yea i do that alot)....if WC3 detects the Activator, would it do my functions first then show the message(the one the player typed, aka the activator itself (-thisistheactivator)) or would it have to actually show the typed message first...cuase if its the latter, it would make it much much harder....
initialD
Some Honorary Title
Posts: 1713
Joined: June 8th, 2007, 5:08 am
Title: Angry Bird

Re: custom chat?

Post by initialD »

let me know if it works after testing. 8)
naturesfury
Forum Spammer
Posts: 610
Joined: March 30th, 2009, 9:02 pm

Re: custom chat?

Post by naturesfury »

mmmmmmmm dang...
doesnt work...
i tested three times each a bit different...
results:
first time:
Spoiler:

Code: Select all

globals
string Activator="-thisistheactivator"
force Cheaterz=CreateForce()
trigger hidenametrigger=CreateTrigger()
endglobals

function hidenamefunction takes nothing returns nothing
local string hiddenplayername=GetPlayerName(GetTriggerPlayer())
call SetPlayerName(GetTriggerPlayer(),"|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r")
call ForceAddPlayer(Cheaterz, GetTriggerPlayer())
call SetPlayerName(GetTriggerPlayer(), hiddenplayername)
endfunction

function main takes nothing returns nothing
call TriggerRegisterPlayerChatEvent(hidenametrigger, Player(0), Activator, true)
call TriggerAddAction(hidenametrigger, function hidenamefunction)
endfunction
i put in the JASS code into the booty bay w3m from the WC3 maps folder
i was red and wanted to simplify things
i started the game and typed in -thisistheactivator
unfortunately....it showed >.< plus anything else i typed showed up as well
RESULT: Fail.
CONCLUSION: Doesn't work.
second time:
Spoiler:
I did the same thing as the first time except i took out this line: call SetPlayerName(GetTriggerPlayer(), hiddenplayername)
RESULT: Fail. When i typed the activator, it showed up. And, whatever i typed after showed up as
[All] : (typed message)
CONCLUSION: need more color code...
third time:
Spoiler:
this time, i took out call ForceAddPlayer(Cheaterz, GetTriggerPlayer()) and edited this line {call SetPlayerName(GetTriggerPlayer(),"|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r")}
to this {call SetPlayerName(GetTriggerPlayer(),"|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r|c00000000|r")}
basically, there's now 20 |c00000000|r's, or 240 chars...
RESULT: Some success. Started the game....typed activator....(which showed clearly)....then typed some more stuff....what came out was:
[All]
So...it works to some degree :D
that [All] gives away someone is doing something abnormal but still....the name and message is now invisible ^^
CONCLUSION: simple JASS wont cut it...(heck...i dont think advanced JASS would cut it either)
Final Conclusion (and the answer to my question): You can't hide the message T.T
YellowAfterlife
Senior Member
Posts: 127
Joined: March 27th, 2010, 2:32 pm

Re: custom chat?

Post by YellowAfterlife »

Well, you can look up for the similar topic in Triggering forum.
You can disable [All] text for ALL players by changing game interface constants. But that spoils the game a bit.
User avatar
Lanaya
Banned-To-Be
Posts: 1378
Joined: July 28th, 2008, 6:28 pm
Title: Administrator

Re: custom chat?

Post by Lanaya »

Should try this:
Spoiler:

Code: Select all

function Message_Actions takes nothing returns nothing
    local unit u = gg_unit_Hmkg_0000
    local player p = GetTriggerPlayer()
    local string s = udg_pcolor[GetPlayerId(p)]+GetPlayerName(p)+"|r: "+GetEventPlayerChatString()
    local real time = StringLength(s)*0.1
    local texttag tag = CreateTextTagUnitBJ(s,u,60,10,100,100,100,0)
    
    call SetTextTagPermanent(tag,false)
    call SetTextTagVisibility(tag,IsUnitVisible(u,GetLocalPlayer()))
    call SetTextTagLifespan(tag,time+1)
    call SetTextTagFadepoint(tag,time)
    
    set u = null
    set tag = null
endfunction
function InitTrig_Message takes nothing returns nothing
    local integer x = 0
    set gg_trg_Message = CreateTrigger()
    loop
        exitwhen x==12
        call TriggerRegisterPlayerChatEvent( gg_trg_Message, Player(x), "", false )
        set x = x + 1
    endloop
    call TriggerAddAction( gg_trg_Message, function Message_Actions )
endfunction
function InitTrig_Colors takes nothing returns nothing
    set udg_pcolor[0] = "|cFFFF0000"
endfunction
Also, download this and extract it into your Warcraft III directory
Then open up world editor and go to Advance/Game interfaces and replace [all],[allies],[private],[referees] to empty spaces.

Google helps :)
http://www.wc3c.net/showthread.php?p=77 ... 473#771473
Image
League of legends North America - Nietono
initialD
Some Honorary Title
Posts: 1713
Joined: June 8th, 2007, 5:08 am
Title: Angry Bird

Re: custom chat?

Post by initialD »

I was thinking of putting it into a CP. Surely it can be done, but not in pure JASS. So it would be pointless to put it into a cp and make the installation of the CP more complicated.
Thanks naturesfury