[GUIDE] How To Enable Single Player

General talk about editing, cheating, and deprotecting maps.

Moderator: Cheaters

Did this help you?

Yes
47
52%
No
20
22%
Kinda
23
26%
 
Total votes: 90

User avatar
JJ2197
Legendary Genius
Posts: 1311
Joined: August 8th, 2007, 8:10 am
Title: Legendary Genius²
Location: St. George Utah

[GUIDE] How To Enable Single Player

Post by JJ2197 »

Well I am going to start out with the easy way...

First search (Ctrl + F) for "-save" you'll end up seeing something probably
like this:
call TriggerRegisterPlayerChatEvent(SaveTrigger,Player(0),"-save",true)

The part in red is the name of the Saving Trigger.
Now search for DisableTrigger(SaveTrigger) and delete them.
Next look for CustomDefeatBJ and delete all of them.
That's the easy way to do it...

This is the harder way to do it, should do this if easy way doesn't work.
First search for PLAYER_SLOT_STATE_PLAYING, there may be more than one.
Now it will most likly either be one that is looped or one for each player.
If there is one for each player most likly you'll see right under them functions
that add to a variable, like set X = X + 1. This variable is how it tells how many
people are in the game. What you want to do is search X (Make sure to check
Match whole words and Match case). Then click Find next till you see something
like X=<1,X=1,X<2 or something that makes it only work if it's one. Now just change
the number to 0. There may be more then one checker, so make sure to get them all.
As for the looped one, there will be more than one X = X + 1 the one that won't be it
will be the one that is with exitwhen X>11. Here is an example:

loop
if GetPlayerSlotState(Player(A))==PLAYER_SLOT_STATE_PLAYING then
set X = X + 1
endif
set A = A + 1
exitwhen A>11
endloop

A is what you want to ignore and X is what you want to look for.

Well that's pretty much it... if you have any questions just post...

(edit by Bartimaeus) I'm just going to add this to the tutorial, since I see no reason why not.

First of all, if there's a special message that displays, or a defeat message, when you play single player, keep it in mind. Next, open the .j file in the map. If it's not STVN, (shortest trigger/variable names), then you should probably just search for save, or single player, delete the defeats, or enable the disabletriggers.

If it IS STVN, then you search for that special message I mentioned earlier. If it's not there, look in the .wts file in the map, and search for that instead. Find out the number of string, and search for it in JassCraft. If it's a defeat, just delete the defeat, and you're done. If there's no defeat, but you see a destroy/disable trigger, then you should enable them, instead. Or, if there's another trigger being run as a result, then follow the name of the trigger that's being run, and just go from them.
Computer Specs:
Motherboard: GA-990FXA-UD3
CPU: FX-8350 @ 4.0GHz
PSU: Corsair CX500
RAM: G.Skill Ripjaws X 8GB @ 1866
GPU: Radeon HD 4870 1GB
HDD: OCZ Vertex series 30GB SSD
Case: Antec 900
Monitor: Toshiba 32"
OS: Windows 7 Ultimate