10 if (
const auto* config = machineConfig.
findChild(
"RenShaTurbo")) {
11 int min_ints = config->getChildDataAsInt(
"min_ints", 47);
12 int max_ints = config->getChildDataAsInt(
"max_ints", 221);
13 if ((min_ints < 1) || (min_ints > max_ints) || (max_ints > 6000)) {
15 "Error in RenShaTurbo speed settings: "
16 "1 <= min_ints <= max_ints <= 6000.");
18 autofire.emplace(motherBoard, min_ints, max_ints,
25 return autofire ? autofire->getSignal(time) :
false;
28template<
typename Archive>
31 if (autofire) ar.serialize(
"autofire", *autofire);
Ren-Sha Turbo is the autofire in several MSX 2+ models and in the MSX turbo R.
RenShaTurbo(MSXMotherBoard &motherBoard, const XMLElement &machineConfig)
void serialize(Archive &ar, unsigned version)
bool getSignal(EmuTime::param time)
Get the output signal in negative logic.
const XMLElement * findChild(std::string_view childName) const
This file implemented 3 utility functions:
#define INSTANTIATE_SERIALIZE_METHODS(CLASS)