Files
oot/tools/ZAPD/ZAPD/ZRoom/Commands/SetSkyboxSettings.cpp
T
Anghelo Carvajal 515ebdce9d ZAPD update: libpng, zroom improvements and others (#811)
* git subrepo pull --force tools/ZAPD

subrepo:
  subdir:   "tools/ZAPD"
  merged:   "769f5702a"
upstream:
  origin:   "https://github.com/zeldaret/ZAPD.git"
  branch:   "master"
  commit:   "769f5702a"
git-subrepo:
  version:  "0.4.3"
  origin:   "???"
  commit:   "???"

* Add `libpng` to readme

* Remove `-ifp` since it doesn't exists anymore in ZAPD

* Remove extra print I added

* Add UNK_09 macro and other minor fixes

* Simplify PNG rules

* simplify gitignore

* Update README.md

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update dockerfile

* basic instructions for cygwin and mac

* git subrepo pull --force tools/ZAPD

subrepo:
  subdir:   "tools/ZAPD"
  merged:   "86160be69"
upstream:
  origin:   "https://github.com/zeldaret/ZAPD.git"
  branch:   "master"
  commit:   "86160be69"
git-subrepo:
  version:  "0.4.3"
  origin:   "???"
  commit:   "???"

* Change nanoseconds to seconds in extract_assets.py

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>
2021-05-30 11:09:59 -04:00

37 lines
1.1 KiB
C++

#include "SetSkyboxSettings.h"
#include "Globals.h"
#include "StringHelper.h"
SetSkyboxSettings::SetSkyboxSettings(ZFile* nParent) : ZRoomCommand(nParent)
{
}
void SetSkyboxSettings::ParseRawData()
{
ZRoomCommand::ParseRawData();
unk1 = cmdArg1;
skyboxNumber = parent->GetRawData().at(rawDataIndex + 0x04);
cloudsType = parent->GetRawData().at(rawDataIndex + 0x05);
isIndoors = parent->GetRawData().at(rawDataIndex + 0x06);
}
std::string SetSkyboxSettings::GetBodySourceCode() const
{
std::string indoors = StringHelper::BoolStr(isIndoors);
if (Globals::Instance->game == ZGame::MM_RETAIL)
return StringHelper::Sprintf("SCENE_CMD_SKYBOX_SETTINGS(0x%02X, %i, %i, %s)", unk1,
skyboxNumber, cloudsType, indoors.c_str());
return StringHelper::Sprintf("SCENE_CMD_SKYBOX_SETTINGS(%i, %i, %s)", skyboxNumber, cloudsType,
indoors.c_str());
}
std::string SetSkyboxSettings::GetCommandCName() const
{
return "SCmdSkyboxSettings";
}
RoomCommand SetSkyboxSettings::GetRoomCommand() const
{
return RoomCommand::SetSkyboxSettings;
}