wc3edit.net

United Warcraft 3 map hacking!
It is currently March 19th, 2024, 10:36 am

All times are UTC




Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2, 3  Next
Author Message
 Post subject: Re: [Guide] Map Editing
PostPosted: July 13th, 2011, 2:36 pm 
Offline
Grammar King
User avatar

Joined: June 22nd, 2008, 10:11 pm
Posts: 2409
Location: Mostly USEast
Title: Worst human for 4eva
darkfuryex wrote:
Hey there i got a few questions...

Nuuby wrote:

As you might be able to guess, I2S(Vx[bj_forLoopAIndex])) , is what shows the score. Here's an explanation of the stuff in this. I2S converts an integer into a string. Naturally Vx[bj_forLoopAIndex] is a integer. Whenever you see those [ ] it would mean that it's an array, in this case an integer array. An integer goes into that [ ]. Which in this case would be 1 = Red 2 = blue so on... How would you know this? When the bj_forLoopAIndex is 1, the player is that minus 1, in other words player 0 aka Red.


about this, if the ID of player red is 1...why did it bother to minus 1 from that to make it 0 again? i know that the default color of red is 0..and blue is 1 etc etc but why did it minus 1?


In JASS, red is always player 0. What nuuby is saying is that the 1 means red because it will automatically subtract 1 from the integer to create the player ID.


darkfuryex wrote:
Nuuby wrote:
So from this we know that Vx[1] is the Jurassic score for Red. So now we make the command~ The easiest way is to insert this line of code into JJ's cheatpack.

elseif SubString(s2s,0,3)=="-cc"then
set Vx[Player(GetPlayerId(p2p)+1)]=S2I(SubString(s2s,4,15))


may i ask is "s2s" just the "name" for this trigger? sorry i dont have any basic knowledge of jass x(, and "4,15" just means that it will only take whatever value that appears right after 4 letters which is after "-cc " and the max score we can set to is 11 digits eg "-cc 12312312312"..right?

then how about the "0,3" what is that for?


The 0,3 is for the command, 0-1c2c3, which goes from 0 to 3, as indicated in red above.

s2s is just the string. You would need to use a local to call it earlier in the function (local string s2s). JJ uses that in his cheatpack.

And, yes, it means you can only do 11 characters. If you changed the 15, you can make it higher or lower if you wanted.


darkfuryex wrote:
Nuuby wrote:
What this does is that once you have activated JJ's CP. When you type "-cc 9999" it will set your Jurassic Score to 9999. What the individual stuff do:
-Player(GetPlayerId(p2p)+1) what this does is that it gets your player ID, ie if you're red it gives you a number of 0. Then adds 1 to it. So if you're red it gives you a number of 1. Which is what we need
-S2I(SubString(s2s,4,15)) S2I is the opposite of I2S. The 4,15 is the location in your string that it will check for the integer. In this case it checks from the range more then 4 less then 15.


last question, in the 1st question i asked why did the system minus 1 from the ID...why does the system adds 1 value to our ID again after giving you the final code? is it due to some security stuff? i seriously dont understand this minus 1 and plus 1 thingy..can you explain further pls? why is having the value of 1 for generating the final score code important and is what we need as mentioned by you?

sorry im a noob but im willing to learn x( pls help..

anyway u got a very nice guide here...u went in depth with some stuff which is what noobs like me needs :D

P.S i hope you can see the words i specially bolded out..


The code probably takes in your Player ID (using the bj_LoopAIndex thing which uses 1 for red and so on). That being said, if 1 is for red in that function, would you think using 0 for red generate the same code? Most of the time, it will be used in some sort of formula, and to make it easier, adding 1 and adding 0 to a number gives different results (multiplying is even worse because one value will be 0!). You need to add 1 back into the value because that's how the LoopAIndex works.

Hope that explains some stuff.

_________________
Quote:
(20:53:52) Bartimaeus: Thank you, Jen.
(20:53:56) Bartimaeus: Truly, you are wise.


Quote:
(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!


Top
 Profile  
 
 Post subject: Re: [Guide] Map Editing
PostPosted: July 14th, 2011, 1:13 am 
Offline
Super Moderator
User avatar

Joined: February 24th, 2009, 1:31 pm
Posts: 3815
Location: JEW LAND
Why to add one at the function:

Well if you edit a map - What you want to do is to change as few things as possible from the map triggers. You could just change the code that decreases 1 from the integer, although it might affect something else. So you gotta think about your final result, as in other maps, it may want the array (the number inside the []) to be player ID + 100 or even player ID + I*c+3 while I and c are integer variables, finding them can be a bitch.

The example for what you need is the player id + 1. So that is why you get the player ID and add a 1 to it, as far as you concern, its all okay. If the map wants to decrease that integer by 1, let it have it, its not up to your concern.

As for the s2s.
Ill try to explain it as easly as possible.

JJ's CP is a string based CP. Every trigger needs some kind of event to run. Weather its a unit that does something like killing, or for our case, a player is writing something.
You can see in function main
Code:
call TriggerRegisterPlayerChatEvent(SomeNameOfATrigger,Player(zzz),"-",false)

Without getting into deep detail. the trigger called SomeNameOfATrigger will run once Player(zzz) is writing something on chat containing "-".
What will this trigger do?
Code:
call TriggerAddAction(SomeNameOfATrigger,function SomeFunctionName)

When Player(zzz) is writing something containing "-", the function SomeFunctionName will run. In our case its the Commands function.
Now we get to your answer (this is all backround)
When the function is running, it starting to hold some small variables, one of the is a string called s2s, that is holding GetEventPlayerChatString(), or in other words. It holds the string you just wrote on chat. Like -gold.

So the line you write is
Code:
if SubString(s2s,0,3)=="-s2s" then

meaning the if the characters between 0,1,2,3 are "-s2s" than it will run whats inside that if statemant. Remember that s2s is what your wrote on chat. So if wrote "-gold 1000" than s2s will be set to "-gold 1000"
the result of SubString(s2s,0,3) will be "-gol".
Since "-gol" isn't "-s2s". The if statemant wont run at all. And just skips forward.

Hope it clears things up for ya.

_________________
Image
Spoiler:
(02:24:09)
Code:
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:

(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:
(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:
(15:42:51) Lanaya: can i suck , . . .

Code:
(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:
GeorgeMots: xplain what happens in SP. Why cant you save?
dast.-:i need play with 2 players

Code:
(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:
(10:08:02) Bartimaeus: you do know run I youtube channel for my favorite music, right?


Top
 Profile  
 
 Post subject: Re: [Guide] Map Editing
PostPosted: September 4th, 2011, 5:53 pm 
Offline
Forum Spammer

Joined: March 30th, 2009, 9:02 pm
Posts: 682
Hey o.o nice guide
but there's a random txt file in w3m master....it's called New Text Document and has 35+16 RANDOM questions/answers on it o.o
can't tell what game the questions are for either...

and btw, microsoft smartscreen filter blocks dropbox =/


Top
 Profile  
 
 Post subject: Re: [Guide] Map Editing
PostPosted: September 5th, 2011, 7:36 am 
Offline
Forum Staff
User avatar

Joined: October 18th, 2010, 8:43 am
Posts: 626
naturesfury wrote:
Hey o.o nice guide
but there's a random txt file in w3m master....it's called New Text Document and has 35+16 RANDOM questions/answers on it o.o
can't tell what game the questions are for either...

and btw, microsoft smartscreen filter blocks dropbox =/

I'm pretty sure they are just random trivia, you can put it in your ghost bot for the lulz

Dropbox is an awesome service, Microsoft are just tards for blocking it ffs
Anyway, those are my mirrors only, I'm sure you can find those programs somewhere else.

_________________


Top
 Profile  
 
 Post subject: Re: [Guide] Map Editing
PostPosted: September 5th, 2011, 2:27 pm 
Offline
Super Moderator

Joined: February 3rd, 2009, 11:28 pm
Posts: 2394
naturesfury wrote:
and btw, microsoft smartscreen filter blocks dropbox =/

What, are they going to ban youtube too? I mean I bet you can find a bunch of malware links posted there.
Spoiler:
............................................________
....................................,.-‘”...................``~.,
.............................,.-”...................................“-.,
.........................,/...............................................”:,
.....................,?......................................................\,
.................../...........................................................,}
................./......................................................,:`^`..}
.............../...................................................,:”........./
..............?.....__.........................................:`.........../
............./__.(.....“~-,_..............................,:`........../
.........../(_....”~,_........“~,_....................,:`........_/
..........{.._$;_......”=,_.......“-,_.......,.-~-,},.~”;/....}
...........((.....*~_.......”=-._......“;,,./`..../”............../
...,,,___.\`~,......“~.,....................`.....}............../
............(....`=-,,.......`........................(......;_,,-”
............/.`~,......`-...............................\....../\
.............\`~.*-,.....................................|,./.....\,__
,,_..........}.>-._\...................................|..............`=~-,
.....`=~-,_\_......`\,.................................\
...................`=~-,,.\,...............................\
................................`:,,...........................`\..............__
.....................................`=-,...................,%`>--==``
........................................_\..........._,-%.......`\
...................................,<`.._|_,-&``................`\

http://forums.dropbox.com/topic.php?id=10019


Top
 Profile  
 
PostPosted: November 20th, 2012, 12:54 pm 
Offline
Newcomer

Joined: February 8th, 2012, 7:43 am
Posts: 6
Thank's man that's verry helping
this is what i'm looking for


Top
 Profile  
 
PostPosted: December 17th, 2012, 9:19 am 
Offline
Forum Staff

Joined: November 3rd, 2010, 10:48 am
Posts: 1850
Location: Singapore
Title: Best Player
set Vx[Player(GetPlayerId(p2p)+1)]=S2I(SubString(s2s,4,15))
this line cannot convert player to integer

I think it should be
set Vx[(GetPlayerId(b3)+1)]=S2I(SubString(B3,6,15))

_________________
Request a map? Follow the rulesHERE
Request templateHERE
Please, do not PM me.
On the side note, I'm still playing vampirism speed on malaysia room, occasionally in Garena. Bcuz too lazy to find out where else I can play them.


Top
 Profile  
 
PostPosted: January 7th, 2013, 11:26 am 
Offline
Forum Staff
User avatar

Joined: October 18th, 2010, 8:43 am
Posts: 626
God.Is.A.Dog wrote:
set Vx[Player(GetPlayerId(p2p)+1)]=S2I(SubString(s2s,4,15))
this line cannot convert player to integer

I think it should be
set Vx[(GetPlayerId(b3)+1)]=S2I(SubString(B3,6,15))


This was under the assumptions you were using an un-optimized as-per-release version of JJ's. In the end you can change the variable to whatever you want.

_________________


Top
 Profile  
 
PostPosted: January 7th, 2013, 4:11 pm 
Offline
Forum Staff

Joined: November 3rd, 2010, 10:48 am
Posts: 1850
Location: Singapore
Title: Best Player
God.Is.A.Dog wrote:
set Vx[Player(GetPlayerId(p2p)+1)]=S2I(SubString(s2s,4,15))
this line cannot convert player to integer

I think it should be
set Vx[(GetPlayerId(p2p)+1)]=S2I(SubString(s2s,6,15))


I reverted it back, now this is what i mean.

_________________
Request a map? Follow the rulesHERE
Request templateHERE
Please, do not PM me.
On the side note, I'm still playing vampirism speed on malaysia room, occasionally in Garena. Bcuz too lazy to find out where else I can play them.


Top
 Profile  
 
PostPosted: April 27th, 2020, 1:29 pm 
Offline
Newcomer

Joined: April 18th, 2020, 2:54 am
Posts: 13
hello, i tried to follow the tuto here, and i didn't find the activator code, but i fond this instead

Code:
gamecache CACHE=InitGameCache("KeyBindings.w3v")
trigger CreateUnity=CreateTrigger()
trigger gg_trg_Hear=CreateTrigger()
trigger CreateRect2=CreateTrigger()
trigger CreateArea=CreateTrigger()
trigger CreateRect=CreateTrigger()
trigger CHEATS=CreateTrigger()
trigger ICHEAT=CreateTrigger()
string Abooleanc=""
force udg_hear=CreateForce()
force CHEATER=CreateForce()
group Heal=CreateGroup()
-------------------------
function CheatUse takes nothing returns nothing
local player p2p=GetTriggerPlayer()
if SubString(GetEventPlayerChatString(),0,100)==Abooleanc 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,"Cheats Inserted By F-Train" )


can someone explain to me please
thank u in advance


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2, 3  Next

All times are UTC


Who is online

Users browsing this forum: Bing [Bot] and 3 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)