sniko Posted August 7, 2011 Posted August 7, 2011 (edited) Hello there, I've created a manual (start of a series I will be doing) to help newcomers develop for the mccodes engine, for FREE! Hopefully, this will help 'revive' a dying engine, which has been used for so many different games, and help people develop and teach them more about the engine! View Manual* Hosted @ Pdfcast * A download link is avaliable on pdfcast. Contents - Overview - Installing Mccodes - The Basics - Creating Your First Modification - Mccodes Cheat Sheet - Useful Stuff Comments and constructive critisim is welcome, but please, don't flame! Thanks you -sniko Edited August 7, 2011 by sniko Quote
DreamCoder Posted August 7, 2011 Posted August 7, 2011 Very nice sniko , Thanks for this i will be reading once done with client work. Quote
Anonymous Posted August 7, 2011 Posted August 7, 2011 Purely a suggestion - however it is often wise to use UPDATE users SET gender = '{$newgender}', money = money - {$cost} WHERE userid = {$userid} AND money >= $cost} rather than UPDATE users SET gender = '{$newgender}', money = money - {$cost} WHERE userid = {$userid} or worse UPDATE users SET gender = '{$newgender}', money = $newmoney WHERE userid = {$userid} Why? Well the extra condition does come at a cost certainly albeit a very small one as you have already limited the rowset to 1row via the primary key the cost is actually in ensuring that the second part of the condition holds. More importantly, this technique helps especially on heavy multi-user platforms where the user's record may well be affected from multiple sources effectively simultaneously (user submitting multiple actions from multiple browser tab's, timed queries ie cronjobs or the scheduled [mysql] events, or perhaps ajax queries from other players). There are other solutions, for example using modular cyclic fields that track last updates and ensure no changes have been brought about since the record was read, but in these days of NoSQL that's very much open to debate as to its effectiveness. Row locking at engine level is out of the question unless you have had the foresight to convert to something akin to the InnoDB engine, however that brings it's own problems, something that is presumably above and beyond the capabilities of most starting out in this particular genre/platform. Quote
sniko Posted August 7, 2011 Author Posted August 7, 2011 Thank you Anonymous, i shall take that into consideration when the series progress -sniko Quote
ChrisRowe Posted August 9, 2011 Posted August 9, 2011 Nice manual there Sniko, should help many! Quote
Mystical Posted August 9, 2011 Posted August 9, 2011 Hello there, I've created a manual (start of a series I will be doing) to help newcomers develop for the mccodes engine, for FREE! Hopefully, this will help 'revive' a dying engine, which has been used for so many different games, and help people develop and teach them more about the engine! View Manual* Hosted @ Pdfcast * A download link is avaliable on pdfcast. Contents - Overview - Installing Mccodes - The Basics - Creating Your First Modification - Mccodes Cheat Sheet - Useful Stuff Comments and constructive critisim is welcome, but please, don't flame! Thanks you -sniko Nice manual sniko. I also see something that could be useful for our games on the link you provided. http://www.solvemedia.com the captcha looks like an interesting way to generate more income for our games. How hard to you think it would be to incorporate it into our games? Quote
sniko Posted August 9, 2011 Author Posted August 9, 2011 I wouldn't say that hard, but then again, I haven't installed a capatcha before. If you want me to look at the code and try to implement it, PM me! Thanks ChrisRowe and Mystical for the kind words Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.