Which hook is called after addons are loaded?

I created a relatively simple entity spawning script but, it’s having issues with spawning since addons are loaded after this script is ran.

I put this in the autorun/server directory of lua



hook.Add( "PostGamemodeLoaded", "SpawnPiano", function()
	local ent = ents.Create( [[gmt_instrument_piano]] )
	ent:GetPhysicsObject():EnableMotion( false )
	ent:SetAngles( Angle(0, 140, 0) )
	ent:SetPos( Vector( -154, 100, 17.5 ) )
	ent:Spawn()
end)


Is there anything else called after PostGamemodeLoaded?

Call it plainly in an addon file without a hook after the entity has been created

Use

GM/InitPostEntity for entity spawning

And don’t use the square brackets for a string, just use “double quotes” or ‘single quotes’.

There’s nothing wrong with using square brackets.