How do I make a sitelock?

0 favourites
  • 10 posts
From the Asset Store
Easy SiteLock
$11.99 USD
Protect your game from being stolen and posted on another site with Easy SiteLock!
  • I use dropbox to host my games and I was wondering if there's a method in Construct 2 that can help me sitelock them?

    There's one thread in the forum that says it can be done.I don't understand the capabilities of browser object being used to compare domain.

    I appreciate if there's further explanation on how-to.

    Thank you for your time.

  • If you're trying to lock your game from being played by others you can insert a password option at the start of the game so only people who you give the password to can access the actual game. If someone inserts the right password they get sent to the proper game starting layout.

  • To be clear on what I'm looking for, what I need is to have it prevented from being embed from someone's website which they'll make profit from by using ads.

    What if I used materials from creative commons that is non-commercial, then someone mischievous takes advantage of it by embedding the iframe which is open to the public.

    It sounds discouraging in my opinion if this scenario were to happen to anyone.

    I intended to be played by anyone, but not in a way they'll profit from the works of others.

  • Maybe this thread will a help a little:

    Thank you very much, I'll look into the method to see if it works.

  • I don't quite grasp the concept...

    How do I make the two values compatible with each other?

    The last step I'm not familiar with "You can output Browser.Domain to a Text or SpriteFont object to confirm what the domain is for your website."

    Can the Browser.Domain be made with a variable or the browser object itself?

    My apologies for asking few more questions, an extra sense of security is important to me and the clients I'm collaborating with.

    Edit: I'm currently trying out a different method.

    Edit again: No, no progress at all.

  • Nilo

    Browser.Domain is one of the included values of the Browser object, same way a Sprite has Sprite.X and Sprite.Y, but is a text/string value.

    So you need to insert the Browser object first before you can access the Browser.Domain value for comparison.

    If you already included the Browser object but you renamed it, you'll have to access it via the new name, e.g. NewBrowserName.Domain

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I added the Browser object first and finally got through the first value with "Browser" as the name.

    The second field name which is the domain name "dl.dropboxusercontent.com". (I get the message "dl" is not an object name.)

    I don't know how I should proceed next. If I were to add an object with the domain name, the invalid characters gets removed.

  • Nilo

    "dl.dropboxusercontent.com" is text/string, so you need to include the " " around it.

    Just whipped up a simple example.

    This is the exported file on dropbox:

    https://dl.dropboxusercontent.com/u/905 ... index.html

    Here is the capx:

    https://dl.dropboxusercontent.com/u/905 ... Check.capx

    Preview the capx to run it locally (i.e. not on DropBox) and you'll get a different message.

    For a proper site lock on a game, you just need to expand on the example and in the first Layout do a check for the domain in "On start of layout", if the domain is correct, load a different Layout with a lock message and maybe a link to the proper site.

  • Neat, thank you. I'll try to expand on what I've learned from the capx.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)