Jump to content

erro script sound local player help


Recommended Posts

not managing to sound the alarm when one player get close and appears in chat

  
local sound = playSound3D ("siren.mp3",-1249.4000244141,-1990.9000244141,2.7000000476837, 'cylinder', 100, 100, 0, 255, 0) 
setSoundMaxDistance ( sound, 100 ) 
local puerta = createObject (5856,-1250.4000244141,-1991.5,3.5,0,0,306) 
local markerADM = createMarker (-1249.4000244141,-1990.9000244141,2.7000000476837, 'cylinder', 3, 0, 0, 255, 0) 
-------------------------- 
  
  
--Ésta es una zona de Admins. Sólo ellos pueden ingresar. 
addEventHandler ("onMarkerHit",markerADM, 
function (hitPlayer) 
 local account = getPlayerAccount(hitPlayer) 
 if isObjectInACLGroup( 'user.'..getAccountName( account ), aclGetGroup( 'Admin' ) ) then 
  moveObject (puerta,1000, -1250.4000244141, -1991.5, 5.5) 
  outputChatBox ("",hitPlayer,0,255,0) 
 else 
  outputChatBox ("¡Tienes que ser administrador para entrar en esta zona.",hitPlayer) 
  
 end 
end) 

Did not understand this and pq 1 resource when player reaches 100 meters the siren sounds,

podir faser the script for min?

Edited by Guest
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...