Commit Graph

2154 Commits

Author SHA1 Message Date
Ilya Shurumov
87799cda0d - fix spooler thread 2020-04-12 19:56:52 +06:00
Ilya Shurumov
b447fb2725 - Temporarily fix crash when exiting/restarting game 2020-04-12 19:36:26 +06:00
Ilya Shurumov
9c9ff94f3d - [EMU] remove EndScene from VSync and put it to the end of DrawOTag 2020-04-12 19:36:14 +06:00
Ilya Shurumov
37aef8da1d - implement SfxVolume, MusicVolume
- update pause strings
- update Ghidra DB
2020-04-12 19:26:25 +06:00
Ilya Shurumov
c17e09945a - implement ControlMenu, SetupMenu 2020-04-12 19:04:54 +06:00
Ilya Shurumov
6e99edce58 - little changes 2020-04-12 17:59:06 +06:00
Ilya Shurumov
22fbc4e934 Merge branch 'FETCH_HEAD' into Fireboyd78/master 2020-04-12 17:57:45 +06:00
Ilya Shurumov
5342dcaa40 Merge branch 'master' into Fireboyd78/master 2020-04-12 17:51:03 +06:00
Ilya Shurumov
e70524d57a - 'volatile spoolactive' to fix blocking issue on SpoolSync 2020-04-12 17:41:42 +06:00
Ilya Shurumov
526b5fc703 - teporarily disable ProcessDentLump 2020-04-12 17:40:27 +06:00
Ilya Shurumov
a331e962ba - implement MaxMenuStringLength
- fix pause menu rectangle
2020-04-12 03:57:32 +06:00
Ilya Shurumov
8c2fe08356 - fix ordering table size
- fixed SetupDrawBuffers
2020-04-12 03:25:03 +06:00
Ilya Shurumov
c5b878f63d - correct pause strings 2020-04-12 03:24:54 +06:00
Ilya Shurumov
f8190cf54a - attempt to draw pause menus
- implement bunch of functions
2020-04-12 03:02:26 +06:00
Ilya Shurumov
c0ab1a4627 - implement SwapDrawBuffers2 2020-04-12 01:25:49 +06:00
Ilya Shurumov
d7ba985945 - implement SwapDrawBuffers 2020-04-12 01:21:06 +06:00
Ilya Shurumov
87cfbffc82 - implement InitaliseDrawEnv, UpdatePadData, SetupDrawBuffers, SetupDrawBufferData 2020-04-12 01:13:54 +06:00
Ilya Shurumov
51d3938035 - implement LoadSky 2020-04-12 00:54:44 +06:00
Ilya Shurumov
2e39693ea5 - commented out printfs 2020-04-12 00:33:58 +06:00
Ilya Shurumov
dff435a4e8 - fixed spool thread ready callback 2020-04-12 00:15:11 +06:00
Fireboyd78
956f135c73 Fixed bugs in ProcessTextureInfo. 2020-04-11 10:48:12 -07:00
Fireboyd78
3751016845 Merge branch 'master' of https://github.com/SoapyMan/REDRIVER2 2020-04-11 09:52:08 -07:00
Ilya Shurumov
3da3d2044b Merge branch 'master' into Fireboyd78/master 2020-04-11 22:37:35 +06:00
Ilya Shurumov
5c90d922ba - fixed bug in SendTPage
- assign callbacks in 'changemode'
2020-04-11 22:34:58 +06:00
Ilya Shurumov
fd0ae8e6b7 - fixed callback invoke for getLevSectorPC 2020-04-11 22:04:19 +06:00
Ilya Shurumov
5241105487 - implement test spooling
- LoadInAreaTSets back to UNIMPLEMENTED
2020-04-11 21:04:02 +06:00
Ilya Shurumov
63be8e1ce4 - implement data_ready, sector_ready, loadsectors (for PSX)
- dummy CdDiskReady function
2020-04-11 17:21:25 +06:00
Fireboyd78
7e26777504 Fixed incorrect ordering type changes. 2020-04-10 19:02:32 -07:00
Fireboyd78
29b2a181f3 Implemented some DRAW stuff.
* Added DrawAllBuildings

* Added RenderModel

* Defined Apply_InvCameraMatrixSetTrans
 - TODO: Implement code

* Defined Apply_InvCameraMatrixAndSetMatrix
 - TODO: Implement code
2020-04-10 18:40:49 -07:00
Fireboyd78
5de9d091d0 Added typedef for plot context struct. 2020-04-10 18:37:07 -07:00
Fireboyd78
b162dfbd49 Fixed a bug where OTTYPE would select the wrong size. 2020-04-10 18:36:44 -07:00
Fireboyd78
6a5af89aae Fixed 'setCopControlWord' macro. 2020-04-10 16:09:37 -07:00
Fireboyd78
55d450bbbd Fixed more invalid arguments for coprocessor stuff. 2020-04-10 16:06:01 -07:00
Fireboyd78
05b0bdf10d Implemented EnablePause, CheckForPause. 2020-04-10 15:44:35 -07:00
Fireboyd78
2ddcda382c Implemented various functions + code cleanup.
* Added GetCarPalIndex

* Added GetRandomChase

* Added FindMissionLadderPos

* Added FindPrevMissionFromLadderPos

* Added EndGame

* Added Find_TexID

* Updated GameStart
 - Improved code flow
 - Removed gotos
 - Removed garbage "debug check"
 - Fixed code for cheats
 - Added inline helper functions to reduce bloat

* Updated ProcessLumps
 - Cleaned up code

* Updated DrawGame
 - Cleaned up code
 - Better VSync waiting

* Updated ProcessTextureInfo
 - Improved code flow
 - Cleaned up garbled non-sense code

* Updated SetVariable
 - Improved code flow
 - Removed gotos
 - Fixed code for cheats

* Updated HandleKeyPress
 - Improved code flow
 - Fixed decompilation bugs

* Updated PadChecks
 - Improved code flow
2020-04-10 15:12:50 -07:00
Fireboyd78
291d03d4f0 Fixed ACTIVE_CHEATS structure. 2020-04-10 14:57:03 -07:00
Fireboyd78
70e66207e4 Moved PolySizes from CARS into DRAW. 2020-04-10 14:54:19 -07:00
Fireboyd78
bf5b85591c Added coprocessor macros and fixed invalid arguments. 2020-04-10 14:48:36 -07:00
Fireboyd78
d0ca0c57e8 Removed x64 build configuration. 2020-04-10 14:42:54 -07:00
Ilya Shurumov
478f059614 - implemented almost all SPOOL.C (except unused sound bank loading) 2020-04-10 17:56:11 +06:00
Ilya Shurumov
62ef7f3c12 - add dummy CdGetSector, CdReadyCallback, CdDataCallback
- add LoadImage2 define
2020-04-10 06:22:05 +06:00
Ilya Shurumov
c455065eda - implement SetupSpecDenting
- update Ghidra DB
2020-04-10 06:11:21 +06:00
Ilya Shurumov
433370e9a4 - implement SetupSpecCosmetics 2020-04-10 05:52:52 +06:00
Ilya Shurumov
a850509963 - implement Tada 2020-04-10 05:52:35 +06:00
Ilya Shurumov
a9493ae5d5 - implement CleanSpooled, LowSpooled 2020-04-10 05:42:53 +06:00
Ilya Shurumov
2ed3733842 - implement LowModelSpooled 2020-04-10 05:42:04 +06:00
Ilya Shurumov
7437040070 - implement DamagedModelSpooled 2020-04-10 05:37:32 +06:00
Ilya Shurumov
1e637cb53f - implement CleanModelSpooled 2020-04-10 05:37:20 +06:00
Ilya Shurumov
da53db487b - implement lots of spooling sh*tcode 2020-04-10 05:29:12 +06:00
Ilya Shurumov
83f0d3ee34 - implement DrawGame, fix RenderGame 2020-04-10 05:28:27 +06:00
Ilya Shurumov
183b51e432 - [EMU] WaitForTimestep added to Vsync() 2020-04-10 01:33:15 +06:00
Ilya Shurumov
7783d9923a - compile fix 2020-04-10 01:32:19 +06:00
Ilya Shurumov
6f3330ed5b - implement RequestSpool, StartSpooling, UpdateSpool 2020-04-10 00:50:34 +06:00
Ilya Shurumov
7bf256235e - implement GotRegion, unpack_cellpointers 2020-04-10 00:22:38 +06:00
Ilya Shurumov
1559f6e420 - implement CheckUnpackNewRegions 2020-04-10 00:16:26 +06:00
Ilya Shurumov
ca85ad878a - implement LoadRegionData 2020-04-09 23:45:55 +06:00
Ilya Shurumov
9984d347c1 - implement ControlMap 2020-04-09 23:45:25 +06:00
Ilya Shurumov
87a54b18ce - implement ClearRegion 2020-04-09 23:15:54 +06:00
Ilya Shurumov
f5d943e8c5 - implement InitMap, InitSpooling 2020-04-09 23:10:34 +06:00
Ilya Shurumov
739c2ce5f7 - implement ProcessDentLump & LoadDenting
- implement ClearMem
2020-04-09 22:41:58 +06:00
Ilya Shurumov
b4ac9d8240 - implement ProcessLowDetailTable 2020-04-09 22:11:35 +06:00
Ilya Shurumov
630e8c9c73 - implement GetCarModel 2020-04-09 21:53:52 +06:00
Ilya Shurumov
2ce93b0265 - fix ProcessLumps not processing LUMP_CAR_MODELS 2020-04-09 21:42:17 +06:00
Ilya Shurumov
0f4666ae39 - implement ProcessCarModelLump, buildNewCars
- implement NewProcessRoadMapLump
2020-04-09 21:36:53 +06:00
Ilya Shurumov
1489b3a2cb - implement ResetSound, UpdateVolumeAttributesM, SetMasterVolume
- partially implement CalculateVolume
- proper SpuSetVoiceAttr in LibSPU
2020-04-09 19:55:39 +06:00
Ilya Shurumov
9f078caf95 - always redraw menu on non-PSX version 2020-04-09 00:46:50 +06:00
Ilya Shurumov
2b4de546a5 - fix 'samples' declaration
- trying SPU emulation
2020-04-09 00:07:11 +06:00
Ilya Shurumov
955ed5185d - implement CompleteSoundSetup, StopChannel, LockChannel, UnlockChannel, SoundHandler, FESound, VsyncProc 2020-04-08 20:47:04 +06:00
Ilya Shurumov
941160d6fc - implement GetCarPalIndex
- implement ProcessPalletLump
- fixed clut rectangle in LoadPermanentTPages
- human-understandable LoadPermanentTPages two dimensional arrays access
2020-04-07 16:56:13 +06:00
Ilya Shurumov
132b84188e - human-understandable IncrementTPageNum 2020-04-06 22:03:25 +06:00
Ilya Shurumov
bb1ebe5f04 - removed same dead code 2020-04-06 17:59:27 +06:00
Ilya Shurumov
ab044beeb7 - fix ProcessLump not loading LUMP_PALLET
- implement IncrementClutNum, IncrementTPageNum
- implement ASM func unpackTexture
- implement LoadTPageAndCluts
- implement LoadPermanentTPages
2020-04-06 05:06:00 +06:00
Ilya Shurumov
f6119162b1 - fix ProcessLumps
- implement ProcessMapLump
- implement InitCellData
- implement ProcessSpoolInfoLump
2020-04-06 03:04:50 +06:00
Ilya Shurumov
75d757a0b0 - implement ProcessMDSLump
- implement ProcessTextureInfo
- added version info print on frontend
- implement RenderGame
- implement FadeGameScreen
- implement SetupScreenFade
2020-04-06 02:04:37 +06:00
Ilya Shurumov
b754d4e2cb - implement ReInitFrontend()
- implement ReInitScreens()
2020-04-05 22:44:41 +06:00
Ilya Shurumov
59eacce933 - latest emulator
- swap interval for 50 FPS
2020-04-05 21:39:14 +06:00
Ilya Shurumov
da176025ac - implement loadsectorsPC
- implement LoadGameLevel
- implement ProcessLumps
- implement SetCityType, ResetCityType
- implement sdGetBSP, FindRoadInBSP
- implement LoadCosmetics, ProcessCosmeticsLump
- fix wantedCar finally
2020-04-05 19:53:08 +06:00
Ilya Shurumov
6959ab4307 - fix timedelay on ShowHiresScreens 2020-04-05 05:37:55 +06:00
Ilya Shurumov
56d3fbf399 - implement InitialiseMissionDefaults
- implement LoadMission
- implement GetFreeChannel
- fixed wantedCar setup from frontend
2020-04-05 04:53:41 +06:00
Ilya Shurumov
eeb96e39b5 - implement InitSound
- implement LoadBankFromLump
- implement LoadSoundBankDynamic
2020-04-04 19:42:29 +06:00
Ilya Shurumov
bf1dde5d34 - many sources processed and added UNIMPLEMENTED()
- game now goes to loading screen
2020-04-04 10:56:09 +06:00
Ilya Shurumov
6da5f797fa - fix compile errors 2020-04-04 06:14:47 +06:00
Ilya Shurumov
cb74b84f12 - implement GameInit
- add many unimplemented (unfinished)
2020-04-03 04:44:09 +06:00
Ilya Shurumov
61d42df4be - latest changes of emulator 2020-04-03 04:42:51 +06:00
Ilya Shurumov
8b2a232c55 - Latest emulator
- [EMU] Discard for all shaders corrected
- disable publisher intro screens
- Ghidra DB updates
2020-04-02 18:03:23 +06:00
Ilya Shurumov
c31dae4b5a - fix FEInitCDIcon 2020-04-01 19:24:35 +06:00
Ilya Shurumov
9d9a384134 - attempt on 8 bit LUT textures
- the DrawSync should draw all polygons from DrawPrim and end scene
2020-04-01 19:24:24 +06:00
Ilya Shurumov
5b7d5a404a - fixed extraRect var 2020-04-01 17:31:43 +06:00
Ilya Shurumov
87c16cd025 - fix CarSelectScreen
- fix LoadBackgroundFile
- updateVRAM immediately using DrawSync
2020-04-01 05:27:09 +06:00
Ilya Shurumov
acaffb85f0 - discard black colour before dithering occurs 2020-04-01 03:08:47 +06:00
Ilya Shurumov
5b8e0dfe1d - OT to use OTTYPE instead of just u_long for EMU
- latest emulator
- emulator polygon drawing improvements
- fixed bugs regarding to render frontend in D2
2020-04-01 03:04:08 +06:00
Ilya Shurumov
ee87194914 - add DR_MOVE to ParseLinkedPrimitiveList
- Every textured polygon is affecting active DRAWENV texture page
- added rendering skip if unhandled primitive encountered
- add some 'unimplemented' methods required by Driver 2
- compilation fix
- added key bind to save VRAM
2020-03-31 23:00:33 +06:00
Ilya Shurumov
08403ce5c4 - add TOMB5 emulator code 2020-03-31 22:56:49 +06:00
Ilya Shurumov
0e8b4ca696 - implement GameStart
- implement SetPleaseWait
- implement StringWidth, PrintString, PrintStringCentered, PrintStringFeature
- implement LoadFont
- implement SetFontTPage
2020-03-30 02:33:32 +06:00
Ilya Shurumov
b9382cf872 - implement SetVariable
- Memcard Main renamed to not conflict with OBJ
2020-03-29 23:03:53 +06:00
Ilya Shurumov
b203128d34 - fixed some decompilation bugs
- implement SetupExtraPoly
- implement CarSelectScreen
- implement CityCutOffScreen
2020-03-29 22:13:32 +06:00
Ilya Shurumov
26d979a408 - fix NewSelection
- fix InitControllers
- fix MapPad
2020-03-29 20:08:55 +06:00
Ilya Shurumov
bd04543844 - implement ReadControllers
- implement ClearPad
- implement HandleKeyPress
2020-03-29 18:33:48 +06:00
Ilya Shurumov
cf88c50291 - implement NewSelection
- fix EnableDisplay
- fix DrawScreen Ordering Table
- fix SetupBackgroundPolys and SetupScreenSprts
2020-03-29 18:13:32 +06:00
Ilya Shurumov
8879f114d0 - implement EnableDisplay
- implement EndFrame
- implement GetTimeStamp
- implement SetTextColour
- implement EnableDisplay
- implement DrawScreen
- implement FEPrintString
- font loading correctly
2020-03-29 06:56:49 +06:00
Ilya Shurumov
54128aebc6 - implement ShowLoadingScreen
- implement ShowLoading
2020-03-29 04:26:18 +06:00
Ilya Shurumov
223da63fe2 - implement SetupBackgroundPolys
- implement SetupScreenSprts
- implement SetFEDrawMode
- LoadFrontendScreens done prettier
2020-03-29 02:29:37 +06:00
Ilya Shurumov
2facb27782 - implement LoadFrontendScreens
- implement FEInitCdIcon
- adding frontend vars
- redid other vars
2020-03-28 21:44:13 +06:00
Ilya Shurumov
c40d40bd22 - added sources rebuilt with TDR and partially decompiled intro sequence
- moved necessary data to new sources
- running intro with TOMB5 HLE emulator
2020-03-28 03:25:35 +06:00