@@ -2920,10 +2920,25 @@ end
2920
2920
-- Security
2921
2921
2922
2922
function SHA256_PassHash (amx , pass , salt , ret_hash , ret_hash_len )
2923
- local secret = hash ( ' sha256' , salt .. ' ' .. pass )
2923
+ local secret = hash ( ' sha256' , pass .. ' ' .. salt ) -- who is it guy which writes salt after pass?
2924
2924
writeMemString (amx , ret_hash , string.upper (secret ) )
2925
2925
end
2926
2926
2927
+ -- Siren
2928
+
2929
+ function GetVehicleParamsSirenState (amx , vehicle )
2930
+ local sirenstat = getVehicleSirensOn ( vehicle )
2931
+
2932
+ -- in samp this native returns 3 states
2933
+ -- 1 - siren on
2934
+ -- 0 - siren off
2935
+ -- -1 - siren not exist, but we never get it.
2936
+ if (sirenstat == true ) then
2937
+ return 1
2938
+ else
2939
+ return 0
2940
+ end
2941
+ end
2927
2942
---- -------------------------------------------------
2928
2943
-- List of the functions and their argument types
2929
2944
@@ -3502,5 +3517,8 @@ g_SAMPSyscallPrototypes = {
3502
3517
SetActorVirtualWorld = {' y' , ' i' },
3503
3518
3504
3519
-- security
3505
- SHA256_PassHash = {' s' , ' s' , ' r' , ' r' }
3520
+ SHA256_PassHash = {' s' , ' s' , ' r' , ' i' },
3521
+
3522
+ -- siren
3523
+ GetVehicleParamsSirenState = {' v' }
3506
3524
}
0 commit comments