/* ScummVM - Graphic Adventure Engine
*
* ScummVM is the legal property of its developers, whose names
* are too numerous to list here. Please refer to the COPYRIGHT
* file distributed with this source distribution.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*
*/
/* --- What is a Room ---
*
*/
// Common/system includes basic things like Array
#include "common/system.h"
// Story is needed by both immortal.h and room.h
#include "immortal/story.h"
// Utilities.h contains many things used by all objects, not just immortal
#include "immortal/utilities.h"
#include "immortal/immortal.h"
#ifndef IMMORTAL_ROOM_H
#define IMMORTAL_ROOM_H
namespace Immortal {
enum RoomTile : uint8 {
kTileFloor,
kTileUpper5,
kTileUpper3,
kTileCeiling,
kTileTop1,
kTileTop7,
kTileWallFace,
kTileTopLower13,
kTileTopLower75,
kTileLower3,
kTileLower5,
kTileCeilingTile = 2 // This duplicate is intentional
};
/* Quick note:
* This looks entirely redundant and silly, I agree. However
* this is because the source does more or less the same thing.
* At compile time, it creates and stores in memory what are the
* equivalent of structs (or maybe tuples), and then at run time
* when creating a room, it makes room specific versions that can
* be changed. So essentially it creates two RAM structs and then
* treats the first as ROM. As such, that's what I'm doing here.
* The 'Story' structs are ROM, the 'Room' structs are RAM. There
* are also slight differences, like how the room Flame has a reference
* to the Cyc it is using. Although again the Story ones are ram
* and could do this too.
*/
// Temp
struct Object {
};
// Temp
struct Monster {
};
struct Flame {
FPattern _p = kFlameOff;
uint8 _x = 0;
uint8 _y = 0;
int _c = 0;
};
struct Chest {
};
struct Bullet {
};
class Room {
private:
Common::RandomSource _randomSource;
public:
Room(uint8 x, uint8 y, RoomFlag f);
~Room() {}
/*
* --- Data ---
*
*/
// Constants
const uint8 kLightTorchX = 10;
const uint8 kMaxFlameCycs = 16;
Common::Array _cycPtrs;
Common::Array _fset;
Common::Array _monsters;
Common::Array