OpenSiv3D for Web
This page is targeted who uses the previous version of OpenSiv3D for Web and no longer maintained.

OpenSiv3D for Web brings you to developing interactive WebGL application with C++17!
Getting Started
Download OpenSiv3D for Web Or Try OpenSiv3D for Web on Browser
# include <Siv3D.hpp> // OpenSiv3D v0.4.3
void Main()
{
Scene::SetBackground(ColorF(0.8, 0.9, 1.0));
const Font font(60);
const Texture cat(Emoji(U"🐈"));
Vec2 catPos(640, 450);
Platform::Web::System::SetMainLoop([&]()
{
System::Update();
font(U"Hello, Siv3D!🐣").drawAt(Scene::Center(), Palette::Black);
cat.resized(100 + Periodic::Sine0_1(1s) * 20).drawAt(catPos);
Circle(Cursor::Pos(), 40).draw(ColorF(1, 0, 0, 0.5));
if (KeyA.down())
{
Print << U"Hello!";
}
if (SimpleGUI::Button(U"Move the cat", Vec2(600, 20)))
{
catPos = RandomVec2(Scene::Rect());
}
});
}