Original Author: raydan
CS:GO Rally Race
This is a direct descendent of raydan's old Rally Race mod
for CS:S. Credit goes to him for the original idea and much of the functionality of this plugin. Sometime in 2011 I unofficially took over developing the CS:S version, but now I have taken it and made a new CS:GO version.
0.51 (10 May 2015)
- Sounds now use EmitSoundAny
- Added countdown to race start
- Fixed Dodge Charger model
- Removed some depreciated hooks
- First version for CS:GO
- Headlights are +lookatweapon
- Compatibility for CS:S Cars
- Fixed UI elements for CS:GO
rallyrace_version_csgo -- version number
car_horn_delay -- Delay between horn honks in seconds -- Defaults to 1.0
rallyrace_readytime -- Wait time between races in seconds -- Defaults to 20
rallyrace_racetime -- Maximum race time in seconds -- Defaults to 320
rallyrace_raceround -- Number of races before map vote -- Defaults to 6
rallyrace_use -- If 1 this lets players press +use (e) to exit the car -- Defaults to 1
The above file contains a basic install.
What does a Rally Race server need?
- A compatible map
- A car model
- A script for the car
- The plugin and configs
Optional: sounds and custom surfaceproperty scripts
In the .zip above I include
- 5 cars
- Scripts for those cars and other cars not present
- Configs for RR
- 3 other plugins -- sm_downloader, rallyrace_times, and mapchooser.smx
sm_downloader and rallyrace_times are optional, but you probably want them. mapchooser is mandatory.
CS:GO Rally Race maps work exactly the same as the CS:S ones, except the spectate zone doesn't work right now. It is okay to add the spectate zone brush, in the future I may get it operational.
Here are some maps you can download and use right away:
The map needs a few things to work right, I'm just copying raydan's explanation as this stuff has not changed.
Check Point: car check points
Wait (Delay before reset): 0.1 (best value is 0.1, don't set 0)
for the first checkpoint, targetname must be "checkpoint_#1", second checkpoint, "checkpoint_#2". (up to checkpoint_#x , where x is the largest integer number in sourcemod, and don't make stupid things, like checkpoint_#-1, checkpoint_#a, checkpoint_## and so on, if server crash don't ask me)
Ready Zone: when player inside the zone, mean player can play on next race round
Wait: 0.1 or default
Create a "env_sprite", use model "zx2_car/go.vmt", put it into the "ready_zone" center, it will show a "GO!" picture
Spectate Zone: when player inside the zone, switch player to spectate team directly
Wait: 0.1 or default
Create a "cycler", use model "models/gman.mdl", let player know there is a spectate zone (or some sexy model)
Car Spawn Point: car spawn points
Angle: you must set the correct angle
I use prop_vehicle_driveable. Most cars from the CS:S Rally Race will work, but you need to use appropriate flags in carconfig.txt
I'll explain the variables with this example:
"name" "Dodge Charger"
"5" "Dark Green"
"9" "Bright Blue"
name - car name as it will be displayed
type - unused right now
model - path to the .mdl
script - path to the vehicle script (determines handling of the car)
val_1 - unused right now
val_2 - unused right now
skin_min - should be 0
skin_max - maximum skin number, this is indexed so if the car has 10 skins you put 9 here
"0" - name for the colour or whatever of the skin of this number
"1" - name for the next colour etc
"vip" - leave this 0 unless you want only server admins or vips to use this car
(to make someone a VIP add them to the admin config file, but give immunity 0 and no flags)
siren - does this car have a police siren? use 0 for most cars
police_lights - if the car has attachments for flashing police lights set this to 1
lights - 1 means brake lights only, 2 means headlights also, these are determined by the model
view - does this model have an attachment for 3rd person? if so use 1
driver - is using a CS:S car set to 0 or else server can crash
driver, view, lights, and police_lights are all dependent upon the vehicle model. If it doesn't have the right stuff set them to 0. driver MUST be set to 0 for all vehicles except the dodge charger in the above .zip file because I have not made any other car work with a driver view model for CS:GO. Even if the view model worked for CS:S rally race it won't work now, so keep it 0. Look at the charger .mdl in HLMV to see the attachments.
If you want to model a car and give it functionality use the following attachment names:
vehicle_3rd <-- this one floats behind the vehicle up in the air
vehicle_driver_eyes <-- for driver view model, but this REQUIRES a skeleton rigged properly
Talk to me on Steam (natalyaaf or natalya_fs) if you want to make a compatible car model I can explain everything in detail.
@ SM Mods:
If there are problems with this submission, I apologize, I can fix stuff or whatever if need be.
@ Everyone else:
Thanks for downloading, I hope you have fun racing on CS:GO