This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <Siv3D.hpp> | |
void Main() { | |
Graphics::SetTargetFrameRateHz(60); | |
Window::SetTitle(U"五月祭 TSGLIVE 5! day-1 ライブゲームプログラミング"); | |
Scene::SetBackground(Palette::Lightblue); | |
Window::Resize({ 500, 800 }); | |
constexpr double timeDelta = 1 / 60.0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# include <Siv3D.hpp> // OpenSiv3D v0.4.2 | |
# include "JSON.hpp" | |
# include "boost/ut.hpp" | |
JSON MakeDummy() | |
{ | |
JSON json; | |
json[U"Dummy"][U"title"] = U"My title"; | |
json[U"Dummy"][U"width"] = 640; | |
json[U"Dummy"][U"height"] = 480; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# pragma once | |
# include <memory> | |
# include <variant> | |
# include "Fwd.hpp" | |
# include "TextReader.hpp" | |
# include "TextWriter.hpp" | |
# include "Array.hpp" | |
namespace s3d |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//----------------------------------------------- | |
// | |
// This file is part of the HamFramework for Siv3D. | |
// | |
// Copyright (C) 2014-2017 HAMSTRO | |
// Copyright (c) 2017 OpenSiv3D Project | |
// | |
// Licensed under the MIT License. | |
// | |
//----------------------------------------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# include <Siv3D.hpp> // OpenSiv3D v0.1.6 | |
# include "cpptoml.h" | |
namespace toml | |
{ | |
class TOMLValue; | |
} | |
namespace s3d | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <Siv3D.hpp> | |
// image を大きさ size の画像に分割 | |
Array<Texture> makeDividedTexture(const Image& image, const Size& size) { | |
// 分割数 | |
const Size numDiv{ image.size.x / size.x, image.size.y / size.y }; | |
Array<Texture> result; | |
result.reserve(numDiv.x * numDiv.y); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <Siv3D.hpp> | |
#include <array> | |
#include <vector> | |
#include <algorithm> | |
using ShapeType = std::array<std::array<bool, 4>, 4>; | |
struct TetrominoInfo { | |
ShapeType shape; | |
Color color; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdexcept> | |
#include <string> | |
#include <tuple> | |
#include "Pasolib.hpp" | |
#include "felicalib.h" | |
#pragma comment(lib, "felicalib.lib") | |
namespace pasolib { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <string.h> | |
#include <stdbool.h> | |
#include "sc1.h" | |
#define DELTA_X 1 | |
#define DELTA_Y N | |
#define NUM_OF_LINE (N + N + 2) | |
#define LINE_SUM 111 | |
#define HOLE_NUM 15 |