Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
745cb07
Merge pull request #2 from Kafouille/master
Kafouille Oct 17, 2012
1b86b28
Bugfix: Changed a \ to a / in the tracer setup. renamed info.txt to …
generalwrex Oct 25, 2012
d796a20
Merge pull request #3 from generalwrex/master
Kafouille Oct 25, 2012
b7dc7dd
Bugfix: Rounded the Magnitude of the bullet effect so it received the…
generalwrex Oct 29, 2012
5cba02c
Bugfix: Added in a timer so the particles loaded properly.
generalwrex Oct 29, 2012
44d4169
Merge pull request #8 from generalwrex/master
Kafouille Oct 29, 2012
cb162fc
Bugfix: Removed the color tables from the effects, replaced the varia…
generalwrex Oct 30, 2012
f70dd50
Merge pull request #9 from generalwrex/master
Kafouille Oct 30, 2012
91fbf45
Bugfix: Repaired the the alpha changes on the debris.
generalwrex Oct 30, 2012
f5368dc
Merge pull request #10 from generalwrex/master
Kafouille Nov 1, 2012
db1122f
Bugfix : Fixed an oversight in the Gearbox RPM calculation code that …
Kafouille Nov 1, 2012
ab65283
Bugfix : Fixed an issue where setting a Gearbox to neutral would caus…
Kafouille Nov 1, 2012
a2f6821
Content: Autocannon model
lazermaniac Nov 3, 2012
6a100d9
Content: Added a readme
lazermaniac Nov 3, 2012
ca0432d
Merge pull request #12 from lazermaniac/master
Kafouille Nov 5, 2012
1a33506
Differential fix
Nov 6, 2012
e38d002
Diff Fix
Nov 15, 2012
4fe3cd5
Bugfix: Lowercased all lua files and references.
profan Nov 16, 2012
bca0f79
Revert "Bugfix: Lowercased all lua files and references."
profan Nov 16, 2012
7f2583d
Bugfix: Lowercased all lua files and references.
profan Nov 16, 2012
0464fbf
Merge pull request #15 from Profan/master
Kafouille Nov 16, 2012
7cd29a4
Merge pull request #14 from Fervidusletum/Diff_Fix
Kafouille Nov 17, 2012
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions README
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Advanced Combat Framework

The Advanced Combat Framework is a [Garry's Mod][] addon which creates a balanced, realistic and fun to play combat damage system, simulating projectiles, armor and explosions, as well as engines and gearboxes.

[Garry's Mod]: <http://garrysmod.com/>
22 changes: 11 additions & 11 deletions info.txt → addon.txt
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
"AddonInfo"
{
"name" "Armored Combat Framework"
"version" "v2.0"
"up_date" "Feb 2011"
"author_name" "Kafouille"
"author_email" "[email protected]"
"info" "A damage system based on prop size and weight, with customizable weapons"
"override" "0"
"AddonInfo"
{
"name" "Armored Combat Framework"
"version" "v2.0"
"up_date" "Feb 2011"
"author_name" "Kafouille"
"author_email" "[email protected]"

"info" "A damage system based on prop size and weight, with customizable weapons"

"override" "0"
}
2 changes: 1 addition & 1 deletion lua/ACF/Shared/ACFGunList.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/ACFGunList.lua" )
AddCSLuaFile( "acf/shared/acfgunlist.lua" )


-- local Exemple = {} --That name is just a variable name and doesn't have much meaning
Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/ACFMissileList.lua
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
--ACF missile list.
--Obviously none of this is balanced yet.

AddCSLuaFile("ACF/Shared/ACFMissileList.lua")
AddCSLuaFile("acf/shared/acfmissilelist.lua")

local RackTable = {}

Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/ACFMobilityList.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/ACFMobilityList.lua" )
AddCSLuaFile( "acf/shared/acfmobilitylist.lua" )

local MobilityTable = {} --Start mobility listing

Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/ACFSensorList.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/ACFSensorList.lua" )
AddCSLuaFile( "acf/shared/acfsensorlist.lua" )

local SensorTable = {} --Start sensors listing

Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/Rounds/RoundAP.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/Rounds/RoundAP.lua" )
AddCSLuaFile( "acf/shared/rounds/roundap.lua" )

local DefTable = {}
DefTable.type = "Ammo" --Tells the spawn menu what entity to spawn
Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/Rounds/RoundAPHE.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/Rounds/RoundAPHE.lua" )
AddCSLuaFile( "acf/shared/rounds/roundaphe.lua" )

local DefTable = {}
DefTable.type = "Ammo" --Tells the spawn menu what entity to spawn
Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/Rounds/RoundFunctions.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/Rounds/RoundFunctions.lua" )
AddCSLuaFile( "acf/shared/rounds/roundfunctions.lua" )

function ACF_RoundBaseGunpowder( PlayerData, Data, ServerData, GUIData )

Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/Rounds/RoundHE.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/Rounds/RoundHE.lua" )
AddCSLuaFile( "acf/shared/rounds/roundhe.lua" )

local DefTable = {}
DefTable.type = "Ammo" --Tells the spawn menu what entity to spawn
Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/Rounds/RoundHEAT.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/Rounds/RoundHEAT.lua" )
AddCSLuaFile( "acf/shared/rounds/roundheat.lua" )

local DefTable = {}
DefTable.type = "Ammo" --Tells the spawn menu what entity to spawn
Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/Rounds/RoundHP.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/Rounds/RoundHP.lua" )
AddCSLuaFile( "acf/shared/rounds/roundhp.lua" )

local DefTable = {}
DefTable.type = "Ammo" --Tells the spawn menu what entity to spawn
Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/Rounds/RoundRefill.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/Rounds/RoundRefill.lua" )
AddCSLuaFile( "acf/shared/rounds/roundrefill.lua" )

local DefTable = {}
DefTable.type = "Ammo" --Tells the spawn menu what entity to spawn
Expand Down
2 changes: 1 addition & 1 deletion lua/ACF/Shared/Rounds/RoundSmoke.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
AddCSLuaFile( "ACF/Shared/Rounds/RoundSmoke.lua" )
AddCSLuaFile( "acf/shared/rounds/roundsmoke.lua" )

local DefTable = {}
DefTable.type = "Ammo" --Tells the spawn menu what entity to spawn
Expand Down
16 changes: 9 additions & 7 deletions lua/autorun/ACF_Globals.lua
Original file line number Diff line number Diff line change
Expand Up @@ -82,14 +82,16 @@ ACF.RoundTypes = list.Get("ACFRoundTypes")

ACF.IdRounds = list.Get("ACFIdRounds") --Lookup tables so i can get rounds classes from clientside with just an integer

game.AddParticles("particles/acf_muzzleflashes.pcf")
game.AddParticles("particles/explosion1.pcf")
game.AddParticles("particles/rocket_motor.pcf")
timer.Simple(5,function()
game.AddParticles("particles/acf_muzzleflashes.pcf")
game.AddParticles("particles/explosion1.pcf")
game.AddParticles("particles/rocket_motor.pcf")

PrecacheParticleSystem("tracer_tail_white")
for Class,Table in pairs(ACF.Classes["GunClass"]) do
PrecacheParticleSystem(Table["muzzleflash"])
end

for Class,Table in pairs(ACF.Classes["GunClass"]) do
PrecacheParticleSystem(Table["muzzleflash"])
end
end)

function ACF_MuzzleVelocity( Propellant, Mass, Caliber )

Expand Down
10 changes: 5 additions & 5 deletions lua/effects/ACF_AP_Penetration/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ function EFFECT:Metal()
Debris:SetRollDelta( math.Rand(-3, 3) )
Debris:SetAirResistance( 100 )
Debris:SetGravity( Vector( 0, 0, -650 ) )
Debris:SetColor( Color(120,120,120 ))
Debris:SetColor( 120,120,120 )
end
end

Expand All @@ -91,7 +91,7 @@ function EFFECT:Metal()
Embers:SetRollDelta( math.Rand(-0.2, 0.2) )
Embers:SetAirResistance( 20 )
Embers:SetGravity( VectorRand()*10 )
Embers:SetColor( Color(200,200,200 ))
Embers:SetColor( 200,200,200 )
end
end

Expand Down Expand Up @@ -124,7 +124,7 @@ function EFFECT:Concrete()
Debris:SetRollDelta( math.Rand(-3, 3) )
Debris:SetAirResistance( 100 )
Debris:SetGravity( Vector( 0, 0, -650 ) )
Debris:SetColor( Color(120,120,120 ))
Debris:SetColor( 120,120,120 )
end
end

Expand All @@ -143,7 +143,7 @@ function EFFECT:Concrete()
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 200 )
Smoke:SetGravity( Vector( math.random(-5,5)*self.Scale, math.random(-5,5)*self.Scale, -50 ) )
Smoke:SetColor( Color(90,90,90 ))
Smoke:SetColor( 90,90,90 )
end

end
Expand All @@ -165,7 +165,7 @@ function EFFECT:Concrete()
Embers:SetRollDelta( math.Rand(-0.2, 0.2) )
Embers:SetAirResistance( 20 )
Embers:SetGravity( VectorRand()*10 )
Embers:SetColor( Color(200,200,200 ))
Embers:SetColor( 200,200,200 )
end
end

Expand Down
11 changes: 6 additions & 5 deletions lua/effects/ACF_BulletEffect/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ function EFFECT:Init( data )
else
--print("Creating Bullet Effect")
local BulletData = {}
BulletData.Crate = Entity(data:GetMagnitude())
BulletData.Crate = Entity(math.Round(data:GetMagnitude()))
BulletData.SimFlight = data:GetStart()*10
BulletData.SimPos = data:GetOrigin()
BulletData.Caliber = BulletData.Crate:GetNetworkedInt( "Caliber" ) or 10
Expand All @@ -55,8 +55,9 @@ function EFFECT:Init( data )

if BulletData.Crate:GetNetworkedInt( "Tracer" ) > 0 then
BulletData.Tracer = ParticleEmitter( BulletData.SimPos )
local r,g,b,a = BulletData.Crate:GetColor()
BulletData.TracerColour = Vector(r,g,b)
local col = BulletData.Crate:GetColor()
BulletData.TracerColour = Vector(col.r,col.g,col.b)

end


Expand Down Expand Up @@ -117,7 +118,7 @@ function EFFECT:ApplyMovement( Bullet )
if (Light) then
Light:SetAngles( Bullet.SimFlight:Angle() )
Light:SetVelocity( Bullet.SimFlight:GetNormalized() )
Light:SetColor( Color(Bullet.TracerColour.x, Bullet.TracerColour.y, Bullet.TracerColour.z ))
Light:SetColor( Bullet.TracerColour.x, Bullet.TracerColour.y, Bullet.TracerColour.z )
Light:SetDieTime( 0.1 )
Light:SetStartAlpha( 255 )
Light:SetEndAlpha( 155 )
Expand All @@ -130,7 +131,7 @@ function EFFECT:ApplyMovement( Bullet )
if (Smoke) then
Smoke:SetAngles( Bullet.SimFlight:Angle() )
--Smoke:SetVelocity( Vector(0,0,0) )
Smoke:SetColor( Color(200 , 200 , 200 ))
Smoke:SetColor( 200 , 200 , 200 )
Smoke:SetDieTime( 1.2 )
Smoke:SetStartAlpha( 10 )
Smoke:SetEndAlpha( 0 )
Expand Down
5 changes: 3 additions & 2 deletions lua/effects/ACF_Cookoff/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ function EFFECT:Init( data )
self.Entity:SetMoveType( MOVETYPE_VPHYSICS )
self.Entity:SetSolid( SOLID_VPHYSICS )
self.Entity:SetColor( Color(0,0,0,0 ))
self.Entity:SetRenderMode(RENDERMODE_TRANSALPHA)
--Msg("Effect Spawned/n")

self.LifeTime = RealTime() + math.random(1, 2)
Expand Down Expand Up @@ -43,7 +44,7 @@ function EFFECT:Think()
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 50 )
Smoke:SetGravity( Vector( math.Rand(0, 0)*self.Scale, math.Rand(0, 0)*self.Scale, 0 ) )
Smoke:SetColor( Color(90,90,90 ))
Smoke:SetColor( 90,90,90 )
end

local Fire = self.Emitter:Add( "particles/flamelet"..math.random(1,5), self.Entity:GetPos())
Expand All @@ -59,7 +60,7 @@ function EFFECT:Think()
Fire:SetRollDelta( math.Rand(-0.2, 0.2) )
Fire:SetAirResistance( 100 )
Fire:SetGravity( VectorRand()*self.Scale )
Fire:SetColor( Color(255,255,255 ))
Fire:SetColor( 255,255,255 )
end

return self.LifeTime > RealTime()
Expand Down
6 changes: 3 additions & 3 deletions lua/effects/ACF_HEAT_Explosion/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ function EFFECT:Init( data )
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 300 )
Smoke:SetGravity( Vector( math.random(-5,5)*self.Radius, math.random(-5,5)*self.Radius, -450 ) )
Smoke:SetColor( Color(160,160,160) )
Smoke:SetColor( 160,160,160)
end

end
Expand All @@ -46,7 +46,7 @@ function EFFECT:Init( data )
Debris:SetRollDelta( math.Rand(-3, 3) )
Debris:SetAirResistance( 200 )
Debris:SetGravity( Vector( 0, 0, -650 ) )
Debris:SetColor( Color(120,120,120 ))
Debris:SetColor( 120,120,120 )
end
end

Expand All @@ -67,7 +67,7 @@ function EFFECT:Init( data )
Embers:SetRollDelta( math.Rand(-0.2, 0.2) )
Embers:SetAirResistance( 20 )
Embers:SetGravity( Vector( 0, 0, -650 ) )
Embers:SetColor( Color(200,200,200 ))
Embers:SetColor( 200,200,200 )
end
end

Expand Down
22 changes: 11 additions & 11 deletions lua/effects/ACF_Scaled_Explosion/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ function EFFECT:Core()
Flame:SetRollDelta( math.Rand(-1, 1) )
Flame:SetAirResistance( 300 )
Flame:SetGravity( Vector( 0, 0, 4 ) )
Flame:SetColor( Color(255,255,255 ))
Flame:SetColor( 255,255,255 )
end

end
Expand All @@ -105,7 +105,7 @@ function EFFECT:Core()
Debris:SetRollDelta( math.Rand(-3, 3) )
Debris:SetAirResistance( 10 )
Debris:SetGravity( Vector( 0, 0, -650 ) )
Debris:SetColor( Color(120,120,120 ))
Debris:SetColor( 120,120,120 )
end
end

Expand All @@ -126,7 +126,7 @@ function EFFECT:Core()
Embers:SetRollDelta( math.Rand(-0.2, 0.2) )
Embers:SetAirResistance( 20 )
Embers:SetGravity( Vector( 0, 0, -650 ) )
Embers:SetColor( Color(200,200,200 ))
Embers:SetColor( 200,200,200 )
end
end

Expand All @@ -144,7 +144,7 @@ function EFFECT:Core()
Whisp:SetRollDelta( math.Rand(-0.2, 0.2) )
Whisp:SetAirResistance( 100 )
Whisp:SetGravity( Vector( math.random(-5,5)*self.Radius, math.random(-5,5)*self.Radius, 0 ) )
Whisp:SetColor( Color(150,150,150 ))
Whisp:SetColor( 150,150,150 )
end
end

Expand Down Expand Up @@ -184,7 +184,7 @@ function EFFECT:Shockwave( Ground, SmokeColor )
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 200 )
Smoke:SetGravity( Vector( math.Rand( -20 , 20 ), math.Rand( -20 , 20 ), math.Rand( 10 , 100 ) ) )
Smoke:SetColor( Color(SmokeColor.x,SmokeColor.y,SmokeColor.z ))
Smoke:SetColor( SmokeColor.x,SmokeColor.y,SmokeColor.z )
end

end
Expand All @@ -210,7 +210,7 @@ function EFFECT:Metal( SmokeColor )
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 100 )
Smoke:SetGravity( Vector( math.random(-5,5)*self.Radius, math.random(-5,5)*self.Radius, -50 ) )
Smoke:SetColor( Color(SmokeColor.x,SmokeColor.y,SmokeColor.z ))
Smoke:SetColor( SmokeColor.x,SmokeColor.y,SmokeColor.z )
end

end
Expand All @@ -236,7 +236,7 @@ function EFFECT:Concrete( SmokeColor )
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 100 )
Smoke:SetGravity( Vector( math.random(-5,5)*self.Radius, math.random(-5,5)*self.Radius, -50 ) )
Smoke:SetColor( Color(SmokeColor.x,SmokeColor.y,SmokeColor.z ))
Smoke:SetColor( SmokeColor.x,SmokeColor.y,SmokeColor.z )
end

end
Expand All @@ -262,7 +262,7 @@ function EFFECT:Dirt( SmokeColor )
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 100 )
Smoke:SetGravity( Vector( math.random(-5,5)*self.Radius, math.random(-5,5)*self.Radius, -50 ) )
Smoke:SetColor( Color(SmokeColor.x,SmokeColor.y,SmokeColor.z ))
Smoke:SetColor( SmokeColor.x,SmokeColor.y,SmokeColor.z )
end

end
Expand All @@ -288,7 +288,7 @@ function EFFECT:Sand( SmokeColor )
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 100 )
Smoke:SetGravity( Vector( math.random(-5,5)*self.Radius, math.random(-5,5)*self.Radius, -50 ) )
Smoke:SetColor( Color(SmokeColor.x,SmokeColor.y,SmokeColor.z ))
Smoke:SetColor( SmokeColor.x,SmokeColor.y,SmokeColor.z )
end

end
Expand All @@ -314,7 +314,7 @@ function EFFECT:Airburst( SmokeColor )
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 100 )
Smoke:SetGravity( Vector( math.random(-5,5)*self.Radius, math.random(-5,5)*self.Radius, -50 ) )
Smoke:SetColor( Color( SmokeColor.x,SmokeColor.y,SmokeColor.z ))
Smoke:SetColor( SmokeColor.x,SmokeColor.y,SmokeColor.z )
end

end
Expand All @@ -334,7 +334,7 @@ function EFFECT:Airburst( SmokeColor )
AirBurst:SetRollDelta( math.Rand(-0.2, 0.2) )
AirBurst:SetAirResistance( 200 )
AirBurst:SetGravity( Vector( math.random(-10,10)*self.Radius, math.random(-10,10)*self.Radius, 20 ) )
AirBurst:SetColor( Color(SmokeColor.x,SmokeColor.y,SmokeColor.z ))
AirBurst:SetColor( SmokeColor.x,SmokeColor.y,SmokeColor.z )
end
end

Expand Down
4 changes: 2 additions & 2 deletions lua/effects/ACF_Smoke/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ function EFFECT:Core()
Whisp:SetRollDelta( math.Rand(-0.2, 0.2) )
Whisp:SetAirResistance( 100 )
Whisp:SetGravity( Vector( math.random(-5,5)*self.Radius, math.random(-5,5)*self.Radius, 0 ) )
Whisp:SetColor( Color(150,150,150 ))
Whisp:SetColor( 150,150,150 )
end
end

Expand Down Expand Up @@ -81,7 +81,7 @@ function EFFECT:Shockwave( Ground, SmokeColor )
Smoke:SetRollDelta( math.Rand(-0.2, 0.2) )
Smoke:SetAirResistance( 200 )
Smoke:SetGravity( Vector( math.Rand( -20 , 20 ), math.Rand( -20 , 20 ), math.Rand( 10 , 100 ) ) )
Smoke:SetColor( Color(SmokeColor.x,SmokeColor.y,SmokeColor.z ))
Smoke:SetColor( SmokeColor.x,SmokeColor.y,SmokeColor.z )
end

end
Expand Down
Loading