Plate Posted December 1, 2012 Posted December 1, 2012 Hola tengo una duda y es sobre este script ¿Por que no funciona? function bloqeo ( theVehicle , player, seat, jacked ) local elev = exports.exp_system:getPlayerLevel ( player ) local id = getElementModel ( theVehicle ) if ( seat == 0 ) and ( id == 432 or id == 425 or id == 420 ) and ( elev < 40 ) then outputChatBox ("[sERVER]: No puedes entrar a este vehiculo por que no tienes el level necesario", player, 255, 100, 100, false) cancelEvent() end end addEventHandler ( "onVehicleStartEnter", getRootElement(), bloqeo ) Visita Full GameZ DayZ Mod Server IP: mtasa://158.69.125.144:29015
Castillo Posted December 1, 2012 Posted December 1, 2012 El primer argumento de 'onVehicleStartEnter' es el jugador que entro, el segundo es el asiento y el tercero es si hizo "hijack". function bloqeo ( thePlayer, seat, jacked ) local elev = tonumber ( getElementData ( thePlayer, "level" ) ) or 0 local id = getElementModel ( source ) if ( seat == 0 ) and ( id == 432 or id == 425 or id == 420 ) and ( elev < 40 ) then outputChatBox ( "[sERVER]: No puedes entrar a este vehiculo por que no tienes el level necesario", thePlayer, 255, 100, 100, false ) cancelEvent ( ) end end addEventHandler ( "onVehicleStartEnter", getRootElement(), bloqeo ) San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Plate Posted December 1, 2012 Author Posted December 1, 2012 me dice Bad argument @ getPlayerLevel Visita Full GameZ DayZ Mod Server IP: mtasa://158.69.125.144:29015
Castillo Posted December 1, 2012 Posted December 1, 2012 En mi script? imposible, yo no use esa funcion. San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Plate Posted December 1, 2012 Author Posted December 1, 2012 Gracias solid ya se arreglo lo copie denuevo y dejo de decir eso Visita Full GameZ DayZ Mod Server IP: mtasa://158.69.125.144:29015
Castillo Posted December 1, 2012 Posted December 1, 2012 De nada. San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Recommended Posts