Ski Run

Anything QL Software or Programming Related.
Post Reply
User avatar
dilwyn
Mr QL
Posts: 2793
Joined: Wed Dec 01, 2010 10:39 pm

Ski Run

Post by dilwyn »

Staying indoors thanks to a few inches of snow here (this is Wales after all), so for a bit of fun I ported a ZX81 BASIC game by Trevor Toms to QL SuperBASIC. On the theme of snow, it's a downhill ski run, where you have to guide a skier down a curving ski run, using the left and right cursor arrow keys. Avoid hitting the course marker posts or straying off course - you get a penalty point for this. Keep your "score" as low as possible.
Ski Run instructions
Ski Run instructions
skirun1.jpg (21.06 KiB) Viewed 1135 times
The game in progress
The game in progress
skirun2.jpg (12.2 KiB) Viewed 1135 times
It's fairly basic graphically as it stands, and well commented for anyone wishing to tinker with it to enhance it.

To run it, just use LRUN flp1_SKIRUN_bas. The instructions are in a Quill doc file called SKIRUN_doc

It should run on any system, including unexpanded QL. You'll need to tweak the running speed by altering the value of the slowdown factor variable called "slowdown" in line 160. Very low value for slow systems such as unexpanded QL. On my QPC2 system, it needs a value as high as 200,000. Other systems will be a trial and error with values somewhere in between.

At the moment, it has two courses chosen at random. More can be added by adding values to the variable course$ by following instructions on how to code that. There are 3 skill levels, based on course width.

Enjoy yourself in the snow!
Attachments
skirun.zip
BASIC program and instructions
(4.06 KiB) Downloaded 37 times
Last edited by dilwyn on Fri Mar 10, 2023 4:40 pm, edited 1 time in total.
Reason: Typo "teak" -> "tweak"


qbits
Trump Card
Posts: 185
Joined: Sun Dec 11, 2016 3:32 pm

Re: Ski Run

Post by qbits »

Thanks Dilywyn, your Suggestions implies this simple game could do with a 21st Century Makeover.

The challenge starting with some user defined FONTs ie. SKIRun_fnt. For which may I suggest the QBITS FontEdit2SE. Create Flag Posts for the ‘*’ maybe some Fir Trees (simple design) to the sides not forgetting the Skier with central, left, right positions.

Way back I did make a start on design of a Curling game. The SKI run is a simpler option may take a closer look at a makeover in the coming weeks.

QBITS


User avatar
dilwyn
Mr QL
Posts: 2793
Joined: Wed Dec 01, 2010 10:39 pm

Re: Ski Run

Post by dilwyn »

Will look forward to the 'Qbits Makeover' ! Your software always looks great.

Personally, rather than having the program loading a SKIRUN_fnt , I'd put the font within the program as DATA statements. Easily done using my Font2Data program https://dilwyn.qlforum.co.uk/fonts/font2data.zip after the font itself has been created.

For such a small program I'd prefer the program to be self-contained and not have to be configured to "find" the font file etc, makes it easier to just put the program in a directory of your choice. Just personal preference with small programs like this one.


User avatar
RalfR
Aurora
Posts: 872
Joined: Fri Jun 15, 2018 8:58 pm

Re: Ski Run

Post by RalfR »

Hehe, that reminds of ferries in Switzerland. Makes great fun!


4E75 7000
Derek_Stewart
Font of All Knowledge
Posts: 4058
Joined: Mon Dec 20, 2010 11:40 am
Location: Sunny Runcorn, Cheshire, UK

Re: Ski Run

Post by Derek_Stewart »

Hi,

Looks good, maybe a version of Horace Goes Skiing for the QL.


Regards,

Derek
Post Reply