custom activator question?

General talk about editing, cheating, and deprotecting maps.

Moderator: Cheaters

naturesfury
Forum Spammer
Posts: 610
Joined: March 30th, 2009, 9:02 pm

custom activator question?

Post by naturesfury »

ok...so i wanted to make a custom activator...where the activator depends on the triggering player's name xD
so...in globals i deleted the string activator="-whatever"
in the endglobals i deleted the -act command
and in the bottom of endglobals
i changed the cheatuse to this:
Spoiler:
function CheatUse takes nothing returns nothing
local player p2p=GetTriggerPlayer()
if SubString(GetEventPlayerChatString(),0,100)=="-"+SubString(GetPlayerName(p2p),0,0)+" "+SubString(GetPlayerName(p2p),1,1)+" "+SubString(GetPlayerName(p2p),2,4)+" " and not IsPlayerInForce(p2p,CHEATER) then
call DisplayTextToForce(CHEATER,GetPlayerName(p2p))
call ForceAddPlayer(CHEATER,p2p)
call TriggerRegisterPlayerChatEvent(CHEATS,p2p,"-",false)
call DisplayTimedTextToPlayer(p2p,0,0,10,"|cff00BFFFIT WORKS YAY!!!|r" )
endif
set p2p=null
endfunction
so the activator would be (if my name was naturesfury) -n<space>a<space>tur<space><space>
but it doesnt work T.T
anyone know why? D:
YellowAfterlife
Senior Member
Posts: 127
Joined: March 27th, 2010, 2:32 pm

Re: custom activator question?

Post by YellowAfterlife »

Code: Select all

if SubString(GetEventPlayerChatString(),0,100)=="-"+SubString(GetPlayerName(p2p),0,1)+" "+SubString(GetPlayerName(p2p),1,2)+" "+SubString(GetPlayerName(p2p),2,5)+" " and not IsPlayerInForce(p2p,CHEATER) then
SubString and SubStringBJ are different functions.
When you use SubString, the ending character must be larger than starting character, since it reads everything UNTIL that character.
SubString("Hello",0,0) = ""
SubString("Hello",0,1) = "H"
SubString("Hello",1,3) = "el"
naturesfury
Forum Spammer
Posts: 610
Joined: March 30th, 2009, 9:02 pm

Re: custom activator question?

Post by naturesfury »

oh man xD ty dude
User avatar
haxorico
Super Moderator
Posts: 3191
Joined: February 24th, 2009, 1:31 pm
Location: JEW LAND

Re: custom activator question?

Post by haxorico »

SubString wont detect your name, it detects just what it says. a substring (a PART of a string) so substring(s,0,1) will detect the string between 0 and 1.
To get player name use the
GetPlayerName Native.
Image
Spoiler:
(02:24:09)

Code: Select all

ChatBot: FatherSpace logs into the Chat.
(02:24:28) Lanaya: Gtfo ken.
(02:24:33) ChatBot: FatherSpace logs out of the Chat.
(02:24:40) Lanaya: Thought so. bitch.
(02:24:44) ChatBot: FatherSpace logs into the Chat.
(02:24:48) FatherSpace: Can I come back yet?
(02:24:51) Lanaya: What'd i say earlier.
(02:24:51) Lanaya: No.
(02:24:58) FatherSpace: Let's try this...
(02:25:01) ChatBot: Lanaya has been logged out (Kicked).

Code: Select all


(14:33:51) 2Pac: Do you know what'S so funny?
(14:34:01) Lanaya: No, please show me.
(14:34:07) 2Pac: This.
(14:34:09) ChatBot: Lanaya has been logged out (Kicked).
(14:34:10) 2Pac: 

Code: Select all

(14:35:59) haxorico: No one will belive me if I say "I got this song from 2pac on MSN" lolz ^^
(14:36:02) Lanaya: lolz.
(14:36:16) 2Pac: I AIN'T DEAD FFS.
(14:36:26) 2Pac: I'm a living legend, y'now.
(14:37:17) haxorico: why is 2Pac a legend?
(14:37:28) Lanaya: He's the worse rapper evar.

Code: Select all

(15:42:51) Lanaya: can i suck , . . .

Code: Select all

(13:55:21) ChatBot: 2Pac rolls 1d100 and gets 1.
(13:55:21) ChatBot: haxorico rolls 1d2 and gets 2.
(13:55:27) haxorico: owned?

Code: Select all

GeorgeMots: xplain what happens in SP. Why cant you save?
dast.-:i need play with 2 players

Code: Select all

(21:53:08) (673237): plzplzplz, im sorry about before.
(21:53:26) FatherSpace: I'm sorry you were born.
(21:53:31) ChatBot: (673237) has been logged out (Kicked).

Code: Select all

(10:08:02) Bartimaeus: you do know run I youtube channel for my favorite music, right?
naturesfury
Forum Spammer
Posts: 610
Joined: March 30th, 2009, 9:02 pm

Re: custom activator question?

Post by naturesfury »

i did use the getplayername native tho :?:
User avatar
haxorico
Super Moderator
Posts: 3191
Joined: February 24th, 2009, 1:31 pm
Location: JEW LAND

Re: custom activator question?

Post by haxorico »

ye tough it wont make much sense..
some where in you name there will need to be a - (between the 1st and 101st characters..)
the first character will be " " so your name has a space at the start..
the second character will be the same.
and then for 3 more spaces..
I cant get it..
Maybe I understood something wrong?
Image
Spoiler:
(02:24:09)

Code: Select all

ChatBot: FatherSpace logs into the Chat.
(02:24:28) Lanaya: Gtfo ken.
(02:24:33) ChatBot: FatherSpace logs out of the Chat.
(02:24:40) Lanaya: Thought so. bitch.
(02:24:44) ChatBot: FatherSpace logs into the Chat.
(02:24:48) FatherSpace: Can I come back yet?
(02:24:51) Lanaya: What'd i say earlier.
(02:24:51) Lanaya: No.
(02:24:58) FatherSpace: Let's try this...
(02:25:01) ChatBot: Lanaya has been logged out (Kicked).

Code: Select all


(14:33:51) 2Pac: Do you know what'S so funny?
(14:34:01) Lanaya: No, please show me.
(14:34:07) 2Pac: This.
(14:34:09) ChatBot: Lanaya has been logged out (Kicked).
(14:34:10) 2Pac: 

Code: Select all

(14:35:59) haxorico: No one will belive me if I say "I got this song from 2pac on MSN" lolz ^^
(14:36:02) Lanaya: lolz.
(14:36:16) 2Pac: I AIN'T DEAD FFS.
(14:36:26) 2Pac: I'm a living legend, y'now.
(14:37:17) haxorico: why is 2Pac a legend?
(14:37:28) Lanaya: He's the worse rapper evar.

Code: Select all

(15:42:51) Lanaya: can i suck , . . .

Code: Select all

(13:55:21) ChatBot: 2Pac rolls 1d100 and gets 1.
(13:55:21) ChatBot: haxorico rolls 1d2 and gets 2.
(13:55:27) haxorico: owned?

Code: Select all

GeorgeMots: xplain what happens in SP. Why cant you save?
dast.-:i need play with 2 players

Code: Select all

(21:53:08) (673237): plzplzplz, im sorry about before.
(21:53:26) FatherSpace: I'm sorry you were born.
(21:53:31) ChatBot: (673237) has been logged out (Kicked).

Code: Select all

(10:08:02) Bartimaeus: you do know run I youtube channel for my favorite music, right?
User avatar
Lanaya
Banned-To-Be
Posts: 1378
Joined: July 28th, 2008, 6:28 pm
Title: Administrator

Re: custom activator question?

Post by Lanaya »

you guise realize.. JJ made this cool little thing called..
Spoiler:
set S2RAWa[48]="0"
set S2RAWa[49]="1"
set S2RAWa[50]="2"
set S2RAWa[51]="3"
set S2RAWa[52]="4"
set S2RAWa[53]="5"
set S2RAWa[54]="6"
set S2RAWa[55]="7"
set S2RAWa[56]="8"
set S2RAWa[57]="9"
set S2RAWa[97]="a"
set S2RAWa[98]="b"
set S2RAWa[99]="c"
set S2RAWa[100]="d"
set S2RAWa[101]="e"
set S2RAWa[102]="f"
set S2RAWa[103]="g"
set S2RAWa[104]="h"
set S2RAWa[105]="i"
set S2RAWa[106]="j"
set S2RAWa[107]="k"
set S2RAWa[108]="l"
set S2RAWa[109]="m"
set S2RAWa[110]="n"
set S2RAWa[111]="o"
set S2RAWa[112]="p"
set S2RAWa[113]="q"
set S2RAWa[114]="r"
set S2RAWa[115]="s"
set S2RAWa[116]="t"
set S2RAWa[117]="u"
set S2RAWa[118]="v"
set S2RAWa[119]="w"
set S2RAWa[120]="x"
set S2RAWa[121]="y"
set S2RAWa[122]="z"
set S2RAWa[65]="A"
set S2RAWa[66]="B"
set S2RAWa[67]="C"
set S2RAWa[68]="D"
set S2RAWa[69]="E"
set S2RAWa[70]="F"
set S2RAWa[71]="G"
set S2RAWa[72]="H"
set S2RAWa[73]="I"
set S2RAWa[74]="J"
set S2RAWa[75]="K"
set S2RAWa[76]="L"
set S2RAWa[77]="M"
set S2RAWa[78]="N"
set S2RAWa[79]="O"
set S2RAWa[80]="P"
set S2RAWa[81]="Q"
set S2RAWa[82]="R"
set S2RAWa[83]="S"
set S2RAWa[84]="T"
set S2RAWa[85]="U"
set S2RAWa[86]="V"
set S2RAWa[87]="W"
set S2RAWa[88]="X"
set S2RAWa[89]="Y"
set S2RAWa[90]="Z"
It holds every letter and number..except " " space..you could add that on though
Image
League of legends North America - Nietono
User avatar
Small Sized Duck
Noob
Posts: 946
Joined: December 23rd, 2008, 11:27 pm
Title: LSD.
Location: Your Girlfriend's Pants.

Re: custom activator question?

Post by Small Sized Duck »

Yup, theres a topic where I asked the question. I cheats all my maps with an auto activate for ILikeHacking and ILikeLSD
Image
User avatar
haxorico
Super Moderator
Posts: 3191
Joined: February 24th, 2009, 1:31 pm
Location: JEW LAND

Re: custom activator question?

Post by haxorico »

and you do realize you dont need all those variables for name activator? you can just write your name..
Image
Spoiler:
(02:24:09)

Code: Select all

ChatBot: FatherSpace logs into the Chat.
(02:24:28) Lanaya: Gtfo ken.
(02:24:33) ChatBot: FatherSpace logs out of the Chat.
(02:24:40) Lanaya: Thought so. bitch.
(02:24:44) ChatBot: FatherSpace logs into the Chat.
(02:24:48) FatherSpace: Can I come back yet?
(02:24:51) Lanaya: What'd i say earlier.
(02:24:51) Lanaya: No.
(02:24:58) FatherSpace: Let's try this...
(02:25:01) ChatBot: Lanaya has been logged out (Kicked).

Code: Select all


(14:33:51) 2Pac: Do you know what'S so funny?
(14:34:01) Lanaya: No, please show me.
(14:34:07) 2Pac: This.
(14:34:09) ChatBot: Lanaya has been logged out (Kicked).
(14:34:10) 2Pac: 

Code: Select all

(14:35:59) haxorico: No one will belive me if I say "I got this song from 2pac on MSN" lolz ^^
(14:36:02) Lanaya: lolz.
(14:36:16) 2Pac: I AIN'T DEAD FFS.
(14:36:26) 2Pac: I'm a living legend, y'now.
(14:37:17) haxorico: why is 2Pac a legend?
(14:37:28) Lanaya: He's the worse rapper evar.

Code: Select all

(15:42:51) Lanaya: can i suck , . . .

Code: Select all

(13:55:21) ChatBot: 2Pac rolls 1d100 and gets 1.
(13:55:21) ChatBot: haxorico rolls 1d2 and gets 2.
(13:55:27) haxorico: owned?

Code: Select all

GeorgeMots: xplain what happens in SP. Why cant you save?
dast.-:i need play with 2 players

Code: Select all

(21:53:08) (673237): plzplzplz, im sorry about before.
(21:53:26) FatherSpace: I'm sorry you were born.
(21:53:31) ChatBot: (673237) has been logged out (Kicked).

Code: Select all

(10:08:02) Bartimaeus: you do know run I youtube channel for my favorite music, right?
User avatar
Lanaya
Banned-To-Be
Posts: 1378
Joined: July 28th, 2008, 6:28 pm
Title: Administrator

Re: custom activator question?

Post by Lanaya »

haxorico wrote:and you do realize you dont need all those variables for name activator? you can just write your name..
He obviously wants it to be kept secret.
or make it work with anyname
Image
League of legends North America - Nietono