[Tutorial] RPC - Pawn.RakNet
#21

Nice tutorial, it will surely help people understand how server communicate with client using RakNet and how to work with Pawn.RakNet.

Quote:
Originally Posted by Jelly23
View Post
I will be updating the list as I can, I know some RPCs are missing, but won't be for long.

Information about reliability updated.
I looked into samp-server, it looks like RPC ID 44 (CreateObject) contains all these stuff.
If object is attached to a vehicle or another object it will write to BitStream those stuff you wrote in your RPC List.
Code:
float AttachOffsetX, float AttachOffsetY, float AttachOffsetZ, float AttachRotX, float AttachRotY, float AttachRotZ, BYTE SyncRotation
If it is not attached, it won't contain these parameters.

About materials, both MaterialText and Material are being used with the same CreateObject RPC.
All 16 materials slots will be stored in the same RPC.

Parameters:
If it is Material:
Code:
BYTE byteMethod; // (always 1 here, because it is material)
BYTE byteSlot;
WORD wModelID;
char szTXDName[65];
char szTextureName[65];
DWORD dwMaterialColor;
Else if it is MaterialText:
Code:
BYTE byteMethod; // (always 2 here, because it is materialtext)
BYTE byteSlot;
BYTE byteMaterialSize;
char szFont[65];
BYTE byteFontSize;
BYTE byteBold;
DWORD dwFontColor;
DWORD dwBackgroundColor;
BYTE byteAlign;
And your ShowTextDraw - ID: 134 is not correct.
Correct parameters:
Code:
BYTE byteFlags;
float fLetterWidth;
float fLetterHeight;
DWORD dwLetterColor;
float fLineWidth;
float fLineHeight;
DWORD dwBoxColor;
BYTE byteShadow;
BYTE byteOutline;
DWORD dwBackgroundColor;
BYTE byteStyle;
BYTE byteSelectable;
float fX;
float fY;
WORD wModelID;
float fRotX;
float fRotY;
float fRotZ;
float fZoom;
WORD wColor1;
WORD wColor2;
char szText[1024];
Hope that helps.
Reply


Messages In This Thread
RPC - Pawn.RakNet - by Jelly23 - 15.11.2017, 14:26
Re: RPC - Pawn.RakNet - by Zeth - 15.11.2017, 14:34
Re: RPC - Pawn.RakNet - by StrikerZ - 15.11.2017, 14:35
Re: RPC - Pawn.RakNet - by HydraHumza - 15.11.2017, 14:45
Re: RPC - Pawn.RakNet - by DeitY - 15.11.2017, 16:47
Re: RPC - Pawn.RakNet - by Logic_ - 15.11.2017, 17:15
Re: RPC - Pawn.RakNet - by Eoussama - 15.11.2017, 18:42
Re: RPC - Pawn.RakNet - by RIDE2DAY - 15.11.2017, 19:52
Re: RPC - Pawn.RakNet - by Jelly23 - 18.11.2017, 17:04
Re: RPC - Pawn.RakNet - by Dayrion - 18.11.2017, 20:10
Re: RPC - Pawn.RakNet - by Jelly23 - 19.11.2017, 14:41
Re: RPC - Pawn.RakNet - by Marllun - 20.11.2017, 13:51
Re: RPC - Pawn.RakNet - by Dayrion - 20.11.2017, 14:08
Re: RPC - Pawn.RakNet - by Jelly23 - 20.11.2017, 15:43
Re: RPC - Pawn.RakNet - by TiW - 20.11.2017, 15:46
Re: RPC - Pawn.RakNet - by Jelly23 - 20.11.2017, 15:51
Re: RPC - Pawn.RakNet - by Dayrion - 20.11.2017, 22:26
Re: RPC - Pawn.RakNet - by Manyula - 24.11.2017, 21:16
Re: RPC - Pawn.RakNet - by Jelly23 - 28.11.2017, 20:38
Re: RPC - Pawn.RakNet - by Marllun - 02.12.2017, 14:27
Re: RPC - Pawn.RakNet - by Aliassassin123456 - 09.12.2017, 06:20
Re: RPC - Pawn.RakNet - by Jelly23 - 13.12.2017, 21:51
Re: RPC - Pawn.RakNet - by PRoleplay - 05.05.2020, 16:24
Re: RPC - Pawn.RakNet - by JasonTheMan - 12.05.2020, 08:57

Forum Jump:


Users browsing this thread: 1 Guest(s)