03DA

From GTAMods Wiki
Jump to navigation Jump to search

GTA III Vice City NO_SPECIAL_CAMERA_FOR_THIS_GARAGE


Description
Disables special camera for the garage
Syntax
03DA: set_garage [garage handle] camera_follows_player
Parameter
[garage handle]
The handle of the garage

By default, when a garage is created, entering the garage places the camera outside the garage at a fixed position and the camera will track the player character as you move around in the garage (this does not happen when in standard controls on foot in Vice City). This opcode disables that special camera for the garage, allowing the regular game camera to be in control.

Reenabling special camera

This supplemental code allows you to reenable the special camera for the garage. It uses Sanny Builder with CLEO for GTA III and Vice City in an external script (not the main one) and tested on US v1.0. Place this at the end of the file for Vice City:

:opcode_03DA_supplement
// 0@ - input param (garage handle)
0@ *= 0xA8  // size of each garage struct
0@ += 0x812668  // base address for garages
0@ += 0x1A  // special camera for garage
05DF: write_memory 0@ size 1 value 0 virtual_protect 0  // set value
05F6: ret 0

or for GTA III:

:opcode_03DA_supplement
// 0@ - input param (garage handle)
0@ *= 0x8C  // size of each garage struct
0@ += 0x72BCD0  // base address for garages
0@ += 0x1A  // special camera for garage
05DF: write_memory 0@ size 1 value 0 virtual_protect 0  // set value
05F6: ret 0

Use this line as a supplement for opcode 03DA. This can be placed anywhere within the external script:

05F5: call_scm_func @opcode_03DA_supplement inputs 1 garage [garage handle]

Keywords

set, garage, special, camera, follows, player