aliens

Author Topic: Reversing to Orion - project 1oom  (Read 67783 times)

Offline Kilgore T.M. Replicant

  • Colonel
  • ****
  • Posts: 100
  • Mangia!
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #105 on: July 28, 2018, 06:53:53 am »
Thanks for the detailed analysis.

I did not test this, end even never try using this function, but I except this could avoid most problems.

I fear it would create a few more.

Instead of relative we use absolute mouse position. SDL do not move mouse anywhere only read its position.
If you press keyboard arrow key then and only then SDL move real mouse to expected position, this will keep real mouse and display cursors in sync.

The expected position varies based on window size and which aspect ratio is used (if any). The current mouse code is blissfully unaware of all that.

Using SDL_WarpMouseInWindow generates a mouse event. I fear that could affect mouse acceleration in some broken cases (see bug).

Side effect:

Arrows keys do not working in RDP, but as it do not work now ether so we do not lose any thing.

The cursor is moved on other occasions too. Any hotkey which points to an object (for example "n" to Next turn), at the start of main menu to New game, when exploring a planet (IIRC) to Continue...

So this would not be a complete fix and would add messy mouse->screen coord translation code. I certainly won't change the current code to absolute to almost-fix RDP. I also won't outright reject a patch that implements it for -norelmouse only.
« Last Edit: July 28, 2018, 11:43:09 am by Kilgore T.M. Replicant »

Offline Kilgore T.M. Replicant

  • Colonel
  • ****
  • Posts: 100
  • Mangia!
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #106 on: July 29, 2018, 12:54:03 pm »
1oom v0.6 has been released. Changes:
    - fix mouse handling on large resolutions, replace -mousediv with -mousespd
    - extend mouse wheel support for counts, add options for inverting
    - clicking cycles selection of overlapping fleets/transports
    - new -uiextra UI features, notably:
        * space combat autoresolve for skipping uninteresting battles
        * target bases for planetary governor (right-click planet name)
        * partial fleet send does not deselect fleet
        * click destination again to Accept
        * Game screen options overhaul: sound/music volume, mouse speed, ...
    - less than 100 bugs fixed, notably:
        * AI expansion was hindered by several bugs
        * space combat had issues
        * fixed a few crashes
    - doc/pbxin_fixbugs.txt expanded, including fixed starting ship costs
    - cmdline UI is now complete
    - 1oom_lbxedit (which you should ignore and use 1oom_pbxmake instead)

Source code: https://gitlab.com/KilgoreTroutMaskReplicant/1oom
Binaries: https://gitlab.com/KilgoreTroutMaskReplicant/1oom/tags/v0.6
Homepage: https://kilgoretroutmaskreplicant.gitlab.io/plain-html/

HELP WANTED!

The project has reached a point where the game is fully playable, not crashing all the time and actually fighting back.

Many of the undoubtedly remaining bugs will need MOO1 expertise to spot. If you can beat MOO1 on impossible (which the project maintainer has yet to do) then please give this a whirl and report any oddities you encounter.

On the other hand, many of the remaining bugs will be obvious once bumped into. Play and report! Onward to v1.0!

Still looking for big endian hardware test results.

Offline Kilgore T.M. Replicant

  • Colonel
  • ****
  • Posts: 100
  • Mangia!
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #107 on: August 10, 2018, 08:52:55 am »
Does the music have correct tempo?

I lack the sense of rhythm and/or software to verify this. The option -xmidtpq / xmid_ticksperq controls the tempo, the default value is 55. I'd like to get the correct value determined and the option removed.

I'd suggest recording two loops of the main menu music with MOO1 and 1oom (with xmidtpq values near 55) and trying to align the recordings with an audio editor. Report which one is closest.

If you have the software and about 15 minutes to spare, consider lending the project a hand.

Offline Kilgore T.M. Replicant

  • Colonel
  • ****
  • Posts: 100
  • Mangia!
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #108 on: August 17, 2018, 10:46:25 pm »
1oom v0.7 has been released. Changes:
    - game is deterministic by default
    - more options for planetary governor: (see doc/usage_common.txt)
        * spend rest on research/ships/reserve
        * ecology mode
        * build star gates
    - new -yearsave option for yearly saves (1oom_save_YYYY.bin)
    - Ctrl-F5 takes a screenshot
    - new -uiextra UI features:
        * 1.40m-like research bonus lights
        * extra menu (click bottom-left corner)
        * message filtering (via extra menu)
    - new "planet X has finished terraforming" message (off by default)
    - about 30 bugs fixed, notably:
        * many memory corruption crashes fixed (C is fun)
        * ETA is now correct
        * spy cost in Races screen matches actual costs
    - doc/pbxin_fixbugs.txt expanded, including fix for Oracle Interface

Source code: https://gitlab.com/KilgoreTroutMaskReplicant/1oom
Binaries: https://gitlab.com/KilgoreTroutMaskReplicant/1oom/tags/v0.7
Homepage: https://kilgoretroutmaskreplicant.gitlab.io/plain-html/

Offline Kilgore T.M. Replicant

  • Colonel
  • ****
  • Posts: 100
  • Mangia!
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #109 on: September 06, 2018, 05:40:29 am »
MOO1 was released 1993-09-06. Happy 25th anniversary! Here's 1oom v0.8 to celebrate the occasion. Changes:
    - click again to accept for transport redirection
    - all Advanced Technology are available for research
    - multiplayer player switching reduced
    - fix several music bugs
    - fix ship visibility during movement
    - fix ship scanner range
    - a handful of small fixes

Source code: https://gitlab.com/KilgoreTroutMaskReplicant/1oom
Binaries: https://gitlab.com/KilgoreTroutMaskReplicant/1oom/tags/v0.8
Homepage: https://kilgoretroutmaskreplicant.gitlab.io/plain-html/

tl;dr see above pic

Offline Yankes

  • Global Moderator
  • Commander
  • *****
  • Posts: 3350
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #110 on: September 08, 2018, 02:05:22 am »
One small tweak.
When you hold left button on production scroll (like SHIP, IND or DEF) and move mouse outside it, game still should adjust value to max or min.
Currently if you too fast move mouse (without releasing button) it will skip last step.

Offline Kilgore T.M. Replicant

  • Colonel
  • ****
  • Posts: 100
  • Mangia!
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #111 on: September 08, 2018, 07:19:16 am »
One small tweak.
When you hold left button on production scroll (like SHIP, IND or DEF) and move mouse outside it, game still should adjust value to max or min.
Currently if you too fast move mouse (without releasing button) it will skip last step.

I think this is a case of original behaviour that no one wants. Thanks for pointing it out. Attempting a fix... EDIT: Fixed in v0.8-3.
« Last Edit: September 08, 2018, 05:01:07 pm by Kilgore T.M. Replicant »

Offline Kilgore T.M. Replicant

  • Colonel
  • ****
  • Posts: 100
  • Mangia!
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #112 on: September 14, 2018, 05:14:04 am »
Dear Windows user,

If you know how to compile 1oom on Windows or are planning to find out, please consider documenting the setup process for a "How to compile on Windows" article for the 1oom homepage.

Regards,
- KTMR
Not a Windows user

Offline Yankes

  • Global Moderator
  • Commander
  • *****
  • Posts: 3350
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #113 on: September 15, 2018, 12:59:23 am »
Last nitpicking, when you press mouse down on scroll and move mouse out and release it then mouse click is triggered on spot where you move mouse.
Aside from that, last version work lot better when you fix last scroll quirk.

Offline Stoddard

  • Colonel
  • ****
  • Posts: 485
  • in a fey mood
    • View Profile
    • Linux builds & stuff
Re: Reversing to Orion - project 1oom
« Reply #114 on: September 15, 2018, 01:56:00 am »
Dear Windows user,

If you know how to compile 1oom on Windows or are planning to find out, please consider documenting the setup process for a "How to compile on Windows" article for the 1oom homepage.

Ahem, between mxe and autoconf it should be fairly straightforward. Or did you mean the unholy mess named VS?

Offline Kilgore T.M. Replicant

  • Colonel
  • ****
  • Posts: 100
  • Mangia!
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #115 on: September 15, 2018, 11:04:48 am »
Last nitpicking, when you press mouse down on scroll and move mouse out and release it then mouse click is triggered on spot where you move mouse.
Aside from that, last version work lot better when you fix last scroll quirk.

Unfortunately click-on-release is original behaviour. The related code is hairy and I'm not sure if it can be fixed without rewriting a lot of code and introducing a slew of new bugs.

Ahem, between mxe and autoconf it should be fairly straightforward. Or did you mean the unholy mess named VS?

As outlined in HACKING this project is autotools only. I'm thinking of Joe Q. Mooexpert who wants to tinker a bit with the AI code but has never compiled anything. A nice "download this, install that, type ./configure" guide would come handy for poor Joe. I'm half temped to write one myself with the first steps being "install Linux and MXE"... I wouldn't know where to start on Windows, and I doubt Joe would either.

Offline Yankes

  • Global Moderator
  • Commander
  • *****
  • Posts: 3350
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #116 on: September 15, 2018, 03:15:29 pm »
Unfortunately click-on-release is original behaviour. The related code is hairy and I'm not sure if it can be fixed without rewriting a lot of code and introducing a slew of new bugs.
"Last nitpicking", if it can't be change then its fine.

Offline SupSuper

  • Lazy Developer
  • Administrator
  • Commander
  • *****
  • Posts: 2162
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #117 on: September 18, 2018, 03:01:44 am »
As outlined in HACKING this project is autotools only. I'm thinking of Joe Q. Mooexpert who wants to tinker a bit with the AI code but has never compiled anything. A nice "download this, install that, type ./configure" guide would come handy for poor Joe. I'm half temped to write one myself with the first steps being "install Linux and MXE"... I wouldn't know where to start on Windows, and I doubt Joe would either.
If you're only gonna support autotools, then the only option is installing the Linux tools on Windows (eg. MSYS or WSL), at which point the steps are the same as Linux. :P All roads lead to Rome.

Offline Kilgore T.M. Replicant

  • Colonel
  • ****
  • Posts: 100
  • Mangia!
    • View Profile
Re: Reversing to Orion - project 1oom
« Reply #118 on: September 18, 2018, 10:13:51 am »
If you're only gonna support autotools, then the only option is installing the Linux tools on Windows (eg. MSYS or WSL), at which point the steps are the same as Linux. :P All roads lead to Rome.

Let's peek at the current INSTALL:
Quote
If you want to use SDL1:
    aptitude install libsdl1.2-dev libsdl-mixer1.2-dev

Does either of those come with Debian-derived packaging system?

Request stands. At least now I (and Joe) have some acronyms to google, but I can't test any of it.

Offline Stoddard

  • Colonel
  • ****
  • Posts: 485
  • in a fey mood
    • View Profile
    • Linux builds & stuff
Re: Reversing to Orion - project 1oom
« Reply #119 on: September 18, 2018, 04:37:15 pm »

Does either of those come with Debian-derived packaging system?

MSYS2 has pacman (from Arch Linux)

What I tried is:
Code: [Select]
install http://www.msys2.org/
run the mingw32 version

/bin/pacman -Syuu
 - close shell window as per instructions
/bin/pacman -S git autoconf automake gcc mingw32/mingw-w64-i686-SDL_image pacman -S mingw32/mingw-w64-i686-readline

git clone https://gitlab.com/KilgoreTroutMaskReplicant/1oom.git
cd 1oom
autoreconf -fi
./configure
(it fails)
make
(hopefully)


But then it did not found -lmingw32 and an hour of head-bashing the wall didn't make it work, so at this point it'd be simpler to just fire up a linux VM (for me)

It also doesn't find readline, which can be mitigated with
Code: [Select]
export LDFLAGS=-L/mingw64/lib/
export CFLAGS=-I/mingw64/include

but it should work without this.
« Last Edit: September 18, 2018, 04:41:52 pm by Stoddard »