Beispiel #1
0
    //---------------------------------------
    // 位置座標Xを配列座標に変換して返す
    //---------------------------------------
    protected int getArrayNumX(int value)
    {
        int ret = value % size.getMapSizeX();

        if (ret < 0)
        {
            ret += size.getMapSizeX();
        }
        return(ret);
    }
Beispiel #2
0
    private bool isMapAppropriate;              // プレイヤーがそのマップで移動可能かどうかの判定

    //---------------------------------------
    // constructor
    //---------------------------------------
    public MapArrayFloor(string name, C21_MapSize size, C22_MapAxis axis) : base(name, size, axis)        //配列の確保とfalseに初期化
    {
        enemyFolder      = new GameObject("EnemyFolder");
        isMapAppropriate = false;
        isMoveArea       = new bool[size.getMapSizeX(), size.getMapSizeZ()];
        for (int z = 0; z < size.getMapSizeZ(); z++)
        {
            for (int x = 0; x < size.getMapSizeX(); x++)
            {
                isMoveArea[x, z] = false;
            }
        }
    }
Beispiel #3
0
    protected int SIGN;                            // 符号

    //---------------------------------------
    // constructor
    //---------------------------------------
    public C23_MapArray(string name, C21_MapSize size, C22_MapAxis axis)
    {
        this.name   = name;
        this.folder = new GameObject(this.name + "_Folder");
        this.array  = new GameObject[size.getMapSizeX(), size.getMapSizeZ()];
        this.size   = size;
        this.axis   = axis;

        this.SIGN = 1;
    }