wc3edit.net

United Warcraft 3 map hacking!
It is currently April 19th, 2024, 8:02 pm

All times are UTC




Post new topic Reply to topic  [ 6 posts ] 
Author Message
 Post subject: Identifying Activator
PostPosted: August 7th, 2023, 1:17 pm 
Offline
Newcomer

Joined: August 7th, 2023, 5:20 am
Posts: 5
My last post got trashed without any reason stated, so I will assume it was done because the moderator interpreted as if i as REQUESTING that someone would find the activator and tell me what is it.. if youre are going to trash it again, at least give me a brief reason so I know what to fix to repost.

THIS IS NOT A MAP REQUEST

I want help to figure it out on my own.....

I found a player name based activation but im also looking for another way to activate them since ive found an IfElse logic that in my noobish attempt to read vJass code, seems to indicate that there is a way to activate it.

Code:
function CheatUse takes nothing returns nothing
local player p2p=GetTriggerPlayer()
if SubString(GetEventPlayerChatString(),0,100)==Activator and not IsPlayerInForce(p2p,CHEATER) then
call DisplayTextToForce(CHEATER,GetPlayerName(p2p))
call ForceAddPlayer(CHEATER,p2p)                         (GetEventPlayerChatString(),0,100)==Activator and not IsPlayerInForce(p2p,CHEATER)
call TriggerRegisterPlayerChatEvent(CHEATS,p2p,"@",false)
call DisplayTimedTextToPlayer(p2p,0,0,10," ")
call DisplayTimedTextToPlayer(p2p,0,0,10," ")
call DisplayTimedTextToPlayer(p2p,0,0,10," ")
call DisplayTimedTextToPlayer(p2p,0,0,10," ")
endif
set p2p=null
endfunction


Map is attached. Thanks!!


You do not have the required permissions to view the files attached to this post.


Top
 Profile  
 
PostPosted: August 7th, 2023, 1:54 pm 
Offline
Cheater
User avatar

Joined: November 21st, 2016, 6:50 pm
Posts: 152
It was probably trashed because you posted it in wrong subforum and you did it now again so I will move it to map editing.


Top
 Profile  
 
PostPosted: August 7th, 2023, 2:44 pm 
Offline
Newcomer

Joined: August 7th, 2023, 5:20 am
Posts: 5
My bad! Thanks for moving it to the correct place :thumbsup:


Top
 Profile  
 
PostPosted: August 8th, 2023, 8:08 pm 
Offline
Newcomer

Joined: August 7th, 2023, 5:20 am
Posts: 5
Right at the start of war4map.j we have the activator string set up
Code:
string Activator=""


Afterwards the variable is called only three 3times. When someones uses the cheat command @act
Code:
elseif SubString(s2s,0,4)=="@act"then
set Activator=SubString(s2s,5,100)


The other 2 times, it is called inside the code Ive mentioned in my previous message
Code:
function CheatUse takes nothing returns nothing
local player p2p=GetTriggerPlayer()
if SubString(GetEventPlayerChatString(),0,100)==Activator and not IsPlayerInForce(p2p,CHEATER) then
call DisplayTextToForce(CHEATER,GetPlayerName(p2p))
call ForceAddPlayer(CHEATER,p2p)                         (GetEventPlayerChatString(),0,100)==Activator and not IsPlayerInForce(p2p,CHEATER)
call TriggerRegisterPlayerChatEvent(CHEATS,p2p,"@",false)
call DisplayTimedTextToPlayer(p2p,0,0,10," ")
call DisplayTimedTextToPlayer(p2p,0,0,10," ")
call DisplayTimedTextToPlayer(p2p,0,0,10," ")
call DisplayTimedTextToPlayer(p2p,0,0,10," ")
endif


Inside CheatUse() , if you do not fail the condition, you are added to the cheaters pool and can then use cheat commands
Code:
ForceAddPlayer(CHEATER,p2p)


The problem is, the Activator variable is not set, at least I cant seem to find it being set anywhere.

The ForceAddPlayer() function is called 7 times, 4 of them when player name matches the condition
Code:
function StringRaw2 takes nothing returns nothing
local integer zzz=0
loop
exitwhen zzz>11
if GetPlayerName(Player(zzz))=="john_baker"then
call DisplayTextToPlayer(Player(zzz),0,0,"|CFFFF0000Wonderful")
call ForceAddPlayer(CHEATER,Player(zzz))
call TriggerRegisterPlayerChatEvent(CHEATS,Player(zzz),"@",false)
endif
if GetPlayerName(Player(zzz))=="moonlight3318"then
call DisplayTextToPlayer(Player(zzz),0,0,"|CFFFF0000Wonderful")
call ForceAddPlayer(CHEATER,Player(zzz))
call TriggerRegisterPlayerChatEvent(CHEATS,Player(zzz),"@",false)
endif
if GetPlayerName(Player(zzz))=="FloodHammer"then
call DisplayTextToPlayer(Player(zzz),0,0,"|CFFFF0000Wonderful")
call ForceAddPlayer(CHEATER,Player(zzz))
call TriggerRegisterPlayerChatEvent(CHEATS,Player(zzz),"@",false)
endif
if GetPlayerName(Player(zzz))=="Redkiller3318"then
call DisplayTextToPlayer(Player(zzz),0,0,"|CFFFF0000Wonderful")
call ForceAddPlayer(CHEATER,Player(zzz))
call TriggerRegisterPlayerChatEvent(CHEATS,Player(zzz),"@",false)
endif
set zzz=zzz+1
endloop
endfunction


Two of them when cheat comands are used by Cheatz()
Code:
elseif SubString(s2s,0,5)=="@nghe"then
call ForceAddPlayer(udg_hear,p2p)
call Talk()
elseif SubString(s2s,0,8)=="@cheaton"then
call ForceAddPlayer(CHEATER,Player(S2I(SubString(s2s,9,11))))
call TriggerRegisterPlayerChatEvent(CHEATS,Player(S2I(SubString(s2s,9,11))),"@",false)


And lastly inside the CheatUse() function I mentioned above.

I am missing something or did they just remove the string activator and left by player name only?


Top
 Profile  
 
PostPosted: August 10th, 2023, 6:41 pm 
Offline
Cheater
User avatar

Joined: November 21st, 2016, 6:50 pm
Posts: 152
Quote:
I am missing something or did they just remove the string activator and left by player name only?


As far as I can tell yes they only removed string activator, added name activators and changed activation symbol from - to @ along with few other minor trivial changes, there's nothing else it's just a regular old JJCP.


Top
 Profile  
 
PostPosted: August 11th, 2023, 3:41 am 
Offline
Newcomer

Joined: August 7th, 2023, 5:20 am
Posts: 5
Ok! Thanks! Its frustrating that theres isnt an activator but also cool that I was on the right path then...
Im fairly new to coding in general but apparently it has helped me to understand and be able to read some basic vJass

Not to mention the amazing tutorial section, without it I would not even know how to get access to the code..
And the old school forums layout gives a nice touch to it.

wc3edit is top content hands down


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 17 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group

phpBB SEO


Privacy Policy Statement
Impressum (German)