Guthen / Guthen/VKXToolsEntitySpawner

Add support for Glide vehicles

Open
#15 0 comments 0 reactions 0 assignees View on GitHub
enhancement good first issue
Dominant language
Lua
Stars
1
Forks
0
PR merge metrics
No merged PRs in 30d

Description

[Glide](https://steamcommunity.com/sharedfiles/filedetails/?id=3389728250) is a new base for vehicles.

We can add support by looking through this function:
```lua
function Glide.VehicleFactory( ply, data )
if not Glide.CanSpawnVehicle( ply, data.Class ) then return end

local ent = ents.Create( data.Class )
if not IsValid( ent ) then return end

ent:SetPos( data.Pos )
ent:SetAngles( data.Angle )
ent:SetCreator( ply )
ent:Spawn()
ent:Activate()

local limitName = IsTrailerClass( data.Class ) and "glide_trailers" or "glide_vehicles"

ply:AddCount( limitName, ent )
cleanup.Add( ply, limitName, ent )

return ent
end
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.