This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--@name Vegetation Painter | |
--@author Cheezus | |
--@shared | |
--[[ | |
Basic usage: | |
0. Start Hammer on the SAME VERSION of the map you're currently playing on; you may need to do a fresh compile | |
1. Define whatever foliage models you want placed using vegetation.models table below | |
2. Spawn the chip and hold your use key (default E) to place foliage and your walk key (default ALT) to erase | |
3. Type /export to export current vegetation models to Hammer | |
4. Type /clear to remove current vegetation models from Hammer (in case you've made a mistake) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@name Car Steering v2.3.1 | |
@inputs A D Active Base:entity | |
@outputs SteeringAngle | |
@persist E:entity [HoloLastPos LastHoloLastPos]:vector MaxAngle SteeringRate SteeringSmoothRate CasterAngle LastRun | |
@persist SlipCounterForce GyroCounterForce CounterMax HoloLastYaw | |
@persist AntiWobbleAngle AntiWobbleMul | |
@trigger Base | |
@model models/sprops/rectangles_thin/size_2/rect_12x12x1_5.mdl | |
####################[READ ME]#################### |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if SERVER then | |
hook.Add("PlayerEnteredVehicle", "GForce::EnterVehicle", function(ply, veh) | |
ply.gforceLastPos = veh:GetPos() | |
ply.gforceLastVel = Vector() | |
end) | |
hook.Add("PlayerLeaveVehicle", "GForce::ExitVehicle", function(ply, Veh) | |
ply.gforceLastPos = nil | |
ply.gforceLastVel = nil | |
end) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--@name tools/Torque Curve Visualizer v1.1 | |
--@author Cheezus | |
--@shared | |
if CLIENT then | |
local Engine = {} | |
Engine.name = "427 V8" | |
--[[ | |
ACF3 curves: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import time | |
extensionFrom = ".txt" | |
extensionTo = ".qc" | |
count = 0 | |
for f in os.listdir(): | |
if f.endswith(extensionFrom): | |
count += 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if SERVER then | |
util.AddNetworkString("TorqueTest") | |
util.AddNetworkString("TorqueTestEntity") | |
local ply = me --If you aren't running this with luapad set this to your player entity | |
local e = ents.Create("prop_physics") | |
e:SetModel("models/props_junk/wood_crate001a.mdl") | |
e:SetPos(ply:GetPos() + Vector( 0, 0, 100 )) | |
e:Spawn() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--@name Simulated Gearbox | |
--@author Cheezus | |
--@shared | |
local crankAxis = Vector(0, 0, 1) -- Rotation axis of the crankshaft | |
local flywheelAxis = Vector(0, 0, 1) -- Rotation axis of the flywheel | |
crankAxis:normalize() | |
flywheelAxis:normalize() | |
if SERVER then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--@name Car Steering v3.4 | |
--@author Cheezus | |
--@shared | |
--@model models/sprops/rectangles_thin/size_2/rect_12x12x1_5.mdl | |
local showAxes = true | |
local frontWheelPos = Vector(50, 0, 0) -- Between your front wheels | |
local rightAxis = Vector(0, -1, 0) -- The RIGHT facing direction of your car | |
local upAxis = Vector(0, 0, 1) -- The UP facing direction of your car |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--@name tools/CPU Tracker | |
--@author Cheezus | |
--@shared | |
-- To use this chip, spawn it on a Starfall screen component | |
if SERVER then | |
if chip():isWeldedTo() then | |
chip():isWeldedTo():linkComponent(chip()) | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--@name Mesh Loader | |
--@author Cheezus | |
--@shared | |
local debugPrints = true -- Shows info about tri count and loading progress | |
if CLIENT then | |
local globalScale = Vector(0.1) -- Scale all meshes added by this amount, or add a scale vector to individual meshes | |
local offsetPos = Vector(0, 0, 0) -- Offsets are relative to chip/base | |
local offsetAngle = Angle(0, 0, 0) |
OlderNewer