- Initiateur de la discussion
Anthonym05
Geek
- Messages
- 46
- Score réaction
- 0
- Points
- 95
Quand je fait clique droit avec mon swep sa me met cette erreur:
[ERROR] addons/atlantacity_portefeulles/lua/weapons/portefeuilles.lua:31: attempt to index global 'vgui' (a nil value)
1. panel - addons/atlantacity_portefeulles/lua/weapons/portefeuilles.lua:31
2. unknown - addons/atlantacity_portefeulles/lua/weapons/portefeuilles.lua:31
Le code:
SWEP.PrintName = "PorteMonnaie"
SWEP.Author = "Anthonym"
SWEP.Instructions = "Clique droit pour ouvrir le porte monnaie"
SWEP.Spawnable = true
SWEP.AdminOnly = true
SWEP.Category = "AtlantaCity_PorteMonnaie"
SWEP.Primary.ClipSize = -1
SWEP.Primary.DefaultClip = -1
SWEP.Primary.Automatic = true
SWEP.Primary.Ammo = "none"
SWEP.Secondary.ClipSize = -1
SWEP.Secondary.DefaultClip = -1
SWEP.Secondary.Automatic = false
SWEP.Secondary.Ammo = "none"
SWEP.Weight = 5
SWEP.AutoSwitchTo = false
SWEP.AutoSwitchFrom = false
SWEP.Slot = 1
SWEP.SlotPos = 2
SWEP.DrawAmmo = false
SWEP.DrawCrosshair = false
function SWEP:SecondaryAttack()
local Panel = vgui.Create( "DFrame" )
Panel:Center()
Panel:SetSize( 300, 200 )
Panel:SetTitle(" ")
Panel:SetDraggable( false )
Panel:ShowCloseButton(true)
Panel:MakePopup()
function Panelaint( w, h )
draw.RoundedBox( 8, 0, 0, w, h, Color(83,83,83,230) )
end
end
surface.CreateFont( "police-1", {
font = "Arial",
size = 30,
weight = 500,
blursize = 0,
scanlines = 0,
antialias = true,
})
merci d'avence
Cordialement,
Anthonym
[ERROR] addons/atlantacity_portefeulles/lua/weapons/portefeuilles.lua:31: attempt to index global 'vgui' (a nil value)
1. panel - addons/atlantacity_portefeulles/lua/weapons/portefeuilles.lua:31
2. unknown - addons/atlantacity_portefeulles/lua/weapons/portefeuilles.lua:31
Le code:
SWEP.PrintName = "PorteMonnaie"
SWEP.Author = "Anthonym"
SWEP.Instructions = "Clique droit pour ouvrir le porte monnaie"
SWEP.Spawnable = true
SWEP.AdminOnly = true
SWEP.Category = "AtlantaCity_PorteMonnaie"
SWEP.Primary.ClipSize = -1
SWEP.Primary.DefaultClip = -1
SWEP.Primary.Automatic = true
SWEP.Primary.Ammo = "none"
SWEP.Secondary.ClipSize = -1
SWEP.Secondary.DefaultClip = -1
SWEP.Secondary.Automatic = false
SWEP.Secondary.Ammo = "none"
SWEP.Weight = 5
SWEP.AutoSwitchTo = false
SWEP.AutoSwitchFrom = false
SWEP.Slot = 1
SWEP.SlotPos = 2
SWEP.DrawAmmo = false
SWEP.DrawCrosshair = false
function SWEP:SecondaryAttack()
local Panel = vgui.Create( "DFrame" )
Panel:Center()
Panel:SetSize( 300, 200 )
Panel:SetTitle(" ")
Panel:SetDraggable( false )
Panel:ShowCloseButton(true)
Panel:MakePopup()
function Panelaint( w, h )
draw.RoundedBox( 8, 0, 0, w, h, Color(83,83,83,230) )
end
end
surface.CreateFont( "police-1", {
font = "Arial",
size = 30,
weight = 500,
blursize = 0,
scanlines = 0,
antialias = true,
})
merci d'avence
Cordialement,
Anthonym