public void giveBonus(bonuses profit) { if (profit.value != -1) { this.setSize(getSize() + profit.size); Speed += profit.speed; score += profit.value; modTime += profit.modTime; } }
public PoinT(int x, int y, bonuses prop) { this.setX(x); this.setY(y); this.setSize(4); this.setValue(prop.value); this.prop = prop; this.newRect(); rect.Fill = prop.brush; //Debug.WriteLine("new Point | "+this.id+" | " + getX() + " : " + getY()); }
public PoinT(bonuses prop) : this(r.Next(55) + 4, r.Next(40) + 4, prop) { }