Garry's Mod Wiki

Revision Difference

game.SetSkillLevel#515058

<function name="SetSkillLevel" parent="game" type="libraryfunc">⤶ <description>⤶ Sets the difficulty level of the game, can be retrieved with <page>game.GetSkillLevel</page>.⤶ ⤶ This will automatically change whenever the "skill" convar is modified serverside.⤶ ⤶ <bug issue="3491">This function will not work if the skill convar doesn't match the targeted value. To work around this, you must use RunConsoleCommand("skill", num) alongside this function.</bug>⤶ </description>⤶ <realm>Server</realm>⤶ <args>⤶ <arg name="level" type="number">The difficulty level, Easy( 1 ), Normal( 2 ), Hard( 3 ).</arg>⤶ </args>⤶ </function>⤶ ⤶