Foros del Web » Programando para Internet » Javascript »

[Aporte] Juego de romper ladrillos

Estas en el tema de [Aporte] Juego de romper ladrillos en el foro de Javascript en Foros del Web. Hola, Este juego fue el primero con movimiento que programe en javascript xD... esta echo 100% javascript + css + html :P DEMO: http://www.halfmusic.com/rompeladrillos.html Codigo: ...
  #1 (permalink)  
Antiguo 19/01/2010, 00:17
Avatar de pato12  
Fecha de Ingreso: septiembre-2007
Ubicación: Salta
Mensajes: 1.620
Antigüedad: 16 años, 7 meses
Puntos: 101
[Aporte] Juego de romper ladrillos

Hola,
Este juego fue el primero con movimiento que programe en javascript xD... esta echo 100% javascript + css + html :P

DEMO: http://www.halfmusic.com/rompeladrillos.html

Codigo:
Código Javascript:
Ver original
  1. // MIRARLO EN LA DEMO, PORQUE ES DEMASIADO LARGO Y ME PASO POR MUCHOS CARACTERES... XD
Modo de uso:
Código HTML:
Ver original
  1. <style type="text/css">
  2. <!--
  3. #game {
  4.     background-color: #FFF;
  5.     height: 400px;
  6.     width: 500px;
  7.     border: 1px solid #000;
  8.     position: relative;
  9. }
  10. .ladrillo {
  11.     background-color: #F00;
  12.     height: 24px;
  13.     width: 55.5px;
  14.     position: absolute;
  15.     border: 1px solid #000;
  16.     line-height: 1px;
  17.     font-size: 1px;
  18. }
  19. #game #bola {
  20.     background-color: #999;
  21.     height: 5px;
  22.     width: 5px;
  23.     position: absolute;
  24.     line-height: 1px;
  25.     font-size: 1px;
  26.     left: -9px;
  27.     top: -26px;
  28. }
  29. #game #barra {
  30.     background-color: #000;
  31.     height: 10px;
  32.     width: 150px;
  33.     position: absolute;
  34. }
  35.  
  36. .l1 {
  37.     background-color: #F00;
  38.     height: 23px;
  39.     width: 54.5px;
  40.     position: absolute;
  41.     border: 1px solid #000;
  42.     line-height: 1px;
  43.     font-size: 1px;
  44. }
  45. .l2 {
  46.     background-color: #00F;
  47.     height: 23px;
  48.     width: 54.5px;
  49.     position: absolute;
  50.     border: 1px solid #000;
  51.     line-height: 1px;
  52.     font-size: 1px;
  53. }
  54. .l3 {
  55.     background-color: #FF0;
  56.     height: 23px;
  57.     width: 54.5px;
  58.     position: absolute;
  59.     border: 1px solid #000;
  60.     line-height: 1px;
  61.     font-size: 1px;
  62. }
  63. .l4 {
  64.     background-color: #0FF;
  65.     height: 23px;
  66.     width: 54.5px;
  67.     position: absolute;
  68.     border: 1px solid #000;
  69.     line-height: 1px;
  70.     font-size: 1px;
  71. }
  72. .l5 {
  73.     background-color: #0F0;
  74.     height: 23px;
  75.     width: 54.5px;
  76.     position: absolute;
  77.     border: 1px solid #000;
  78.     line-height: 1px;
  79.     font-size: 1px;
  80. }
  81.  
  82.  
  83. -->
  84. </style><div id="game" style="overflow:hidden;">
  85.     <div id="gano" style="display:none;"><h1>GANASTE TODO EL JUEGO!</h1></div>
  86.     <div id="campoGanoLevel" style="display:none;"><h1>GANASTE EL NIVEL!</h1></div>
  87.     <div id="bola"></div>
  88.     <div id="barra"></div>
  89. </div>
  90. // CODIGO DEL JUEGO
  91. window.onload=function(){new HalfJueguego.ladrillos().init();};
Y es facil adaptar :p
Esta bajo licencia GNU General Public License
Gracias
Salu2
__________________
Half Music - www.halfmusic.com
  #2 (permalink)  
Antiguo 19/01/2010, 00:56
Avatar de JavierB
Colaborador
 
Fecha de Ingreso: febrero-2002
Ubicación: Madrid
Mensajes: 25.052
Antigüedad: 22 años, 2 meses
Puntos: 772
Respuesta: [Aporte] Juego de romper ladrillos

Hola pato12

Esto me recuerda cuando era joven y me pasaba las tardes enteras jugando con el Arkanoid

Podrías poner un mensaje en las FAQs con enlaces a este juego y el de pin-pong.

Saludos,
  #3 (permalink)  
Antiguo 19/01/2010, 01:09
Avatar de danistrein  
Fecha de Ingreso: septiembre-2008
Ubicación: Salta Capital
Mensajes: 550
Antigüedad: 15 años, 7 meses
Puntos: 9
Respuesta: [Aporte] Juego de romper ladrillos

buen aporte pato. esta bueno el juego jeje
__________________
Appones.net - www.appones.net
  #4 (permalink)  
Antiguo 09/01/2013, 05:37
 
Fecha de Ingreso: enero-2013
Mensajes: 2
Antigüedad: 11 años, 3 meses
Puntos: 0
Respuesta: [Aporte] Juego de romper ladrillos

podrias alguien enviar el codigo completo de este juego me vendria bien para practicar que empiezo en esto de programar muchas gracias

Etiquetas: aportes, juegos
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 11:50.