Login | Register

Cd Runing Protection

August 28, 2007, 10:21 by death-droid
[loading]
-->
This code i originally wrote for some one who asked how do they check the cd is in and make it autorun from the disc and also have it so they cant use some random disk.

So heres what i did.

Make a new txt document

Rename it to.
autorun.inf

Then put this is in it.

[autorun]
open=put game name or installer here
icon=icon can be same thing as exe/installer directory

Then put that in a empty folder NOT ON THE DISC

Then in your game make a room and call it cd_check.


if not cd_playing() or not file_exists("d:DataSecuritysecurity.sec";) then {show_message("Please Insert Disc";) game_end()} else room_goto_next()


Oh yeah in the folder you put the autorun.inf .Then create a folder in that folder named Data then make a folder called Security and a txt named security.sec .(make sure it named exactley as i have put it also make sure it changes the file type)

Then put your game and all the stuff you need with the exe in the folder with autorun.inf then copy all the stuff in the folder and put it on a cd.

If you want the code explained just tell me.

Comments

Loading comments... [loading]
.
Users logged in:

game maker articles, game maker examples, game maker tutorials, gmtutorials, game maker questions and answers, game maker crash course, how to create games