mirror of
https://github.com/pret/pokered.git
synced 2024-10-23 15:08:23 +00:00
4d0797bc3a
hg-commit-id: 1145e088ee27
47 lines
No EOL
703 B
C++
47 lines
No EOL
703 B
C++
#include <sstream>
|
|
#include "Stop.h"
|
|
using namespace std;
|
|
|
|
Stop::Stop()
|
|
{}
|
|
|
|
Stop::Stop(unsigned char* byte)
|
|
{
|
|
Parse(byte);
|
|
}
|
|
|
|
bool Stop::IsValid(unsigned char* byte)
|
|
{
|
|
if(byte[0] == 0xFF)
|
|
{
|
|
error = false; // Unblock assembling
|
|
return true;
|
|
}
|
|
else
|
|
{
|
|
error = true; // Block assembling
|
|
return false;
|
|
}
|
|
}
|
|
|
|
string Stop::GenAsm()
|
|
{
|
|
string tmpRet = AbstractData::GenAsm();
|
|
if(tmpRet != "") return false;
|
|
|
|
stringstream tmpAsmOut;
|
|
tmpAsmOut << "mus_end";
|
|
return tmpAsmOut.str();
|
|
}
|
|
|
|
bool Stop::Parse(unsigned char* byte)
|
|
{
|
|
if(AbstractData::Parse(byte)) return false;
|
|
return true;
|
|
}
|
|
|
|
unsigned int Stop::Arguments()
|
|
{
|
|
// No Arguments
|
|
return 0;
|
|
} |