Froggonater-FroggosFPMotorcycle icon

FroggosFPMotorcycle

First person view (V) on the Motorcycle_Pack bikes. Works alongside Chassis (it keeps its cars) or alone (then cars get first person too).

Last updated 12 hours ago
Total downloads 6
Total rating 1 
Categories Mods IL2CPP
Dependency string Froggonater-FroggosFPMotorcycle-1.0.0
Dependants 0 other packages depend on this package

This mod requires the following mods to function

LavaGang-MelonLoader-0.7.3 icon
LavaGang-MelonLoader

The World's First Universal Mod Loader for Unity Games compatible with both Il2Cpp and Mono

Preferred version: 0.7.3
nachorn-Motorcycle_Pack-0.2.0 icon
nachorn-Motorcycle_Pack

Three motorcycles sold by Jeremy, with saved paint, rider poses, lights, stunts and crash pickup. Multiplayer beta: all players need the same build. Windows IL2CPP; optional S1FuelMod.

Preferred version: 0.2.0

README

Froggos-FP-Motorcycle

First person view for the motorcycles from Motorcycle_Pack (nachorn) in Schedule I, the way Chassis (DooDesch) gives first person in cars. Windows IL2CPP, MelonLoader 0.7.3, game 0.4.7f12.

How it relates to Chassis

It's an add-on that runs alongside Chassis. It does not replace Chassis.

  • Why Chassis doesn't work on bikes: Chassis only seats a player, and only offers first person (V), when it has a seat profile for the vehicle code (ChassisApi.For(vehicle) != null). The bikes are normal LandVehicles with their own codes (s1_offroad_motorcycle, s1_street_motorcycle, s1_cruiser_motorcycle), and Chassis has no profile for them. So no seat is set up and V does nothing.
  • Why not just give the bikes a Chassis profile: a Chassis profile would also make Chassis pose your body in a car seat. Motorcycle_Pack already poses the rider itself (lean, wheelies, stoppies), so the two would fight over your avatar. Instead, this mod puts the camera at the head of the rider that Motorcycle_Pack poses.
  • Who handles what:
    • Bikes: this mod.
    • Cars that have a Chassis profile: Chassis. This mod stays out of the way. If Chassis's own first person turns on, this mod's view turns off.
    • Cars without a Chassis profile, or every car when Chassis isn't installed: this mod uses a simple seat-based view. You can turn this off with CarsWithoutChassis = false.
  • Without Chassis: it works on its own, and then it's one mod for bikes and cars.
  • Licenses: no code from Chassis or Motorcycle_Pack was copied. Chassis is found at runtime through its public API (by reflection, with no compile-time reference). Motorcycle_Pack isn't referenced at all; bikes are recognized by their vehicle code.

Conflicts

  • Both mods use V, but never on the same vehicle, so there's no clash. You can change the key with ToggleKey.
  • On bikes, the mouse moves your view only while in first person.
  • Motorcycle_Pack's lean keys are the Up/Down arrows, and Chassis's indicator keys are Left/Right. This mod uses no extra keys.

Install

Either import exports/MotoFirstPerson-1.0.0.zip into Thunderstore Mod Manager (Settings → Import local mod), or copy exports/MotoFirstPerson.dll into the profile's Mods folder, for example ...\profiles\Yorkz Motorcycle\Mods\. Requires Motorcycle_Pack. Chassis is optional.

Use

Get on a bike and press V. Move the mouse to look around (±130° left/right). Press V again for the normal camera. Your head is hidden locally, but its shadow is kept. With RememberView, the next bike you mount starts in first person if you left the last one that way.

Settings

The settings are in category [MotoFirstPerson] of UserData/MelonPreferences.cfg, in the profile's UserData folder. Restart the game after changing them.

Setting Default What it does
ToggleKey V Key that switches the view (an InputSystem Key name).
RememberView true Start the next ride in first person if the last one ended that way.
CarsWithoutChassis true First person in cars that Chassis doesn't handle.
FollowLean 1.0 0 = the horizon stays level, 1 = the view leans with the bike.
LookSensitivity 1.0 Mouse look speed, on top of the game's own setting.
BikeEyeUp / BikeEyeForward 0.08 / 0.10 Eye position relative to the rider's head bone, in meters.
CarEyeUp / CarEyeForward 0.70 / 0.0 Eye position above the seat in cars without Chassis.
NearClip 0.03 Near clip in first person, so the handlebars aren't cut off.
VerboseLog false Logs where the camera is placed, for troubleshooting.

How it works

  • VehicleCamera.LateUpdate postfix: after the vanilla chase camera has moved, the camera goes to the eye point.
  • AvatarAnimation.LateUpdate postfix (Priority.Last): Motorcycle_Pack finishes the rider pose in its own postfix on this method. Running after it means the eye always uses this frame's head pose, so the view doesn't lag one frame at speed.
  • Player.ExitVehicle prefix: leaves first person before the game restores the on-foot camera.
  • Head: the game's own AvatarEffects.DisableHead is used, and small renderers next to the head bone (hair, eyes, hats) are set to shadow-only while in first person.

Build

dotnet build -c Release

The output goes to exports/: MotoFirstPerson.dll and the Thunderstore zip MotoFirstPerson-<version>.zip (manifest, icon, README, CHANGELOG, Mods/MotoFirstPerson.dll). The game folder is only read, for references. Use -p:GameDir=... if the game is somewhere else.