SA-MP Forums Archive
Missing operator in includes - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Missing operator in includes (/showthread.php?tid=271768)



Missing operator in includes - RSX - 25.07.2011

I just stumbled upon the fact that you can assign a value to a float, but you get a warning when you do the opposite, so did the sa-mp team forget to add this operator in includes :
pawn Код:
stock operator=(Float:oper1)
    return floatround(oper1);
Which handles it as it should and repairs the warning.


Re: Missing operator in includes - Mauzen - 25.07.2011

Hehe, simple but effective. Should be added to future float.incs in my opinion.


Re: Missing operator in includes - RSX - 26.07.2011

Yes, that's exactly what I'm thinking.


Re: Missing operator in includes - RSX - 26.07.2011

Well, I know you're right, however I still find this needed in some form of default include.