mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-26 22:11:54 +00:00
directory structure cleanup
This commit is contained in:
parent
5cbca32967
commit
7379288f4b
14 changed files with 190 additions and 46 deletions
|
@ -65,5 +65,6 @@
|
||||||
#include "src/weapon.cpp"
|
#include "src/weapon.cpp"
|
||||||
|
|
||||||
// This includes the VM so it is last
|
// This includes the VM so it is last
|
||||||
|
#include "src/vmexports.cpp"
|
||||||
#include "src/d_menu.cpp"
|
#include "src/d_menu.cpp"
|
||||||
|
|
||||||
|
|
|
@ -140,6 +140,18 @@ public:
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ChangeType(PClass* newtype)
|
||||||
|
{
|
||||||
|
if (newtype->IsDescendantOf(RUNTIME_CLASS(DBloodActor)) && newtype->Size == RUNTIME_CLASS(DBloodActor)->Size && GetClass()->Size == RUNTIME_CLASS(DBloodActor)->Size)
|
||||||
|
{
|
||||||
|
// It sucks having to do this but the game heavily depends on being able to swap out the class type and often uses this to manage actor state.
|
||||||
|
// We'll allow this only for classes that do not add their own data, though.
|
||||||
|
SetClass(newtype);
|
||||||
|
//spr.setspritetexture(GetDefaultByType(newtype)->spr.spritetexture());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
int GetType() const
|
int GetType() const
|
||||||
{
|
{
|
||||||
return spr.type;
|
return spr.type;
|
||||||
|
|
|
@ -1,25 +1,3 @@
|
||||||
//-------------------------------------------------------------------------
|
|
||||||
/*
|
|
||||||
Copyright (C) 2010-2019 EDuke32 developers and contributors
|
|
||||||
Copyright (C) 2019 Nuke.YKT
|
|
||||||
|
|
||||||
This file is part of NBlood.
|
|
||||||
|
|
||||||
NBlood is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU General Public License version 2
|
|
||||||
as published by the Free Software Foundation.
|
|
||||||
|
|
||||||
This program is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
||||||
|
|
||||||
See the GNU General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
|
||||||
along with this program; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
||||||
*/
|
|
||||||
//-------------------------------------------------------------------------
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "misc.h"
|
#include "misc.h"
|
||||||
|
|
42
source/games/blood/src/vmexports.cpp
Normal file
42
source/games/blood/src/vmexports.cpp
Normal file
|
@ -0,0 +1,42 @@
|
||||||
|
//-------------------------------------------------------------------------
|
||||||
|
/*
|
||||||
|
Copyright (C) 2020-2023 - Christoph Oelckers
|
||||||
|
|
||||||
|
This file is part of Raze
|
||||||
|
|
||||||
|
This is free software; you can redistribute it and/or
|
||||||
|
modify it under the terms of the GNU General Public License
|
||||||
|
as published by the Free Software Foundation; either version 2
|
||||||
|
of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
|
||||||
|
See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
*/
|
||||||
|
//-------------------------------------------------------------------------
|
||||||
|
|
||||||
|
#include "vm.h"
|
||||||
|
#include "ns.h"
|
||||||
|
#include "buildtiles.h"
|
||||||
|
#include "blood.h"
|
||||||
|
BEGIN_BLD_NS
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
void Blood_ChangeType(DBloodActor* self, PClassActor* type)
|
||||||
|
{
|
||||||
|
self->ChangeType(type);
|
||||||
|
}
|
||||||
|
|
||||||
|
DEFINE_ACTION_FUNCTION_NATIVE(DBloodActor, ChangeType, Blood_ChangeType)
|
||||||
|
{
|
||||||
|
PARAM_SELF_PROLOGUE(DBloodActor);
|
||||||
|
PARAM_POINTER(type, PClassActor);
|
||||||
|
self->ChangeType(type);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
END_BLD_NS
|
|
@ -30,14 +30,14 @@ version "4.10"
|
||||||
|
|
||||||
|
|
||||||
#include "zscript/constants.zs"
|
#include "zscript/constants.zs"
|
||||||
#include "zscript/razebase.zs"
|
#include "zscript/games/razebase.zs"
|
||||||
#include "zscript/summary.zs"
|
#include "zscript/summary.zs"
|
||||||
#include "zscript/statusbar.zs"
|
#include "zscript/games/statusbar.zs"
|
||||||
#include "zscript/usermapmenu.zs"
|
#include "zscript/games/usermapmenu.zs"
|
||||||
#include "zscript/maptypes.zs"
|
#include "zscript/games/maptypes.zs"
|
||||||
#include "zscript/coreactor.zs"
|
#include "zscript/games/coreactor.zs"
|
||||||
#include "zscript/level_postprocessor.zs"
|
#include "zscript/level_postprocessor.zs"
|
||||||
#include "zscript/level_compatibility.zs"
|
#include "zscript/games/level_compatibility.zs"
|
||||||
#include "zscript/alt_hud.zs"
|
#include "zscript/alt_hud.zs"
|
||||||
#include "zscript/games/duke/dukeactor.zs"
|
#include "zscript/games/duke/dukeactor.zs"
|
||||||
#include "zscript/games/blood/bloodactor.zs"
|
#include "zscript/games/blood/bloodactor.zs"
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
class BloodActor : CoreActor native
|
class BloodActor : CoreActor native
|
||||||
{
|
{
|
||||||
|
native void ChangeType(class<BloodActor> newtype);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,18 +0,0 @@
|
||||||
|
|
||||||
// Base class for game screens.
|
|
||||||
class GameScreen : Object ui
|
|
||||||
{
|
|
||||||
virtual bool OnEvent(InputEvent ev)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
virtual bool Tick(int framenum)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
virtual void Draw()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
}
|
|
127
wadsrc/static/zscript/zscript_license.txt
Normal file
127
wadsrc/static/zscript/zscript_license.txt
Normal file
|
@ -0,0 +1,127 @@
|
||||||
|
Unless noted differently in the file, the following license applies to all ZScript sources *outside* the 'engine' folder:
|
||||||
|
|
||||||
|
//-----------------------------------------------------------------------------
|
||||||
|
//
|
||||||
|
// Copyright 1993-2023 Christoph Oelckers et.al.
|
||||||
|
//
|
||||||
|
// This program is free software: you can redistribute it and/or modify
|
||||||
|
// it under the terms of the GNU General Public License as published by
|
||||||
|
// the Free Software Foundation, either version 2 of the License, or
|
||||||
|
// (at your option) any later version.
|
||||||
|
//
|
||||||
|
// This program is distributed in the hope that it will be useful,
|
||||||
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
// GNU General Public License for more details.
|
||||||
|
//
|
||||||
|
// You should have received a copy of the GNU General Public License
|
||||||
|
// along with this program. If not, see http://www.gnu.org/licenses/
|
||||||
|
//
|
||||||
|
//-----------------------------------------------------------------------------
|
||||||
|
//
|
||||||
|
|
||||||
|
Unless noted differently in the file, the following license applies to all ZScript sources *inside* the 'engine' folder:
|
||||||
|
|
||||||
|
/*
|
||||||
|
**
|
||||||
|
**---------------------------------------------------------------------------
|
||||||
|
** Copyright 2005-2023 Randy Heit, Christoph Oelckers et.al.
|
||||||
|
** All rights reserved.
|
||||||
|
**
|
||||||
|
** Redistribution and use in source and binary forms, with or without
|
||||||
|
** modification, are permitted provided that the following conditions
|
||||||
|
** are met:
|
||||||
|
**
|
||||||
|
** 1. Redistributions of source code must retain the above copyright
|
||||||
|
** notice, this list of conditions and the following disclaimer.
|
||||||
|
** 2. Redistributions in binary form must reproduce the above copyright
|
||||||
|
** notice, this list of conditions and the following disclaimer in the
|
||||||
|
** documentation and/or other materials provided with the distribution.
|
||||||
|
** 3. The name of the author may not be used to endorse or promote products
|
||||||
|
** derived from this software without specific prior written permission.
|
||||||
|
**
|
||||||
|
** THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
|
||||||
|
** IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||||
|
** OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||||
|
** IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||||
|
** INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
|
||||||
|
** NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||||
|
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||||
|
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||||
|
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||||
|
** THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
|
**---------------------------------------------------------------------------
|
||||||
|
**
|
||||||
|
*/
|
||||||
|
|
||||||
|
Unless noted differently in the file, the following license applies to all ZScript sources *inside* the 'games/duke' folder:
|
||||||
|
Unless noted differently in the file, all scripted code for Duke Nukem 3D/Redneck Rampage that has not been newly written originates from:
|
||||||
|
* EDuke 2.0 for Duke Nukem 3D
|
||||||
|
* DukeGDX for the World Tour extensions
|
||||||
|
* Redneck Reconstructed for Redneck Rampage
|
||||||
|
|
||||||
|
//-------------------------------------------------------------------------
|
||||||
|
/*
|
||||||
|
Copyright (C) 1996, 2003 - 3D Realms Entertainment
|
||||||
|
Copyright (C) 2000, 2003 - Matt Saettler (EDuke Enhancements)
|
||||||
|
Copyright (C) 2017-2019 Nuke.YKT
|
||||||
|
Copyright (C) 2020-2023 - Christoph Oelckers
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or
|
||||||
|
modify it under the terms of the GNU General Public License
|
||||||
|
as published by the Free Software Foundation; either version 2
|
||||||
|
of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
|
||||||
|
See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
*/
|
||||||
|
//-------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Unless noted differently in the file, the following license applies to all ZScript sources *inside* the 'games/blood' folder:
|
||||||
|
Unless noted differently in the file, all scripted code for Blood that has not been newly written originates from Blood-RE:
|
||||||
|
|
||||||
|
//-------------------------------------------------------------------------
|
||||||
|
/*
|
||||||
|
Copyright (C) 2018, 2022 nukeykt
|
||||||
|
Copyright (C) 2020-2022 Christoph Oelckers
|
||||||
|
|
||||||
|
This file is part of Raze
|
||||||
|
|
||||||
|
Raze is free software; you can redistribute it and/or
|
||||||
|
modify it under the terms of the GNU General Public License version 2
|
||||||
|
of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
|
||||||
|
See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
*/
|
||||||
|
//-------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Unless noted differently in the file, the following license applies to all ZScript sources *inside* the 'games/sw' folder:
|
||||||
|
|
||||||
|
//-------------------------------------------------------------------------
|
||||||
|
/*
|
||||||
|
Copyright (C) 1997, 2005 - 3D Realms Entertainment
|
||||||
|
Copyright (C) 2020-2022 Christoph Oelckers
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or
|
||||||
|
modify it under the terms of the GNU General Public License
|
||||||
|
as published by the Free Software Foundation; either version 2
|
||||||
|
of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
|
||||||
|
See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
*/
|
||||||
|
//-------------------------------------------------------------------------
|
||||||
|
|
Loading…
Reference in a new issue