Garry's Mod Wiki

Panel:SetActionFunction

Panel:SetActionFunction( function func )

Description

We advise against using this. It may be changed or removed in a future update. Does nothing at all.

Used in Button to call a function when the button is clicked and in Slider when the value changes.

Arguments

1 function func
Function to call when the Button is clicked or the Slider value is changed.

Arguments given are:

  • Panel self - The panel itself
  • string action - "Command" on button press, "SliderMoved" on slider move.
  • number val - The new value of the Slider. Will always equal 0 for buttons.
  • number zed - Always equals 0.

Page Links


Special Pages


Wikis

?

Render Time: 89ms

DB GetPage 36
Generate Html 10
SaveChanges (1) 27
Render Body 0
Render Sidebar 13