Revision Difference
undo.Finish#516001
<function name="Finish" parent="undo" type="libraryfunc">
<description>Completes an undo entry, and registers it with the player's client</description>
<realm>Shared</realm>
</function>
⤶
{{Example⤶
| Description = This example creates a prop_physics, and adds it to the players undo list.⤶
| Code = prop = ents.Create("prop_physics")⤶
⤶
<example>⤶
<description>This example creates a prop_physics, and adds it to the players undo list.</description>⤶
<code>⤶
prop = ents.Create("prop_physics")⤶
prop:SetModel("models/props_junk/wood_crate001a.mdl")
prop:Spawn()
undo.Create("prop")
```⤶
⤶
undo.AddEntity(prop)⤶
undo.AddEntity(prop)⤶
undo.SetPlayer(Player)
```⤶
⤶
undo.Finish()⤶
}}undo.Finish()⤶
</code>⤶
⤶
</example>