The Internet belongs to everyone. Let’s keep it that way.

Protect Net Neutrality
Loading presentation...

Present Remotely

Send the link below via email or IM

Copy

Present to your audience

Start remote presentation

  • Invited audience members will follow you as you navigate and present
  • People invited to a presentation do not need a Prezi account
  • This link expires 10 minutes after you close the presentation
  • A maximum of 30 users can follow your presentation
  • Learn more about this feature in our knowledge base article

Do you really want to delete this prezi?

Neither you, nor the coeditors you shared it with will be able to recover it again.

DeleteCancel

3_2:Így készült : Firefox OS - Róka és a Kakas

No description
by

Krisztián Karóczkai

on 20 February 2016

Comments (0)

Please log in to add your comment.

Report abuse

Transcript of 3_2:Így készült : Firefox OS - Róka és a Kakas

Hogyan működik?
Beállítások menü
Kijelző tájolása
Találkozások: Róka + Kakas vagy Vadász
Amikor fut a róka
window.screen.mozLockOrientation("
landscape-primary
");
function isCatch() {
if (foxleft >= bx - size && foxleft <= bx + size)
if (foxtop >= by - size && foxtop <= by + size) {
domChicken = document.getElementById("chicken");
animflag = true;

if (domChicken.style.backgroundImage == 'url("/icons/hunter.gif")')
showEndPanel();
else {
document.getElementById("soundstop").play();
foxes++;
domChicken.style.display = "none";
setTimeout(nextFox, 1000);
} }}
Készítette:
Karóczkai Krisztián

Firefox OS
minta alkalmazás

Róka és a Kakas
Mozog a telefon
mozog a Róka
A Kakas táncol
Rókának ennie kell
15 másodpercenként
Néha Vadász lesz
a Kakas... nem
lehet megenni...
Motiváció: ennyit evett a Róka
Minél többet evett annál gyorsabb a mozgás és kissebbek a figurák
Amivel elment az idő...
<label class="pack-switch">
<input type="checkbox" checked>
<span></span>
</label>
#menu-vibra
#menu-volume
<label class="pack-radio">
<input type="radio"
name="example" checked>
<span></span>
</label>
#menu-down
#menu-up
#menu-auto
#orientport
#orientland
<input type="range" min="24" value="64" max="64" />
#size
#speed
Switches & input range
window.screen.unlockOrientation()
window.screen.mozLockOrientation("portrait-primary")
window.screen.mozLockOrientation("landscape-primary")
screen.addEventListener("
mozorientationchange
", handleScreenOrientation, true);
.style.left =
(screen.width - size)+ "px";
.style.top =
(screen.height - size) + "px";
window.addEventListener('deviceorientation', function(event){}, true);
speed = document.getElementById("speed").value;
z = speed * event.alpha; //z
x = speed * event.beta; // x
y = speed * event.gamma; //y
foxleft -= Math.round(x);
foxtop += Math.round(y);
foxleft += Math.round(x);
foxtop -= Math.round(y);
foxleft -= Math.round(x);
foxtop -= Math.round(y);
foxleft += Math.round(x);
foxtop += Math.round(y);
foxleft += Math.round(x);
foxtop -= Math.round(y);
foxleft -= Math.round(x);
foxtop += Math.round(y);
foxleft += Math.round(x);
foxtop += Math.round(y);
foxleft -= Math.round(x);
foxtop = Math.round(y);
landscape-primary
portrait-primary
landscape-secondary
portrait-secondary
foxleft,foxtop
bx,by
size
size
if (Math.random() > 0.9)
document.getElementById("chicken").style.backgroundImage = 'url("/icons/hunter.gif")';
else
document.getElementById("chicken").style.backgroundImage = 'url("/icons/ChickenDancing.gif")';
setTimeout(timer, 1000);
}
moz
orientationchange

window.screen.
moz
LockOrientation("
landscape-primary
");

foxleft
(-/+)
= Math.round(x);
foxtop
(-/+)
= Math.round(y);
Full transcript