• xtrn/utopia/utopia.js

    From Rob Swindell (on Windows 11)@VERT to Git commit to main/sbbs/master on Tuesday, January 20, 2026 22:57:09
    https://gitlab.synchro.net/main/sbbs/-/commit/996c10d895fd35996a8874d8
    Added Files:
    xtrn/utopia/utopia.js
    Log Message:
    AI (Gemini) attempt at a clone of the Intellivision game "Utopia" for SBBS

    This version of the script (the AI called v10.1.16) was the result of several prompts/iterations and at a point where the bot really couldn't add any more features or functions (even though it kept suggesting great ones) without removing basic functionality or (re)introducing bugs. It got really frustrating after this point, basically going in circles with a very apologetic but confident programming robot. Still... impressive for a *free* AI chat bot. https://gemini.google.com/share/71b6228f0bf7

    I did js-beautify the code and removed the comment block at the top, but otherwise, it's exactly as Gemini made it. It's a playable game but has some issues I'll be addressing:
    - the cosmetics (e.g. graphic character choices) are pretty basic/ugly
    - it's very hard-coded for an 80x24 terminal (not a huge issue)
    - it only spawns a single fish
    - it saves the user-game data in the current directory instead of the "correct"
    path/filename (data/user/####.*)
    - the saved-game data (json) isn't versioned, so it really has to match the
    game version you run or weird behavior or errors will happen when you load a
    saved game from a different version
    - the game economics aren't really fleshed out
    - some of the (important?) elements of the original (e.g. hospitals) aren't
    included (https://history.blueskyrangers.com/instructions/utopia.html), but
    being single player instead of multi-player I do expect there to be some
    differences (e.g. PT boats being sinkable by pirates and being able to sink
    pirates, I think is a good one)

    There were a lot of good ideas that the AI suggested and even implemented before and after this version of the script and I'll try to merge those in while also addressing my own concerns/issues with the game.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Wednesday, January 21, 2026 03:32:24
    https://gitlab.synchro.net/main/sbbs/-/commit/8665d57b9ebd4a6cdf4dc829
    Modified Files:
    xtrn/utopia/utopia.js
    Log Message:
    Multi-fish patch

    Successfully merged in Gemini's patch for multiple fish

    I also changed some of the characters used to be a little better
    (e.g. $ for merchant, the Pt symbol for Pirate, lowercase alpha for fish)

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Wednesday, January 21, 2026 18:16:36
    https://gitlab.synchro.net/main/sbbs/-/commit/11183ff911935e79e5a7edf8
    Modified Files:
    xtrn/utopia/utopia.js
    Log Message:
    Cosmetic and usability improvements

    - flash (blink) the fish and boats when they're caught/sunk for one turn
    - don't redraw the legend for every turn
    - add Ctrl-R key to force a redraw (for testing mainly)
    - add [L]og key to view all past messages
    - turns count up rather than down
    - some code cleanup
    - better error logging
    - no AI-generated code added in this commit

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Saturday, January 24, 2026 05:47:19
    https://gitlab.synchro.net/main/sbbs/-/commit/6a514d1a1c618cecc5c3460b
    Modified Files:
    xtrn/utopia/utopia.js
    Log Message:
    This is a good checkpoint - it's now a fun playable game that's not too easy

    Still messing with the economics and such (I think I'd like to have trawlers chase fish, but then tracking age/damage gets tricky).

    I still want to add mouse, sound, maybe graphics.

    And probably some more items like a more robust food item to buy/build, maybe
    a fort, hospital, etc.

    No docs or anything so if you're not familiar with the original Utopia or this genre of game, it might be really confusing and hard. So only the really
    really curious and experimental should try this right now. Oh, and spews a lot of (info-level) debug output to the terminal server log.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Saturday, January 24, 2026 19:24:29
    https://gitlab.synchro.net/main/sbbs/-/commit/af39138ac64523a908259f37
    Modified Files:
    xtrn/utopia/utopia.js
    Log Message:
    Trawlers chase fish, PT Boats track damage/age

    Doesn't spew debug log messages now unless passed -debug option

    Don't start game until first land item built

    Save the game file in the correct location (data/user) and other little usability things (e.g. display number of current built items of each type).

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Saturday, January 24, 2026 22:12:07
    https://gitlab.synchro.net/main/sbbs/-/commit/32d243e9f8ba8778cef98958
    Modified Files:
    xtrn/utopia/utopia.js
    Log Message:
    Encapsulate the rules, not the game functions

    I anticipate I'll want to support tracking/iterating and providing multiple sets of rules that the user can choose from and sysops might want to provide their own. And high score lists should be specific to the set rules used to play the game. So the *rules* should have been encapsulated (and were not).

    However, the game functions were encapsulated via the Utopia object and
    we'll never have multiple instances of this Utopia object, so just get rid
    of that (and over 600 required uses of 'this.that' syntax).

    Whew! That's more like it. Yes, the script-global namespace is all polluted with variables and objects now, but this is better suited to my taste.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Sunday, January 25, 2026 04:18:59
    https://gitlab.synchro.net/main/sbbs/-/commit/4fe495ec6ab9823fe55bebbb
    Modified Files:
    xtrn/utopia/utopia.js
    Log Message:
    Add buildable docks which are required for building boats

    ... and the merchat will now trade with a dock, not "Industry"

    You can extend the dock with a bridge, making a pier

    Can't build diagnoally to the dock/pier though, kind strict. (N,S,E, or W
    of the dock only) - I might make that more liberal to keep one or two boats from keeping one from building (though that does encourage bridge building).

    Other nice user niceties added, like showing the health of individual
    item the cursor is on.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Sunday, January 25, 2026 15:23:59
    https://gitlab.synchro.net/main/sbbs/-/commit/0958ba1616c91d21bef48233
    Modified Files:
    xtrn/utopia/utopia.js
    Log Message:
    Time was being throttled by the inkey() timeout (of 500ms)

    Holding down <any> key would allow time to move at the (increased) rate,
    that was the clue.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Monday, January 26, 2026 03:54:59
    https://gitlab.synchro.net/main/sbbs/-/commit/b6ef48a5d87bd9749331a726
    Modified Files:
    xtrn/utopia/utopia.js
    Log Message:
    Added animals (another food source), smarter boats

    Some UI enhancements and other nice features (e.g. P to Pause)

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Tuesday, January 27, 2026 01:16:51
    https://gitlab.synchro.net/main/sbbs/-/commit/616dbb54e15de61cd6fc57ff
    Modified Files:
    xtrn/utopia/utopia.js
    Log Message:
    Some display optimizations

    Enable the v3.21 gotoxy optimization and use drawRow where we should

    PT boat won't be quite a shy of the Merchant ship if the pirate ship is near.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net