Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > Script Language
2016-11-24 14:03
thesuperfrog

Registered: Oct 2016
Posts: 3
Script Language

Hi all,

have you ever used a script language to create a game?

I'm very courious to know if it could be possible make the porting the lua on c64.

thanks
2016-11-24 14:21
Oswald

Registered: Apr 2002
Posts: 5094
as c64 is limited your best bet is to tailor your own language for the minimum scripting you need for your game.However I have no experience in this.
2016-11-24 14:28
oziphantom

Registered: Oct 2014
Posts: 490
I've used LUA on a PS2 and that was a bad idea. C64 not a hope in hell.

That being said I have made games in BASIC. Also some games I've made use a custom byte code to control things, but not a full language.
2016-11-24 15:13
Radiant

Registered: Sep 2004
Posts: 639
Several games on the C64 have used scripting languages (or something akin to them) for implementing game logic. Most notably adventure and strategy games.

I'd look at something a bit simpler than Lua for that if you want to use an existing language - maybe Forth; it's similar to Lua in that it's stack based, but it's not as fancy pancy and more geared towards low-end platforms. There's an implementation already available: DurexForth V1.6.1
2016-11-24 18:35
chatGPZ

Registered: Dec 2001
Posts: 11386
you could have a look at "small", its another c-style script language, with a supposedly smaller core and also comes with a compiler
2016-11-24 19:23
lft

Registered: Jul 2007
Posts: 369
Inform 6 is a high-level object oriented language for interactive fiction (i.e. text games), which you can then play on the C64 using Zeugma, although it requires a REU.

Unfortunately Inform 7 (which is a different language altogether, and a quite interesting one) grinds to almost a halt on the C64, due to a massively bloated runtime.
2016-11-24 20:12
Hoild

Registered: Apr 2005
Posts: 29
Quoting Radiant
Several games on the C64 have used scripting languages (or something akin to them) for implementing game logic. Most notably adventure and strategy games.


Indeed. Just like NEWCOMER, Enhanced NEWCOMER, and Ultimate NEWCOMER was/is implemented via a Domain Specific Language that evolved slightly with each revision:
http://newcomer.hu/ENCscript-xmpl.html

Actually, I have slightly changed the syntax in this example to make it more legible in English, because the original syntaxes in all three major revisions use a wicked "Hunglish" (Hungarian-English hybrid).

The evolution of this Domain Specific Language involved eliminating extra steps required by the designer due to the laziness of the original toolkit/build chain coder, and replacing awkward hacks with natural/descriptive syntax (for example, the arg for selecting teammembers is now by their name rather than two unique hex values from their name string).
2016-11-24 21:01
4mat

Registered: May 2010
Posts: 66
Haven't used it for a game but our demo "engine" has a small script language built in for building and controlling each scene. It has a few extra commands for directly manipulating registers, which is kind of inefficient but doing those changes within the script rather than some separate code makes things easier to read.
2016-11-24 23:31
Jammer

Registered: Nov 2002
Posts: 1335
Enthusi created his own script language for room interaction in 'Caren And The Tangled Tentacles'.
2016-11-25 16:26
MagerValp

Registered: Dec 2001
Posts: 1078
Quote: you could have a look at "small", its another c-style script language, with a supposedly smaller core and also comes with a compiler

Link? It's completely ungooglable.
2016-11-25 17:26
chatGPZ

Registered: Dec 2001
Posts: 11386
http://www.compuphase.com/small.htm ... apparently its called "pawn" now (not sure if that is better to google for... =P)
2016-11-25 17:27
Frantic

Registered: Mar 2003
Posts: 1648
http://www.compuphase.com/small.htm
...which leads to this page:
http://www.compuphase.com/pawn/pawn.htm

..maybe? :)
2016-11-25 17:28
j0x

Registered: Mar 2004
Posts: 215
If I'm not mistaken, Small (the scripting language) is now known as Pawn: http://www.compuphase.com/pawn/pawn.htm

I once did a music routine with a scripting language. Tunes were really small in memory (including runtime), but heavy on the cpu time.
2016-11-26 09:02
El Topo

Registered: Jun 2006
Posts: 43
I don't want to sound like an ass but isn't C64/C128 BASIC a scripting language? :)
2016-11-26 09:37
thesuperfrog

Registered: Oct 2016
Posts: 3
Quote: I don't want to sound like an ass but isn't C64/C128 BASIC a scripting language? :)

But i'm trying to adopt/create someting more modern.

i would like to experiment the idea to use a 16bit opcodes with registers based instructions. I'm thinking to translate this instructions with relative 6010 opcodes. on top use a language like lua.

An evolution of sweet16 but without a vm, just translate in 8bit opcodes.
2016-11-26 14:55
MagerValp

Registered: Dec 2001
Posts: 1078
Quote: http://www.compuphase.com/small.htm ... apparently its called "pawn" now (not sure if that is better to google for... =P)

Thank you. "pawn scripting language" gives plenty of relevant hits, so yes, that was a good name change :)
2016-11-26 15:04
MagerValp

Registered: Dec 2001
Posts: 1078
And as for scripting languages on the C64, I've experimented a bit with it, but in the end I just settled on using C for those parts that don't need the performance of asm. Since projects are limited to a few dozen kB of code you don't really bump into the problems that large C codebases struggle with. The only practical drawback I've found is that, at least cc65, generates code that's a little more bloated than a small VM interpreter or hand written asm.
2016-11-26 17:34
chatGPZ

Registered: Dec 2001
Posts: 11386
why not simply use BASIC for scripting? :)
2016-11-29 15:45
Jammer

Registered: Nov 2002
Posts: 1335
Because its syntax sucks? ;)
2016-11-30 00:51
Martin Piper

Registered: Nov 2007
Posts: 722
And the BASIC interpreter sprays all over large areas of memory, especially zero page.
2016-12-01 14:55
chatGPZ

Registered: Dec 2001
Posts: 11386
easy enough to save/restore that when needed :)
2016-12-01 15:17
Frantic

Registered: Mar 2003
Posts: 1648
only lamers save/restore when needed.
2016-12-01 15:42
chatGPZ

Registered: Dec 2001
Posts: 11386
PROS use SUPERPOKER for scriptz!
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Faayd/Quantum
Copyfault/Extend^tsn..
kbs/Pht/Lxt
Mythus/Delysid
t0m3000/hf^boom!^ibx
chancer
Walt/Bonzai
Mike
Mason/Unicess
katon/Lepsi De
Freeze/Blazon
Magic/Nah-Kolor
crayon/Hokuto Force
MWR/Visdom
Thierry
Steffan/BOOM!
MCM/ONSLAUGHT
Guests online: 122
Top Demos
1 Next Level  (9.7)
2 13:37  (9.7)
3 Mojo  (9.7)
4 Coma Light 13  (9.6)
5 Edge of Disgrace  (9.6)
6 What Is The Matrix 2  (9.6)
7 The Demo Coder  (9.6)
8 Uncensored  (9.6)
9 Comaland 100%  (9.6)
10 Wonderland XIV  (9.6)
Top onefile Demos
1 Layers  (9.6)
2 No Listen  (9.6)
3 Cubic Dream  (9.6)
4 Party Elk 2  (9.6)
5 Copper Booze  (9.6)
6 Dawnfall V1.1  (9.5)
7 Rainbow Connection  (9.5)
8 Onscreen 5k  (9.5)
9 Morph  (9.5)
10 Libertongo  (9.5)
Top Groups
1 Performers  (9.3)
2 Booze Design  (9.3)
3 Oxyron  (9.3)
4 Triad  (9.3)
5 Censor Design  (9.3)
Top Crackers
1 Mr. Z  (9.9)
2 Antitrack  (9.8)
3 OTD  (9.8)
4 Fungus  (9.8)
5 S!R  (9.8)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.176 sec.