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