SA-MP Forums Archive
memcpy problem - 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)
+--- Thread: memcpy problem (/showthread.php?tid=639181)



memcpy problem - RakeDW - 12.08.2017

http://prntscr.com/g7px5j - OnPlayerConnect
http://prntscr.com/g7pxaq - OnGameModeInit
ofc PlayerData[MAX_PLAYERS + 1][ENUM_PLAYER_DATA]

Tried sizeof PlayerData[][] and without any brackets []


Re: memcpy problem - Vince - 12.08.2017

Why use memcpy at all? Both arrays are the same size so it should simply be a matter of
Код:
PlayerData[playerid] = PlayerData[MAX_PLAYERS];
Also please don't make screenshots of text. Copy-pasting isn't that hard.


Re: memcpy problem - RakeDW - 12.08.2017

I know that way (PlayerData[playerid] = PlayerData[MAX_PLAYERS])

but i heard that memcpy way is 'faster'

anyway tnx