Well, i'm trying to convert a swep into a ttt wep. Here are the sweps [url]http://steamcommunity.com/sharedfiles/filedetails/?id=255659990&searchtext=swep[/url]. And here's my shared.lua file for the hk417_iron weapon [CODE]// Variables that are used on both client and server
SWEP.Base = "weapon_mad_base"
SWEP.ViewModelFlip = false
SWEP.ViewModel = "models/weapons/v_m417_iron.mdl"
SWEP.WorldModel = "models/weapons/w_m417_iron.mdl"
SWEP.HoldType = "ar2"
SWEP.Spawnable = true
SWEP.AdminSpawnable = false
SWEP.Kind = WEAPON_HEAVY
SWEP.AmmoEnt = "item_ammo_pistol_ttt"
SWEP.AllowDrop = true
SWEP.AutoSpawnable = false
SWEP.Primary.Sound = Sound("Bender_HK417.Single")
SWEP.Primary.Recoil = 1
SWEP.Primary.Damage = 35
SWEP.Primary.NumShots = 1
SWEP.Primary.Cone = 0.0010
SWEP.Primary.Delay = 0.1
SWEP.Primary.RPM = 600
SWEP.Primary.ClipSize = 20 // Size of a clip
SWEP.Primary.DefaultClip = 20 // Default number of bullets in a clip
SWEP.Primary.Automatic = true // Automatic/Semi Auto
SWEP.Primary.Ammo = "StriderMinigun"
SWEP.Secondary.ClipSize = -1 // Size of a clip
SWEP.Secondary.DefaultClip = -1 // Default number of bullets in a clip
SWEP.Secondary.Automatic = false // Automatic/Semi Auto
SWEP.Secondary.Ammo = "none"
SWEP.ShellEffect = "effect_mad_shell_rifle" // "effect_mad_shell_pistol" or "effect_mad_shell_rifle" or "effect_mad_shell_shotgun"
SWEP.Pistol = false
SWEP.Rifle = true
SWEP.Shotgun = false
SWEP.Sniper = false
SWEP.IronSightsPos = Vector(-1.941, 0, 0.6)
SWEP.IronSightsAng = Vector(0, 0.1, 0)
SWEP.RunArmOffset = Vector(4.44, 0, 1.08)
SWEP.RunArmAngle = Vector(-12.801, 35.299, 0)
/*---------------------------------------------------------
Name: SWEP:Precache()
Desc: Use this function to precache stuff.
---------------------------------------------------------*/
function SWEP:Precache()
util.PrecacheSound("weapons/HK417/Single.wav")
end[/CODE]
and heres the mad cow base [CODE]
local Sound = Sound
local Vector = Vector
local CreateConVar = CreateConVar
local CurTime = CurTime
local IsFirstTimePredicted = IsFirstTimePredicted
local Angle = Angle
local EffectData = EffectData
local SinglePlayer = SinglePlayer
local FrameTime = FrameTime
local IsValid = IsValid
local WorldSound = WorldSound
local util = util
local hook = hook
local math = math
local timer = timer
local ents = ents
local ACT_VM_IDLE = ACT_VM_IDLE
local PLAYERANIMEVENT_CUSTOM_GESTURE = PLAYERANIMEVENT_CUSTOM_GESTURE
local GESTURE_SLOT_ATTACK_AND_RELOAD = GESTURE_SLOT_ATTACK_AND_RELOAD
local ACT_MP_ATTACK_CROUCH_PRIMARYFIRE = ACT_MP_ATTACK_CROUCH_PRIMARYFIRE
local ACT_MP_ATTACK_STAND_PRIMARYFIRE = ACT_MP_ATTACK_STAND_PRIMARYFIRE
local FCVAR_REPLICATED = FCVAR_REPLICATED
local FCVAR_ARCHIVE = FCVAR_ARCHIVE
local ACT_VM_DRAW_EMPTY = ACT_VM_DRAW_EMPTY
local ACT_VM_DRAW_SILENCED = ACT_VM_DRAW_SILENCED
local ACT_VM_DRAW = ACT_VM_DRAW
local IN_SPEED = IN_SPEED
local ACT_VM_IDLE_SILENCED = ACT_VM_IDLE_SILENCED
local ACT_VM_IDLE_EMPTY = ACT_VM_IDLE_EMPTY
local IN_FORWARD = IN_FORWARD
local IN_BACK = IN_BACK
local IN_MOVELEFT = IN_MOVELEFT
local IN_MOVERIGHT = IN_MOVERIGHT
local HUD_PRINTTALK = HUD_PRINTTALK
local ACT_VM_RELOAD = ACT_VM_RELOAD
local ACT_VM_RELOAD_SILENCED = ACT_VM_RELOAD_SILENCED
local ACT_VM_RELOAD_EMPTY = ACT_VM_RELOAD_EMPTY
local IN_USE = IN_USE
local ACT_INVALID = ACT_INVALID
local IN_DUCK = IN_DUCK
local SERVER = SERVER
local CLIENT = CLIENT
local MAT_GLASS = MAT_GLASS
local MAT_SAND = MAT_SAND
local MAT_FLESH = MAT_FLESH
local MAT_ALIENFLESH = MAT_ALIENFLESH
local MAT_WOOD = MAT_WOOD
local MAT_CONCRETE = MAT_CONCRETE
local MAT_PLASTIC = MAT_PLASTIC
/*---------------------------------------------------------
------mmmm---mmmm-aaaaaaaa----ddddddddd---------------------------------------->
mmmmmmmmmmmm aaaaaaaaa dddddddddd Name: Mad Cows Weapons
mmm mmmm mmm aaa aaa ddd ddd Author: Worshipper
mmm mmm mmm aaaaaaaaaaa ddd ddd Project Start: October 23th, 2009
mmm mmm aaa aaa dddddddddd Version: 2.0
---mmm--------mmm-aaa-----aaa-ddddddddd---------------------------------------->
---------------------------------------------------------*/
// Variables that are used on both client and server
local RecoilMul = CreateConVar ("mad_recoilmul", "1", {FCVAR_REPLICATED, FCVAR_ARCHIVE})
local DamageMul = CreateConVar ("mad_damagemul", "1", {FCVAR_REPLICATED, FCVAR_ARCHIVE})
SWEP.Category = "Mad Cows Weapons"
SWEP.Author = "Worshipper"
SWEP.Contact = "Josephcadieux@hotmail.com"
// I have nothing to say here because I'm a prick
SWEP.Purpose = ""
SWEP.Instructions = ""
SWEP.HoldType = "pistol"
SWEP.ViewModelFOV = 60
SWEP.ViewModelFlip = false
SWEP.ViewModel = "models/weapons/v_pistol.mdl"
SWEP.WorldModel = "models/weapons/w_pistol.mdl"
SWEP.AnimPrefix = "python"
SWEP.AmmoEnt = "item_ammo_smg1_ttt"
SWEP.Spawnable = false
SWEP.AdminSpawnable = false
SWEP.Primary.Sound = Sound("Weapon_AK47.Single")
SWEP.Primary.Recoil = 10
SWEP.Primary.Damage = 10
SWEP.Primary.NumShots = 1
SWEP.Primary.Cone = 0
SWEP.Primary.Delay = 0
SWEP.Primary.ClipSize = 5 // Size of a clip
SWEP.Primary.DefaultClip = 5 // Default number of bullets in a clip
SWEP.Primary.Automatic = false // Automatic/Semi Auto
SWEP.Primary.Ammo = "none"
SWEP.Secondary.ClipSize = -1 // Size of a clip
SWEP.Secondary.DefaultClip = -1 // Default number of bullets in a clip
SWEP.Secondary.Automatic = false // Automatic/Semi Auto
SWEP.Secondary.Ammo = "none"
SWEP.ActionDelay = CurTime()
// I added this function because some weapons like the Day of Defeat weapons need 1.2 or 1.5 seconds to deploy
SWEP.DeployDelay = 1
SWEP.ShellEffect = "effect_mad_shell_pistol" // "effect_mad_shell_pistol" or "effect_mad_shell_rifle" or "effect_mad_shell_shotgun"
SWEP.ShellDelay = 0
// Is it a pistol, a rifle, a shotgun or a sniper? Choose only one of them or you'll fucked up everything. BITCH!
SWEP.Pistol = false
SWEP.Rifle = false
SWEP.Shotgun = false
SWEP.Sniper = false
SWEP.IronSightsPos = Vector (0, 0, 0)
SWEP.IronSightsAng = Vector (0, 0, 0)
SWEP.RunArmOffset = Vector (0, 0, 5.5)
SWEP.RunArmAngle = Vector (-35, -3, 0)
// Burst options
SWEP.Burst = false
SWEP.BurstShots = 3
SWEP.BurstDelay = 0.05
SWEP.BurstCounter = 0
SWEP.BurstTimer = 0
// Custom mode options (Do not put a burst mode and a custom mode at the same time, it will not work)
SWEP.Type = 1 // 1 = Automatic/Semi-Automatic mode, 2 = Suppressor mode, 3 = Burst fire mode
SWEP.Mode = false
SWEP.data = {}
SWEP.data.NormalMsg = "Switched to semi-automatic."
SWEP.data.ModeMsg = "Switched to automatic."
SWEP.data.Delay = 0.5 // You need to wait 0.5 second after you change the fire mode
SWEP.data.Cone = 1
SWEP.data.Damage = 1
SWEP.data.Recoil = 1
SWEP.data.Automatic = false
// Constant accuracy means that your crosshair will not change if you're running, shooting or walking
SWEP.ConstantAccuracy = false
// I don't think it's hard to understand this
SWEP.Penetration = true
SWEP.Ricochet = true
SWEP.MaxRicochet = 1
SWEP.Tracer = 0 // 0 = Normal Tracer, 1 = Ar2 Tracer, 2 = Airboat Gun Tracer, 3 = Normal Tracer + Sparks Impact
SWEP.IdleDelay = 0
SWEP.IdleApply = false
SWEP.AllowIdleAnimation = true
SWEP.AllowPlaybackRate = true
SWEP.BoltActionSniper = false // Use this value if you want to remove the scope view after you shoot
SWEP.ScopeAfterShoot = false // Do not try to change this value
SWEP.IronSightZoom = 1.5
SWEP.ScopeZooms = {10}
SWEP.ScopeScale = 0.4
SWEP.ShotgunReloading = false
SWEP.ShotgunFinish = 0.5
SWEP.ShotgunBeginReload = 0.3
/*---------------------------------------------------------
Name: SWEP:Initialize()
Desc: Called when the
Sorry, you need to Log In to post a reply to this thread.