mirror of
https://github.com/dashr9230/SA-MP.git
synced 2025-09-19 20:26:14 +08:00
[server] Update n_floatstr(...)
This commit is contained in:
@ -84,7 +84,11 @@ static cell AMX_NATIVE_CALL n_floatstr(AMX *amx,cell *params)
|
|||||||
amx_GetString(szSource, pString, 0, sizeof szSource);
|
amx_GetString(szSource, pString, 0, sizeof szSource);
|
||||||
|
|
||||||
/* Now convert this to a float. */
|
/* Now convert this to a float. */
|
||||||
|
#ifdef WIN32
|
||||||
fNum = (REAL)atof(szSource);
|
fNum = (REAL)atof(szSource);
|
||||||
|
#else
|
||||||
|
fNum = (REAL)strtod(szSource,NULL);
|
||||||
|
#endif
|
||||||
|
|
||||||
return amx_ftoc(fNum);
|
return amx_ftoc(fNum);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user