SA-MP Forums

Go Back   SA-MP Forums > SA-MP > News and Updates

Thread Tools Display Modes
Old 25/07/2011, 04:09 AM   #1
SA-MP Developer
Join Date: Apr 2005
Posts: 1,180
Reputation: 2891
Exclamation SA-MP 0.3c R3/R4/R5 server update

This update is for SA-MP server owners only

We are issuing a server update for SA-MP 0.3c to address some security concerns.

If updating from an existing 0.3c R1/R2 server: you can update simply by replacing the 'samp03svr' file on linux or 'samp-server.exe' file on Windows found in the 0.3c R5 server download package.

SA-MP 0.3c R5 server

- The server crash vulnerabilities, described as resolved in the 0.3c R3/R4 server, were not completely fixed. We are making the 0.3c R5 server available. These server crash vulnerabilities only effect the Linux version of the SA-MP 0.3c server. Both Windows and Linux versions of the SA-MP server are being updated to 0.3c R5 for server version consistency.

SA-MP 0.3c R4 server

- Another denial of service vulnerability was discovered after the 0.3c R3 server release and has been fixed in the 0.3c R4 server.
- Fixes an issue with GetPlayerSurfingObjectID() returning the wrong object ID.
- Fixes a few minor problems with the format() function in pawn.

New pawn natives:
pawn Code:
native GetPlayerNetworkStats(playerid, retstr[], size);
native GetNetworkStats(retstr[], size);

The above functions return a string similar to the information seen in the player's F5 stats. It is the server's version of the network statistics which includes a list of things like network Packetloss, Upload/Download rates etc. This information might be useful in determining network problems for specific players, or for the entire server. If you are interested in these functions please see the netstats.pwn filterscript included with the Windows server package.

SA-MP 0.3c R3 server

- Fixes a denial of service vulnerability on SA-MP linux servers where a remote attacker could send a specially crafted packet which would trigger a debug assertion in SA-MP's networking layer; causing the server to shut down.

New pawn natives:
pawn Code:
native GetPlayerCameraMode(playerid);
Returns the current GTA camera mode for the requested player. The camera modes are useful in determining whether a player is aiming, doing a passenger driveby etc.

pawn Code:
native Float:GetPlayerDistanceFromPoint(playerid, Float:X, Float:Y, Float:Z);
native Float:GetVehicleDistanceFromPoint(vehicleid, Float:X, Float:Y, Float:Z);
The above functions can be used as fast alternatives to calculating distances in pawn. It is still preferable to use IsPlayerInRangeOfPoint() if you don't require the exact distance.

pawn Code:
native GetPlayerSurfingObjectID(playerid);
GetPlayerSurfingObjectID is similar to GetPlayerSurfingVehicleID. If the player is standing on a global moving object, the ID of the object will be returned. If the player is not surfing a moving object, it will return INVALID_OBJECT_ID.

New callback:
pawn Code:
forward OnUnoccupiedVehicleUpdate(vehicleid, playerid, passenger_seat);
This callback is called when a player updates the position of a vehicle they're not driving. This can happen outside of the vehicle or when the player is a passenger of a vehicle that has no driver.


SA-MP 0.3c R5 Linux Server:
SA-MP 0.3c R5 Windows Server:

Update 25/07/2011 There was a small issue regarding space padding in the format() function in the original 0.3c R3 release. If you happened to download this version, please download the above 0.3c R3-1 server.
Update 27/07/2011 0.3c R3 server was updated to SA-MP 0.3c R4.
Update 28/07/2011 0.3c R4 server was updated to SA-MP 0.3c R5.

Last edited by Kalcor; 28/07/2011 at 03:49 PM.
Kalcor is offline   Reply With Quote
Old 25/07/2011, 04:26 AM   #2
Retardedwolf's Avatar
Join Date: Jun 2009
Posts: 1,466
Reputation: 60
Default Re: SA-MP 0.3c R3 server update

Seems like OnUnoccupiedVehicleUpdate could help some Roleplay servers, thanks for the update Kalcor.
Retardedwolf is offline   Reply With Quote
Old 25/07/2011, 04:28 AM   #3
Join Date: Mar 2008
Location: New Zealand
Posts: 2,629
Reputation: 410
Default Re: SA-MP 0.3c R3 server update

Thanks for the release Kalcor, great as always . The GetPlayerSurfingObjectID will become quite useful.
[HiC]TheKiller is offline   Reply With Quote
Old 25/07/2011, 04:49 AM   #4
willsuckformoney's Avatar
Join Date: Dec 2009
Posts: 1,492
Reputation: 65
Default Re: SA-MP 0.3c R3 server update

Jizzed my pants. Good job
Fuck the system.
willsuckformoney is offline   Reply With Quote
Old 25/07/2011, 05:15 AM   #5
Toni's Avatar
Join Date: Aug 2009
Location: United States
Posts: 1,464
Reputation: 162
Default Re: SA-MP 0.3c R3 server update

Great update. I'm looking to more camera functions in the future hopefully those are nice, but maybe some that can be used to create easy made moving cameras? Built-in functions would be much better than those scripts with math equations and server lag timers.
Toni is offline   Reply With Quote
Old 25/07/2011, 06:33 AM   #6
Big Clucker
Join Date: Apr 2011
Location: Bacau/Roumanie
Posts: 149
Reputation: 1
Default Re: SA-MP 0.3c R3 server update

truly awesome.
we'll finally get rid of the god damn server attackers
Paul.eboy is offline   Reply With Quote
Old 25/07/2011, 07:28 AM   #7
Join Date: Jan 2009
Posts: 6,129
Reputation: 1127
Default Re: SA-MP 0.3c R3 server update

Added most of the new functions to the wiki (, with the exception of GetPlayerCameraMode because I can't find any defines (like CAMERA_MODE_AIMING) in
Calgon is offline   Reply With Quote
Old 25/07/2011, 07:32 AM   #8
Huge Clucker
Whitetiger's Avatar
Join Date: Nov 2007
Posts: 406
Reputation: 156
Default Re: SA-MP 0.3c R3 server update

I put GetPlayerCameraMode (in a SendClientMessage) in OnPlayerUpdate with the default LVDM.amx on my server, The server crashes within a minute, and doesn't crash when I unload this test FS.

pawn Code:
#include <a_samp>

public OnPlayerUpdate(playerid)
    new string[128];
    format(string, sizeof(string), "%d", GetPlayerCameraMode(playerid));
    SendClientMessage(playerid, 0x0FFFFFFFA, string);
    return 1;

Author of SA-MP AC

Whitetiger is offline   Reply With Quote
Old 25/07/2011, 07:47 AM   #9
Join Date: Nov 2008
Location: England
Posts: 1,843
Reputation: 52
Default Re: SA-MP 0.3c R3 server update

Thanks for the update. What does GetPlayerCameraMode actually return? A string, float, or integer?
Burridge is online now   Reply With Quote
Old 25/07/2011, 07:50 AM   #10
Beta Tester
JernejL's Avatar
Join Date: Jan 2006
Location: Slovenia
Posts: 580
Reputation: 418
Default Re: SA-MP 0.3c R3 server update

It returns an integer.

Some camera modes i found:

camera 3: tram/train passenger entering camera (??!), tram/train driver camera
camera 4: normal onfoot chasing camera (several variable distances)
camera 7: sniper aiming mode
camera 8: rpg aiming mode
camera 16: front closeup camera attached on car (+skimmer+heli+airplane)
camera 18: normal car (+skimmer+helicopter+airplane) chase camera (several variable distances)
camera 22: normal boat chase camera (several variable distances)
camera 15: chase cinematic camera (also spray garage camera)
camera 46: picture-camera camera mode
camera 51: heatseeker aiming mode
camera 53: over-shoulder on-foot aiming with a weapon (any, including minigun)
camera 55: passenger window-driveby mode
camera 56: news-reporter style chase cinematic camera (wobbbling and zooming)
Please, do no message me anymore, i'm no longer part of sa-mp scene.

I will not reply to private messages.
JernejL is offline   Reply With Quote
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
update in server!! marik1599 Help Archive 2 23/07/2011 07:02 PM
how do I server update zimon_5 Server Support 3 09/01/2011 01:13 AM
[Help] How can i update my server to 0.3c? karloz Server Support 4 01/01/2011 09:12 PM
Server update: 0.3a R8 Kalcor Server Support 365 31/10/2010 03:36 PM

All times are GMT. The time now is 08:07 AM.

Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.