Discord
Steam
/
Garry's Mod
/
Developers
/
SWEP.UseHands ..
Login/Join
Event Log
SWEP.UseHands Broken?!?!
2 replies, posted
Search
In This Thread
[t]http://i.imgur.com/gpdspK2.png[/t] ^ What the heck?! I've tried with different Player models... maybe I've forgotten how to use it? I have a VERY simple script right now, it's not even a functioning SWEP yet... [code]AddCSLuaFile() SWEP.Author = "Dank Dragon™" SWEP.Category = "WIP" SWEP.Spawnable = true SWEP.UseHands = true SWEP.MinClip = -3 SWEP.MaxClip = 30 SWEP.ClipDivider = 1 SWEP.Chamber = true SWEP.Primary.ClipSize = 30 SWEP.Primary.DefaultClip = 0 SWEP.Primary.Automatic = true SWEP.Primary.Ammo = "none" SWEP.Secondary.ClipSize = -1 SWEP.Secondary.DefaultClip = -1 SWEP.Secondary.Automatic = false SWEP.Secondary.Ammo = "none" function SWEP:Initialize() local ClipFunction = math.floor( math.max( 0, math.random( self.MinClip, self.MaxClip ) / self.ClipDivider ) ) local ClipSize = math.min( ClipFunction, self.Primary.ClipSize+1 ) -- local Reserves = math.max( 0, ClipFunction - ClipSize ) or 0 self:SetClip1( ClipSize ) -- self.Owner:GiveAmmo( Reserves, self.Primary.Ammo, true ) -- ^ GiveAmmo was nil end function SWEP:PrimaryAttack() print( self:Clip1() ) -- Verify random starting clip works end[/code] Could someone please help me figure out what's wrong?
Set a view model.
[QUOTE=Mechanical Mind;49284114]Set a view model.[/QUOTE] ...thanks. I withdraw my question, shamefully
Sorry, you need to
Log In
to post a reply to this thread.