Cars
Cars are the bread and butter of Keep Driving, and what the player will be in for the majority of the run. All cars made are designed to always support 1 passenger and 1 driver seat out of the box.
You may define some images by creating a cars.kdr file.
The following properties that exist:
| Key | Type | Required | Default | Explanation |
|---|---|---|---|---|
car_dev_name |
String |
Yes | N/A |
Internal name of car |
car_title |
String |
Yes | N/A |
Name of the car to show to the player |
car_year |
String |
Yes | N/A |
The year the car was made in |
car_desc |
String |
Yes | N/A |
The description of the car to show to the player |
car_slot_disabled |
Number,Number |
No | N/A |
What inventory slots are disabled. |
car_color |
String |
No | spr_player_car_volvo240_body_white |
The starting sprite colour for the car. |
car_main_sprite |
String |
No | spr_player_car_volvo240_body_white |
The main car sprite to use. |
car_bg |
String |
No | spr_player_car_volvo240_background |
The background sprite to use for the car (the insides while driving). |
car_windows |
String |
No | spr_player_car_volvo240_windows_1 |
The sprite to use for back of the car. |
car_front_window |
String |
No | spr_player_car_volvo240_front_window |
The sprite to use for front of the car. |
car_wheel |
String |
No | spr_player_car_volvo240_wheel_normal |
The wheel to use for the car. |
car_inv_background |
String |
No | spr_ui_inventory_volvo_bg_2 |
The sprite to use for the inventory menu. |
car_rvm_bg |
String |
No | spr_rear_mirror_bg |
The sprite to use for the car mirror. |
car_player_seat_sprite |
String |
No | spr_driver_inventory |
The sprite to use for the player car seat while in inventory view. |
car_player_seat_sprite_x |
number |
No | 172 |
The xoffset of the player car seat sprite. |
car_player_seat_sprite_y |
Number |
No | 22 |
The yoffset of the player car seat sprite. |
car_wheel_front_x |
Number |
No | 122 |
The x offset of the car wheel front. |
car_wheel_front_y |
Number |
No | 55 |
The y offset of the car wheel front. |
car_wheel_back_x |
Number |
No | 41 |
The x offset of the car wheel back. |
car_wheel_back_y |
Number |
No | 55 |
They offset of the car wheel back. |
car_windows_x |
Number |
No | 0 |
The x offset of the car window. |
car_windows_y |
Number |
No | 0 |
The y offset of the car window. |
car_inv_base_w |
Number |
No | 9 |
The base width of the car inventory. |
car_inv_base_h |
Number |
No | 9 |
The base height of the car inventory. |
car_base_carhealth |
Number |
No | 16 |
The cars starting health. |
car_base_gas_max |
Number |
No | 13 |
The cars starting gas. |
car_base_social |
Number |
No | 1 |
The cars starting social. |
car_driver_offset_x |
Number |
No | 0 |
The cell x offset for the driver seat. |
car_driver_offset_y |
Number |
No | 0 |
The cell y offset for the driver seat. |
car_backseat_offset_x |
Number |
No | 22 |
|
car_backseat_offset_y |
Number |
No | 0 |
|
car_base_speed |
Number |
No | 1 |
The cars starting speed. |
car_accel_tag |
String |
No | sfx_v_accel |
The tag to use for the car accel. |
car_deaccel_tag |
String |
No | sfx_v_deaccel |
The tag to use for the car deaccel. |
car_start_tag |
String |
No | sfx_v_start |
|
car_stop_tag |
String |
No | sfx_v_stop |
|
car_engine_idle_loop |
String |
No | SFX_Player_Car_Volvo_Engine_Idle_Loop_01 |
The audio sound for the car idle loop. |
car_engine_drive_loop |
String |
No | SFX_Player_Car_Volvo_Engine_Driving_Loop_01 |
The audio sound for the car driving loop. |
car_rev_sound |
String |
No | SFX_Player_Car_Volvo_Engine_Rev_Loop_01 |
The audio sound for the car rev sound. |
car_seat |
Object |
No | N/A |
Describes what this car seat is. |
car_seat_count_override |
Number |
No | 0 |
Overrides how many seats there are. |
In addition, car_seat has the following:
| Key | Type | Explanation |
|---|---|---|
seat_slot |
Number |
The slot position of the seat currently being modified. 0 by default is the driver seat. |
removable |
Number |
Whether the seat can be removed or not. |
x |
Number |
X position of the seat on the grid. |
y |
Number |
Y position of the seat on the grid. |
passenger |
Number |
Determines if the seat is available to passengers or not. |
social |
Number |
|
sprite |
String |
The sprite name to use for the car seat. |
adj |
Number |
How many seats are adjacent to this car seat. |
seat_adj |
Number,Number,Number |
Example format:
{
car_dev_name: "tab_420"
car_title: "Broken"
car_base_speed: 0.01
car_bg: "spr_player_car_volvo240_background"
car_color: "spr_player_car_volvo240_body_white"
car_main_sprite: "spr_player_car_volvo240_body_white"
car_wheel: "spr_player_car_volvo240_wheel_none"
car_slot_disabled: 0,0
car_slot_disabled: 1,0
car_slot_disabled: 2,0
car_slot_disabled: 3,0
car_slot_disabled: 0,8
car_slot_disabled: 1,8
car_slot_disabled: 2,8
car_slot_disabled: 3,8
car_player_seat_sprite: "spr_driver_inventory"
car_player_seat_sprite_x: 172
car_player_seat_sprite_y: 22
car_inv_x: 0
car_inv_y: 0
car_bg_x: 0
car_seat: {
seat_slot: 1
x: 9
y: 6
passengar: -1
social: 1
removable: 0
sprite: "spr_inventory_seat_64x48_bottom_"
adj: 1
seat_adj: 0,0,0
}
}