A downloadable game

#################################
# BASIC Tenliners Contest 2026  #
#                               #
# 10-a-gotchi                   #
# (c) 2026 Roman Werner @romwer #
# email: xxxxxxxxxx@xxxxxxxxxx  #
#################################

Do you remember Tamagotchi, the 90's Japanese toy which simulates a virtual pet that you must take care of? 10-a-gotchi is a simplified version of it.

Task and Goal

=============

- Your pet starts as a little seed. Think of a cute name for it and start bonding.

- Your pet has needs. When it needs love you should give it a hug. When it gets hungry then you better feed it. After a poop it needs some help with cleaning.

- After five successful actions your little pet starts to grow. You can follow its development in the little pet-home-frame.

- When you do a good job as a parent then you will see your pet eventually fully fledged in its complete grown-up-state!

- But be quick because the grumpy-meter (patience time of your pet) gets down fast and your pet will eventually die if neglected 3 times.

- There are 3 different pets you can raise. It is a random choice by nature what animal you will get. Try to see them all hatch.


Control:

========

There are three keys you can press during the game:

'h' to give your pet a hug

'f' to feed it

'c' to clean its bottom

After a growth-spurt you can relax for a moment (parent work can be hard) and then press any key to continue with the next development stage


Game Requirements:

==================

- C64/C128* with BASIC 2.0 runtime environment (or compatible)

- 1 Player

*Also playable on Windows/MacOS/iOS/Android (C64 Emulator required)


10-a-gotchi BASIC program code:

===============================

0dIa(18):s=1145:fOi=0to18:rEa(i):nE:o=int(rN(0)*3)*8+1:s$(0)="love":s$(1)="food"
1?"{clear}{down}10-a-gotchi   h=hug f=feed c=clean":?"UCCCI":fOi=1to3:?"B   B":nE:?"JCCCK{down}"
2s$(2)="poop":k$(0)="h":k$(1)="f":k$(2)="c":pOs+41,46:goS6:pOs+41,81:goS6:l=3
3pOs+1,111:pOs+41,162:goS6:pOs+81,34:goS6:goS4:goS6:l=8:goS4:?"fully fledged":eN
4pOs+int(j/3)*37+j,a(aS(mI("@g@@dfhi@j@kd@lmnopod@qr",o+j,1))-64):j=j+1:ifj<lgO4
5reT:dA32,46,81,111,162,34,60,241,95,203,161,233,201,170,109,248,125,194,242
6i=int(rN(0)*3):on-(i=oi)gO6:oi=i:?"{home}{down*8}need: "s$(i)" {reverse on}{space*10}":t=11
7fOw=1to200:nE:pO1353+t,32:t=t-1:gEa$:on-(a$=""aNt>0)gO7:e=(k$(i)<>a$):f=f-e
8?"fail:"f:iff=3tH?"{home}{down*3}{right}   {down}{left*3} {sh +} {down}{left*3}U{cm e}I":?"{down*5}game over":wA198,1:geta$:rU
9on-egO6:g=g+1:on-(g<5)gO6:?"{up*2}*** growth ***{space*10}":fOi=0to999:nE:g=0:reT

Tip: Copy/paste the program-Code into CBM prg Studio (http://www.ajordison.co.uk/).

There you can see the commands in nice color highlighting and you can directly execute the game in an emulator of your choice.


10-a-gotchi 10liner explained (000=row 0/100=row 1/...):

========================================================

000 dima(18): rem allocate array for 19 char values (0-18) 

001 s=1145: rem start position on screen to plot/poke visual pet state 

002 fori=0to18: rem for 19 times...

003 reada(i): rem read data values (line 5)

004 next

005 o=int(rnd(0)*3)*8+1: rem assign random pet string offset 1, 9 or 17

006 s$(0)="love": rem assign need state 0

007 s$(1)="food": rem assign need state 1

101 print"{clear}{down}10-a-gotchi   h=hug f=feed c=clean": rem print title

102 print"UCCCI": rem print top of pet-home-frame

103 fori=1to3: rem for 3 times...

104 print"B   B": rem print sides

105 next

106 print"JCCCK{down}": rem print bottom part

200 s$(2)="poop": rem assign need state 2

201 k$(0)="h": rem assign key state 0

202 k$(1)="f": rem assign key state 1

203 k$(2)="c": rem assign key state 2

204 pokes+41,46: rem poke a full stop character to this screen position

205 gosub600: rem show need and wait for actions

206 pokes+41,81: rem poke a round circle character to this screen position

207 gosub600: rem show need and wait for actions

208 l=3: rem set length to show only the first 3 characters of the final pet

300 pokes+1,111: rem poke a bottom line character to this screen position (top)

301 pokes+41,162: rem poke a inversed double quote (=eyes) character to this screen position

302 gosub600:  rem show need an wait for actions

303 pokes+81,34: rem poke a double quote (legs) character to this screen position

304 gosub600: rem show need and wait for actions

305 gosub400: rem show first 3 characters of final pet

306 gosub600: rem show need and wait for actions

307 l=8: rem set length to show all characters of the final pet

308 gosub400: rem show final pet

309 print"fully fledged": rem print success message

310 end: rem end of game

400 pokes+int(j/3)*37+j,a(asc(mid$("@g@@dfhi@j@kd@lmnopod@qr",o+j,1))-64): rem poke pet chars onto screen (3x3)

401 j=j+1: rem next character

402 ifj<lgoto400: rem do this again until defined length has been reached

500 return: rem return from subroutine

501 data32,46,81,111,162,34,60,241,95,203,161,233,201,170,109,248,125,194,242: rem char screen values that make the pet look

600 i=int(rnd(0)*3): rem find the next random need (0-2)

601 on-(i=oi)goto600: rem same need as before? if so then try again

602 oi=i: rem remember current need

603 print"{home}{down*8}need: "s$(i)" {reverse on}{space*10}": rem print need text to screen

604 t=11: rem set position for grumpy bar

700 forw=1to200:next: rem wait some time

701 poke1353+t,32: rem poke space to last position of grumpy bar to make it shrink

702 t=t-1: rem reduce grumpy bar position

703 geta$: rem check for key press

704 on-(a$=""andt>0)goto700: rem loop when there was no key press or grumpy bar position is greater than 0

705 e=(k$(i)<>a$): rem check if key press was different to need (0=false/-1=true)

706 f=f-e:rem add 0 or 1 to fail counter (-- = +)

800 print"fail:"f: rem print fail status

801 iff=3thenprint"{home}{down*3}{right}   {down}{left*3} {sh +} {down}{left*3}U{cm e}I":print"{down*5}game over":wait198,1:geta$:run: rem show game over when failed 3 times

900 on-egoto600: rem if failed then continue with next need

901 g=g+1: rem development counter +1

902 on-(g<5)goto600: rem repeat until 5 successful needs were fulfilled

903 print"{up*2}***growth***{space*10}": rem print growth message

904 fori=1to999:next: rem wait some time

905 g=0: rem reset development counter for next round

906 return: rem return from subroutine

Tools Used

==========

- VICE 2.4 (http://vice-emu.sourceforge.net/)

- CBM prg Studio V4.0.1 by Arthur Jordison (http://www.ajordison.co.uk)

Download

Download
10-a-gotchi.prg 757 bytes
Download
10-a-gotchi.txt 6.7 kB

Install instructions

Starting in VICE: C64 emulator (http://vice-emu.sourceforge.net/):

===============================================================

Start the emulator and then drag and drop the "10-a-gotchi.prg" into the VICE window.

-or-

Load the program with the command: load "10-a-gotchi.prg",8

Then start the program with:       run

Comments

Log in with itch.io to leave a comment.

very good