QB64.org Forum

Active Forums => Programs => Topic started by: xra7en on December 12, 2018, 01:35:55 pm

Title: BBS Game Legend written from scratch!
Post by: xra7en on December 12, 2018, 01:35:55 pm
Yup. ye old BBS farts should recognize this.


changes

It is about 65% - 75% done still adding
QB64 was a perfect fit for this game (and the alt-enter for full screen is a magic touch)

Haven't released the source yet, but will be happy to post any scripts your are interest in on how something works in the game
I usually work on it heavily on the weekends - I have it at itch but not sure if i can post that here. so here is the game to test.

enjoy -
Title: Re: BBS Game Legend written from scratch!
Post by: xra7en on December 12, 2018, 02:15:07 pm
Now here is one trick I picked up. Didnt work the first time til I did some research. Apprently there is a glitch in the INSTR function that prevented this from working (for me anyways)

Code: QB64: [Select]
  1. FUNCTION GET_OPTION$ (OPTION_STR AS STRING)
  2.     DIM OPT AS STRING
  3.     OPTION_STR = " " + OPTION_STR 'The space in the INSTR instruction and the > 1 are there as otherwise the loop would exit on the first pass.
  4.     DO
  5.         OPT = UCASE$(INKEY$)
  6.     LOOP UNTIL INSTR(UCASE$(OPTION_STR), OPT) > 1 AND OPT <> ","
  7.     GET_OPTION = OPT
  8.  

in my game I use a lot of INKEY$ options for players. So I made a routine. originally it was
Quote
LOOP UNTIL OPT = "A" OR OPT = "B" OPT = "C" OR OPT = "D" ' BLA BLA BLA


THAT got really annoying. so "went in search of..."

what I found out is the INSTR is perfect, BUT, big but, IT WILL NEVER EXECUTE.
Originally I found that

Code: QB64: [Select]
  1. IF INSTR(UCASE$(OPTION_STR), OPT) > 0

IT fails. I couldn't find anything in the qb64 wiki as why. I cant remember where I found this, but if you put a " " (space) in front of your string and change the  ">0" to  "> 1" then it works.

the "," is there because I use the OPTION_STR as a double use - one for display and the other for this function.

so now I can just use

Code: QB64: [Select]
  1. PLAYER_CHOICE = GET_OPTION$("A,B,C,D")

Now you watch...
either Pete or Fillipp will swoop in on their white horse gallantly and say ooo hey,, you can do it this way too (qb64 has a new function ) LOL

fingers crossed :)


Title: Re: BBS Game Legend written from scratch!
Post by: pagetelegram on December 16, 2018, 08:28:37 pm
I may start or be involved in starting a DOS/CMD only marketplace website.....one truly needs to exist that isn't just all games and abandonware.

I envision it to be tool based website and full applications, although I think BBS style games such as your adaptation would be welcome.

Also a lot of what you did with this game can probably be supported by wwwbasic....a google project with java interpretation of basic code for live world wide web use.

I did my lotto randomizer that way at http://pagetelegram.com/piball.html
Title: Re: BBS Game Legend written from scratch!
Post by: xra7en on December 17, 2018, 09:17:58 am
Interesting, my personal opinion is that the bbs need to take the lead again. The net is not as personal as the bbs's were, anonymity can be a bad thing.

 since it does not look promising to get an ok from gameport to reproduce this, i spent the weekend rewriting the game, space, new colors and hoards of other features.
The original design,which I am still working on,is a idle version. Not quite a clicker. Should have that version done soon