26
2. ročník / Re: Naprogramujeme vsetko
« on: 25.03.2013, 18:31:12 »
ale su jedini, ktori maju realny tento konkretny hardware (atlas 5-551)
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
begin constructor
int doorInterval = random.int()
...
end constructor
begin checkEverySecond
doorIntervalCounter++
if (doorIntervalCounter == doorInterval) then
door.openClose()
doorIntervalCounter = 0
end if
end checkEverySecond
Implementujte metódu act() v triede Key nasledovne:
získajte inštanciu hráča
ak sa pozícia kľúča prekrýva s pozíciou hráča, pridajte predmet do batohu a odoberte predmet zo sveta
Player player = world.GetPlayer();
if (player.Intersects(this)) {
Backpack backpack = player.GetBackpack();
backpack.Add(this);
world.Remove(this);
}
Najlepsie, ked si to pisu druhaci
for (x from 0 to 1.5 step 0.5)
for (y from 0 to 2 step 1)
z = (0.5*x + 3.2/x ...)
print x + " | " + y + " | " + z
end for
end for
v com moze byt chyba?
picoviny tu riesite na 10 stranach !!!
Silvusik, daj mi cislo (telefonu, ne topanok)
public Iterator<Item> iterator() {
return items.iterator();
}