What command do I use to change a class’ color, including alpha? I’ve looked across a ton of class tables and I’ve found models (CLASS.PlayerModel), health (CLASS.StartHealth), speed (CLASS.RunSpeed), but no PlayerColor.
You’re using Fretta right? There is no color for specific classes as far as I know. But you could always set the color on spawn in the CLASS:OnSpawn() function
Which would be what? Sorry to sound like a noob, but this is literally my first steps in Lua, and this is the Noob section…
In the Class file you have functions that will be called for the class only, such as CLASS:OnSpawn(), inside you can set the players color every time they spawn with this:
ply:SetColor(R, G, B, A)
Just change R,G,B,A to what you want.
The snippet works, but only if I remove
function CLASS:Loadout( pl ) pl:Give( "weapon_fish" ) end
I don’t see why they would be conflicting with each other, but they are. If the player is given a fish, they can’t be colored.
Use ply and not pl, or change the above user’s snippet to use pl.
Why? You can call the argument whatever you want, it won’t affect an argument from a different method.
Oh, nevermind then. I see what you mean now lol.
Hey, do you think you could help me out with my fretta problems? I made a thread in this section.