Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Program Announcements / ANDROID NIM 2D

Author
Message
CHRIS 037
19
Years of Service
User Offline
Joined: 17th Feb 2005
Location: WA, USA
Posted: 17th Feb 2005 13:03
Hello Dark Basic Users,

Back in the Dark Ages of 1978 (probably before many forum members were even born) I wrote a game for the Radio Shack TRS-80 called ANDROID NIM. Even though that was over 25 years ago, I still get emails from people who enjoyed that little game.

About three weeks ago I found out about Dark Basic Pro and bought the program. I decided to rewrite ANDROID NIM in DBP. DBP is wonderful !!! I’ve done a bit of messing around with DirectX through C++ and had decided that it was just too much trouble. But no longer. Thanks DBPro.

I would like to ask you game programmers to have a look at ANDROID NIM 2D if you would and give me the benefits of your greater DBP experience through your comments. The program is available for download at www.leochristopherson.com and in zipped form is about 6 MB in size. From my main page follow the link to Android Nim.

From the forum postings I see that most members are involved in 3D programming and are doing terrific stuff. I hope to get into that eventually, too. But for now I think I’ll just enjoy working up some more 2D versions of the old TRS-80 games I did back in the late ‘70’s and ‘80’s. What Fun!

Leo Christopherson
AlexRiva
19
Years of Service
User Offline
Joined: 29th Jan 2005
Location: Monza, Italy
Posted: 17th Feb 2005 23:37
Good work, Mr.Christopherson! Even if this game is old like me it's fun(but chess are older than anyone alive and are veeeery fun) Did you create the game concept by yourself?('cause nowadays I've seen some flash games with the same concept applied to pearls or colored balls instead of aliens). Cute animations and explosions. Only one suggest, when you click on the aliens to select them, the selected aliens should be coloured in different way, only my opinion anyway. Another question, in which language did you write the original, in Basic or Assembly ? And did you make something with the C64, I am curious 'cause I've done something in Assembly on C64 in late 80's (yes, I was an enfant prodige). Waiting for other works!

Alex
CHRIS 037
19
Years of Service
User Offline
Joined: 17th Feb 2005
Location: WA, USA
Posted: 18th Feb 2005 00:48
Thanks Alex,

To answer your questions:

Yes, I came up with the game concept for Android Nim myself just after I got my old TRS-80 Model I in 1978. I learned about the game NIM from my high school algebra teacher years earlier and knew how to express it mathematically. That’s why I chose NIM.

As I was putting this version together, I did think about what you suggest—some way to indicate which android has been selected. Actually, if one waits just a bit, the selected androids will turn their heads toward the Controller Android and close their eyes, waiting for destruction. The unselected ones just continue to look all around as usual. If you play the game faster, which is fine of course, the little guys don’t have time to respond.

The original TRS-80 version was written in a combination of BASIC and Z-80 machine-level code. I used a weird combination of what I called “line-packing” to imbed machine code into BASIC strings, then used vectors through certain unused areas of the memory to call the code. The screen dumping and sound effects were done that way to increase the speed. The BASIC took care of the organization and logic of the game. The overall reason to do this was that it was relatively easy to record and load a BASIC program using tape (remember those days?). But loading a machine level chunk of code was a pain (my opinion, at least).

No, I never had the pleasure of working with a C64, though I often wished I had one back then. A great programmer, Chris Crawford, who programmed for the Atari, did send me an Atari 800, I think it was, and urged me to have a shot at programming some of my stuff on that machine. But as luck would have it, Radio Shack / Tandy also had just sent me their new Color Computer and an offer I couldn’t refuse. They had just gotten permission from Robert Heinlein to do a version of “Starship Troopers” and asked if I would like to try that. So my first CoCo game was “Klendathu” which sold pretty well through Radio Shack stores. I also always wanted an Amiga, but that never happened.

Thanks again for your comments and good luck to you,

Leo Christopherson
Jeku
Moderator
21
Years of Service
User Offline
Joined: 4th Jul 2003
Location: Vancouver, British Columbia, Canada
Posted: 18th Feb 2005 10:41 Edited at: 18th Feb 2005 10:41
Great game--- I used to play this with my dad many years ago with coins! But with our rules the object of the game was to get the *other* guy to pick up the last coin

Still fun, though!


--[GameBasic - Coming Soon]-- ^^^ banner generously designed by TheBigBabou
CHRIS 037
19
Years of Service
User Offline
Joined: 17th Feb 2005
Location: WA, USA
Posted: 18th Feb 2005 12:35
Hello Jeku,

Yes, I've played Nim with the reverse idea too: whoever takes the last piece, loses.

I went the way I did for two reasons. First I learned it that way. And second, The computer/math computation for winning can go all the way to the end my way. The 'last picked = loser' causes a final departure from the math algorithm in the last few moves. I chose the easier way.

Although I must admit, when I was a junior high math teacher and used to offer $5.00 to anyone that could beat me playing Nim on the blackboard, (and some kid always started to see the patterns and won the money) I would sometimes switch the rules, which did confuse the issue enough to keep the game going longer. . . Well, I was the teacher and teachers make the rules, don't they?

Anyway, thanks for your positive comments

Leo Chris.
CHRIS 037
19
Years of Service
User Offline
Joined: 17th Feb 2005
Location: WA, USA
Posted: 21st Feb 2005 07:44
In case you're interested,

I just added a MS WORD file of the source code for my Android Nim 2D at the request of a few people. It may be useful to beginning DBP programmers, I hope.

http://www.leochristopherson.com/android_nim.htm

Note: I forgot to mention that the program needs to be run in 16-bit color mode for proper operation. I think most DBP users will have realized this.

Leo Chris.
ChuckyZ
19
Years of Service
User Offline
Joined: 2nd Feb 2005
Location:
Posted: 21st Feb 2005 09:16 Edited at: 21st Feb 2005 09:16
You wrote that? Wow!! I used to play that on my old TRS-80 Model 1 computer. That was just after StarWars came out and I was blown away that the androids used lightsabers. Very cool game... What a blast from the past...

David Raines >!<
chuckyz2004@comcast.net
CHRIS 037
19
Years of Service
User Offline
Joined: 17th Feb 2005
Location: WA, USA
Posted: 21st Feb 2005 09:24
David,

Thanks for remembering. I suspect you're actually refering to another TRS-80 program I wrote back then that featured the same android characters. It was called "DUEL 'n' DROIDS." They did fight with lightsabers. You and your droid fought against the computer's droid.

Leo Christopherson

Login to post a reply

Server time is: 2024-11-22 08:48:54
Your offset time is: 2024-11-22 08:48:54