di3g0 Posted September 3, 2020 Posted September 3, 2020 Hola a todos tengo un problema con un script , de comprar bebidas... compro la bebida y todo va bien ,no puedo comprar otra mientras tenga esa en la mano y la elimino apretando la tecla b(con bindkey) , pero despues quiero comprar bebida de nuevo y me muestra el ultimo mensaje , ese que dice: Ya tengo una bebida y ahì ya no se como hacerle xD animTimers={} function buyDrink() --si el dinero es 35 y no tienes activada la funciòn animation2 , activa animation2 local money = getPlayerMoney( source ) if (money >= 35 and not animTimers[source]) then setPedAnimation( source,"VENDING","VEND_Use", -1, false, true, true, false) animTimers[source] = setTimer(animation2,2500,1,source) takePlayerMoney( source, 35 ) --si es menor a 35 nada elseif money<35 then setPedAnimation( source,"ped","facsurpm", 0, false, true, false, true) outputChatBox( "No me alcanza el dinero...",source,200,0,0) else --si dinero es 35 y tengo la funcion mostrar mensaje if money>=35 and animTimers[source] then outputChatBox( "Ya tengo una bebida...",source,200,0,0) end end end
Moderators Patrick Posted September 3, 2020 Moderators Posted September 3, 2020 Wrong language, moved to Spanish section. community profile | map converters | map images | pDownloader | pAttach | model encrypter
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now