coloredlot.java

来自「大富翁游戏monopoli」· Java 代码 · 共 16 行

JAVA
16
字号
import java.util.*;public abstract class ColoredLot extends Allotment {  protected LotColors color;  protected static Hashtable<LotColors, Integer> _owns = new Hashtable<LotColors, Integer>(); // un lotto appartiene allo stesso player?    public void setOwner(int own) {    owner = own;    Integer n = _owns.get(color);    if (n == null) _owns.put(color, new Integer(own));    else _owns.put(color, new Integer(own*n.intValue()));  }  public LotColors getColor() {return color;}  public int getLotsOwner(LotColors c) {return _owns.get(c);}}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?