-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a71311e
commit 2fcd762
Showing
4 changed files
with
70 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
if IS_CHAR_SITTING_IN_ANY_CAR $scplayer | ||
then | ||
int myCar = STORE_CAR_CHAR_IS_IN_NO_SAVE $scplayer | ||
int myCarID = SAMP_GET_CAR_ID myCar | ||
// Construct a Bitstream holding a SampRpc.DamageCar data | ||
int myBitStream = SAMP_RAKNET_CREATE_BITSTREAM // create bitstream object with class Bitstream | ||
SAMP_RAKNET_BITSTREAM_WRITE myBitStream {value} myCarID {datatype} SampBitStreamDataType.Short {datasize} DataTypeSize.Short // CarID | ||
SAMP_RAKNET_BITSTREAM_WRITE myBitStream {value} 0xFFFFFFFF {datatype} SampBitStreamDataType.Int {datasize} DataTypeSize.Int // bodyflags | ||
SAMP_RAKNET_BITSTREAM_WRITE myBitStream {value} 0xFFFFFFFF {datatype} SampBitStreamDataType.Int {datasize} DataTypeSize.Int // doorflags | ||
SAMP_RAKNET_BITSTREAM_WRITE myBitStream {value} 0xFF {datatype} SampBitStreamDataType.Byte {datasize} DataTypeSize.Byte // lightflags | ||
SAMP_RAKNET_BITSTREAM_WRITE myBitStream {value} 0xFF {datatype} SampBitStreamDataType.Byte {datasize} DataTypeSize.Byte // wheelflags | ||
// | ||
// Bitstream is ready to be transmitted | ||
SAMP_RAKNET_SEND_BITSTREAM_AS_RPC_TO_SERVER {rpcid} SampRpc.DamageCar {bitstream} myBitStream {priorityid} SampPriority.Medium {reliabilityid} SampReliability.ReliableOrdered {orderingchannel} 0 {shifttimestamp} 0 | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
int myRCONCommand = ALLOCATE_MEMORY 58 | ||
myRCONCommand = STRING_FORMAT "This_is_a_very_long_String_Example_we_will_send_to_Server" | ||
int textLength = SF_STRLEN myRCONCommand | ||
// Construct a Bitstream holding a SampRpc.RconCommand data | ||
int myBitStream = SAMP_RAKNET_CREATE_BITSTREAM // create bitstream object with class Bitstream | ||
SAMP_RAKNET_BITSTREAM_WRITE myBitStream {value} SampRpc.RconCommand {datatype} SampBitStreamDataType.Byte {datasize} DataTypeSize.Byte // PacketID | ||
SAMP_RAKNET_BITSTREAM_WRITE myBitStream {value} textLength {datatype} SampBitStreamDataType.Int {datasize} DataTypeSize.Int // TextLength | ||
SAMP_RAKNET_BITSTREAM_WRITE myBitStream {value} myRCONCommand {datatype} SampBitStreamDataType.Array {datasize} textLength // CMDText | ||
// | ||
// Bitstream is ready to be transmitted | ||
SAMP_RAKNET_SEND_RAW_BITSTREAM_TO_SERVER {bitstream} myBitStream {priorityid} SampPriority.Medium {reliabilityid} SampReliability.ReliableOrdered {orderingchannel} 0 | ||
FREE_MEMORY myRCONCommand |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
0.868 | ||
0.869 |