private void cubukOzellikCarpismaKontrol(Nokta Ozellik) { if (Ozellik.Location.Y + Ozellik.Size.Height == cubuk.getCubuk().Location.Y&& Ozellik.Location.X >= cubuk.getCubuk().Location.X - Ozellik.Size.Width && Ozellik.Location.X <= cubuk.getCubuk().Location.X + cubuk.getCubuk().Size.Width) { if (Ozellik.Durumu == "Buyu") { cubuk.setbuyumeOz(new Buyu()); cubuk.buyu(cubuk.getCubuk(), 1.2, 1.0); } if (Ozellik.Durumu == "Ates") { AtesEt a = new AtesEt(); a.setForm(main); cubuk.setAtesEtmeOz(a); } if (top.getTop().Location.Y + 20 == cubuk.getCubuk().Location.Y) { cubuk.setAtesEtmeOz(new AtesEtme()); } dusenNoktalar.Remove(Ozellik); map.deleteInMap(Ozellik); } else if (Ozellik.Location.Y >= main.Size.Height - 58) { dusenNoktalar.Remove(Ozellik); map.deleteInMap(Ozellik); } }
public void ozellikleriZamanla() { if (cubuk.getAtesEtmeOz().GetType().ToString() == "DxBall.Interfaces.Ates.AtesEt") { AtesEt t = new AtesEt(); t = (AtesEt)cubuk.getAtesEtmeOz(); t.AtesZamani++; if (t.AtesZamani >= t.OzellikSure) { cubuk.setAtesEtmeOz(new AtesEtme()); t.AtesZamani = 0; } } }