Commit graph

38 commits

Author SHA1 Message Date
Christian Semmler
be4c351d7d
Rename Start/StopTimer to Pause/Resume (#1007)
* Rename Start/StopTimer to Pause/Resume

* Fix
2024-06-09 13:39:22 -04:00
Christian Semmler
6e7e9a3f20
Add more annotations to ISLE (#990)
* Minor improvements in ISLE.EXE

* Add more annotations

* Fix

* Comment out

* Fix lint
2024-06-05 12:31:23 +02:00
Christian Semmler
df20b05510
Define cursor enum and custom cursor window message (#980)
* Define cursor enum and custom cursor window message

* Fix param name

* Remove unused header
2024-06-01 16:07:58 +02:00
Christian Semmler
b67af71f33
Improve naming, use virtual key constants (#979) 2024-06-01 04:46:05 +02:00
Christian Semmler
1b1d2ecde6
Refactor LegoOmni into LegoMain/Scripts (#883)
* Refactor LegoOmni into LegoMain/Scripts

* Fix guard
2024-05-04 14:06:32 +02:00
Christian Semmler
51adf75b9b
(Refactor) Use more forward declarations (#881)
* Use more forward declarations

* Use more forward declarations

* Add more forward declarations

* Fix
2024-05-03 18:19:12 +02:00
Christian Semmler
8069923651
Refactor files based on beta debug build (#645)
* Rename LegoUnkSaveDataWriter -> LegoCharacterManager

* Refactor mxomni into mxomni/mxmisc

* Refactor legoomni into legoomni/misc

* Resolve deps

* Refactor atom

* Refactor mxutil

* Refactor mxio

* Rename/relocate files

* Fix format
2024-03-09 21:07:52 +01:00
Nathan M Gilbert
84af3e2158
Match some names/values (#545)
* Match some names/values

* Fix mingw warning as error
2024-02-10 00:40:52 +01:00
Christian Semmler
a2c1bd66b3
Various changes to IsleApp (#531)
* ISLE experiment

* Annotations

* Remove define.cpp

* Remove header

* Fix types

* Leave as MxLong for now
2024-02-05 15:01:48 +01:00
MS
264b9e815b
Match static function variables (#530)
* Match static function variables

* IsleApp::Tick static variables
2024-02-05 12:43:13 +01:00
Anonymous Maarten
9e686e2a87
cmake+ci: run clang-tidy (#512)
* cmake+ci: run clang-tidy

* Remove DESCRIPTION from LEGO1/LegoOmni.mingw.def

* Add initial .clang-tidy and fixes

* fix file perms

* Comment out DESCRIPTION

* Remove LegoEntity::~LegoEntity and MxPresenter::~MxPresenter from mingw's LEGO1.def

* Looks like clang is allergic to the libs in the directx5 SDK

* Update .clang-tidy

* Fix typo in .clang-tidy

* Attempt to generate an action error

* Revert "Attempt to generate an action error"

This reverts commit 96c4c65fedbc4102837f4bcbbb9ee83a7d14cba3.

* cmake: test with -Wparentheses + optionally with -Werror

* ci: -k0 is a Ninja argument

* Use -Werror only for msys2 builds

* cmake: only emit warnings for specific warnings

* cmake: and don't do -Werror/-WX anymore

* Fix warnings

* Fix mingw warnings

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
2024-02-01 21:42:10 +01:00
Anonymous Maarten
5f413165cc
Spinoff some sources to static libraries (#484)
* cmake: use imported targets for 3rd party libs

* Fix casing of skateboard.h include

* cmake: tglrl realtime viewmanager mxgeometry

* cmake: spin off some source in static libraries

* dx5 for everyone

* ci: bump actions/checkout to v4

* move LEGO1/realtime/realtimeview.cpp to lego1 because it exports symbols

* add misc library

* Add omni library

* Return of the .def's

* Remove COMPAT_CONST in MxVideoParam::MxVideoParam

* Run clang-format

* move LEGO1/realtime/realtimeview.cpp to realtime lib

* Add 3dmanager library

* Rename .def files

* Remove incorrect deps to Omni

* Remove DLL expor decls

* Remove unnecessary library dep from ROI

* Remove COMPAT_CONST

* Move 3dmanager lib before Omni

* Remove mxgeometry lib (`geom` is actually `lego/sources/geom`, which we don't have in our decomp yet)

* viewmanager has a dependency on realtime + fix mingw's def

* Remove Smacker::Smacker from lego1 link libraries

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
2024-01-24 21:16:29 -05:00
Misha
f50b771fff
begin implementation of InfoCenter class (#444)
* Push changes

* fixes

* Implement Infocenter::HandleEndAction

* match Infocenter::StopCutScene

* implement Infocenter::HandleKeyPress

* fixes

* Update infocenter.cpp

* Update legoworld.cpp

* use enums

* WIP Fixes

* Fix

* Fix

* Fix

* Rename function

* Change enum

* Update enums

* Refactor another enum

* Refactor MxDSType

* Refactor HashTableOpt

* Fixes

* Refactor tickle enum

* Update other enums

* Add EnumConstantName to ncc

* Move enum to global namespace

* Rename enum

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
2024-01-17 17:53:53 +01:00
Joshua Peisach
763fcf8980
ElevatorBottom ctor/dtor (#436)
* ElevatorBottom ctor

* ElevatorBottom destructor

* Use setters

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
2024-01-14 22:58:00 +01:00
Christian Semmler
c47206617d
Reorganize sources and files (#414)
* Reorganize sources

* Refactor

* Remove relative paths

* Renames

* Fix gitignore

* Remove stuff

* Try fixing format script

* Fix format

* Fix format

* Fix naming script

* Test format

* Fix format
2024-01-08 10:58:49 +01:00
Anonymous Maarten
fbe7f8bbb0
Fix all mingw errors & warnings (#411)
* Use COMPAT_MODE macro to fix errors with mingw gcc 12.2

* MxOmni::m_timerRunning is a MxBool

* MxDirect3D::m_unk0x88c is a MxBool

* MxBackgroundAudioManager::m_unk0x13c is a MxS32

* Fix warning: deleting 'void*' is undefined [-Wdelete-incomplete]

* Fix inline function 'void TglImpl::RendererImpl::Destroy()' used but never defined

* Fix warning: inline function 'MxStreamerSubClass1::MxStreamerSubClass1(undefined4)' used but never defined

* Use `FALSE` for m_timerRunning

* Format

* Format

* Remove comment

* Limit scope for variables in compat mode

* clang-format

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
2024-01-07 18:30:45 +01:00
Christian Semmler
bb7e4df11b
Move MxDirectDraw and MxDirect3D to mxdirectx (#413) 2024-01-07 18:07:22 +01:00
Christian Semmler
8db36722d8
Implement/match Lego3DView and parent classes (#412)
* Implement/match TglSurface

* Implement/match LegoView/1

* Lego3DView

* Fixes

* Lego3DManager

* Remove garbage

* Remove garbage

* Use shorthand calls
2024-01-07 03:29:32 +01:00
Christian Semmler
d4e7bb1132
Implement/match MxDirect3D::SetDevice (#401)
* WIP

* WIP

* WIP

* Rename class

* Rename vars

* Rename function

* Rename

* Rename flag

* Fix deletion of modeArray

* Remove obsolete comment
2024-01-04 20:37:15 +01:00
Christian Semmler
afd24fbe18
Implement MxStreamController::FUN_100c1a00 (#357)
* Implement MxStreamController::FUN_100c1a00

* Move include
2023-12-24 21:00:20 +01:00
Christian Semmler
bc5ca621a4
(Proposal) Introduction of naming convention checker (ncc) (#322)
* Add ncc tool

* Add symlink

* Fixes

* Try this

* Try this

* Try this

* Try this

* Add include path

* Update style

* Update style

* Add more rules

* Fix style

* Update styles

* Fix name parameter

* Fix MxParam p

* Fix m_unk0x pattern

* Allow 4 digits for relative hex

* Add missing offset

* Fix some parameters

* Fix some vtables

* Fix more vtables

* Update rules, fixes

* More fixes

* More fixes

* More fixes

* More fixes

* More fixes

* More fixes

* More fixes

* Fix last issue

* Update readme

* Update readme

* Update CONTRIBUTING.md

* Fix annotations

* Rename

* Update CONTRIBUTING.md

* Update README.md
2023-12-13 11:48:14 +01:00
Christian Semmler
3b155bfe38
(Discussion/Proposals) Consistency regarding annotations of header-implemented functions (#316)
* Open discussion

* Move annotations of header-implemented functions back to `.h` files

* Adjust `README.md`

* Relocate annotation

* linter

* Comment markers in headers only, rename script, update github actions

* type hint compat

* Rename github action, better argparse for linter

* Type hints, working test for byname ignore

* Move annotation

* CI rename and enable warnfail, enforce mode always on

* Two step linting

* or one step

* continue on error

* two jobs instead

* Fixes

---------

Co-authored-by: disinvite <disinvite@users.noreply.github.com>
2023-12-12 20:27:17 +01:00
Christian Semmler
02aaf1533f
Increased ISLE accuracy (#319)
* Improve WndProc accuracy

* Another accuracy fix for `WndProc`
2023-12-09 18:49:13 +01:00
Christian Semmler
494a556f8e
(Proposal) Adjustments to "decomp" language (#308)
* Adjustments to "decomp" language

* Fix a comment

* Fix accidental clang-formatting

* Fix order

* Fix order

* Remove junk

* Fix OFFSET

* Adjustments based on new suggestions

* Annotate globals

* Globals in ISLE

* More globals

* Merge from parser2 branch

* Allow prepending space for exact marker match

* To eliminate noise, require the 0x prefix on offset for marker match

* fix test from previous

* Count tab stops for indented functions to reduce MISSED_END_OF_FUNCTION noise

* FUNCTION to SYNTHETIC where needed

* Missed marker conversion on SetAtomId

* pylint cleanup, remove unused code

* Fix unexpected function end, add more unit tests

* Be more strict about synthetic name syntax

* Revert "Missed marker conversion on SetAtomId"

This reverts commit d87d665127fae7dd6e5bd48d9af14a0a829bf9e2.

* Revert "FUNCTION to SYNTHETIC where needed"

This reverts commit 8c815418d261ba8c5f67a9a2cae349fe4ac92db8.

* Implicit lookup by name for functions

* Fix VTABLE SYNTHETIC and other decomp markers

* Get vtable class name

* Vtable marker should identify struct

* No colon for SIZE comment

* Update README.md

* Update README.md

* Update CONTRIBUTING.md

* Update README.md

* Update README.md

* Update CONTRIBUTING.md

* Update README.md

* Update CONTRIBUTING.md

* Fix destructor/annotation

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

---------

Co-authored-by: disinvite <disinvite@users.noreply.github.com>
2023-12-06 13:10:45 +01:00
MS
1ae3b07dc2
Checkorder tool to keep functions in original binary order (#228)
* First commit of order tool

* More flexible match on module name. Bugfix on blank_or_comment

* Report inexact offset comments in verbose mode. Bugfix for exact regex

* Refactor checkorder into reusable isledecomp module

* Find bad comments in one pass, add awareness of TEMPLATE

* Refactor of state machine to prepare for reccmp integration

* Use isledecomp lib in reccmp

* Build isledecomp in GH actions, fix mypy complaint

* Ensure unit test cpp files will be ignored by reccmp

* Allow multiple offset markers, pep8 cleanup

* Remove unused variable

* Code style, remove unneeded module and TODO

* Final renaming and type hints

* Fix checkorder issues, add GH action and enforce (#2)

* Fix checkorder issues

* Add GH action

* Test error case

* Works

* Fixes

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
2023-11-21 09:44:45 +01:00
MS
7834f18999
MxQueue and parts of LegoInputManager (#268)
* MxQueue and parts of LegoInputManager

* Missed clang-format on mxqueue.h

* Fix declarations

* MxParamType -> NotificationId

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
2023-11-07 09:30:26 +01:00
Christian Semmler
b449da1fa3
Introduce clang-format (#240) 2023-10-25 01:38:27 +02:00
Misha
625ee52fe0
implement a few mxomni/legoomni functions (#193) 2023-10-09 12:31:36 +02:00
Misha
d82649c6f0
MxStream provider and controller vtables (#191)
* MxStreamProvider and MxRamStreamProvider vtable

* Update mxramstreamprovider.h

* Match IsA

* Fixes, improvements

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
2023-10-08 22:41:34 +02:00
ChrisMiuchiz
aa516af434
Remove goto from isleapp.cpp (#188)
* Remove goto from isleapp.cpp

* Simplify if statement and make indent consistent
2023-10-08 16:10:16 +02:00
Misha
8281e195f7
Implement MxOmni Start/stop timer (#181)
* Implement start/stop timer

* Mark StartDirectSound as stub

* remove accidently committed files
2023-10-07 19:12:59 +02:00
Christian Semmler
5164ef1a54
Refactor MxOmni/LegoOmni headers to use forward declarations (#148)
* Refactor MxOmni/LegoOmni headers to use forward declarations

* Fixes

* Fix build

* Fix deps
2023-10-07 17:30:04 +02:00
MattKC
3f6e3af8ca
Fix LegoOmni vtable (#140) 2023-09-25 13:28:25 -07:00
Christian Semmler
bd9dca0d3f
Implement most of MxDSAction (#103)
* Implement most of MxDSAction

* Update mxdsaction.h

* Update mxdsobject.cpp
2023-08-08 19:38:07 -07:00
Christian Semmler
d41b7f2ca4
Add GetDeviceModeFinder to WndProc (#102) 2023-08-06 13:26:14 -07:00
pewpew
0f92e345b3
MxTickleManager mostly done (#94)
* Checkpoint to show MxTickleManager::SetClientTickleInterval match.

* Match MxTickleManager::~MxTickleManager, obliterate MxTickleManager::SetClientTickleInterval.

* Make conditional more realistic, move MxTime to mxtypes.h, add TODO for MxTickleManager::Tickle.
2023-08-03 11:19:05 -07:00
MattKC
e16249b672
Define MxLong/MxULong (#71)
* define MxLong/MxULong

The "long" type has different sizes on different platforms, and this may cause issues.

* use DWORD to match RegQueryValueExA arg
2023-07-02 01:05:49 -07:00
Cydra
07912eb05a
Class layout for LEGO1 classes (#43)
* Stubbed a bunch of classes and annotated them for later use. Heavily wip and more of pseudocode right now.

* Converted pseudocode into real code!

* Created a bunch more classes and added more information to exisiting ones
Did not error check, this was pushed just for reference

* More classes and implementation details. Still not checked for any errors

* Fixed code and decided on a way to handle virtual table stubs

* Some additional fixes

* More smaller fixes

* Added classes to project and made it compile

* Fixed function adresses that caused the python script to fail

* More classes and virtual function resolves. Builds and compares fine.

* Again more classes and virtual function resolves. Builds and compares fine.

* No clue, I guess forced update for line endings

* Finished up some work, compiles fine. All functions are STUB annotated to not pollute reccmp.py output.

* line ending change

* rename GetClassName/IsClass

Mirroring recent changes from master

* further conform to current master

* update project

* cleanup

* project only updates when you close msdev

---------

Co-authored-by: Cydra <cydra95@gmail.com>
Co-authored-by: itsmattkc <34096995+itsmattkc@users.noreply.github.com>
2023-06-29 01:10:08 -07:00
Renamed from ISLE/isle.cpp (Browse further)