Category:DModelSelect

From Garry's Mod
Jump to: navigation, search

Contents

DescriptionPanelPage

This feature is deprecated.
You should avoid using it as it may be removed in a future version.

This is derived from the deprecated DPanelList.
A vertical list of models.

Inherited Functions

Inherits the following functions from DPanelSelect and its parents up to 3 levels deep:


Examples

Example

Creates a DModelSelect within a DFrame and adds four models.

-- Create a table of models
local models = {
	["models/props_c17/oildrum001_explosive.mdl"] = {}, 
	["models/props_c17/oildrum001.mdl"] = {}, 
	["models/props_junk/TrafficCone001a.mdl"] = {},
	["models/props_c17/gravestone004a.mdl"] = {}
}
	
local frame = vgui.Create("DFrame")
frame:SetSize(220, 220)
frame:SetTitle("DModelSelect Example")
frame:MakePopup()
frame:Center()

local mselect = vgui.Create( "DModelSelect", frame ) 
mselect:SetModelList( models, "", false, true )
mselect:SetSize(150, 150)
mselect:Center()

Output:

See Preview

Pages in category "DModelSelect"

The following 2 pages are in this category, out of 2 total.

Personal tools
Navigation