Menu

#20 Stopping Autoclickers

open
nobody
None
5
2005-03-31
2005-03-31
No

After working a few things out. I have come up with a
way to stop these auto clickers.

First off you need to enter two new lines in players. One
is an INT with 3 chars and default 0.

The second is a line for a character string with
default 'N'

Then use this php in the header.

<?php
$secure_test = rand(1,100);
if ($secure_test==100) {
$security = rand(100,999);
mysql_query("update players set
anticlick_code=$security, anticlick_test='Y' where
id=$stat[id]");
}
if ($stat[anticlick_test]=='Y') {
print "<center><b>Brief Encounter</b></center>";
if ($code) {
if ($code==$stat[anticlick_code]) {
print "<br><i><b>Thank you Adventurer</b> Sorry for
any inconvenience. Please accept this 100 gold for your
assistance.</i><br><br>";
mysql_query("update players set anticlick_test='N',
credits=credits+100 where id=$stat[id]");
include("footer.php");
exit;
} else { print "<br><i>Now I know, that is not how many
she asked for. Try again.</i><br><br>The old man gets
angry and casts a skill leech spell at you. You lose 1
full point off <b>Combat</b><br>(Skills will not be
altered at the moment. They will be shortly)<br>"; }
}
print "<br>And old merchant approaches you, and asks
in a scruffy voice, the man obviously having enjoyed his
share of whiskey in his life.<br><br><i>Noble
adventurer, could you help me in this predicament I find
myself in:<br><br>My wife wrote down the number of
eggs I am to purchase at the market, but I forgot my
reading glasses at home, and cannot see it. Could you
please tell me what she wrote on this tablet?
</i><br><br>The tablet reads <b>$stat[anticlick_code]
</b> eggs.";
print "<form name=form3 method=post action=#?
code=$code><input name=code type=text id=code>
<input type=submit name=Submit
value=Eggs></form>";
include("footer.php");
exit;
}
?>

This stops action dead unless the right code is put in.
You can get it to drop skills or other things if a wrong
answer is entered.

If you wish to see this in action, please visit my game.
You dont even have to create an account, just click on
Try the game.

www.dealers-of-destiny.org.uk

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.