2015-04-27 02:50:50 +00:00
|
|
|
// Emacs style mode select -*- C++ -*-
|
2014-11-19 00:45:57 +00:00
|
|
|
//-----------------------------------------------------------------------------
|
|
|
|
//
|
|
|
|
// Copyright(C) 2004 Stephen McGranahan
|
|
|
|
//
|
|
|
|
// 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.
|
2015-04-27 02:50:50 +00:00
|
|
|
//
|
2014-11-19 00:45:57 +00:00
|
|
|
// 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.
|
2015-04-27 02:50:50 +00:00
|
|
|
//
|
2014-11-19 00:45:57 +00:00
|
|
|
// 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
|
|
//
|
|
|
|
//--------------------------------------------------------------------------
|
|
|
|
//
|
|
|
|
// DESCRIPTION:
|
|
|
|
// Slopes
|
|
|
|
// SoM created 05/10/09
|
|
|
|
//
|
|
|
|
//-----------------------------------------------------------------------------
|
|
|
|
|
|
|
|
#ifndef P_SLOPES_H__
|
|
|
|
#define P_SLOPES_H__
|
|
|
|
|
|
|
|
#ifdef ESLOPE
|
2015-04-27 02:50:50 +00:00
|
|
|
void P_ResetDynamicSlopes(void);
|
|
|
|
void P_RunDynamicSlopes(void);
|
2014-11-19 00:45:57 +00:00
|
|
|
// P_SpawnSlope_Line
|
|
|
|
// Creates one or more slopes based on the given line type and front/back
|
|
|
|
// sectors.
|
|
|
|
void P_SpawnSlope_Line(int linenum);
|
|
|
|
|
2015-04-27 03:20:03 +00:00
|
|
|
#ifdef SPRINGCLEAN
|
2014-11-19 00:45:57 +00:00
|
|
|
// Loads just map objects that make slopes,
|
|
|
|
// terrain affecting objects have to be spawned first
|
|
|
|
void P_SetSlopesFromVertexHeights(lumpnum_t lumpnum);
|
|
|
|
|
|
|
|
typedef enum
|
|
|
|
{
|
|
|
|
THING_SlopeFloorPointLine = 9500,
|
|
|
|
THING_SlopeCeilingPointLine = 9501,
|
|
|
|
THING_SetFloorSlope = 9502,
|
|
|
|
THING_SetCeilingSlope = 9503,
|
|
|
|
THING_CopyFloorPlane = 9510,
|
|
|
|
THING_CopyCeilingPlane = 9511,
|
|
|
|
THING_VavoomFloor=1500,
|
|
|
|
THING_VavoomCeiling=1501,
|
|
|
|
THING_VertexFloorZ=1504,
|
|
|
|
THING_VertexCeilingZ=1505,
|
|
|
|
} slopething_e;
|
2015-04-27 03:20:03 +00:00
|
|
|
#endif
|
2014-11-19 00:45:57 +00:00
|
|
|
|
|
|
|
//
|
|
|
|
// P_CopySectorSlope
|
|
|
|
//
|
|
|
|
// Searches through tagged sectors and copies
|
|
|
|
//
|
|
|
|
void P_CopySectorSlope(line_t *line);
|
|
|
|
|
|
|
|
// Returns the height of the sloped plane at (x, y) as a fixed_t
|
|
|
|
fixed_t P_GetZAt(pslope_t *slope, fixed_t x, fixed_t y);
|
|
|
|
|
2015-04-29 05:35:54 +00:00
|
|
|
// Lots of physics-based bullshit
|
2015-05-23 03:07:07 +00:00
|
|
|
void P_QuantizeMomentumToSlope(vector3_t *momentum, pslope_t *slope);
|
2015-04-29 05:35:54 +00:00
|
|
|
void P_SlopeLaunch(mobj_t *mo);
|
2015-05-13 21:15:32 +00:00
|
|
|
void P_HandleSlopeLanding(mobj_t *thing, pslope_t *slope);
|
2015-04-29 05:35:54 +00:00
|
|
|
void P_ButteredSlope(mobj_t *mo);
|
|
|
|
|
2014-11-19 00:45:57 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
// EOF
|
|
|
|
#endif // #ifdef ESLOPE
|
|
|
|
|