MaurO^ Posted October 25, 2016 Share Posted October 25, 2016 (edited) Ayuda soy nuevo en esto y no se porque me sale este error "attempt to compare number with boolean" aca dejo el codigo: server-side function darArma()if getPlayerMoney(source) >= 200 thengiveWeapon(source, 24, 20)takePlayerMoney(source, 200)else outputChatBox("No tienes suficiente dinero para comprar esta arma.") end endaddEvent("onGet", true)addEventHandler("onGet", root, darArma) Edited October 25, 2016 by Mauro.e Link to comment
Tomas Posted October 25, 2016 Share Posted October 25, 2016 (edited) if getPlayerMoney(client) >= 200 then Si quieres obtener el dinero del cliente que triggea usa client, no source, si es otro jugador (como en una gridlist) publica el client. Edited October 25, 2016 by Tomas Link to comment
MaurO^ Posted October 26, 2016 Author Share Posted October 26, 2016 @Tomas gracias me funcionó. Link to comment
Recommended Posts