Commit Graph

240 Commits

Author SHA1 Message Date
Joshua Peisach
776483fa39
Annotate MxPalette members' offsets 2023-07-08 18:07:13 -04:00
Joshua Peisach
8d81a5cca7
Merge branch 'isledecomp:master' into mxpalette 2023-07-08 17:48:11 -04:00
Joshua Peisach
d4305d95da
Merge pull request #4 from ktkaufman03/matching/mxpalette
More work on MxPalette
2023-07-07 19:58:03 -04:00
itsmattkc
67115e32d3 cmake: bump minimum version 2023-07-07 12:22:42 -07:00
Mark Langen
889fd886f0
MxSemphore + MxThread + MxThread implementions (#80)
* Add MxSemphore + MxThread and the two implementations I could find
  of MxThread (consumers extend it and override the Run method).

* Implement a function in MxDiskStreamProvider which uses thread and
  semaphore to confirm correct layout / size of those classes.

* All 100% match except two functions with a pair of registers swapped.
2023-07-07 11:00:48 -07:00
MattKC
f8fe635248
ci: don't show context lines when diffing progress, only show changed lines 2023-07-07 10:44:53 -07:00
Mark Langen
391ca9908f
LegoStream and implementations 100% match (#77)
* MxFile and implementations 100% match

* Add MxFile and it's implementations, MxSystemFile and MxMemoryFile.
  The names are chosen by me, we don't know their original naming.

* These expose a Read/Write/Seek/Tell interface for reading and writing
  data, either from a file on disk or memory buffer.

* 100% match all functions.

* Change name to LegoStream

* Use p_ convention

* Assert size
2023-07-07 09:20:51 -07:00
ktkaufman03
f63190e3d4
fix: MxPalette::SetSkyColor is 100% matching 2023-07-05 18:02:54 -04:00
ktkaufman03
149d0e4f9b
feat: add/match MxPalette::CreateNativePalette [0x100BF000] 2023-07-04 21:45:12 -04:00
ktkaufman03
8734935beb
refactor: change unk50 in MxVideoManager to LPDIRECTDRAW 2023-07-04 21:44:24 -04:00
ktkaufman03
4097e0fa0d
fix: add MVideoManager() to mxomni header 2023-07-04 21:43:44 -04:00
ktkaufman03
7b774666c8
feat: add/match MxPalette::Reset [0x100BF490] 2023-07-04 20:54:58 -04:00
ktkaufman03
d711e015dc
fix: I once again forgot to commit mxpalette.h... 2023-07-04 20:50:44 -04:00
ktkaufman03
7182644f7f
rename MxPalette::SetPalette to MxPalette::SetEntries 2023-07-04 20:48:15 -04:00
ktkaufman03
df039077ce
fix: call ApplySystemEntriesToPalette from MxPalette(const RGBQUAD *) 2023-07-04 20:36:33 -04:00
ktkaufman03
f02d6198f1
refactor: remove MxPalette::FromBitmapPalette 2023-07-04 20:26:48 -04:00
ktkaufman03
cc3f3139b7
tidy: use Mx* primitives instead of builtins 2023-07-04 20:24:52 -04:00
ktkaufman03
0495056bf3
fix: I forgot to commit mxpalette.h... 2023-07-04 20:20:49 -04:00
ktkaufman03
ebc3145ca7
fix: MxPalette rgbquad ctor functionally matches
Not quite ASM matching yet because of weird
register allocation mismatches.
2023-07-04 20:11:48 -04:00
ktkaufman03
5dd157fe6c
fix: MxPalette::SetPalette is now functionally matching
Not assembly matching yet because of MSVC weirdness.
At some point it will probably start matching, because
the structure seems to be accurate.
2023-07-04 19:46:55 -04:00
ktkaufman03
5a6fcde97b
tidy: rename DC var in GetDefaultPalette to hdc 2023-07-04 18:33:19 -04:00
ktkaufman03
57885103c0
fix: MxPalette::ApplySystemEntriesToPalette is now 100% matching 2023-07-04 18:29:41 -04:00
ktkaufman03
1eb30e1ad1
fix: MxPalette::GetDefaultPalette is now 100% matching 2023-07-04 18:19:57 -04:00
Joshua Peisach
1f478a5bda Match GetDefaultPalette a bit more 2023-07-04 15:03:17 -04:00
Joshua Peisach
2b8480adb3 Fixes
- reordered the functions in order of where they are in the hex because recmp.py sometimes kept saying it couldn't find the symbol (??)
- clone returns a pointer, not a ref
- worked a bit on setpalette/applysysentriestopalette
2023-07-04 14:29:06 -04:00
Joshua Peisach
ad18611565
Merge branch 'isledecomp:master' into mxpalette 2023-07-04 13:55:18 -04:00
Joshua Peisach
09f1933ac3
Merge pull request #3 from ktkaufman03/matching/mxpalette-tmp-july3
MxPalette changes
2023-07-03 18:27:11 -04:00
ktkaufman03
1a69a7c299
improved MxPalette::Clone, will be 100% when MSVC feels like making it so 2023-07-03 18:25:44 -04:00
ktkaufman03
3ae57f2162
improved MxPalette::SetSkyColor, will be 100% when MSVC feels like making it so 2023-07-03 18:23:52 -04:00
ktkaufman03
772980db17
improved MxPalette::operator==, will be 100% when MSVC feels like making it so 2023-07-03 18:20:23 -04:00
MishaProductions
fb56735fbd
[lego] Implement LegoGameState::SetSavepath (#76)
* SetSavePath 100% match

* fix naming convention
2023-07-03 10:25:37 -07:00
Christian Semmler
e0e338ee44
lego: add MxDSType enum, add it to all ctors, refactor MxDSObject (#73)
* lego: add MxDSType enum, add to all ctors

* refactor header

* re-type members

* add size assert for MxDSObject

* fix Parse param

* fix types
2023-07-03 10:24:51 -07:00
Joshua Peisach
e3658b84ed
Merge branch 'isledecomp:master' into mxpalette 2023-07-02 21:48:36 -04:00
Joshua Peisach
7e3b925e3e Push MxPalette progress - read comments in code. 2023-07-02 21:26:39 -04:00
Joshua Peisach
7a8c18ca44
Update mxpalette.cpp 2023-07-02 19:10:16 -04:00
Christian Semmler
d64a04705c
lego: fix/match SetColorString (#72)
* lego: fix/match SetColorString

* explicitly cast to float to avoid warning

* style fixes

* remove superfluous includes

* Update legobackgroundcolor.cpp
2023-07-02 10:17:15 -07:00
itsmattkc
9415bd18bb
fill out the rest of our primitives in mxtypes 2023-07-02 10:07:55 -07:00
Joshua Peisach
1b53ef0d95 prefer decimal values than hex for m_entries 2023-07-02 10:13:53 -04:00
Joshua Peisach
a59a3ebb6e Use MxTypes instead of generics 2023-07-02 10:09:00 -04:00
Joshua Peisach
ef4ffe2e8d
Merge branch 'isledecomp:master' into mxpalette 2023-07-02 10:03:42 -04:00
itsmattkc
8fa45bbe0f replace shorts with MxS16/MxU16/undefined2 2023-07-02 02:07:11 -07:00
MattKC
5d099115fe
Update CONTRIBUTING.md [skip ci] 2023-07-02 01:11:49 -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
Kai Kaufman
0555e05756
fix: ConvertHSVToRGB is effectively 100% matching (#70) 2023-07-02 01:02:05 -07:00
Kai Kaufman
b91c7d436b
fix: MxDSFile::Open is now matching 100% (#69) 2023-07-02 00:51:57 -07:00
Anonymous Maarten
646b39e876
Implement MxObjectFactory::{MxObjectFactory,Create} + match sizes of Mx.*Presenter objects created by it (#59)
* Get Isle building on MinGW32 (#63)

* Add MxUnknown100dc6b0::~MxUnknown100dc6b0 stub

* Declare destructor of MxOmni and MxTransitionManager in class

* inline attribute must go first

* Stub LegoState::Vtable0x14 for Act3State

* MxStreamer::VTable0x14 is not an override

* Stub MxEntity::Destroy for LegoState::Destroy

* Stub MxUnknown100dc6e0 for MxSoundManager

* ::ClassName and ::IsA are const methods

* methods in the class body don't need a namespace

* MxSoundManager subclasses MxUnknown100dc6e0

* LegoInputManager subclasses MxPresenter

* NotificationId is an enum, and does not need __declspec(dllexport)

* Fix final #endif of legoomni.h and mxobjectfactory.h

* Add const alternative for LegoOmni::Create and MxVideoParam, only available for MinGW

* Alternative approach to MinGW compatibility

* MinGW on Linux is case sensitve

* Don't delete a member variable. C++ automatically destructs member variables

---------

Co-authored-by: MattKC <34096995+itsmattkc@users.noreply.github.com>

* MxatomId: implement inline operator==

* Add decomp.h header, containing macro's only used when matching the original binaries

* Add in-line constructor of MxPresenter

* MxMediaPresenter: add members to match size

* MxVideoPresenter: add members to match size

* MxCompositePresenter: add members to match size

* MxFlcPresenter: add members to match size

* MxSmkPresenter: add members to match size

* MxStillPresenter: add members to match size

* MxAudioPresenter: add members to match size

* MxWavePresenter: add members to match size

* MxMIDIPresenter: add members to match size

* MxEventPresenter: add members to match size

* MxLoopingFlcPresenter: add members to match size

* MxLoopingSmkPresenter: add members to match size

* MxLoopingMIDIPresenter: add check for size

* Implement MxObjectFactory::{MxObjectFactory,Create}

Matching of MxObjectFactory::Create is not good, because none of the other objects have been implemented.

* Implement a few MxPresenter methods

* Fix size of LegoInputManager

* Fix name of first padding member of legoinputmanager.h

* add DECOMP_SIZE_ASSERT macro

* Use DECOMP_SIZE_ASSERT macro + convert to hexadecimal

* fixed minor typos

---------

Co-authored-by: MattKC <34096995+itsmattkc@users.noreply.github.com>
Co-authored-by: itsmattkc <itsmattkc@gmail.com>
2023-07-02 00:00:28 -07:00
Anonymous Maarten
302b3f66f0
Get Isle building on MinGW32 (#63)
* Add MxUnknown100dc6b0::~MxUnknown100dc6b0 stub

* Declare destructor of MxOmni and MxTransitionManager in class

* inline attribute must go first

* Stub LegoState::Vtable0x14 for Act3State

* MxStreamer::VTable0x14 is not an override

* Stub MxEntity::Destroy for LegoState::Destroy

* Stub MxUnknown100dc6e0 for MxSoundManager

* ::ClassName and ::IsA are const methods

* methods in the class body don't need a namespace

* MxSoundManager subclasses MxUnknown100dc6e0

* LegoInputManager subclasses MxPresenter

* NotificationId is an enum, and does not need __declspec(dllexport)

* Fix final #endif of legoomni.h and mxobjectfactory.h

* Add const alternative for LegoOmni::Create and MxVideoParam, only available for MinGW

* Alternative approach to MinGW compatibility

* MinGW on Linux is case sensitve

* Don't delete a member variable. C++ automatically destructs member variables

---------

Co-authored-by: MattKC <34096995+itsmattkc@users.noreply.github.com>
2023-07-01 23:53:54 -07:00
Anonymous Maarten
40dd0a93d4
Faster reccmp.py on linux (#62)
* reccmp: avoid repeated execution of winepath

Executing winepath many times is slow,
so try we like to avoid it as much as possible.

When the path start with a known prefix, replace it with
a cached prefix and do some string manipulation.

This change reduces execution time of reccmp.py from 90s to 2s.

Which is nice.

m

* reccmp: continue looking when source cannot be found

Most often, the reasons is mismatched sources.

* reccmp: add basic logging + optional debug

* Read the addresses in the exe headers as little endian
2023-07-01 23:52:47 -07:00
stonedDiscord
904640e028
CI steps (#65)
* break build up into steps

* download artifacts

* clone uploadtool

* need env on windows

* just use ubuntu for inkscape

* report went missing

* add inkscape to path

* use ubuntu for compare

* Revert "use ubuntu for compare"

This reverts commit a4ce103d09.

* reinstall after cache

* try different apt cache

* use im

* use rsvg

* change size to avoid downscaling

* remove png

* do not install librsvg anymore
2023-07-01 21:51:26 -07:00
Christian Semmler
8aad15d18b
lego1: match MxBitmap::Read and vtable (#67)
* lego1: match MxBitmap::Read and vtable

* fix param name
2023-07-01 21:49:42 -07:00