Show Posts
|
Pages: [1] 2
|
1
|
Other / Trouble in Terrorist Town / Re: Another "Looking for LUA Coder"
|
on: August 15, 2011, 01:55:11 AM
|
UMP45: if SERVER then
AddCSLuaFile( "shared.lua" ) end
SWEP.HoldType = "ar2"
if CLIENT then
SWEP.PrintName = "UMP45" SWEP.Slot = 2
SWEP.Icon = "VGUI/ttt/icon_mac" end
SWEP.Base = "weapon_tttbase" SWEP.Spawnable = true SWEP.AdminSpawnable = true
SWEP.Kind = WEAPON_HEAVY
SWEP.Primary.Delay = 0.1 SWEP.Primary.Recoil = 1.2 SWEP.Primary.Automatic = true SWEP.Primary.Ammo = "smg1" SWEP.Primary.Damage = 25 SWEP.Primary.Cone = 0.02 SWEP.Primary.ClipSize = 30 SWEP.Primary.ClipMax = 60 SWEP.Primary.DefaultClip = 30 SWEP.AutoSpawnable = true SWEP.AmmoEnt = "item_ammo_smg1_ttt" SWEP.ViewModel = "models/weapons/v_smg_ump45.mdl" SWEP.WorldModel = "models/weapons/w_smg_ump45.mdl"
SWEP.Primary.Sound = Sound( "Weapon_UMP45.Single" )
SWEP.IronSightsPos = Vector( 7.3, -5.5, 3.2 ) SWEP.IronSightsAng = Vector( -1.5, 0.35, 2 )
AWP (for traitors): if SERVER then AddCSLuaFile( "shared.lua" ) end
SWEP.HoldType = "ar2"
if CLIENT then SWEP.PrintName = "AWP"
SWEP.Slot = 2
SWEP.Icon = "VGUI/ttt/icon_scout" end
SWEP.Base = "weapon_tttbase" SWEP.Spawnable = true SWEP.AdminSpawnable = true
SWEP.Kind = WEAPON_EQUIP1 SWEP.WeaponID = AMMO_RIFLE
SWEP.Primary.Delay = 1.5 SWEP.Primary.Recoil = 7 SWEP.Primary.Automatic = true SWEP.Primary.Damage = 100 SWEP.Primary.Cone = 0.005 SWEP.Primary.ClipSize = 1 SWEP.Primary.ClipMax = 1 SWEP.Primary.DefaultClip = 1
SWEP.AutoSpawnable = false SWEP.ViewModel = Model("models/weapons/v_snip_awp.mdl") SWEP.WorldModel = Model("models/weapons/w_snip_awp.mdl")
SWEP.Primary.Sound = Sound(")weapons/awp/awp1.wav")
SWEP.Secondary.Sound = Sound("Default.Zoom")
SWEP.IronSightsPos = Vector( 5, -15, -2 ) SWEP.IronSightsAng = Vector( 2.6, 1.37, 3.5 ) SWEP.CanBuy = { ROLE_TRAITOR } SWEP.InLoadoutFor = nil SWEP.LimitedStock = true if CLIENT then -- Path to the icon material SWEP.Icon = "VGUI/ttt/icon_scout"
-- Text shown in the equip menu SWEP.EquipMenuData = { type = "Magnum Sniper", desc = "One shot, one kill." }; end
function SWEP:SetZoom(state) if CLIENT then return else if state then self.Owner:SetFOV(20, 0.3) else self.Owner:SetFOV(0, 0.2) end end end
-- Add some zoom to ironsights for this gun function SWEP:SecondaryAttack() if not self.IronSightsPos then return end if self.Weapon:GetNextSecondaryFire() > CurTime() then return end bIronsights = not self:GetIronsights() self:SetIronsights( bIronsights ) if SERVER then self:SetZoom(bIronsights) else self:EmitSound(self.Secondary.Sound) end self.Weapon:SetNextSecondaryFire( CurTime() + 0.3) end
function SWEP:PreDrop() self:SetZoom(false) self:SetIronsights(false) return self.BaseClass.PreDrop(self) end
function SWEP:Reload() self.Weapon:DefaultReload( ACT_VM_RELOAD ); self:SetIronsights( false ) self:SetZoom(false) end
function SWEP:Holster() self:SetIronsights(false) self:SetZoom(false) return true end
if CLIENT then local scope = surface.GetTextureID("sprites/scope") function SWEP:DrawHUD() if self:GetIronsights() then surface.SetDrawColor( 0, 0, 0, 255 ) local x = ScrW() / 2.0 local y = ScrH() / 2.0 local scope_size = ScrH()
-- crosshair local gap = 80 local length = scope_size surface.DrawLine( x - length, y, x - gap, y ) surface.DrawLine( x + length, y, x + gap, y ) surface.DrawLine( x, y - length, x, y - gap ) surface.DrawLine( x, y + length, x, y + gap )
gap = 0 length = 50 surface.DrawLine( x - length, y, x - gap, y ) surface.DrawLine( x + length, y, x + gap, y ) surface.DrawLine( x, y - length, x, y - gap ) surface.DrawLine( x, y + length, x, y + gap )
-- cover edges local sh = scope_size / 2 local w = (x - sh) + 2 surface.DrawRect(0, 0, w, scope_size) surface.DrawRect(x + sh - 2, 0, w, scope_size)
surface.SetDrawColor(255, 0, 0, 255) surface.DrawLine(x, y, x + 1, y + 1)
-- scope surface.SetTexture(scope) surface.SetDrawColor(255, 255, 255, 255)
surface.DrawTexturedRectRotated(x, y, scope_size, scope_size, 0)
else return self.BaseClass.DrawHUD(self) end end
function SWEP:AdjustMouseSensitivity() return (self:GetIronsights() and 0.2) or nil end end
Where's my money, bitch?
|
|
|
5
|
Other / Trouble in Terrorist Town / Re: AK47 script throws an error
|
on: July 15, 2011, 09:00:35 PM
|
There's no TTT-related error there, though the "couldn't include" stuff might point to a gmod issue.
I've just tested the script you posted and it works fine for me. So it looks like it's some sort of install/configuration issue with gmod or the server. Maybe scriptenforcer.
So should I disable script enforcer? Or reinstall the gmod server?
|
|
|
6
|
Other / Trouble in Terrorist Town / Re: AK47 script throws an error
|
on: July 15, 2011, 06:07:15 PM
|
Here are some lua errors that pop up after lua is inited: Lua initialized (Lua 5.1) LuaGetfile: Not Loading autorun/ Couldn't include file 'autorun/' (File not found) (<nowhere>) LuaGetfile: Not Loading autorun/client/ Couldn't include file 'autorun/client/' (File not found) (<nowhere>) LuaGetfile: Not Loading postprocess/ Couldn't include file 'postprocess/' (File not found) (<nowhere>) LuaGetfile: Not Loading vgui/ Couldn't include file 'vgui/' (File not found) (<nowhere>) Included TTT language file: chef.lua Included TTT language file: english.lua Registering gamemode 'fretta' derived from 'base' Registering gamemode 'terrortown' derived from 'fretta' TTT Client initializing... Sending 12 'User Info' ConVars to server (cl_spewuserinfoconvars to see) Scanning for downloaded fonts.. Reloading Particles.. Hey 'k9rosie' - You're in the 'superadmin' group on this server. Client "[Red Vinyl] k9rosie" spawned in server (72.177.93.240:27005)<STEAM_0:1:25111336>. Welcome to Red Vinyl [TTT] [FastDL]! We're playing ttt_minecraft_b3. Warning: Unhandled usermessage 'ULStart' Warning: Unhandled usermessage 'ULPacket' W
|
|
|
9
|
Other / Trouble in Terrorist Town / Re: AK47 script throws an error
|
on: July 15, 2011, 12:54:50 AM
|
If i remember correctly, this is to do with CSS mounting incorrectly, try reinstalling the CSS content on your server.
Seriously? I had to wait 2 days for technical support to install the CS:S content and now they have to install it again?
|
|
|
12
|
Other / Trouble in Terrorist Town / AK47 script throws an error
|
on: July 12, 2011, 02:49:14 PM
|
This is pretty much the M4A1 script with changed sound, model, and vector values to match the ak47. Whenever I pick one up, my gui dissapears and throws the following error: [terrortown\gamemode\cl_wepswitch.lua:101] attempt to call method 'Ammo1' (a nil value)(Hook: HUDPaint)
The ammo values are the same from the M4A1 and the M4A1 runs fine.
if SERVER then
AddCSLuaFile( "shared.lua" ) end
SWEP.HoldType = "ar2"
if CLIENT then
SWEP.PrintName = "AK47" SWEP.Slot = 2
SWEP.Icon = "VGUI/ttt/icon_ak47" end
SWEP.Base = "weapon_tttbase" SWEP.Spawnable = true SWEP.AdminSpawnable = true
SWEP.Kind = WEAPON_HEAVY
SWEP.Primary.Delay = 0.19 SWEP.Primary.Recoil = 1.6 SWEP.Primary.Automatic = true SWEP.Primary.Ammo = "Pistol" SWEP.Primary.Damage = 23 SWEP.Primary.Cone = 0.02 SWEP.Primary.ClipSize = 20 SWEP.Primary.ClipMax = 60 SWEP.Primary.DefaultClip = 20 SWEP.AutoSpawnable = true SWEP.AmmoEnt = "item_ammo_pistol_ttt" SWEP.ViewModel = "models/weapons/v_rif_ak47.mdl" SWEP.WorldModel = "models/weapons/w_rif_ak47.mdl"
SWEP.Primary.Sound = Sound( "Weapon_AK47.Single" )
SWEP.IronSightsPos = Vector( 6.05, -5, 2.4 ) SWEP.IronSightsAng = Vector( 2.2, -0.1, 0 )
function SWEP:SetZoom(state) if CLIENT then return end if state then self.Owner:SetFOV(35, 0.5) else self.Owner:SetFOV(0, 0.2) end end
-- Add some zoom to ironsights for this gun function SWEP:SecondaryAttack() if not self.IronSightsPos then return end if self.Weapon:GetNextSecondaryFire() > CurTime() then return end bIronsights = not self:GetIronsights() self:SetIronsights( bIronsights ) if SERVER then self:SetZoom(bIronsights) end self.Weapon:SetNextSecondaryFire(CurTime() + 0.3) end
function SWEP:PreDrop() self:SetZoom(false) self:SetIronsights(false) return self.BaseClass.PreDrop(self) end
function SWEP:Reload() self.Weapon:DefaultReload( ACT_VM_RELOAD ); self:SetIronsights( false ) self:SetZoom(false) end
function SWEP:Holster() self:SetIronsights(false) self:SetZoom(false) return true end
|
|
|
13
|
Other / Trouble in Terrorist Town / Re: Are vanilla servers generally what people want?
|
on: July 11, 2011, 12:04:44 AM
|
I've never been a huge fan of custom content, but if it actually adds to the game and is balanced, I can tolerate it. I do not, however, even bother tolerating the suicide bomb or one hit kill knife. They are not balanced and merely serve to get traitors easy kills without any real skill or manipulation involved--and the traitors do not really need any more advantages over the innocents than vanilla TTT provides them. As such, I have all servers with such content on my blacklist (and, unfortunately, this leaves me with very little choice in servers, never mind populated servers).
If you just want to be another generic modified server appealing to people whose TTT experience revolves solely around killing people as traitor, then sure, throw unbalanced weapons in. If you want to take the game seriously, then please do not do so. I personally would love to have another vanilla server to play on (as I do not have many valid options). Other things that are appealing are decent admins that do not abuse and do not take very matter into their own hands, and also decent rules that do not restrict innocents from killing obvious traitors.
Edit: Oh yes, and also keeping the maximum player count as 16 or below is very nice. People just don't take the game seriously and it can be hard to follow otherwise.
Just to be honest with you, I made the knife an instant kill on my server. But to balance it out is there away for DNA to never decay and for the DNA to avoid Decoys?
|
|
|
17
|
Other / Trouble in Terrorist Town / Re: Guns and other weapons don't feel like using gravity AND Fretta voting dsnt work
|
on: July 09, 2011, 02:35:28 PM
|
If you do it the correct way it might work, I know many people try this and it doesnt work out. But honestly if your hoster wont answer your support ticketd theres probably gonna be a lot more issues in the future. Your much much better off getting a new host, that way you wouldnt have to deal with these problems or hopefully future ones.
What do you mean by 'correct way'? EDIT: Also, is this client side or is this server side? I pulled this from the developer console: Mounting hl2.. OK Mounting cstrike.. OK Mounting dod.. SteamMountDepot: Error SteamMountFilesystem 300 - (dependency 4 (301)) SteamMountFilesystem(869,301,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair OK Mounting ep2.. SteamMountDepot: Error SteamMountFilesystem 420 - (dependency 2 (421)) SteamMountFilesystem(869,421,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair SteamMountDepot: Error SteamMountFilesystem 420 - (dependency 3 (423)) SteamMountFilesystem(869,423,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair SteamMountDepot: Error SteamMountFilesystem 420 - (dependency 4 (422)) SteamMountFilesystem(869,422,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair SteamMountDepot: Error SteamMountFilesystem 420 - (dependency 5 (308)) SteamMountFilesystem(869,308,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair SteamMountDepot: Error SteamMountFilesystem 420 - (dependency 12 (213)) SteamMountFilesystem(869,213,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair OK Mounting tf.. SteamMountDepot: Error SteamMountFilesystem 440 - (dependency 4 (441)) SteamMountFilesystem(869,441,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair SteamMountDepot: Error SteamMountFilesystem 440 - (dependency 5 (442)) SteamMountFilesystem(869,442,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair OK Mounting episodic.. SteamMountDepot: Error SteamMountFilesystem 380 - (dependency 6 (308)) SteamMountFilesystem(869,308,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair SteamMountDepot: Error SteamMountFilesystem 380 - (dependency 7 (213)) SteamMountFilesystem(869,213,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair OK Mounting hl2mp.. SteamMountDepot: Error SteamMountFilesystem 320 - (dependency 4 (321)) SteamMountFilesystem(869,321,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair OK Mounting portal.. OK Mounting lostcoast.. OK Mounting hl1.. SteamMountDepot: Error SteamMountFilesystem 280 - (dependency 4 (281)) SteamMountFilesystem(869,281,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair OK Mounting hl1mp.. SteamMountDepot: Error SteamMountFilesystem 360 - (dependency 4 (281)) SteamMountFilesystem(869,281,0xb55d9c61=,0xb55d9d60) failed with error 116: Cache needs repair OK Mounting zeno_clash.. No permission Mounting left4dead2.. Disabled Mounting left4dead.. Disabled Mounting diprip.. Disabled Mounting zps.. Disabled Mounting pvkii.. Disabled M
If it's server side then CS:S is mounting it, but not using the files. I'm so confused.
|
|
|
|
|