Page 1 of 1
Richmond eats Escargots
Posted: Wed Feb 19, 2025 1:31 pm
by richmond62
Well, personally I would not recommend them; extremely disappointing: and certainly not part of a 'sattvic' diet.
HOWEVER, a while back a 'small blob' who was attending my ESF school turned up early and was singing the praises of some daft game (or series of games) called
Snail Bob:
https://www.1001games.com/puzzle/snail-bob
-

- SB1.jpg (90.7 KiB) Viewed 76161 times
-

- SB3.jpg (108.15 KiB) Viewed 76161 times
-
This made me moderately sick (especially the horrible, repetitive music); and I remember trying to point out to a 9 year old that "that sort of thing" did not appeal to 'mature' types like me.
Later it occurred to me that while I did not like Snail Bob as such, the game had potential as something to 'clone' in xTalk as a programming exercise.
Re: Richmond eats Escargots
Posted: Wed Feb 19, 2025 1:46 pm
by richmond62

- SBfunctions.jpg (107.38 KiB) Viewed 76157 times
-
If we perform what people who like to dream up jargon might call a 'functional analysis' of scene #1 of the game it can be broken down into essential components:
1. The snail (which is animated) that moves forward.
1.1. Preferably there should be a START button which should start the snail animation.
1.2. Preferably clicking on the snail when it is moving should stop it moving, and when it is not moving a click should start it moving.
2. A 'pipe' from which the snail emerges.
2.1. A 'pipe' into which the snail disappears having completed the scene.
3. A toggle switch that raises and lowers a log on a chain.
4. Some sort of lift/elevator toggled by a button.
For reasons of simplification I am not bothering about a score.
Re: Richmond eats Escargots
Posted: Wed Feb 19, 2025 1:56 pm
by richmond62

- MOTION1.png (186.83 KiB) Viewed 76129 times
-

- MOTION2.png (189.12 KiB) Viewed 76129 times
-
I have just popped in a button so you can see all the image resources stored out of sight at the bottom of the stack:
-

- MOTION3.jpg (141.19 KiB) Viewed 76118 times
Re: Richmond eats Escargots
Posted: Wed Feb 19, 2025 2:26 pm
by richmond62
Here is that stack:
Click on the RUN button to make the snail move.
Click on the snail when it is moving to make it stop.
Click on the snail when it is not moving to make it move.
Look at the field that sometimes contains an 'x'.
Re: Richmond eats Escargots
Posted: Wed Feb 19, 2025 5:57 pm
by tperry2x
Oh, I think I got the wrong idea - I thought you meant you'd made a
platformer (2D-controller) with this character, using the keyboard to control it. No problem. Was only trying to avoid duplicated effort.
Re: Richmond eats Escargots
Posted: Wed Feb 19, 2025 6:19 pm
by richmond62
It is perfectly possible to replace those mouse-clicks with keys: and Snail Bob is a 2D game that in its origianl conception is both key controlled and mouse-clicked:
-

- SB3.jpg (108.15 KiB) Viewed 76092 times
-
The snail's movement is key-controlled, while the 2 things ringed with those white broken-line circles are activate with mouse-clicks.
If you think that would be OK: let one of your children have 15 minutes on the original game: and
watch them.

Re: Richmond eats Escargots
Posted: Wed Feb 19, 2025 6:46 pm
by tperry2x
Ah, okay - got you.
I see what you mean, it's mostly a point and click kind of thing but can use keys too.
However, the original (as far as I can make out,
here) allows me to click on things once the snail is moving.
On the stack version, you can't click anything while the snail is in motion as it's just a continuous loop.

- snail.gif (1.21 MiB) Viewed 76060 times
Re: Richmond eats Escargots
Posted: Wed Feb 19, 2025 7:24 pm
by richmond62
From a pedagogical point of view reinventing the wheel is going a bit far: but copying the functionality of a computer game/program is a useful learning process.
As one has NO access to either the underlying code of something one is copying, NOR access to whatever was going on in the minds of the original designers one has to come up with one's own (possibly original) ways to achieve the same thing.
While copying a picture might be fairly trivial, copying the functionality of what is to all effects and purposes a locked box is far from trivial.
Re: Richmond eats Escargots
Posted: Wed Feb 26, 2025 10:30 am
by richmond62

- Screenshot 2025-02-26 at 12.27.31.png (389.08 KiB) Viewed 70921 times
-
This demonstrates a way to implement the barrier:
-

- barrier.jpg (25.14 KiB) Viewed 70920 times
-
The 'log' and the 'pulley' are simple images, while the 'lever' is a graphic rectangle with a series of 3 images (stored off screen) used as its backGroundPattern:
-

- Screenshot 2025-02-26 at 12.35.14.png (53.5 KiB) Viewed 70919 times
-
The script in the lever graphic simply resets the position of the 'log' image and the backGroundPattern of the graphic:
Code: Select all
on mouseUp
if intersect(img "SR", img "log", 4) then
put empty into fld "STATUS"
end if
set the backGroundPattern of grc "LL" to the id of img "lever2"
set the top of img "log" to 270
wait 5 ticks
set the top of img "log" to 250
wait 5 ticks
set the top of img "log" to 230
wait 5 ticks
set the top of img "log" to 210
set the backGroundPattern of grc "LL" to the id of img "lever3"
wait 5 ticks
set the top of img "log" to 190
wait 5 ticks
set the top of img "log" to 170
wait 5 ticks
set the top of img "log" to 150
wait 5 ticks
send "mouseUp" to img "SR"
end mouseUp
Re: Richmond eats Escargots
Posted: Wed Feb 26, 2025 10:42 am
by richmond62
The RESET button "pulls" the snail back to its starting position and chnages the backGroundPattern of the 'lever' graphic:
Code: Select all
on mouseUp
set the loc of img "SR" to 40,400
put empty into fld "STATUS"
set the backGroundPattern of grc "LL" to the id of img "lever1"
set the top of img "log" to 290
end mouseUp
OBVIOUSLY this stack does NOT feature the animated snail of the previous stack . . .
'Uncle Richmond' is NOT going to do ALL the work (as I SHOUTED once at a load of extremely passive children waiting for me to spoon feed them):
-

- wink.jpg (3.97 KiB) Viewed 70913 times
-
Re: Richmond eats Escargots
Posted: Wed Feb 26, 2025 6:14 pm
by richmond62

- Screenshot 2025-02-26 at 20.12.16.png (252.12 KiB) Viewed 70667 times
-
More on its way shortly . . .
Or "
MORON" its way; depending on your point of view.

Re: Richmond eats Escargots
Posted: Sat Mar 01, 2025 2:59 pm
by richmond62
Click the red button when the snail arrives at the lift.
-

- Elevator.png (209.15 KiB) Viewed 67331 times