Author Topic: Making a Secret Mission Cheat-proof  (Read 2757 times)

0 Members and 2 Guests are viewing this topic.

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Making a Secret Mission Cheat-proof
HLP, I've come to bargain. This is more a question of "do I've overlooked something" rather than "how to do it".....

I have this campaign which going to include a secret mission. But I don't want that mission to be playable unless the campaign has been beaten at least one before - so it will only unlock on the second playthrough.

To make it so that you can't cheat your way into the mission from the mainhall, I devised two systems of checks:

First, you have accumulating campaign-persitent variable which is increased everytime a mission is successfully completed by the mission number. @MissionsCompleted therefor has score from 0 (no mission completed, default value) to 171 (all missions completed), by adding up the number of missions in the campaign.
If by the time credits roll (sperate mission file) the score has reached 171 an event will set a player perstient-variable @{Acronym}completed by 1 (unless it is already 2). @{Acronym}completed being 2 is required for the campaign to progress to the Secret Mission.

Second, in the Secret Mission it imideately checks if @MissionsCompleted has a value of 171. If it doesn't an event will end-mission at once (the Secret Mission will have no Briefing).

So did I miss anything?

Edit:corrected transcription error which containted the wrong logic
« Last Edit: March 16, 2017, 05:25:45 pm by 0rph3u5 »
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 
Re: Making a Secret Mission Cheat-proof
Why bother? If the player wants to outright cheat, just let them. You're never going to actually keep a mission secret on a modding platform this open.
The good Christian should beware of mathematicians, and all those who make empty prophecies. The danger already exists that the mathematicians have made a covenant with the devil to darken the spirit and to confine man in the bonds of Hell.

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Making a Secret Mission Cheat-proof
Why bother? If the player wants to outright cheat, just let them. You're never going to actually keep a mission secret on a modding platform this open.

a) because I want to, b) because I can and c) to reward players that come back
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."

 

Offline mjn.mixael

  • Cutscene Master
  • 212
  • Chopped liver
    • Steam
    • Twitter
Re: Making a Secret Mission Cheat-proof
This is a post to remind me to respond when I get home.
Cutscene Upgrade Project - Mainhall Remakes - Between the Ashes
Youtube Channel - P3D Model Box
Between the Ashes is looking for committed testers, PM me for details.
Freespace Upgrade Project See what's happening.

 
Re: Making a Secret Mission Cheat-proof
b) because I can

Thaaaaat's a negative. You can hide the mission as well as you'd like, but nothing's going to stop someone going into the .vp, copying it, and loading it up in the simulator. You can add checks to stop someone launching it from the simulator, and the player can remove them just as easily. You can get into an obfuscation arms-race if you want, but all you're doing is making your mission more complicated (and introducing the possibility of bugs while you're at it); if a player wants to cheat into the mission, they'll, because they've got all the data there already.

It's like the old "how do I stop someone copy-pasting an image from my Web page question"? The answer is, you don't. By the time someone can see the image in their browser, they're in control of it. You can try to shut off the right-click menu through Javascript, but someone can always disable Javascript; you can render it as a Flash file or <canvas> element, but they can take a screenshot. So you watermark your image or put a banner asking people not to steal your images, because there's no solution.

...hell, even if you did find some effectively unbreakable system, nothing stops the player from ~k-ing their way through the entire campaign.

Now, I mean, there's nothing wrong with having an Easter egg mission or w/e, but going out of your way to hide it is an exercise in futility. The checks you have in place seem fine.

 

Offline mjn.mixael

  • Cutscene Master
  • 212
  • Chopped liver
    • Steam
    • Twitter
Re: Making a Secret Mission Cheat-proof
BtA has 3 hidden arcade missions that I don't think anyone has found yet... Just saying. You can't absolutely stop HLP's modders from finding the mission files, but you can obfuscate them in clever ways where no one has yet thought to look. :)
Cutscene Upgrade Project - Mainhall Remakes - Between the Ashes
Youtube Channel - P3D Model Box
Between the Ashes is looking for committed testers, PM me for details.
Freespace Upgrade Project See what's happening.

 
Re: Making a Secret Mission Cheat-proof
Yes, those

Spoiler:
texture files

were pretty clever. :)

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: Making a Secret Mission Cheat-proof
So did I miss anything?

Yeah. The behaviour of persistent variables that you're counting on is actually a bug.

http://www.hard-light.net/forums/index.php?topic=93306.0

And it's going to be fixed at some point which will result in the secret mission being completely inaccessible. When the new kind of persistent variable is in, you can just switch over to it though.


BTW, if anyone plays your campaign halfway through and then restarts the secret mission won't be accessible unless you're checking the score is equal or greater than 171.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

  

Offline mjn.mixael

  • Cutscene Master
  • 212
  • Chopped liver
    • Steam
    • Twitter
Re: Making a Secret Mission Cheat-proof
Unless you set the score back to 0 in mission 1.
Cutscene Upgrade Project - Mainhall Remakes - Between the Ashes
Youtube Channel - P3D Model Box
Between the Ashes is looking for committed testers, PM me for details.
Freespace Upgrade Project See what's happening.

 
Re: Making a Secret Mission Cheat-proof
Better yet, do both!

 

Offline 0rph3u5

  • 211
  • Oceans rise. Empires fall.
Re: Making a Secret Mission Cheat-proof
So did I miss anything?

Yeah. The behaviour of persistent variables that you're counting on is actually a bug.

http://www.hard-light.net/forums/index.php?topic=93306.0

It's telling that I knew something like it was going to pop up - that's why I ask
Thanks for the heads up

BTW, if anyone plays your campaign halfway through and then restarts the secret mission won't be accessible unless you're checking the score is equal or greater than 171.

Unless you set the score back to 0 in mission 1.

Yeah, I overlooked that - Thanks

You can hide the mission as well as you'd like, but nothing's going to stop someone going into the .vp, copying it, and loading it up in the simulator. You can add checks to stop someone launching it from the simulator, and the player can remove them just as easily. You can get into an obfuscation arms-race if you want, but all you're doing is making your mission more complicated (and introducing the possibility of bugs while you're at it); if a player wants to cheat into the mission, they'll, because they've got all the data there already.

mjn.mixeals teaching me his black arts nitwithstanding, this isn't about the segment of people who would open the .vp
But thanks to a narrative device I got those already covered :)
"As you sought to steal a kingdom for yourself, so must you do again, a thousand times over. For a theft, a true theft, must be practiced to be earned." - The terms of Nyrissa's curse, Pathfinder: Kingmaker

==================

"I am Curiosity, and I've always wondered what would become of you, here at the end of the world." - The Guide/The Curious Other, Othercide

"When you work with water, you have to know and respect it. When you labour to subdue it, you have to understand that one day it may rise up and turn all your labours into nothing. For what is water, which seeks to make all things level, which has no taste or colour of its own, but a liquid form of Nothing?" - Graham Swift, Waterland

"...because they are not Dragons."