Fix random warnings from clang 8.0.0
This commit is contained in:
parent
467be1dcb9
commit
7330d0412a
@ -2419,7 +2419,7 @@ char * GameSave::serialiseOPS(unsigned int & dataLength)
|
|||||||
soapLinkData = new unsigned char[3*soapCount];
|
soapLinkData = new unsigned char[3*soapCount];
|
||||||
if (!soapLinkData)
|
if (!soapLinkData)
|
||||||
throw BuildException("Save error, out of memory (SOAP)");
|
throw BuildException("Save error, out of memory (SOAP)");
|
||||||
soapLinkDataPtr = std::move(std::unique_ptr<unsigned char[]>(soapLinkData));
|
soapLinkDataPtr = std::unique_ptr<unsigned char[]>(soapLinkData);
|
||||||
|
|
||||||
//Iterate through particles in the same order that they were saved
|
//Iterate through particles in the same order that they were saved
|
||||||
for (y=0;y<fullH;y++)
|
for (y=0;y<fullH;y++)
|
||||||
|
@ -297,7 +297,7 @@ void GameController::Install()
|
|||||||
#if defined(MACOSX)
|
#if defined(MACOSX)
|
||||||
new InformationMessage("No installation necessary", "You don't need to install The Powder Toy on OS X", false);
|
new InformationMessage("No installation necessary", "You don't need to install The Powder Toy on OS X", false);
|
||||||
#elif defined(WIN) || defined(LIN)
|
#elif defined(WIN) || defined(LIN)
|
||||||
new ConfirmPrompt("Install The Powder Toy", "Do you wish to install The Powder Toy on this computer?\nThis allows you to open save files and saves directly from the website.", { [this] {
|
new ConfirmPrompt("Install The Powder Toy", "Do you wish to install The Powder Toy on this computer?\nThis allows you to open save files and saves directly from the website.", { [] {
|
||||||
if (Client::Ref().DoInstallation())
|
if (Client::Ref().DoInstallation())
|
||||||
{
|
{
|
||||||
new InformationMessage("Success", "Installation completed", false);
|
new InformationMessage("Success", "Installation completed", false);
|
||||||
|
@ -12,7 +12,6 @@ class DropDownWindow : public ui::Window
|
|||||||
DropDown * dropDown;
|
DropDown * dropDown;
|
||||||
Appearance appearance;
|
Appearance appearance;
|
||||||
std::vector<Button> buttons;
|
std::vector<Button> buttons;
|
||||||
bool isMouseInside;
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
DropDownWindow(DropDown * dropDown):
|
DropDownWindow(DropDown * dropDown):
|
||||||
|
@ -602,7 +602,7 @@ void PreviewView::NotifyCommentsChanged(PreviewModel * sender)
|
|||||||
if (showAvatars)
|
if (showAvatars)
|
||||||
{
|
{
|
||||||
tempAvatar = new ui::AvatarButton(ui::Point(2, currentY+7), ui::Point(26, 26), comments->at(i)->authorName);
|
tempAvatar = new ui::AvatarButton(ui::Point(2, currentY+7), ui::Point(26, 26), comments->at(i)->authorName);
|
||||||
tempAvatar->SetActionCallback({ [this, tempAvatar] {
|
tempAvatar->SetActionCallback({ [tempAvatar] {
|
||||||
if (tempAvatar->GetUsername().size() > 0)
|
if (tempAvatar->GetUsername().size() > 0)
|
||||||
{
|
{
|
||||||
new ProfileActivity(tempAvatar->GetUsername());
|
new ProfileActivity(tempAvatar->GetUsername());
|
||||||
|
@ -48,7 +48,7 @@ RenderView::RenderView():
|
|||||||
renderModes.push_back(renderModeCheckbox);
|
renderModes.push_back(renderModeCheckbox);
|
||||||
renderModeCheckbox->mode = mode;
|
renderModeCheckbox->mode = mode;
|
||||||
renderModeCheckbox->SetIcon(icon);
|
renderModeCheckbox->SetIcon(icon);
|
||||||
renderModeCheckbox->SetActionCallback({ [this, mode, renderModeCheckbox] {
|
renderModeCheckbox->SetActionCallback({ [this, renderModeCheckbox] {
|
||||||
if (renderModeCheckbox->GetChecked())
|
if (renderModeCheckbox->GetChecked())
|
||||||
c->SetRenderMode(renderModeCheckbox->mode);
|
c->SetRenderMode(renderModeCheckbox->mode);
|
||||||
else
|
else
|
||||||
@ -69,7 +69,7 @@ RenderView::RenderView():
|
|||||||
displayModes.push_back(displayModeCheckbox);
|
displayModes.push_back(displayModeCheckbox);
|
||||||
displayModeCheckbox->mode = mode;
|
displayModeCheckbox->mode = mode;
|
||||||
displayModeCheckbox->SetIcon(icon);
|
displayModeCheckbox->SetIcon(icon);
|
||||||
displayModeCheckbox->SetActionCallback({ [this, mode, displayModeCheckbox] {
|
displayModeCheckbox->SetActionCallback({ [this, displayModeCheckbox] {
|
||||||
if (displayModeCheckbox->GetChecked())
|
if (displayModeCheckbox->GetChecked())
|
||||||
c->SetDisplayMode(displayModeCheckbox->mode);
|
c->SetDisplayMode(displayModeCheckbox->mode);
|
||||||
else
|
else
|
||||||
@ -99,7 +99,7 @@ RenderView::RenderView():
|
|||||||
colourModes.push_back(colourModeCheckbox);
|
colourModes.push_back(colourModeCheckbox);
|
||||||
colourModeCheckbox->mode = mode;
|
colourModeCheckbox->mode = mode;
|
||||||
colourModeCheckbox->SetIcon(icon);
|
colourModeCheckbox->SetIcon(icon);
|
||||||
colourModeCheckbox->SetActionCallback({ [this, mode, colourModeCheckbox] {
|
colourModeCheckbox->SetActionCallback({ [this, colourModeCheckbox] {
|
||||||
if(colourModeCheckbox->GetChecked())
|
if(colourModeCheckbox->GetChecked())
|
||||||
c->SetColourMode(colourModeCheckbox->mode);
|
c->SetColourMode(colourModeCheckbox->mode);
|
||||||
else
|
else
|
||||||
|
@ -50,16 +50,11 @@ void Element::Element_PPIP()
|
|||||||
Graphics = &Element_PIPE_graphics;
|
Graphics = &Element_PIPE_graphics;
|
||||||
}
|
}
|
||||||
|
|
||||||
constexpr int PFLAG_NORMALSPEED = 0x00010000;
|
|
||||||
// parts[].tmp flags
|
// parts[].tmp flags
|
||||||
// trigger flags to be processed this frame (trigger flags for next frame are shifted 3 bits to the left):
|
// trigger flags to be processed this frame (trigger flags for next frame are shifted 3 bits to the left):
|
||||||
constexpr int PPIP_TMPFLAG_TRIGGER_ON = 0x10000000;
|
constexpr int PPIP_TMPFLAG_TRIGGER_ON = 0x10000000;
|
||||||
constexpr int PPIP_TMPFLAG_TRIGGER_OFF = 0x08000000;
|
constexpr int PPIP_TMPFLAG_TRIGGER_OFF = 0x08000000;
|
||||||
constexpr int PPIP_TMPFLAG_TRIGGER_REVERSE = 0x04000000;
|
constexpr int PPIP_TMPFLAG_TRIGGER_REVERSE = 0x04000000;
|
||||||
constexpr int PPIP_TMPFLAG_TRIGGERS = 0x1C000000;
|
|
||||||
// current status of the pipe
|
|
||||||
constexpr int PPIP_TMPFLAG_PAUSED = 0x02000000;
|
|
||||||
constexpr int PPIP_TMPFLAG_REVERSED = 0x01000000;
|
|
||||||
// 0x000000FF element
|
// 0x000000FF element
|
||||||
// 0x00000100 is single pixel pipe
|
// 0x00000100 is single pixel pipe
|
||||||
// 0x00000200 will transfer like a single pixel pipe when in forward mode
|
// 0x00000200 will transfer like a single pixel pipe when in forward mode
|
||||||
|
Reference in New Issue
Block a user