Jump to content

» «

Protect Main.scm file

3 replies to this topic
  • Zeb89

    Digital Artist

  • Members
  • Joined: 26 Feb 2007


Posted 04 September 2013 - 09:08 AM

It's probably not possible, but I'm looking for a way to prevent my compiled main.scm code from being decompiled again by Sanny/Mission Builder. So technically, if I create a mod, is there any way to copy-protect my code?

Thanks in advance.

  • Node

    War. War never changes.

  • Members
  • Joined: 31 May 2010
  • None


Posted 04 September 2013 - 10:14 AM

I know there's a way to add some code that, if removed, makes the script useless.

But I don't know how to do it..

  • Wesser

    The complexity simplifier, the efficiency optimizer

  • Feroci
  • Joined: 19 Aug 2006
  • Unknown
  • Contribution Award [Mods]


Posted 04 September 2013 - 11:40 AM

It is almost impossible. Neither encryption would be retained as a safe alternative. Indeed, you can cheat the compiler by building a rough GOTO (0002) command within hex-end construct:
† †02 00 01 // unresolved jump offset

Put these lines at the very end of the MAIN section (before the first mission). The compiler is unable to parse such a command properly, because the EOS (End Of Stream; EOF, End Of File, in CLEO) breaks its completion which will lead the compiling process to a fatal error.

However, Sanny Builder specifies the offset where the error occured, therefore advanced users can fix it easily.

  • Zeb89

    Digital Artist

  • Members
  • Joined: 26 Feb 2007


Posted 04 September 2013 - 08:20 PM

Thank you very much for your response. I'll try that method.

cookie.gif cookie.gif cookie.gif

1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users