• GMCP2 Problem 1 - Helicopter Bomb Gun Firing Mode
    0 replies, posted
Most people don't know about GMC. It stands for Garry's Mod Classics. It contains some weapons I 'modified' to create new weapons similar to the original Gmod weapons. Here is 1 of the problems. When I tried to add a firing mode to the Helicopter Bomb Gun, it worked. There is one problem though, it just drops the bombs. It will not fire no matter how I change the speed. Here, take a look at the Lua: Shared.lua /*--------------------------------------------------------- PrimaryAttack ---------------------------------------------------------*/ function SWEP:PrimaryAttack() self.Weapon:SetNextPrimaryFire( CurTime() + 0.1 ) self:EmitSound( ShootSound ) self:ShootEffects( self ) // The rest is only done on the server if (!SERVER) then return end local Forward = self.Owner:EyeAngles():Forward() local ent = ents.Create( "grenade_helicopter" ) if ( ValidEntity( ent ) ) then ent:SetPos( self.Owner:GetShootPos() + Forward * 32 ) ent:SetAngles( self.Owner:EyeAngles() ) ent:Spawn() ent:SetVelocity( Forward * 2000 ) end ent:SetOwner( self.Owner ) end --------------------------------------------------------- Help with this would be appreciated. If you need to take a look at the whole script for some reason, download is below. [url]http://www.mediafire.com/?87f7kr85pgf1wur[/url]
Sorry, you need to Log In to post a reply to this thread.