Garry's Mod Wiki

undo.Finish

undo.Finish( string NiceText )

Description

Completes an undo entry, and registers it with the player's client

Arguments

1 string NiceText
Text that appears in the player's undo history

Example

This example creates a prop_physics, and adds it to the players undo list.

prop = ents.Create("prop_physics") prop:SetModel("models/props_junk/wood_crate001a.mdl") prop:Spawn() undo.Create("prop") undo.AddEntity(prop) undo.SetPlayer(Player) undo.Finish( "Prop (" .. prop:GetModel() .. ")" )

Page Links


Special Pages


Wikis

?

Render Time: 166ms

DB GetPage 18
Generate Html 2
SaveChanges (1) 133
Render Body 0
Render Sidebar 11