So, what does the function player.Alpha does?
I need to use player.SetAlpha(0,0); instead of player.Alpha = 0;
If I use player.Alpha = 0; It prints out the error as:-
Member variable not found.
I used Message(player.Alpha); but still the same(^^) error comes.
I want to know what does that player.Alpha do.
If player.Alpha is exists then its just a readonly function
onPlayerSpawn(player)
{
print(player.Alpha);
}
We can change alpha through player.SetAlpha as already discussed here (http://forum.vc-mp.org/?topic=1640.0)
QuoteI used Message(player.Alpha); but still the same(^^) error comes.
Any Idea?
Quote from: KAKAN on Oct 12, 2015, 06:32 AMQuoteI used Message(player.Alpha); but still the same(^^) error comes.
Any Idea?
You are returning integer in Message since it needs string/instance. Use
Message("alpha: "+player.Alpha);
Make sure player isn't null
(player == null) ? Message("Unknown buddy") : Message(player.Alpha+"");
Why all the concatenation with strings. What's wrong with a good old .tostring()?
It exists? Because as far as I remember in the unofficial forum I asked why I got that error and it didn't exist.
Quote from: NE.CrystalBlue on Oct 13, 2015, 12:31 PMIt exists? Because as far as I remember in the unofficial forum I asked why I got that error and it didn't exist.
yea, it does. I use it in my script. Just forgot about it. :/