Skip to main content

Deutschzentrum

#dz-space-game{font-family:Arial,sans-serif;max-width:850px;margin:20px auto;color:#fff;background:#080d27;border-radius:18px;overflow:hidden} #dz-space-game *{box-sizing:border-box} #dz-space-game .top{text-align:center;padding:15px 8px;background:#111b46} #dz-space-game h2{margin:0;font-size:25px;color:#93c5fd} #dz-space-game .stats{display:flex;justify-content:center;gap:18px;flex-wrap:wrap;margin-top:10px;font-weight:bold} #dz-space-game canvas{display:block;width:100%;height:auto;aspect-ratio:800/480;background:#070b20;touch-action:none} #dz-space-game .controls{padding:12px;text-align:center} #dz-space-game .choices{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin-bottom:12px} #dz-space-game button{border:0;border-radius:10px;padding:12px 15px;font-weight:bold;font-size:15px;cursor:pointer;touch-action:manipulation} #dz-space-game .der{background:#3b82f6;color:white} #dz-space-game .die{background:#ec4899;color:white} #dz-space-game .das{background:#10b981;color:white} #dz-space-game .action{background:#facc15;color:#172033} #dz-space-game .move{background:#dbeafe;color:#172554;min-width:60px} #dz-space-game .selected{outline:3px solid white;outline-offset:2px} #dz-space-game .help{font-size:13px;line-height:1.6;color:#cbd5e1;margin:12px 0 0} #dz-space-game .row{display:flex;justify-content:center;gap:8px;align-items:center;flex-wrap:wrap}

🚀 DEUTSCHZENTRUM SPACE SHOOTER

⭐ Scor: 0 ❤️ Vieți: 15 🎯 Nivel: 1
Alege articolul corect și împușcă substantivul!

Calculator: ← → pentru mișcare, 1/2/3 pentru articol și SPACE pentru foc.
Telefon: folosește butoanele de pe ecran.
Greșelile nu scad vieți! Viețile se pierd doar când o țintă ajunge jos.

(function(){ const root=document.getElementById('dz-space-game'); if(root.dataset.ready)return; root.dataset.ready='1'; const canvas=root.querySelector('#dzs-canvas'); const ctx=canvas.getContext('2d'); const W=800,H=480; const $=s=>root.querySelector(s); const words=[ ['TISCH','masă','der'],['SCHULE','școală','die'], ['BUCH','carte','das'],['HUND','câine','der'], ['KATZE','pisică','die'],['HAUS','casă','das'], ['APFEL','măr','der'],['BLUME','floare','die'], ['AUTO','mașină','das'],['STUHL','scaun','der'], ['TÜR','ușă','die'],['FENSTER','fereastră','das'], ['BALL','minge','der'],['MILCH','lapte','die'], ['WASSER','apă','das'],['ZUG','tren','der'], ['ZEITUNG','ziar','die'],['TELEFON','telefon','das'], ['KUCHEN','prăjitură','der'],['JACKE','geacă','die'], ['MESSER','cuțit','das'],['GARTEN','grădină','der'], ['TASCHE','geantă','die'],['ZIMMER','cameră','das'], ['LEHRER','profesor','der'],['LEHRERIN','profesoară','die'], ['KIND','copil','das'],['BRUDER','frate','der'], ['SCHWESTER','soră','die'],['MÄDCHEN','fată','das'], ['COMPUTER','calculator','der'],['LAMPE','lampă','die'], ['HANDY','telefon mobil','das'],['MOND','lună','der'], ['SONNE','soare','die'],['STERNE','stele','die'], ['FISCH','pește','der'],['BANANE','banană','die'], ['BROT','pâine','das'],['VATER','tată','der'], ['MUTTER','mamă','die'],['BABY','bebeluș','das'], ['KÄSE','brânză','der'],['SUPPE','supă','die'], ['EI','ou','das'],['SCHLÜSSEL','cheie','der'], ['UHR','ceas','die'],['HEFT','caiet','das'] ]; let score=0,lives=15,level=1,selected='der'; let playing=false,shipX=400,bullets=[],targets=[]; let stars=[],spawn=0,frame=0,message='Apasă START pentru a începe!'; let keys={},lastShot=0,feedbackUntil=0; for(let i=0;i{ b.classList.toggle('selected',b.dataset.article===a); }); } root.querySelectorAll('[data-article]').forEach(b=>{ b.addEventListener('click',()=>chooseArticle(b.dataset.article)); }); function newTarget(){ const w=words[Math.floor(Math.random()*words.length)]; targets.push({ x:75+Math.random()*(W-150), y:-35, word:w[0],translation:w[1],article:w[2], speed:.28+Math.random()*.22, phase:Math.random()*6 }); } function start(){ score=0;lives=15;level=1;shipX=400; bullets=[];targets=[];spawn=0;frame=0; playing=true; message='Alege DER, DIE sau DAS și trage!'; $('#dzs-start').textContent='↻ RESTART'; newTarget(); newTarget(); updateStats(); } function finish(){ playing=false; message='JOC TERMINAT! Scor final: '+score+' puncte.'; $('#dzs-start').textContent='▶ JOACĂ DIN NOU'; } function shoot(){ if(!playing)return; const now=Date.now(); if(now-lastShot{ s.y+=s.s; if(s.y>H){s.y=0;s.x=Math.random()*W;} ctx.fillStyle='#c7d2fe'; ctx.globalAlpha=.4+Math.random()*.4; ctx.fillRect(s.x,s.y,s.r,s.r); }); ctx.globalAlpha=1; if(playing){ frame++; spawn++; if(spawn>145){ newTarget(); spawn=0; } if(keys.ArrowLeft||keys.a)shipX-=5; if(keys.ArrowRight||keys.d)shipX+=5; shipX=Math.max(25,Math.min(W-25,shipX)); bullets.forEach(b=>b.y-=b.speed); for(let i=bullets.length-1;i>=0;i--){ const b=bullets[i]; let hit=-1; for(let j=0;j<targets.length;j++){ const t=targets[j]; if(Math.abs(b.x-t.x)<65&&Math.abs(b.y-t.y)=0){ const t=targets[hit]; if(b.article===t.article){ score+=10; level=1+Math.floor(score/100); message='🎯 CORECT! '+t.article.toUpperCase()+' '+t.word+' = '+t.translation; }else{ message='💡 Era '+t.article.toUpperCase()+' '+t.word+' = '+t.translation+'. Mai încearcă!'; } feedbackUntil=frame+100; targets.splice(hit,1); bullets.splice(i,1); updateStats(); } } bullets=bullets.filter(b=>b.y>-20); targets.forEach(t=>{ t.y+=t.speed; t.x+=Math.sin(frame*.018+t.phase)*.4; }); targets=targets.filter(t=>{ if(t.y>H-75){ lives--; message='🚨 A scăpat! '+t.article.toUpperCase()+' '+t.word+' = '+t.translation; feedbackUntil=frame+100; updateStats(); if(livesfeedbackUntil&&playing){ message='Țintește articolul corect!'; } } // Laserele se deplasează de jos în sus bullets.forEach(b=>{ ctx.strokeStyle='#67e8f9'; ctx.lineWidth=5; ctx.shadowColor='#22d3ee'; ctx.shadowBlur=12; ctx.beginPath(); ctx.moveTo(b.x,b.y+14); ctx.lineTo(b.x,b.y-14); ctx.stroke(); ctx.shadowBlur=0; }); const colors={der:'#2563eb',die:'#db2777',das:'#059669'}; targets.forEach(t=>{ ctx.fillStyle=colors[t.article]; ctx.shadowColor=colors[t.article]; ctx.shadowBlur=12; ctx.beginPath(); ctx.roundRect(t.x-64,t.y-27,128,54,13); ctx.fill(); ctx.shadowBlur=0; ctx.fillStyle='#fff'; ctx.textAlign='center'; ctx.font='bold 18px Arial'; ctx.fillText(t.word,t.x,t.y+3); ctx.font='12px Arial'; ctx.fillText(t.translation,t.x,t.y+20); }); drawShip(); ctx.textAlign='center'; ctx.font='bold 17px Arial'; ctx.fillStyle='#e0e7ff'; ctx.fillText(message,W/2,30); if(!playing){ ctx.fillStyle='#070b20dd'; ctx.fillRect(0,0,W,H); ctx.fillStyle='#93c5fd'; ctx.font='bold 34px Arial'; ctx.fillText(lives{ if(['ArrowLeft','ArrowRight',' ','ArrowUp'].includes(e.key))e.preventDefault(); keys[e.key]=true; if(e.repeat)return; if(e.key==='1')chooseArticle('der'); if(e.key==='2')chooseArticle('die'); if(e.key==='3')chooseArticle('das'); if(e.key===' '||e.key==='ArrowUp')shoot(); }); document.addEventListener('keyup',e=>{keys[e.key]=false;}); function bindMove(id,key){ const b=$(id); b.addEventListener('pointerdown',e=>{ e.preventDefault(); keys[key]=true; }); ['pointerup','pointerleave','pointercancel'].forEach(ev=>{ b.addEventListener(ev,()=>keys[key]=false); }); } bindMove('#dzs-left','ArrowLeft'); bindMove('#dzs-right','ArrowRight'); $('#dzs-fire').addEventListener('click',shoot); $('#dzs-start').addEventListener('click',start); canvas.addEventListener('pointermove',e=>{ if(!playing)return; if(e.buttons===0)return; const r=canvas.getBoundingClientRect(); shipX=Math.max(25,Math.min(W-25,(e.clientX-r.left)/r.width*W)); }); updateStats(); draw(); })();
Deutschzentrum
Confidentialitatea datelor

Poți afla mai multe despre ce cookie-uri folosim sau să le dezactivezi în [setting]setări[/setting].  Politica cookies    click GDPR

Cu exceptia categoriilor de modulele cookie care sunt strict necesare pentru functionarea site-ului, puteti accepta sau refuza utilizarea de module cookie, separat pentru fiecare categorie de module cookie, prin mutarea selectorului de la sfarsitul fiecarui rand de mai jos. De fiecare data cand vi se solicita sa acceptati sau sa refuzati utilizarea categoriilor de module cookie, va oferim informatiile esentiale pe care trebuie sa le cunoasteti pentru a alege: categoriile de module cookie, datele de identificare ale operatorului, daca sunt categorii de module cookie care se refera la module cookie persistente sau de sesiune, daca acea categorie de modul cookie este un modul cookie primar sau un modul cookie tert (cu exceptia modulelor Cookie Strict Necesare [acestea fiind mereu module cookie primare]), si daca datele dvs personale sunt transferate in afara Spatiului Economic European. Odata ce ati acceptat utilizarea de catre noi a categoriilor de module cookie, puteti reveni la alegerea dvs. prin mutarea selectorului la sfarsitul randului respectiv. Accesati aceasta functie in cadrul politicii de confidentialitate a site-ului modulelor cookie.

Mai multe detalii puteți afla accesând pagina Politica de confidentialitate