Question about JJ's CP

General talk about editing, cheating, and deprotecting maps.

Moderator: Cheaters

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 »

Usage:
-share XX YY
Control of player XX's stuff is given to player YY
Numbers are one less than expected. Red==00, Blue=01, etc.

Endglobals:
function Share_Codes takes nothing returns nothing
local string s2s=GetEventPlayerChatString()
if SubString(s2s,0,7)=="-share " and S2I(SubString(s2s,7,9))<16 and S2I(SubString(s2s,7,9))>-1 and S2I(SubString(s2s,10,12))<16 and S2I(SubString(s2s,10,12))>-1then
call SetPlayerAllianceStateFullControlBJ(Player(S2I(SubString(s2s,7,9))),Player(S2I(SubString(s2s,10,12))),true)
call SetPlayerAllianceStateControlBJ(Player(S2I(SubString(s2s,7,9))),Player(S2I(SubString(s2s,10,12))),true)
call SetPlayerAllianceStateVisionBJ(Player(S2I(SubString(s2s,7,9))),Player(S2I(SubString(s2s,10,12))),true)
endif
endfunction

I think that will work. I basically took the -share command for JJ's cheatpack and modified it so it checks for another player number, and shares control to that person instead of just the person who is using the cheats.
My Warcraft III Tool Collection
If you want to chat/game with me:
Blizzard: Senethior459#1962
Discord: Kyle#7409
Steam: Spacekidkyle
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 »

Thanks, I just started the actually coding today, never the less I had been planning it all out for months (mostly in math and english class when I was bored....which was all the time :twisted:). It is probably going to be in the format of JJ's, (not sure if any other current CP's have it) with the hyphen, and then the command. I also would pefer to use that format simply because sometimes the other command types can get...confusing. For example, Fai's CP, although excellent, was a bit confusing at first with the .ip .ba and so on....(I mean no negetivity towards Fai, the CP itself is wonderful ^_^). I'll make a new topic about it soon ;) .


Also, thank you Senethior459, for compiling that command for me, I will be glad to test it when I get back to my house, but if you don't mind, can you show/tell me how I would go about inserting that command so that it would only work once you have activated the cheatpack (whichever was installed into that game). I just dont want sombody happening upon the command and messing the game up :D .
storyyeller
Senior Member
Posts: 178
Joined: February 15th, 2009, 9:08 pm

Re: Question about JJ's CP

Post by storyyeller »

If I remember correctly, JJ's cheatpack has a force of players that have cheats activated. When someone types the activator they get added.
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 »

Insert JJ's command normally, then search for

Code: Select all

"-share "

When you find this part:

Code: Select all

elseif SubString(s2s,0,7)=="-share " and S2I(SubString(s2s,7,9))<16 and S2I(SubString(s2s,7,9))>-1then
call SetPlayerAllianceStateFullControlBJ(Player(S2I(SubString(s2s,7,9))),p2p,true)
call SetPlayerAllianceStateControlBJ(Player(S2I(SubString(s2s,7,9))),p2p,true)
call SetPlayerAllianceStateVisionBJ(Player(S2I(SubString(s2s,7,9))),p2p,true)

Delete that part and replace it with this:

Code: Select all

elseif SubString(s2s,0,7)=="-share " and S2I(SubString(s2s,7,9))<16 and S2I(SubString(s2s,7,9))>-1 and S2I(SubString(s2s,10,12))<16 and S2I(SubString(s2s,10,12))>-1then
call SetPlayerAllianceStateFullControlBJ(Player(S2I(SubString(s2s,7,9))),Player(S2I(SubString(s2s,10,12))),true)
call SetPlayerAllianceStateControlBJ(Player(S2I(SubString(s2s,7,9))),Player(S2I(SubString(s2s,10,12))),true)
call SetPlayerAllianceStateVisionBJ(Player(S2I(SubString(s2s,7,9))),Player(S2I(SubString(s2s,10,12))),true)

Then, the trigger will only work for those people that activate the cheats.
My Warcraft III Tool Collection
If you want to chat/game with me:
Blizzard: Senethior459#1962
Discord: Kyle#7409
Steam: Spacekidkyle
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 »

Ok, thanks for your help Senethior459, I am going to test this out ASAP, I will be sure to update my post on the results of the test!


Update: Ok Senethior459, I just tested the code you created, but there is a problem... I would like it to give the units to the second player specified instead of just sharing the units to the second player. The exact command I used was '-share 00 04' because I was purple and I was going to take all of red's units and give them to me, although it didn't work quite right...All that happened was me getting shared control of red's units instead of owning them.... If you could please fix this it would be much, much appreciated!!
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 »

then we got some misunderstandings here.
If all you wanted is to "own" them. You will need to use fatherspace's codes?
That's what it does.

We all thinking of unit sharing because you kept talking sharing?
lol

All right?

For Fai's cp. I asked my users. Once they get used to it. ALl commands has only one format which is easy. But you are not a Fai's user. So that's why it get confused. Don't mind it.

Good luck.
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 »

If you want to make them belong to someone else, just select the unit and type "-owner <color>", replacing <color> with red, blue, teal, purple, yellow, orange, green, pink, gray, lb, dg, or brown, not a number.
My Warcraft III Tool Collection
If you want to chat/game with me:
Blizzard: Senethior459#1962
Discord: Kyle#7409
Steam: Spacekidkyle
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 »

initialD wrote:then we got some misunderstandings here.
If all you wanted is to "own" them. You will need to use fatherspace's codes?
That's what it does.

We all thinking of unit sharing because you kept talking sharing?
lol

All right?

For Fai's cp. I asked my users. Once they get used to it. ALl commands has only one format which is easy. But you are not a Fai's user. So that's why it get confused. Don't mind it.

Good luck.


Uh I am a bit confused about what you said here initialD...I am not sure what you mean when you say that "I will need to use fatherspace's codes." or "What they do"

As for your comment about Fai's CP, I am not sure whether your native language is English or not, but I am not sure what your reffering to there......

Also, about the supposed confusion because I kept mentioning 'sharing', that's not quite true....I only mentioned it earlier to restate that I did not want the 'sharing' but the 'owning' of a persons units!!

EliteGamer wrote: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!



Oh and Senethior459, I also know of the '-owner [color]' command that is already included in JJ's CP, the entire reason of this thread was to have the effect that command had (completely owning the selected unit) on a much wider scale. (the reason for my request of the creation of an '-ownall XX YY' command or something akin to it, not necessarily that exact command.....)