Snakes and Ladders

Posted By: Nems

Snakes and Ladders - 10/09/13 20:25

Hi George, Love the snakes and ladder example and am adapting it for my little version but I have hit a problem.

I've checked through the code over and over and there is no difference except for the number of nodes used, the level name and some comments.

The problem is that on start, the +1 factor does not function correctly for me and counts node skill1 as the start of the dice results but the examples calculates from skill1 then adds the result to that and so the 'Player' moves correctly.

So if the dice roll is 1, the game freezes and the player remains in the start pos.

Only skill1 is set in WED and all other skills remain at 0 for the start node.

The edits I made are for 64 nodes set in an 8x8 grid.

I intend to recreate the project now that I am familiar with it (spent 2 days playing with it, making the board, changing node skills, adding new nodes and it's great to use this example to get back into light c)and see if the prob resolves itself...

In the meantime, would you have any immediate thoughts on where I may have slipped up given the above?

Thanks for all your examples as I now realise that they are perfect for small projects and even for publishing them, reborn that is laugh
Posted By: Nems

Re: Snakes and Ladders - 10/11/13 19:22

Found the problem!
Somehow number 2 node had morphed into something else or was not actually evident because the total nodes equaled the amount set but number 2 did not exist!
Reproducing the create steps sorted the problem out nicely thanks and number 2 node now exists.
Posted By: George

Re: Snakes and Ladders - 10/12/13 12:14

It's good to hear that you have managed to solve the problem; it would have been impossible for me to catch that bug. The good news is that now you've learned how the code works, so you'll be able to tweak it according to your needs.
Posted By: Nems

Re: Snakes and Ladders - 10/12/13 22:57

Sure and kind of you to 'suggest' 'bug' laugh but am adding other AUM based scripts with the intent of uploading to Acknex resources for Smart Ph style and Tablet style as an example of Basing projects on your supplied content to produced a full working title for user resources, including multiplayer, if I can get your multiplayer series wrapped in.

Hope to wrap it in OSAKit for browser play or include tute to the same for individual user experience.

Currently having issues with level restart but should be able to work thru them...

Thanks again for your precious resources...
Cheers..
Posted By: George

Re: Snakes and Ladders - 10/13/13 18:54

You are most welcome. Most game restart issues come from variables that aren't reset to their initial values.
Posted By: sivan

Re: Snakes and Ladders - 10/13/13 19:11

using okakit would be fine, I had no success with it... jcl mentioned a long time ago to make a working example in future...
Posted By: Nems

Re: Snakes and Ladders - 10/14/13 00:10

Cheers sivan, if OSAKit doesn't work out then an ordinary Java wrapper should do the trick.
Posted By: sivan

Re: Snakes and Ladders - 10/14/13 06:57

I'm not familiar with Java wrappers at all... frown
Posted By: Nems

Re: Snakes and Ladders - 10/14/13 10:10

Neither am I but I do know folks who write java and have demonstrated wrapped games within a browser, the player still has to download the Game but plays it thru the browser, like Runescape etc.
If multiplayer is scripted in then play becomes a bit more interesting.

I have had a quick look at OSAKit and its a tough one all right but the promises it makes are good.

Might have to buy the pro version to get it working the way I want, that is, multiple players on multiple machines.

Cant find the 'Help' files yet or even a description about it or its process...
© 2024 lite-C Forums