2018-09-23 20:34:47 +00:00
|
|
|
//
|
|
|
|
// Target.hpp
|
|
|
|
// Clock Signal
|
|
|
|
//
|
|
|
|
// Created by Thomas Harte on 23/09/2018.
|
|
|
|
// Copyright © 2018 Thomas Harte. All rights reserved.
|
|
|
|
//
|
|
|
|
|
2024-01-17 04:34:46 +00:00
|
|
|
#pragma once
|
2018-09-23 20:34:47 +00:00
|
|
|
|
2020-03-20 03:24:06 +00:00
|
|
|
#include "../../../Reflection/Enum.hpp"
|
|
|
|
#include "../../../Reflection/Struct.hpp"
|
2020-03-15 04:13:38 +00:00
|
|
|
#include "../StaticAnalyser.hpp"
|
|
|
|
|
2023-05-10 21:02:18 +00:00
|
|
|
namespace Analyser::Static::Sega {
|
2018-09-23 20:34:47 +00:00
|
|
|
|
2020-03-20 01:46:42 +00:00
|
|
|
struct Target: public Analyser::Static::Target, public Reflection::StructImpl<Target> {
|
2018-09-23 20:34:47 +00:00
|
|
|
enum class Model {
|
2018-10-24 02:19:45 +00:00
|
|
|
SG1000,
|
2018-09-23 20:34:47 +00:00
|
|
|
MasterSystem,
|
2018-10-24 02:19:45 +00:00
|
|
|
MasterSystem2,
|
2018-09-23 20:34:47 +00:00
|
|
|
};
|
|
|
|
|
2020-03-20 01:46:42 +00:00
|
|
|
ReflectableEnum(Region,
|
2018-10-20 00:32:09 +00:00
|
|
|
Japan,
|
|
|
|
USA,
|
2018-10-24 02:19:45 +00:00
|
|
|
Europe,
|
|
|
|
Brazil
|
2020-03-20 01:46:42 +00:00
|
|
|
);
|
2018-10-20 00:32:09 +00:00
|
|
|
|
|
|
|
enum class PagingScheme {
|
|
|
|
Sega,
|
|
|
|
Codemasters
|
|
|
|
};
|
|
|
|
|
2018-09-23 20:34:47 +00:00
|
|
|
Model model = Model::MasterSystem;
|
2018-10-20 00:32:09 +00:00
|
|
|
Region region = Region::Japan;
|
|
|
|
PagingScheme paging_scheme = PagingScheme::Sega;
|
2020-03-15 04:13:38 +00:00
|
|
|
|
2020-03-20 01:46:42 +00:00
|
|
|
Target() : Analyser::Static::Target(Machine::MasterSystem) {
|
|
|
|
if(needs_declare()) {
|
|
|
|
DeclareField(region);
|
|
|
|
AnnounceEnum(Region);
|
|
|
|
}
|
|
|
|
}
|
2018-09-23 20:34:47 +00:00
|
|
|
};
|
|
|
|
|
2024-11-30 02:08:35 +00:00
|
|
|
constexpr bool is_master_system(const Analyser::Static::Sega::Target::Model model) {
|
2022-12-29 16:28:47 +00:00
|
|
|
return model >= Analyser::Static::Sega::Target::Model::MasterSystem;
|
|
|
|
}
|
2018-10-24 02:19:45 +00:00
|
|
|
|
2018-09-23 20:34:47 +00:00
|
|
|
}
|