Commit Graph

468 Commits

Author SHA1 Message Date
Ilya Shurumov
b0d2b3b83c - fix sdGetCell and sdGetBSP 2020-05-16 21:39:08 +06:00
Ilya Shurumov
69603d64c2 - fix mistake 2020-05-16 19:20:58 +06:00
Ilya Shurumov
ac84cb24bd - proper spooled models freeing 2020-05-16 18:33:44 +06:00
Ilya Shurumov
6c7e39bc71 - fix ProcessCarModelLump bug sowed by me 2020-05-16 16:07:52 +06:00
Ilya Shurumov
012f87bd62 - USE_CRT_MALLOC - use dynamic malloc whenever possible
- fix buildNewCarFromModel bug
2020-05-16 15:56:08 +06:00
Ilya Shurumov
a8ee800d3e - pretty sdGetBSP, FindRoadInBSP
- more pretty RoadInCell, sdGetCell
2020-05-16 15:31:55 +06:00
Ilya Shurumov
736f8bd09f - implement SetBasePos
- fix camera bug
2020-05-16 15:30:05 +06:00
Ilya Shurumov
a89332db0e - implement CarHasSiren, DealWithHorn 2020-05-16 00:12:44 +06:00
Ilya Shurumov
8b580f41fe - fix sound channel array indexing bugs
- more pretty code
2020-05-15 23:14:23 +06:00
Ilya Shurumov
5c011ebdbd - [EMU] perfect vblank, eliminates WaitForTimestep hack in DrawGame 2020-05-15 22:38:03 +06:00
Ilya Shurumov
465548c9a1 - implement RunMissionLadder 2020-05-15 21:02:45 +06:00
Ilya Shurumov
6f6194bd23 - fix XMPLAY bug again 2020-05-15 19:24:32 +06:00
Ilya Shurumov
8bcd156565 - fix bugs in DisplayMissionTitle 2020-05-15 19:24:13 +06:00
Ilya Shurumov
e056c7f587 - implement ProcessJunctionsDriver2Lump 2020-05-15 19:23:41 +06:00
Ilya Shurumov
44791bc468 - implement SetConfusedCar 2020-05-15 18:41:42 +06:00
Ilya Shurumov
98c58126bc - implement MakeTheCarShutUp, HaveCarSoundStraightAway, RequestSlightPauseBeforeCarSoundStarts 2020-05-15 18:24:56 +06:00
Ilya Shurumov
1ffc429023 - fix pedestrian bugs 2020-05-15 18:21:21 +06:00
Ilya Shurumov
841855a7b4 - implement ChangePedPlayerToCar 2020-05-15 18:04:48 +06:00
Ilya Shurumov
07b893bb3a - implement TannerStuckInCar 2020-05-15 17:50:23 +06:00
Ilya Shurumov
5c0166ba6e - fix SetupGetInCar 2020-05-15 17:50:05 +06:00
Ilya Shurumov
681747cb2e - implement ChangeCarPlayerToPed, FindClosestCar, TannerCanEnterCar
- fix PlaceCameraAtLocation
2020-05-15 17:38:32 +06:00
Ilya Shurumov
168a77735d - implement IHaveThePower easter egg 2020-05-15 17:16:18 +06:00
Ilya Shurumov
4b43aeffb2 - implement ProcessTannerPad 2020-05-15 17:04:48 +06:00
Ilya Shurumov
b573cd702b - implement FindTannerASeat, add_seated,, CalculatePedestrianInterest, PedSurfaceType, ProcessChairLump 2020-05-15 16:54:05 +06:00
Ilya Shurumov
fac5f92a31 - implement CalcPedestrianDirection, IsPavement, SetPedestrianTurn, FindSeated 2020-05-15 16:41:49 +06:00
Ilya Shurumov
bb51019d59 - implement AnimatePed, DeActivatePedestrian, SetupCivPedRouteData, PingOutPed, SetupCivJump, CivPedJump, SetupCivPedWalk, CivPedWalk, CivPedSit, HandlePedestrians
- pretty GetSurfaceIndex
2020-05-15 16:33:29 +06:00
Ilya Shurumov
cdd18b3fb6 - implement PedPressButton, SetupTannerSitDown, TannerCameraHandler, TannerSitDown 2020-05-15 16:00:42 +06:00
Ilya Shurumov
f8b72f3441 - implement PedGetOutCar, SetupGetOutCar, SetupGetInCar, PedGetInCar, SetupPressButton 2020-05-15 15:53:03 +06:00
Ilya Shurumov
dae3fe10b4 - implement PedDoNothing, PedUserRunner, PedUserWalker, PedCarryOutAnimtation 2020-05-15 15:36:25 +06:00
Ilya Shurumov
b0c65729dd - implement SetupWalker, SetupRunner, SetupBack, CivGetIn, CopStand 2020-05-15 15:18:42 +06:00
Ilya Shurumov
a08b3416e0 - implement TannerActionHappening, ControlPedestrians, SetupDoNowt 2020-05-15 15:06:27 +06:00
Ilya Shurumov
e6ef32f08c - bit more prettier PlaceCameraFollowCar
- little crash fixes
2020-05-15 15:05:59 +06:00
Ilya Shurumov
6270cbea4f - implement InitPedestrians, DestroyPedestrian(s), ActivatePlayerPedestrian, SetTannerPosition
- little fixes
2020-05-15 14:50:30 +06:00
Ilya Shurumov
9b48cb9b20 - XM_SetSongPos temporary fix 2020-05-14 23:40:24 +06:00
Ilya Shurumov
8cbdf4473d - more pretty unpack_cellpointers 2020-05-14 23:39:16 +06:00
Ilya Shurumov
90738b4620 - fix damage by water 2020-05-14 23:38:58 +06:00
Ilya Shurumov
859a4713a2 - PauseXM bug fix 2020-05-14 19:11:44 +06:00
Ilya Shurumov
4cf07f34c2 - fixed bug in SetupDrawMapPSX
- more pretty GetPVSRegionCell2
2020-05-14 18:48:09 +06:00
Ilya Shurumov
545e4c83f9 - human-understandable ProcessCarModelLump 2020-05-14 17:11:37 +06:00
Ilya Shurumov
217e686127 - ProcessSpoolInfoLump analyzed and converted to human-readable 2020-05-14 14:46:40 +06:00
Ilya Shurumov
c1fccc2e2d - pretty InitCellData mallocs 2020-05-14 12:57:42 +06:00
Ilya Shurumov
bfb70417db - MALLOC_BEGIN/END macros to track game mallocptr changes 2020-05-14 12:57:20 +06:00
Ilya Shurumov
0a60e120bc - implement FunkUpDaBGMTunez
- change InitMusic to MALLOC_BEGIN/END
2020-05-14 12:56:09 +06:00
Ilya Shurumov
7dafffcea5 - temporary bug fix for car spooling
- pretty GetCarModel
2020-05-14 00:10:18 +06:00
Ilya Shurumov
ee213f576a - bit prettier DrawMapPSX, DrawSprites
- pretty init_spooled_models
2020-05-13 23:37:09 +06:00
Ilya Shurumov
1b180a9f57 - added NOTIFY_MALLOC everywhere mallocptr is used 2020-05-13 22:04:14 +06:00
Ilya Shurumov
b4c5bc7883 - fix XMPLAY structure data 2020-05-13 22:00:28 +06:00
Ilya Shurumov
1af4efcdfa - [EMU] fixed SPU implementation mistakes
- enabled InitMusic
2020-05-13 20:29:10 +06:00
Ilya Shurumov
074715065e - pretty UpdateXMSamples 2020-05-13 19:56:19 +06:00
Ilya Shurumov
0040094e01 - fix XMPLAY reversing bug 2020-05-13 19:55:56 +06:00
Ilya Shurumov
5eed501cd4 - fix car spooling memory pointers 2020-05-13 16:37:30 +06:00
Ilya Shurumov
c83b44a701 - fix SpecClutsSpooled reversing bug 2020-05-13 16:31:17 +06:00
Ilya Shurumov
51dee27b1a - bit pretty InitMap and CheckUnpackNewRegions, fixed invalid area spooling 2020-05-13 16:20:04 +06:00
Ilya Shurumov
bbcb9bc98c - pretty CleanModelSpooled, DamagedModelSpooled, LowModelSpooled
- more understanding to code
2020-05-13 15:58:03 +06:00
Ilya Shurumov
027fc26c28 - crash fix for super-secret car 2020-05-13 15:57:00 +06:00
Ilya Shurumov
a17331a8be - simplify SetupSpecCosmetics, SetupSpecDenting 2020-05-13 14:30:17 +06:00
Ilya Shurumov
e490be66d1 - bit more pretty LoadPermanentTPages 2020-05-13 14:29:32 +06:00
Ilya Shurumov
920895121a - XMPLAY by Jason Page original source code ported back from PS2 2020-05-13 12:40:22 +06:00
Ilya Shurumov
e037675d36 - pretty and bugfixed CheckLoadAreaData
- pretty SpecialStartNextBlock, CheckSpecialSpool, Tada
2020-05-13 12:20:21 +06:00
Ilya Shurumov
5dfc2e3f76 - pretty ProcessLowDetailTable 2020-05-13 12:19:09 +06:00
Ilya Shurumov
989b1c1d1b - pretty LoadGameLevel 2020-05-13 12:17:48 +06:00
Ilya Shurumov
ba669089f6 - pretty SetupPlaneColours, SetupDrawmapPSX 2020-05-13 12:12:53 +06:00
Ilya Shurumov
e0c6c2b8bd - do not do XM_ calls if Song_ID == -1 2020-05-12 21:49:21 +06:00
Ilya Shurumov
fbf0e3c3d0 - fix invalid music type for Chicago day 2020-05-12 21:48:51 +06:00
Ilya Shurumov
f6821c2edb - implement and disable InitMusic 2020-05-12 21:48:33 +06:00
Ilya Shurumov
14b3ebf541 - implement PauseXM, UnpauseXM, UpdateSamples, FreeXM, StartXM, StopXM 2020-05-12 20:53:26 +06:00
Ilya Shurumov
3d588587cf - fixed CloseShutters and FadeGameScreen flicker 2020-05-12 15:21:12 +06:00
Ilya Shurumov
6e357c8bbc - improve and fix bugs in ProcessMDSLump 2020-05-12 14:40:49 +06:00
Ilya Shurumov
837ee218a6 - simplified spooling, added SIMPLE_SPOOL 2020-05-12 14:39:31 +06:00
Ilya Shurumov
bd22233c60 - fix reversing bugs in CheckLoadAreaData 2020-05-12 10:59:42 +06:00
Ilya Shurumov
356b804d14 - pretty SendTPage 2020-05-12 10:46:52 +06:00
Ilya Shurumov
473d94fc97 - LoadInAreaTSets bit better to read 2020-05-12 10:13:05 +06:00
Ilya Shurumov
8657ed5e8c - pretty pause code 2020-05-12 10:00:52 +06:00
Ilya Shurumov
016cca01a4 - fix Take a Ride Vegas loading (again)
- bit more pretty code
2020-05-12 00:34:48 +06:00
Ilya Shurumov
eaac176a19 - pretty init_spooled_models 2020-05-12 00:10:50 +06:00
Ilya Shurumov
217e2cfe7b - remove weird dead commented memcpys 2020-05-12 00:09:51 +06:00
Ilya Shurumov
6e0ba4e9ba - fix CheckCarToCarCollisions bug 2020-05-10 17:18:28 +06:00
Ilya Shurumov
335f7aac35 - collision debug boxes for cars
- car box Y size reduced
2020-05-10 15:31:35 +06:00
Ilya Shurumov
bd0803f160 - implement jump_debris, nose_down
- little fix to CheckCarToCarCollision
2020-05-10 14:36:03 +06:00
Ilya Shurumov
43d6814946 - fix GlobalTimeStep vehicle collision processing 2020-05-10 13:49:39 +06:00
Ilya Shurumov
1ed78a5a47 - implement DamageCar3D 2020-05-10 13:49:22 +06:00
Ilya Shurumov
f927b70b43 - implement PointFaceCheck, collided3d, CarCarCollision3 2020-05-10 13:48:47 +06:00
Ilya Shurumov
096da6924a - implement CheckCarToCarCollisions and correct GlobalTimeStep 2020-05-10 12:21:54 +06:00
Ilya Shurumov
fccc273051 - fix indices bug in buildNewCarFromModel 2020-05-09 15:54:24 +06:00
Ilya Shurumov
b71ec78484 - fix DrawCar, SubDivShadow, PlaceShadowForCar 2020-05-09 14:24:43 +06:00
Ilya Shurumov
53b3607b06 - implement RandomInit, Random2 2020-05-09 14:01:01 +06:00
Ilya Shurumov
ce5ee966e7 - implement ProcessStraightsDriver2Lump, RoadInCell
- fix declarations
2020-05-09 14:00:48 +06:00
Ilya Shurumov
2c0fe8ba03 - implement valid_region 2020-05-09 14:00:06 +06:00
Ilya Shurumov
18711e5edf - implement GetNodePos, PingOutCar, CheckPingOut, PingInCivCar, CivControl 2020-05-09 13:59:47 +06:00
Ilya Shurumov
743ca45385 - implement DentCar, fix CreateDentableCar 2020-05-09 11:27:03 +06:00
Ilya Shurumov
b30842dd91 - implement PlaceCameraInCar, PlaceCameraAtLocation, PointAtTarget
- fix bugs in ModifyCamera
2020-05-09 10:32:19 +06:00
Ilya Shurumov
675256b046 - LoadBankFromLump to deny load non-existing lumps 2020-05-09 10:31:27 +06:00
Ilya Shurumov
0803a18a9c - debug keys to toggle position display
- minor fixes
2020-05-06 17:23:01 +06:00
Ilya Shurumov
0beeccca86 - improve CarBuildingCollision and bcollided2d 2020-05-06 16:13:28 +06:00
Ilya Shurumov
2bfb4a7897 - fix UnpackCellObject
- improve CheckScenaryCollisions
2020-05-06 16:12:50 +06:00
Ilya Shurumov
827c137189 - collision debug to key switch
- some debug pause fixes
2020-05-06 10:42:10 +06:00
Ilya Shurumov
a75e53d385 - fix matrix in DrawSmashable_sprites 2020-05-06 10:20:21 +06:00
Ilya Shurumov
607da2dd0c - fix RenderModel 2020-05-06 10:03:05 +06:00
Ilya Shurumov
f67c643fbf - implement damage_object, MoveSmashable_object, DrawSmashable_sprites 2020-05-06 10:02:48 +06:00
Ilya Shurumov
b43832bec7 - temporary fix for positional correction in CarBuildingCollision 2020-05-06 10:01:42 +06:00
Ilya Shurumov
6ed63d8b3c - fix InitCarPhysics, TempBuildCarMatrix, GlobalTimeStep, LongQuaternionToMatrix, initOBox 2020-05-05 21:31:14 +06:00
Ilya Shurumov
d22d8df453 - implement ApplyDamage, DamageCar 2020-05-05 21:29:44 +06:00
Ilya Shurumov
d164767c7f - fix StepOneCar 2020-05-05 21:29:10 +06:00
Ilya Shurumov
9172422631 - fix camera behavior CheckScenaryCollisions 2020-05-05 18:17:44 +06:00
Ilya Shurumov
b4d9463418 - fix bFindCollisionPoint and CarBuildingCollision 2020-05-05 18:17:06 +06:00
Ilya Shurumov
33ec2cca8d - fix CheckScenaryCollisions 2020-05-03 10:39:51 +06:00
Ilya Shurumov
a9140c9234 - implement COLLISION_DEBUG drawing 2020-05-02 09:20:31 +06:00
Ilya Shurumov
210eeae73b - implement FindModelIdxWithName 2020-05-02 08:15:32 +06:00
Ilya Shurumov
b78b2f72cd - implement FindSmashableObjects
- fix smashable volume levels
2020-05-02 08:15:15 +06:00
Ilya Shurumov
521a90489e - implement PauseSFX, UnPauseSFX, PauseSound, UnPauseSound 2020-05-02 08:13:50 +06:00
Ilya Shurumov
2ff1377c4d - line debug overlay [WIP] 2020-05-01 14:51:44 +06:00
Ilya Shurumov
0ecf83875e - attempt to fix bcollided2d, bFindCollisionTime, bFindCollisionPoint, CarBuildingCollision 2020-05-01 14:51:06 +06:00
Ilya Shurumov
c3347feba5 - implement bcollided2d, bFindCollisionPoint, bFindCollisionTime, CarBuildingCollision 2020-05-01 12:08:36 +06:00
Ilya Shurumov
a3bf2e8e5b - implement ShowFlare
- fix AddNightLights
2020-04-30 21:35:07 +06:00
Ilya Shurumov
535e82e9e9 - implement InitFXPos 2020-04-29 22:01:27 +06:00
Ilya Shurumov
2dd14bac21 - implement AddNightLights, ShowCarlight, FindCarLightFade 2020-04-29 21:03:13 +06:00
Ilya Shurumov
b15abaf8c5 - implement DoThunder, RequestThunder, InitThunder, DoLightning, add_haze 2020-04-29 18:53:02 +06:00
Ilya Shurumov
5d136eb02c - properly decompiled ControlCarRevs 2020-04-29 18:52:01 +06:00
Ilya Shurumov
fe4722dca8 - implement UnpackCellObject
- use UnpackCellObject in DrawMapPSX
- change some types for better understanding the code
2020-04-29 13:10:39 +06:00
Ilya Shurumov
ec6491bb87 - implement CollisionCopList 2020-04-29 13:09:20 +06:00
Ilya Shurumov
234243fbc6 - implement CheckScenaryCollisions 2020-04-29 00:00:25 +06:00
Ilya Shurumov
f56fe13348 - fix bug in ClearRegion 2020-04-28 12:56:10 +06:00
Ilya Shurumov
5535f1f069 - allow secret cars in DEBUG 2020-04-28 12:48:18 +06:00
Ilya Shurumov
4d23f39aac - pretty InitPlayer & UpdatePlayers 2020-04-28 12:48:04 +06:00
Ilya Shurumov
d1b19bddb5 - implement ProcessOverlayLump, InitOverheadMap, DrawMultiplayerMap 2020-04-27 21:38:04 +06:00
Ilya Shurumov
64b0464c0e - fix wheels and shadow OT index
- update Ghidra DB
2020-04-27 21:37:24 +06:00
Ilya Shurumov
b56d325bee - Proper aspect ratio dependent on window size 2020-04-27 19:56:49 +06:00
Ilya Shurumov
447a281220 - fix DrawTILES detail levels 2020-04-27 19:18:11 +06:00
Ilya Shurumov
2181519b65 - non-hardcoded LEV loader for PC version 2020-04-27 16:53:17 +06:00
Ilya Shurumov
09ff4d28af - better VSync handling for PC 2020-04-27 16:30:14 +06:00
Ilya Shurumov
6ae1468c71 - experimental Driver 1 LEV lumps support 2020-04-27 16:29:53 +06:00
Ilya Shurumov
989430b4af - debug keys to change draw distance 2020-04-27 13:53:49 +06:00
Ilya Shurumov
0fdd119bcf - fix my nasty bug in InitSkidding 2020-04-27 13:12:59 +06:00
Ilya Shurumov
b60bf33226 - replace shifts with divisions and miltiplies in SetupDrawMapPSX & ControlMap 2020-04-27 13:12:32 +06:00
Ilya Shurumov
e63eceb816 - pretty ClearRegion and less pretty ProcessSpoolInfoLump 2020-04-27 13:11:19 +06:00
Ilya Shurumov
f90b5b8597 - fix AddWheelForcesDriver1 and CheckCarEffects 2020-04-27 11:52:16 +06:00
Ilya Shurumov
792c9b817e - implement InitSkidding, TerminateSkidding, CheckCarEffects
- marked LoadSoundBankDynamic as BUGGED
- [EMU] little attempt to fix SPU sample lookup
2020-04-27 11:27:09 +06:00
Ilya Shurumov
b6ef02f957 - change shifts to divisions in SOUND.C 2020-04-27 10:36:34 +06:00
Ilya Shurumov
a966e73cb2 - fix SoundTasks, MapCarIndexToBank 2020-04-27 10:36:11 +06:00
Ilya Shurumov
bd8004ee4f - implement ResidentModelsBodge, CollisionSound, SoundTasks, AddEnvSounds
- fix ControlCarRevs
2020-04-27 09:19:08 +06:00
Ilya Shurumov
0303c128b0 - implement LoadSoundBank, ComputeDoppler, SetPlayerOwnsChannel
- fix ClearChannelFields
2020-04-27 05:28:49 +06:00
Ilya Shurumov
1a675344a9 - implement LoadLevelSFX, MapCarIndexToBank, SpecialVehicleKludge 2020-04-27 05:28:02 +06:00
Ilya Shurumov
90fbda26f5 - pretty code in SPOOL.C 2020-04-27 05:27:02 +06:00
Ilya Shurumov
12c7b4fcf8 - little fix to HAVANA_AUGUST_DEMO 2020-04-26 18:36:53 +06:00
Ilya Shurumov
ba6f1753b5 - DEBUG_OPTIONS define to enable Debug Options in Release build 2020-04-26 18:20:35 +06:00
Ilya Shurumov
d3a7a5dbdd - added experimental loading of Aug 2000 Demo LEV files (#define switch) 2020-04-26 18:19:33 +06:00
Ilya Shurumov
6d8a0eb6ee - fix StepOneCar ground collision crash 2020-04-26 18:18:30 +06:00
Ilya Shurumov
503ca5d5ea - fix debug options 2020-04-26 16:23:48 +06:00
Ilya Shurumov
9381e7d6fb - fix pause SetRightWayUp 2020-04-26 16:17:24 +06:00
Ilya Shurumov
f16974ea2c - implement TempBuildHandlingMatrix 2020-04-26 16:10:54 +06:00