Basic programming

Stormyguy

macrumors regular
Original poster
Apr 15, 2002
116
0
UK (Sussex)
Hi all

I am wanting to create a text-based game, rather like the old 'adventure' text-based games that I used to play on my Commodore VIC20 years ago (eeks - that was a long time ago).

I used to be able to program these machines in BASIC language which was exactly what it sounds but perfectly adequate for what I want to do - user inputs, random numbers for different situations, subroutines etc etc etc.....

Can anybody recommend a suitable program or is it perhaps something I could do with Applescript?? If it can cross-platforms to Peecee to (so that I can share it with pals) then that would be much better (guess that rules out Applescript)??

If there is the option to have any graphics or 'buttons' to click on that maybe an enhancement I could build in but my programming skills may not stretch that far!!!!!!

Thanks
Danny
 

OSeXy!

macrumors regular
Jan 17, 2002
239
0
London (or virtually here)
If you want it to be cross-platform, do it in VB (Visual BASIC) or VBA (Visual BASIC for Applications). With VBA You could do the whole thing via a macro in Word or Excel, and anyone on a PC should be able to run it, too. It's fairly easy to pick up if you've done anything Object-Oriented before. Yes, it's M$, so it has it's built in drawbacks, but it does give you the tools to make your own GUI dialogs, etc. and if you're comfortable with BASIC syntax, the learning curve isn't too steep...

There are some good mac-only freeware/shareware BASIC compilers around, if you don't care about using your game on a PC...

Good luck with the project!
 

ftaok

macrumors 603
Jan 23, 2002
6,199
1,220
East Coast
Compilers for BASIC?????

Holy smokes! What's this world coming to? They have compilers for BASIC now. Has BASIC become so advanced that they need compiling?

I'm from the old-school. This is the sort of stuff that used to amuse me.

10 LET A=0
20 PRINT A
30 LET A=A+1
40 GOTO 20

RUN

(and watch the fun for hours)
 

Stormyguy

macrumors regular
Original poster
Apr 15, 2002
116
0
UK (Sussex)
Chortle!

Yes - that's the sort of thing I need to do!! Back to the grass-roots!

Thanks for the above suggestions - I'm going to initially have a crack at the Chipmunk thing - let you know how it goes!!

Danny:D
 

Beej

macrumors 68020
Jan 6, 2002
2,139
0
Buffy's bedroom
Re: Compilers for BASIC?????

Originally posted by ftaok
10 LET A=0
20 PRINT A
30 LET A=A+1
40 GOTO 20

RUN

(and watch the fun for hours)
LOL :D I'm sure that would be very exciting. Like the C program

int main()
{
while(1) exit(1);
}
 

ftaok

macrumors 603
Jan 23, 2002
6,199
1,220
East Coast
Re: Re: Compilers for BASIC?????

Originally posted by Beej
LOL :D I'm sure that would be very exciting. Like the C program

int main()
{
while(1) exit(1);
}
Someone's gonna have to explain this one to me. My programming skills are limited to BASIC, Logo ('member this one), simple HTML, and my VCR.
 

Beej

macrumors 68020
Jan 6, 2002
2,139
0
Buffy's bedroom
Re: Re: Re: Compilers for BASIC?????

Originally posted by ftaok
Someone's gonna have to explain this one to me. My programming skills are limited to BASIC, Logo ('member this one), simple HTML, and my VCR.
It goes like this...
start program
exit program

Fun, hey? :D
 

barkmonster

macrumors 68020
Dec 3, 2001
2,123
12
Lancashire
Realbasic is okay apart from the slow as hell blitting routines

It's not strictly basic as such, it's got way more commands than a sinclair spectrum or GFA basic on the Atari ST had but it seems okay for some things like making the text game you're on about.
 

Stormyguy

macrumors regular
Original poster
Apr 15, 2002
116
0
UK (Sussex)
Yes, it (Chipmunk) seems to have pretty much all the stuff I was looking for and all the old commands I recognise - it's all starting to come back into place - quite nostalgic really, LOL!

Thanks for the pointer firewire.....
 

OSeXy!

macrumors regular
Jan 17, 2002
239
0
London (or virtually here)
Yeah, Chipmunk is great, a real blast from the past. Didn't realise there was a PC version! I used to use it with BBEdit - Chipmunk has a plugin which lets you compile and debug from there. I think it also allows you to choose whether to use line numbers or not... Good for those who like "GOSUB 10053" rather than "CALL MyGreatSub()"... Have fun!
 

evildead

macrumors 65816
Jun 18, 2001
1,275
0
WestCost, USA
RealBASIC

If you did it in RealBASIC you could make exicutable Mac and PC versions of your game. Its a very simple environment to work in and it gives you some GUI tools to work with if you want to make the interface look nicer.


-evildead


#!/bin/bash
#
init 0
 

Spelunk

macrumors newbie
I know this is totally uncalled for, but might I suggest looking at the Python language. It has the advantages of being interpreted, cross-platform (Mac, Win, Unix, etc), free, easy to learn, and lots of other programatic niceness that you might like if you want to get more involved (very sensible object-orientation, extensive library, can use several GUI interfaces). It is also not BASIC. :D

The homepage is http://www.python.org.

Hey, I might not be a very good Mac zealot, but at least I can be a Python zealot.
 

Stormyguy

macrumors regular
Original poster
Apr 15, 2002
116
0
UK (Sussex)
OK guys - thanks for the ideas.

Where do I get RealBasic from?? Tried Versiontracker but only lots of 'extras' for RealBasic.
 

Stormyguy

macrumors regular
Original poster
Apr 15, 2002
116
0
UK (Sussex)
All concerned,

Feedback:
Thanks again for the help - the Chipmunk BASIC seems to be just fine and I'm getting on with the project no worries!

Thanks again
Danny
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.