diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index c9835df23..b51c575d6 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -861,6 +861,7 @@ set (PCH_SOURCES playsim/mapthinkers/dsectoreffect.cpp playsim/a_pickups.cpp playsim/a_action.cpp + playsim/a_fogball.cpp playsim/a_decals.cpp playsim/a_dynlight.cpp playsim/a_flashfader.cpp diff --git a/src/playsim/a_fogball.cpp b/src/playsim/a_fogball.cpp new file mode 100644 index 000000000..838d80e7f --- /dev/null +++ b/src/playsim/a_fogball.cpp @@ -0,0 +1,30 @@ +/* +** Volumetric fog spheres AKA fogballs +** Copyright (c) 2023 Nash Muhandes, Magnus Norddahl +** +** This software is provided 'as-is', without any express or implied +** warranty. In no event will the authors be held liable for any damages +** arising from the use of this software. +** +** Permission is granted to anyone to use this software for any purpose, +** including commercial applications, and to alter it and redistribute it +** freely, subject to the following restrictions: +** +** 1. The origin of this software must not be misrepresented; you must not +** claim that you wrote the original software. If you use this software +** in a product, an acknowledgment in the product documentation would be +** appreciated but is not required. +** 2. Altered source versions must be plainly marked as such, and must not be +** misrepresented as being the original software. +** 3. This notice may not be removed or altered from any source distribution. +*/ + +#include "actor.h" +#include "a_fogball.h" + +IMPLEMENT_CLASS(AFogball, false, false) + +void AFogball::Tick() +{ + Super::Tick(); +} diff --git a/src/playsim/a_fogball.h b/src/playsim/a_fogball.h new file mode 100644 index 000000000..7340f08c6 --- /dev/null +++ b/src/playsim/a_fogball.h @@ -0,0 +1,32 @@ +/* +** Volumetric fog spheres AKA fogballs +** Copyright (c) 2023 Nash Muhandes, Magnus Norddahl +** +** This software is provided 'as-is', without any express or implied +** warranty. In no event will the authors be held liable for any damages +** arising from the use of this software. +** +** Permission is granted to anyone to use this software for any purpose, +** including commercial applications, and to alter it and redistribute it +** freely, subject to the following restrictions: +** +** 1. The origin of this software must not be misrepresented; you must not +** claim that you wrote the original software. If you use this software +** in a product, an acknowledgment in the product documentation would be +** appreciated but is not required. +** 2. Altered source versions must be plainly marked as such, and must not be +** misrepresented as being the original software. +** 3. This notice may not be removed or altered from any source distribution. +*/ + +#pragma once + +#include "actor.h" + +class AFogball : public AActor +{ + DECLARE_CLASS(AFogball, AActor) + +public: + void Tick(); +}; diff --git a/wadsrc/static/zscript.txt b/wadsrc/static/zscript.txt index 04331c388..40567ce90 100644 --- a/wadsrc/static/zscript.txt +++ b/wadsrc/static/zscript.txt @@ -95,6 +95,7 @@ version "4.12" #include "zscript/actors/shared/randomspawner.zs" #include "zscript/actors/shared/dynlights.zs" #include "zscript/actors/shared/corona.zs" +#include "zscript/actors/shared/fogball.zs" #include "zscript/actors/doom/doomplayer.zs" #include "zscript/actors/doom/possessed.zs" diff --git a/wadsrc/static/zscript/actors/shared/fogball.zs b/wadsrc/static/zscript/actors/shared/fogball.zs new file mode 100644 index 000000000..22dd29382 --- /dev/null +++ b/wadsrc/static/zscript/actors/shared/fogball.zs @@ -0,0 +1,8 @@ +class Fogball : Actor native +{ + Default + { + RenderRadius 128.0; + +NOINTERACTION + } +}