Detecting Cheats
There are 2 known anti-cheats, which, coincidentally, are the two best you could have possibly use. They protect the map against 'Black Sheep Wall' (allows the user and all computers to see the entire map), and 'Power Overwhelming' (human player becomes invincible as well as computer players to each other). I credit some of this explanation to the MDA map making bible (Lujayne) as that was where the concept was pulled from.
BLACK SHEEP WALL
When a player puts in this cheat, he sees the entire map. The thing is, is that the computers do also. Usually, computer players cannot see things at 'high elevation' when their unit(s) are at 'low elevation', except when this cheat is accessed, thus, the birth of the 'black sheep wall' anti-cheat.
To make this anti-cheat, choose a place on your map that will not be accessed by anything that may deter this process. Create a tank in siege mode for one of the computer players at 'low elevation' terrain (ex. Normal jungle ground). Now, relatively close to the tank create a piece of terrain which is 'high elevation' (note, not 'mid-elevation', but 'high elevation') and create a 'Protoss Photon Cannon' there for a different computer player. The cannon and the siege tank must be close enough for the siege tank to attack this building. Create a trigger rendering the cannon to 1% of health, and 1% in shield points if any, with a Preserve Trigger.
Create a trigger making the player controlling the siege tank unallied to the player controlling the cannon. Not necessary to do it the other way around.
Create a location over the building that you have created for one of the computer players. Make a trigger stating that if that player does not control that cannon at that location at any time, the human player loses the game.
Now, run the game in single player, type in 'black sheep wall' and you should lose almost instantly. You may want to add other desired effects instead of making the player lose when the cheat is detected. Here is an example, the owner of the tank is player 4 and the owner of the cannon is player 5:
PLAYER(S):
Player 4
CONDITION(S):
ALWAYS
Always
ACTION(S):
SET ALLIANCE STATUS
Set "Player 5" to "Enemy"
PLAYER(S):
Player 1
CONDITION(S):
DEATHS
"Player 5" has suffered "exactly 1" deaths of "Protoss Photon Cannon"
ACTION(S):
DISPLAY TEXT MESSAGE
Display for current player: Black Sheep Wall detected. Immediate defeat.
WAIT
Wait for "1500" milliseconds
DEFEAT
End scenario in defeat for current player
PLAYER(S):
Player 5
CONDITION(S):
ALWAYS
Always
ACTION(S):
MODIFY UNIT HIT POINTS
Set hit points for "1" "Protoss Photon Cannon" owned by "Current Player" at 'Cannon' to "1"%
MODIFY UNIT SHIELD POINTS
Set shield points for "1" "Protoss Photon Cannon" owned by "Current Player" at 'Cannon' to "1"%
POWER OVERWHELMING
Now, this cheat is quite a bit more annoying to set up but also relatively easy. Notice that computer players become invincible to each other when this cheat is processed as well as the human player becomes invincible to all.
Once again, find a location somewhere on your map that won't be tampered with. Create a infested terran in that location. Create a zergling for a different computer player a few centimetres away from it so that if they are enemies they would auto-attack each other.
Make the player controlling the infested terran unallied to the player controlling the zergling, but not the other way around.
Create a location over the zergling and the infested terran (call it 'PO perimeter'). Create a 1 by 1 location over both the zergling and the infested terran (call them 'PO Zergling' and 'PO ITerran'). Now, create a trigger stating that if in 'PO perimeter', there are exactly 0 zerglings and exactly 0 infested terrans, that it will create a zergling in 'PO Zergling' and it will create an infested terran also in 'PO ITerran' at the same time.
Finally, create a final trigger stating that if there are no infested terrans in 'PO perimeter' and there is exactly '1' zergling in 'PO perimeter', the human player loses.
This should work but you can easily make mistakes with this anti-cheat, so watch out. You may also want to change the desired effects here. Here's an example, assuming player 4 controls the infested terran whilst player 5 the zergling and player 1 the human player:
PLAYER(S):
Player 4
CONDITION(S):
ALWAYS
Always
ACTION(S):
SET ALLIANCE STATUS
Set "Player 5" to "Enemy"
PLAYER(S):
Player 4
CONDITION(S):
BRING
"Player 4" brings "exactly 0" "Infested Terran" to 'PO perimeter'
BRING
"Player 5" brings "exactly 0" "Zerg Zergling" to 'PO perimeter'
ACTION(S):
CREATE UNITS
Create "1" "Infested Terran" at 'PO ITerran' for "Current Player"
CREATE UNITS
Create "1" "Zerg Zergling" at 'PO Zergling' for "Player 5"
PRESERVE TRIGGER
Preserve Trigger
PLAYER(S):
Player 1
CONDITION(S):
BRING
"Player 4" brings "exactly 0" "Infested Terran" to 'PO perimeter'
BRING
"Player 5" brings "exactly 1" "Zerg Zergling" to 'PO perimeter'
ACTION(S):
DISPLAY TEXT MESSAGE
Display for current player: Power Overwhelming detected. Immediate defeat.
DEFEAT
End scenario in defeat for current player
|
|
|
| |