s&
newspaperAbout
infoAbout s&box newspaperLatest News published_with_changesChanges mapRoadmap monitoringMetrics
gamesGames
sports_esportsBrowse Games rocketDiscover Games
business_centerWorkshop
sports_esportsGames landscapeMaps chairModels textureMaterials apparelClothing constructionMore..
forumForum docsDocs
docsDocumentation dashboardApi Reference schoolTutorials
inputLog in with Steam chevron_leftChange Language
简体中文EnglishРусскийEspañolPortuguês-BrasilDeutsch日本語FrançaisPolskiTürkçe한국어PirateItalianoไทย繁體中文УкраїнськаČeštinaNederlandsMagyarDanskSuomiSvenskaNorskΕλληνικάRomânăБългарскиTiếng ViệtBahasa IndonesiaEspañol-Latinoaméricaالعربية
Api
Components
Prop
chevron_left Components
class
Prop

Constructors

functionsProp

Properties

data_objectBodyGroupslockHasBodyGroupslockHasMaterialGroupsdata_objectHealthdata_objectIsExplosivedata_objectIsFlammabledata_objectIsOnFiredata_objectIsStaticdata_objectLastAttackerdata_objectMaterialGroupdata_objectModeldata_objectOnPropBreakdata_objectOnPropTakeDamagedata_objectStartAsleepdata_objectTint

Methods

functionsBreakfunctionsCreateExplosionfunctionsCreateGibsfunctionsIgnitefunctionsKillfunctionsNetworkCreateGibsfunctionsOnDamage
Prop
A prop is defined by its model. The model can define its health and what happens when it breaks. This component is designed to be easy to use - since you only need to define the model. Although you can access the procedural (hidden) components, they aren't saved, so it's a waste of time.
class Sandbox .account_tree extends Component
Sandbox.Engine

build Constructors 1

Prop ()

data_object Properties 15

BodyGroups
UInt64
HasBodyGroups
bool
HasMaterialGroups
bool
Health
float
IsExplosive
bool
True if this prop will explode when destroyed.
IsFlammable
bool
True if this prop can be set on fire.
IsOnFire
bool
IsStatic
bool
If the prop is static - it won't have dynamic physics. This is usually used for things that you want to be breakable but don't move. Like fences and stuff.
LastAttacker
GameObject
MaterialGroup
string
Model
Model
OnPropBreak
Action
OnPropTakeDamage
Action`1
StartAsleep
bool
Physics will be asleep until it's woken up.
Tint
Color

functions Methods 7

Break ()
Delete this component and split into the procedural components that this prop created.
CreateExplosion ()
CreateGibs ()
List`1
Create the gibs and return them.
Ignite ()
Kill ()
NetworkCreateGibs ()
Create the gibs for this prop breaking, over the network. This causes clients to spawn the gibs too.
OnDamage (damage)

Inheritance

Component
Prop
Gib
people
Log in to reply
You can't reply if you're not logged in. That would be crazy.
  • News
  • Docs
  • Metrics
  • FAQ
  • Forum
  • Discord
  • Twitter