A silly little game where a robot drives an ambulance.

Pickup zones wait till you've come to a stop.

Changed files
+7
Content
Source
CrazyAmbulance
Private
Public
Content/Ambulance.uasset

This is a binary file and will not be displayed.

Content/PickupZone.uasset

This is a binary file and will not be displayed.

+4
Source/CrazyAmbulance/Private/VehicleNew.cpp
··· 56 56 57 57 bool bTouchingGround = false; 58 58 bool bBothFrontWheelsTouchingGround = true; 59 + CurrentSpeed = 0.0; 59 60 for (int i = 0; i < 4; ++i) 60 61 { 61 62 bool FrontWheel = i / 2 == 0; ··· 123 124 DrawDebugCircle(GetWorld(), TireCenter, TireRadius, 20, FColor::Green, false, -1, 0, 0, TireForward); 124 125 125 126 FVector TireVelocity = Body->GetPhysicsLinearVelocityAtPoint(TireCenter); 127 + CurrentSpeed += TireVelocity.Size(); 126 128 127 129 // Suspension 128 130 double Offset = SuspensionRestDist - (Result.Distance - TireRadius); ··· 180 182 } 181 183 } 182 184 } 185 + 186 + CurrentSpeed /= 4.0; 183 187 184 188 if (!bTouchingGround) 185 189 {
+3
Source/CrazyAmbulance/Public/VehicleNew.h
··· 93 93 UPROPERTY(EditAnywhere) 94 94 double EBrakeFrontSteerMultiplier = 0.5; 95 95 96 + UPROPERTY(BlueprintReadOnly) 97 + double CurrentSpeed; 98 + 96 99 private: 97 100 bool bEBrakeOn = false; 98 101 double EBrakeSteeringAngle;