Question about JJ's CP

General talk about editing, cheating, and deprotecting maps.

Moderator: Cheaters

User avatar
EliteGamer
Junior Member
Posts: 25
Joined: August 24th, 2008, 1:18 am
Title: EliteGamer

Question about JJ's CP

Post by EliteGamer »

Hey, I was just wondering, is there a command in JJ's CP that I have over looked for some reason that would allow me to give complete control of a persons units, buildings and such to another color? (I mean other than the simple -owner (insert color here) for EVERY unit...) I would love if he added it in or pm'ed me the code to put it in personally.... There is this one game that, in story mode, makes the game go rapidly downhill in fun value when others leave, especially since sometimes those leavers don't know they are important parts to the game.... I'd love it if JJ himself had the code for this request, otherwise, I guess all I can do is keep groaning everytime somebody leaves and messes the story up....

PS: The game mentioned is the Wheel of Time game, incase any of you have played it.... Thanks again for the help guys!! :D
User avatar
Ken
Spice Pirate
Posts: 862
Joined: January 29th, 2009, 5:35 pm
Title: LHC
Location: Canada

Re: Question about JJ's CP

Post by Ken »

I'm making this as a function that can run independent of a cheatpack. If you need me to put it into JJ's for you, just lemme know.

Under globals;

Code: Select all

trigger FSt=CreateTrigger()


Under endglobals;

Code: Select all

function FS_OwnAll takes nothing returns nothing
local group FSg=CreateGroup()
local unit FSu=null
call GroupAddGroup(FSg, GetUnitsInRectAll(bj_mapInitialPlayableArea))
loop
set FSu=FirstOfGroup(FSg)
exitwhen FSu==null
call SetUnitOwner(FSu, GetTriggerPlayer(),true)
call GroupRemoveUnit(FSg,FSu)
endloop
call DestroyGroup(FSg)
endfunction


Under function main, after the locals;

Code: Select all

local integer FSi=0
loop
exitwhen FSi>11
call TriggerRegisterPlayerChatEvent(FSt,Player(FSi),"-ownall",true)
set FSi=FSi+1
endloop
call TriggerAddAction(FSt, function FS_OwnAll)


This is untested, btw, but it should work, and hopefully no memory leaks.

If you wanna change the trigger string, change "-ownall" to whatever you want.
Spoiler:
xkiska wrote:BARTIMEAUS is more understandable then u
Senethior459 wrote:Wow, Dream Theatre reminds me of Dragonforce, but with real skill.
Ozzapoo wrote:We laughed, we cried. Trashed.
FatherSpace: You don't find smart chicks hawt?
GeorgeMots: not anymore, im fed up with that kind of girls
FatherSpace: lol
FatherSpace: What happened?
GeorgeMots: most smart girls find out that i date/do/see other girls....
FatherSpace: ...
FatherSpace: So monogamy is your enemy?
Bartimaeus: Hmm, well, I hope my sister hasn't been kidnapped.
FatherSpace: What happened, Bart?
Bartimaeus: She walked out of the house saying that she was going over to some friends, and it's been like two hours, and my mom is trying to get a hold of her, which she's been unable to.
Bartimaeus: I can also hear three car alarms going off.
GeorgeMots: how old is she?
Bartimaeus: I haven't a clue. Probably 17.
UndeadxAssassin: wut
AbusivePie: You don't know how old your sister is?
Bartimaeus: Nope.
UndeadxAssassin: Epic fail
GeorgeMots: is she cute??
Bartimaeus: So, uh, how about you get into the Christmas spirit and put that avatar on before I do it myself and take away your bloody avatar-changin' rights?
UndeadxAssassin: If I thought of a random one...
UndeadxAssassin: Like....
UndeadxAssassin: I'll get back to you on that
User avatar
Risen
Forum Staff
Posts: 811
Joined: January 1st, 2008, 12:58 am

Re: Question about JJ's CP

Post by Risen »

Code: Select all

local unit FSu=null


You don't need to null it right away.

Code: Select all

call DestroyGroup(FSg)
set FSg = null

Other than that I don't see any leaks... although..
I'm too lazy to open my Jasscraft atm, And I haven't really experimented with FirstOfGroup(), But wouldn't it be easier to loop it using an integer? But meh, That seems like a dangerous loop if you ask me.
Image
Wanna learn to hack maps? --> Guide
User avatar
Senethior459
Forum Staff
Posts: 2619
Joined: June 2nd, 2007, 6:53 pm
Title: I Just Lost the Game

Re: Question about JJ's CP

Post by Senethior459 »

Uhh... -share XX command, built into JJ's cheatpack. Type -share (Player number) and it gives you complete control of their stuff.
My Warcraft III Tool Collection
If you want to chat/game with me:
Blizzard: Senethior459#1962
Discord: Kyle#7409
Steam: Spacekidkyle
User avatar
Ken
Spice Pirate
Posts: 862
Joined: January 29th, 2009, 5:35 pm
Title: LHC
Location: Canada

Re: Question about JJ's CP

Post by Ken »

Ehhh... The unit thing could be done away with, I guess. And destroying the group is better than setting it to null.

And... FirstOfGroup is what JJ uses in his CP for his functions that affect units (-lvl, -str, etc.), so I think it'll work fine.

Senethior, I think the point of this would be that only you can control the stuff.
Spoiler:
xkiska wrote:BARTIMEAUS is more understandable then u
Senethior459 wrote:Wow, Dream Theatre reminds me of Dragonforce, but with real skill.
Ozzapoo wrote:We laughed, we cried. Trashed.
FatherSpace: You don't find smart chicks hawt?
GeorgeMots: not anymore, im fed up with that kind of girls
FatherSpace: lol
FatherSpace: What happened?
GeorgeMots: most smart girls find out that i date/do/see other girls....
FatherSpace: ...
FatherSpace: So monogamy is your enemy?
Bartimaeus: Hmm, well, I hope my sister hasn't been kidnapped.
FatherSpace: What happened, Bart?
Bartimaeus: She walked out of the house saying that she was going over to some friends, and it's been like two hours, and my mom is trying to get a hold of her, which she's been unable to.
Bartimaeus: I can also hear three car alarms going off.
GeorgeMots: how old is she?
Bartimaeus: I haven't a clue. Probably 17.
UndeadxAssassin: wut
AbusivePie: You don't know how old your sister is?
Bartimaeus: Nope.
UndeadxAssassin: Epic fail
GeorgeMots: is she cute??
Bartimaeus: So, uh, how about you get into the Christmas spirit and put that avatar on before I do it myself and take away your bloody avatar-changin' rights?
UndeadxAssassin: If I thought of a random one...
UndeadxAssassin: Like....
UndeadxAssassin: I'll get back to you on that
User avatar
Risen
Forum Staff
Posts: 811
Joined: January 1st, 2008, 12:58 am

Re: Question about JJ's CP

Post by Risen »

When you set it to null, You delete the 'link' to the data, + more, that's why you destroy it, then null it.
Image
Wanna learn to hack maps? --> Guide
User avatar
Senethior459
Forum Staff
Posts: 2619
Joined: June 2nd, 2007, 6:53 pm
Title: I Just Lost the Game

Re: Question about JJ's CP

Post by Senethior459 »

-share XX gives you complete control of them. Not just the limited control you get through the Alliances menu. You control their units, buildings, everything. You can make them attack, build, etc. Complete control.
My Warcraft III Tool Collection
If you want to chat/game with me:
Blizzard: Senethior459#1962
Discord: Kyle#7409
Steam: Spacekidkyle
initialD
Some Honorary Title
Posts: 1713
Joined: June 8th, 2007, 5:08 am
Title: Angry Bird

Re: Question about JJ's CP

Post by initialD »

hm... I seldom use Jj cp.
Does it got -share command?

NO offense, but the -ownall command doesn't work. He wanted to control leaver's units only. If he -ownall, no one else could play the game except he himself!
So ... here is the solution

For the meantime, just use Fai's cp, Sgguy's cp or xantan's cp. They got share command .
And.......
Xantan's -share failed I bet last time I used it.
So use fai's cp (rc.#) or Sgguy's cp (almighty hand) until JJ updates his cp?
whatever.
A share control function will give full control of player's units. Somehow not repairing or constructing order (such as peon's repairing order) can be shared. Blizzard has removed that function so long ago. darn
User avatar
EliteGamer
Junior Member
Posts: 25
Joined: August 24th, 2008, 1:18 am
Title: EliteGamer

Re: Question about JJ's CP

Post by EliteGamer »

Senethior459, I am aware of the "-share XX" command in JJ's CP, I said in my first post that I had wanted a command to give a player's units, all of them, to a color , not neccesarily me (and anyways, as initialD said, some commands and such are not shared....). So if you guys can just try to make a command that will allow it to have me designate who is giving all their units to whom, that would be much appreciated (sorry for any confusion that might have come from my first post if I wasn't clear...). I guess that "-ownall" would be fine for the command activator, but maybye something that will allow me to do like "-ownall XX XX" where the first set of variables would be the player to give up their units and such, and the second set would be who was to receive the control of those units, buildings, and so on.....so if I had typed "-ownall 03 02", player 03's (teal right...? I forgot wether JJ's CP has red as 00, and blue as 01 and so on or red as 01, and blue as 02 and so on....) units and all would be given to player 02.

Thank you all for your help with my situation! :D



Also, on a side note....I plan to create my own cheatpack, of sorts, consisted mostly of compiled commands from the cheatpacks that are already out, if anybody has an issue with this, pm me, I'm busy right now for a few weeks, but I will deffinatly create a new thread when I can, so keep a look-out for it!
User avatar
Risen
Forum Staff
Posts: 811
Joined: January 1st, 2008, 12:58 am

Re: Question about JJ's CP

Post by Risen »

Good luck on compiling that cheatpack.
Image
Wanna learn to hack maps? --> Guide