mirror of
https://github.com/unknownworlds/NS.git
synced 2024-11-26 22:41:00 +00:00
Reverted changes to revision 45.
git-svn-id: https://unknownworlds.svn.cloudforge.com/ns1@76 67975925-1194-0748-b3d5-c16f83f1a3a1
This commit is contained in:
parent
8b8fd61e6c
commit
cbd7e95495
12 changed files with 31 additions and 453 deletions
|
@ -34,10 +34,6 @@
|
||||||
#include "mod/AvHNetworkMessages.h"
|
#include "mod/AvHNetworkMessages.h"
|
||||||
#include "ui/ChatPanel.h"
|
#include "ui/ChatPanel.h"
|
||||||
|
|
||||||
// tankefugl: duck toggle
|
|
||||||
bool g_bDuckToggled;
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
class CHLVoiceStatusHelper : public IVoiceStatusHelper
|
class CHLVoiceStatusHelper : public IVoiceStatusHelper
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
@ -196,10 +192,6 @@ void CHud :: Init( void )
|
||||||
m_iLogo = 0;
|
m_iLogo = 0;
|
||||||
m_iFOV = 0;
|
m_iFOV = 0;
|
||||||
|
|
||||||
// tankefugl: duck toggle
|
|
||||||
g_bDuckToggled = false;
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
CVAR_CREATE( "zoom_sensitivity_ratio", "1.2", 0 );
|
CVAR_CREATE( "zoom_sensitivity_ratio", "1.2", 0 );
|
||||||
default_fov = CVAR_CREATE( "default_fov", "90", 0 );
|
default_fov = CVAR_CREATE( "default_fov", "90", 0 );
|
||||||
m_pCvarStealMouse = CVAR_CREATE( "hud_capturemouse", "1", FCVAR_ARCHIVE );
|
m_pCvarStealMouse = CVAR_CREATE( "hud_capturemouse", "1", FCVAR_ARCHIVE );
|
||||||
|
|
|
@ -21,10 +21,6 @@
|
||||||
#include "common/r_efx.h"
|
#include "common/r_efx.h"
|
||||||
#include "mod/AvHNetworkMessages.h"
|
#include "mod/AvHNetworkMessages.h"
|
||||||
|
|
||||||
// tankefugl: duck toggle
|
|
||||||
extern bool g_bDuckToggled;
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
#define MAX_CLIENTS 32
|
#define MAX_CLIENTS 32
|
||||||
|
|
||||||
#if !defined( _TFC )
|
#if !defined( _TFC )
|
||||||
|
@ -50,10 +46,6 @@ int CHud :: MsgFunc_ResetHUD(const char *pszName, int iSize, void *pbuf )
|
||||||
// reset sensitivity
|
// reset sensitivity
|
||||||
m_flMouseSensitivity = 0;
|
m_flMouseSensitivity = 0;
|
||||||
|
|
||||||
// tankefugl: duck toggle
|
|
||||||
g_bDuckToggled = false;
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -61,10 +61,6 @@ extern "C"
|
||||||
#include "engine/APIProxy.h"
|
#include "engine/APIProxy.h"
|
||||||
#include "Exports.h"
|
#include "Exports.h"
|
||||||
|
|
||||||
// tankefugl: duck toggle
|
|
||||||
extern bool g_bDuckToggled;
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
extern int g_iAlive;
|
extern int g_iAlive;
|
||||||
|
|
||||||
extern int g_weaponselect;
|
extern int g_weaponselect;
|
||||||
|
@ -794,12 +790,6 @@ void IN_DuckDown(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
void IN_DuckUp(void) {KeyUp(&in_duck);}
|
void IN_DuckUp(void) {KeyUp(&in_duck);}
|
||||||
// tankefugl: duck toggle
|
|
||||||
void IN_DuckToggle(void)
|
|
||||||
{
|
|
||||||
g_bDuckToggled = !g_bDuckToggled;
|
|
||||||
}
|
|
||||||
// :tankefugl
|
|
||||||
void IN_ReloadDown(void) {KeyDown(&in_reload);}
|
void IN_ReloadDown(void) {KeyDown(&in_reload);}
|
||||||
void IN_ReloadUp(void) {KeyUp(&in_reload);}
|
void IN_ReloadUp(void) {KeyUp(&in_reload);}
|
||||||
void IN_Alt1Down(void) {KeyDown(&in_alt1);}
|
void IN_Alt1Down(void) {KeyDown(&in_alt1);}
|
||||||
|
@ -1328,19 +1318,10 @@ int CL_ButtonBits( int bResetState )
|
||||||
bits |= IN_ATTACK;
|
bits |= IN_ATTACK;
|
||||||
}
|
}
|
||||||
|
|
||||||
// tankefugl: duck toggle
|
if (in_duck.state & 3)
|
||||||
if ( g_bDuckToggled )
|
|
||||||
{
|
|
||||||
if (!(in_duck.state & 3))
|
|
||||||
{
|
{
|
||||||
bits |= IN_DUCK;
|
bits |= IN_DUCK;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
else if (in_duck.state & 3)
|
|
||||||
{
|
|
||||||
bits |= IN_DUCK;
|
|
||||||
}
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
if (in_jump.state & 3)
|
if (in_jump.state & 3)
|
||||||
{
|
{
|
||||||
|
@ -1508,9 +1489,6 @@ void InitInput (void)
|
||||||
gEngfuncs.pfnAddCommand ("-jlook", IN_JLookUp);
|
gEngfuncs.pfnAddCommand ("-jlook", IN_JLookUp);
|
||||||
gEngfuncs.pfnAddCommand ("+duck", IN_DuckDown);
|
gEngfuncs.pfnAddCommand ("+duck", IN_DuckDown);
|
||||||
gEngfuncs.pfnAddCommand ("-duck", IN_DuckUp);
|
gEngfuncs.pfnAddCommand ("-duck", IN_DuckUp);
|
||||||
// tankefugl: duck toggle
|
|
||||||
gEngfuncs.pfnAddCommand ("toggleduck", IN_DuckToggle);
|
|
||||||
// :tankefugl
|
|
||||||
gEngfuncs.pfnAddCommand ("+reload", IN_ReloadDown);
|
gEngfuncs.pfnAddCommand ("+reload", IN_ReloadDown);
|
||||||
gEngfuncs.pfnAddCommand ("-reload", IN_ReloadUp);
|
gEngfuncs.pfnAddCommand ("-reload", IN_ReloadUp);
|
||||||
gEngfuncs.pfnAddCommand ("+alt1", IN_Alt1Down);
|
gEngfuncs.pfnAddCommand ("+alt1", IN_Alt1Down);
|
||||||
|
|
|
@ -333,7 +333,6 @@ void CVoiceStatus::CreateEntities()
|
||||||
int iOutModel = 0;
|
int iOutModel = 0;
|
||||||
for(int i=0; i < VOICE_MAX_PLAYERS; i++)
|
for(int i=0; i < VOICE_MAX_PLAYERS; i++)
|
||||||
{
|
{
|
||||||
|
|
||||||
if(!m_VoicePlayers[i])
|
if(!m_VoicePlayers[i])
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
@ -361,13 +360,7 @@ void CVoiceStatus::CreateEntities()
|
||||||
pEnt->baseline.renderamt = 255;
|
pEnt->baseline.renderamt = 255;
|
||||||
pEnt->curstate.renderfx = kRenderFxNoDissipation;
|
pEnt->curstate.renderfx = kRenderFxNoDissipation;
|
||||||
pEnt->curstate.framerate = 1;
|
pEnt->curstate.framerate = 1;
|
||||||
// tankefugl: different sprite for each team
|
|
||||||
if (pClient->curstate.team <= SPR_Frames(m_VoiceHeadModel))
|
|
||||||
pEnt->curstate.frame = pClient->curstate.team;
|
|
||||||
else
|
|
||||||
pEnt->curstate.frame = 0;
|
pEnt->curstate.frame = 0;
|
||||||
//pEnt->curstate.frame = 0;
|
|
||||||
// :tankefugl
|
|
||||||
pEnt->model = (struct model_s*)gEngfuncs.GetSpritePointer(m_VoiceHeadModel);
|
pEnt->model = (struct model_s*)gEngfuncs.GetSpritePointer(m_VoiceHeadModel);
|
||||||
pEnt->angles[0] = pEnt->angles[1] = pEnt->angles[2] = 0;
|
pEnt->angles[0] = pEnt->angles[1] = pEnt->angles[2] = 0;
|
||||||
pEnt->curstate.scale = 0.5f;
|
pEnt->curstate.scale = 0.5f;
|
||||||
|
@ -395,7 +388,6 @@ void CVoiceStatus::UpdateSpeakerStatus(int entindex, qboolean bTalking)
|
||||||
gEngfuncs.pfnConsolePrint( msg );
|
gEngfuncs.pfnConsolePrint( msg );
|
||||||
}
|
}
|
||||||
|
|
||||||
gEngfuncs.Con_Printf("\n");
|
|
||||||
// Is it the local player talking?
|
// Is it the local player talking?
|
||||||
if( entindex == -1 )
|
if( entindex == -1 )
|
||||||
{
|
{
|
||||||
|
@ -734,11 +726,9 @@ void CVoiceStatus::RepositionLabels()
|
||||||
|
|
||||||
y += bgTall + 2;
|
y += bgTall + 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
if( m_pLocalBitmap && m_pAckBitmap && m_pLocalLabel && (m_bTalking || m_bServerAcked) )
|
if( m_pLocalBitmap && m_pAckBitmap && m_pLocalLabel && (m_bTalking || m_bServerAcked) )
|
||||||
{
|
{
|
||||||
if (m_pParentPanel) {
|
|
||||||
int z = 3;
|
|
||||||
}
|
|
||||||
m_pLocalLabel->setParent(*m_pParentPanel);
|
m_pLocalLabel->setParent(*m_pParentPanel);
|
||||||
m_pLocalLabel->setVisible( true );
|
m_pLocalLabel->setVisible( true );
|
||||||
|
|
||||||
|
|
|
@ -646,10 +646,6 @@ void AvHHud::ClearData()
|
||||||
this->mCurrentGhostIsValid = false;
|
this->mCurrentGhostIsValid = false;
|
||||||
|
|
||||||
this->mAmbientSounds.clear();
|
this->mAmbientSounds.clear();
|
||||||
|
|
||||||
// tankefugl: 0000971
|
|
||||||
this->mTeammateOrder.clear();
|
|
||||||
// :tankefugl
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -2040,41 +2036,31 @@ void AvHHud::OrderNotification(const AvHOrder& inOrder)
|
||||||
AvHOrderType theOrderType = inOrder.GetOrderType();
|
AvHOrderType theOrderType = inOrder.GetOrderType();
|
||||||
AvHHUDSound theSound = HUD_SOUND_INVALID;
|
AvHHUDSound theSound = HUD_SOUND_INVALID;
|
||||||
|
|
||||||
// tankefugl: 0000992
|
|
||||||
// popup indicator for order
|
|
||||||
bool thePopup = false;
|
|
||||||
|
|
||||||
// Play HUD sound depending on order
|
// Play HUD sound depending on order
|
||||||
switch(theOrderType)
|
switch(theOrderType)
|
||||||
{
|
{
|
||||||
case ORDERTYPEL_MOVE:
|
case ORDERTYPEL_MOVE:
|
||||||
theSound = HUD_SOUND_ORDER_MOVE;
|
theSound = HUD_SOUND_ORDER_MOVE;
|
||||||
thePopup = true;
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ORDERTYPET_ATTACK:
|
case ORDERTYPET_ATTACK:
|
||||||
theSound = HUD_SOUND_ORDER_ATTACK;
|
theSound = HUD_SOUND_ORDER_ATTACK;
|
||||||
thePopup = true;
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ORDERTYPET_BUILD:
|
case ORDERTYPET_BUILD:
|
||||||
theSound = HUD_SOUND_ORDER_BUILD;
|
theSound = HUD_SOUND_ORDER_BUILD;
|
||||||
thePopup = true;
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ORDERTYPET_GUARD:
|
case ORDERTYPET_GUARD:
|
||||||
theSound = HUD_SOUND_ORDER_GUARD;
|
theSound = HUD_SOUND_ORDER_GUARD;
|
||||||
thePopup = true;
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ORDERTYPET_WELD:
|
case ORDERTYPET_WELD:
|
||||||
theSound = HUD_SOUND_ORDER_WELD;
|
theSound = HUD_SOUND_ORDER_WELD;
|
||||||
thePopup = true;
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ORDERTYPET_GET:
|
case ORDERTYPET_GET:
|
||||||
theSound = HUD_SOUND_ORDER_GET;
|
theSound = HUD_SOUND_ORDER_GET;
|
||||||
thePopup = true;
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2084,13 +2070,6 @@ void AvHHud::OrderNotification(const AvHOrder& inOrder)
|
||||||
}
|
}
|
||||||
|
|
||||||
this->PlayHUDSound(theSound);
|
this->PlayHUDSound(theSound);
|
||||||
|
|
||||||
// tankefugl: 0000992
|
|
||||||
if (thePopup)
|
|
||||||
{
|
|
||||||
this->SetDisplayOrder(2, this->GetFrameForOrderType(theOrderType), "", "", "");
|
|
||||||
}
|
|
||||||
// :tankefugl
|
|
||||||
}
|
}
|
||||||
//}
|
//}
|
||||||
}
|
}
|
||||||
|
@ -2310,83 +2289,6 @@ int AvHHud::MiniMap(const char* pszName, int iSize, void* pbuf)
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
// tankefugl: 0000971
|
|
||||||
BIND_MESSAGE(IssueOrder);
|
|
||||||
int AvHHud::IssueOrder(const char* pszName, int iSize, void* pbuf)
|
|
||||||
{
|
|
||||||
int ordertype, ordersource, ordertarget;
|
|
||||||
NetMsg_IssueOrder( pbuf, iSize, ordertype, ordersource, ordertarget);
|
|
||||||
|
|
||||||
float now = this->GetTimeOfLastUpdate();
|
|
||||||
TeammateOrderListType::iterator theIter = this->mTeammateOrder.find(ordersource);
|
|
||||||
if (theIter == this->mTeammateOrder.end())
|
|
||||||
{
|
|
||||||
this->mTeammateOrder.insert(theIter, pair<int, TeammateOrderType>(ordersource, TeammateOrderType(ordertype, now)));
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
TeammateOrderType *theOrder = &((*theIter).second);
|
|
||||||
(*theOrder).first = ordertype;
|
|
||||||
(*theOrder).second = now;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (this->GetInTopDownMode() == false)
|
|
||||||
{
|
|
||||||
cl_entity_s* theLocalPlayer = gEngfuncs.GetLocalPlayer();
|
|
||||||
if (theLocalPlayer->index == ordertarget)
|
|
||||||
{
|
|
||||||
hud_player_info_t info;
|
|
||||||
memset(&info, 0, sizeof(info));
|
|
||||||
GetPlayerInfo(ordersource, &info);
|
|
||||||
|
|
||||||
string temp;
|
|
||||||
string nameFormat;
|
|
||||||
// TODO: fetch from titles.txt
|
|
||||||
switch (ordertype) {
|
|
||||||
case TEAMMATE_MARINE_ORDER_WELD:
|
|
||||||
nameFormat = "Weld %s";
|
|
||||||
break;
|
|
||||||
case TEAMMATE_MARINE_ORDER_FOLLOW:
|
|
||||||
nameFormat = "Follow %s";
|
|
||||||
break;
|
|
||||||
case TEAMMATE_MARINE_ORDER_COVER:
|
|
||||||
nameFormat = "%s is covering";
|
|
||||||
break;
|
|
||||||
case TEAMMATE_MARINE_ORDER_UNKNOWN:
|
|
||||||
nameFormat = "%s";
|
|
||||||
break;
|
|
||||||
case TEAMMATE_ALIEN_ORDER_HEAL:
|
|
||||||
nameFormat = "Heal %s";
|
|
||||||
break;
|
|
||||||
case TEAMMATE_ALIEN_ORDER_FOLLOW:
|
|
||||||
nameFormat = "Follow %s";
|
|
||||||
break;
|
|
||||||
case TEAMMATE_ALIEN_ORDER_COVER:
|
|
||||||
nameFormat = "%s is covering";
|
|
||||||
break;
|
|
||||||
case TEAMMATE_ALIEN_ORDER_UNKNOWN:
|
|
||||||
nameFormat = "%s";
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
sprintf(temp, nameFormat.c_str(), info.name);
|
|
||||||
|
|
||||||
this->SetDisplayOrder(1, ordertype, temp, "", "");
|
|
||||||
}
|
|
||||||
if (theLocalPlayer->index == ordersource)
|
|
||||||
{
|
|
||||||
this->mCurrentOrderTarget = ordertarget;
|
|
||||||
this->mCurrentOrderType = ordertype;
|
|
||||||
this->mCurrentOrderTime = now;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// char temp[255];
|
|
||||||
// sprintf(temp, "IssueOrder received - type %d source %d target %d at time %f\n", ordertype, ordersource, ordertarget, now);
|
|
||||||
// gEngfuncs.Con_Printf(temp);
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
BIND_MESSAGE(ServerVar);
|
BIND_MESSAGE(ServerVar);
|
||||||
int AvHHud::ServerVar(const char* pszName, int iSize, void* pbuf)
|
int AvHHud::ServerVar(const char* pszName, int iSize, void* pbuf)
|
||||||
|
@ -2559,20 +2461,6 @@ void AvHHud::ResetGame(bool inMapChanged)
|
||||||
this->mTimeOfLastLevelUp = -1;
|
this->mTimeOfLastLevelUp = -1;
|
||||||
|
|
||||||
memset(this->mMenuImpulses, MESSAGE_NULL, sizeof(AvHMessageID)*kNumUpgradeLines);
|
memset(this->mMenuImpulses, MESSAGE_NULL, sizeof(AvHMessageID)*kNumUpgradeLines);
|
||||||
|
|
||||||
// tankefugl: 0000992 & 0000971
|
|
||||||
this->mTeammateOrder.clear();
|
|
||||||
this->mCurrentOrderTarget = 0;
|
|
||||||
this->mCurrentOrderType = 0;
|
|
||||||
this->mCurrentOrderTime = 0.0f;
|
|
||||||
|
|
||||||
this->mDisplayOrderTime = 0.0f;
|
|
||||||
this->mDisplayOrderType = 0;
|
|
||||||
this->mDisplayOrderIndex = 0;
|
|
||||||
this->mDisplayOrderText1 = "";
|
|
||||||
this->mDisplayOrderText2 = "";
|
|
||||||
this->mDisplayOrderText3 = "";
|
|
||||||
// :tankefugl
|
|
||||||
}
|
}
|
||||||
|
|
||||||
BIND_MESSAGE(SetGmma);
|
BIND_MESSAGE(SetGmma);
|
||||||
|
@ -3587,9 +3475,6 @@ void AvHHud::Init(void)
|
||||||
HOOK_MESSAGE(AlienInfo);
|
HOOK_MESSAGE(AlienInfo);
|
||||||
HOOK_MESSAGE(DebugCSP);
|
HOOK_MESSAGE(DebugCSP);
|
||||||
HOOK_MESSAGE(TechSlots);
|
HOOK_MESSAGE(TechSlots);
|
||||||
// tankefugl: 0000971
|
|
||||||
HOOK_MESSAGE(IssueOrder);
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
HOOK_MESSAGE(ServerVar);
|
HOOK_MESSAGE(ServerVar);
|
||||||
|
|
||||||
|
|
|
@ -397,9 +397,6 @@ public:
|
||||||
|
|
||||||
int GameStatus(const char* pszName, int iSize, void* pbuf);
|
int GameStatus(const char* pszName, int iSize, void* pbuf);
|
||||||
int MiniMap(const char* pszName, int iSize, void* pbuf);
|
int MiniMap(const char* pszName, int iSize, void* pbuf);
|
||||||
// tankefugl: 0000971
|
|
||||||
int IssueOrder(const char* pszName, int iSize, void* pbuf);
|
|
||||||
// :tankefugl
|
|
||||||
int Progress(const char* pszName, int iSize, void* pbuf);
|
int Progress(const char* pszName, int iSize, void* pbuf);
|
||||||
int SetGmma(const char* pszName, int iSize, void* pbuf);
|
int SetGmma(const char* pszName, int iSize, void* pbuf);
|
||||||
int SetSelect(const char* pszName, int iSize, void* pbuf);
|
int SetSelect(const char* pszName, int iSize, void* pbuf);
|
||||||
|
@ -443,20 +440,12 @@ private:
|
||||||
void DrawMouseCursor(int inBaseX, int inBaseY);
|
void DrawMouseCursor(int inBaseX, int inBaseY);
|
||||||
void DrawOrders();
|
void DrawOrders();
|
||||||
void DrawHelpIcons();
|
void DrawHelpIcons();
|
||||||
// tankefugl: 0000971
|
|
||||||
void DrawTeammateOrders();
|
|
||||||
// tankefugl: 0000992
|
|
||||||
void DrawDisplayOrder();
|
|
||||||
void SetDisplayOrder(int inOrderType, int inOrderIndex, string inText1, string inText2, string inText3);
|
|
||||||
// :tankefugl
|
|
||||||
void DrawHUDStructureNotification();
|
void DrawHUDStructureNotification();
|
||||||
void DrawInfoLocationText();
|
void DrawInfoLocationText();
|
||||||
void DrawPlayerNames();
|
void DrawPlayerNames();
|
||||||
void DrawReticleInfo();
|
void DrawReticleInfo();
|
||||||
void DrawToolTips();
|
void DrawToolTips();
|
||||||
// tankefugl: 0000971 -- added inAlpha
|
void DrawWorldSprite(int inSpriteHandle, int inRenderMode, vec3_t inWorldPosition, int inFrame, float inWorldSize);
|
||||||
void DrawWorldSprite(int inSpriteHandle, int inRenderMode, vec3_t inWorldPosition, int inFrame, float inWorldSize, float inAlpha = 1.0f);
|
|
||||||
// :tankefugl
|
|
||||||
void DrawOrderIcon(const AvHOrder& inOrder);
|
void DrawOrderIcon(const AvHOrder& inOrder);
|
||||||
void DrawOrderText(const AvHOrder& inOrder);
|
void DrawOrderText(const AvHOrder& inOrder);
|
||||||
int GetFrameForOrderType(AvHOrderType inOrderType) const;
|
int GetFrameForOrderType(AvHOrderType inOrderType) const;
|
||||||
|
@ -595,20 +584,6 @@ private:
|
||||||
OrderListType mOrders;
|
OrderListType mOrders;
|
||||||
//AvHOrderType mOrderMode;
|
//AvHOrderType mOrderMode;
|
||||||
|
|
||||||
// tankefugl: 0000971
|
|
||||||
map< int, TeammateOrderType > mTeammateOrder;
|
|
||||||
// tankefugl: 0000992
|
|
||||||
float mDisplayOrderTime;
|
|
||||||
int mDisplayOrderType;
|
|
||||||
int mDisplayOrderIndex;
|
|
||||||
string mDisplayOrderText1;
|
|
||||||
string mDisplayOrderText2;
|
|
||||||
string mDisplayOrderText3;
|
|
||||||
int mCurrentOrderTarget;
|
|
||||||
int mCurrentOrderType;
|
|
||||||
float mCurrentOrderTime;
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
AvHMessageID mTechEvent;
|
AvHMessageID mTechEvent;
|
||||||
AvHMessageID mAlienAbility;
|
AvHMessageID mAlienAbility;
|
||||||
AvHMessageID mGroupEvent;
|
AvHMessageID mGroupEvent;
|
||||||
|
@ -696,10 +671,6 @@ private:
|
||||||
HSPRITE mMarineOrderIndicator;
|
HSPRITE mMarineOrderIndicator;
|
||||||
HSPRITE mMarineUpgradesSprite;
|
HSPRITE mMarineUpgradesSprite;
|
||||||
|
|
||||||
// tankefugl: 0000971
|
|
||||||
HSPRITE mTeammateOrderSprite;
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
typedef map<int, int> SpriteListType;
|
typedef map<int, int> SpriteListType;
|
||||||
SpriteListType mActionButtonSprites;
|
SpriteListType mActionButtonSprites;
|
||||||
//SpriteListType mHelpSprites;
|
//SpriteListType mHelpSprites;
|
||||||
|
|
|
@ -139,7 +139,6 @@
|
||||||
#include "mod/AvHSpriteAPI.h"
|
#include "mod/AvHSpriteAPI.h"
|
||||||
#include "mod/AvHParticleEditorHandler.h"
|
#include "mod/AvHParticleEditorHandler.h"
|
||||||
#include <list>
|
#include <list>
|
||||||
#include "common/entity_types.h"
|
|
||||||
|
|
||||||
void IN_GetMousePos( int *mx, int *my );
|
void IN_GetMousePos( int *mx, int *my );
|
||||||
|
|
||||||
|
@ -884,8 +883,7 @@ void AvHHud::DrawToolTips()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void AvHHud::DrawWorldSprite(int inSpriteHandle, int inRenderMode, vec3_t inWorldPosition, int inFrame, float inWorldSize, float inAlpha)
|
void AvHHud::DrawWorldSprite(int inSpriteHandle, int inRenderMode, vec3_t inWorldPosition, int inFrame, float inWorldSize)
|
||||||
// tankefugl: added inAlpha
|
|
||||||
{
|
{
|
||||||
vec3_t theUpperLeft;
|
vec3_t theUpperLeft;
|
||||||
vec3_t theLowerRight;
|
vec3_t theLowerRight;
|
||||||
|
@ -970,7 +968,7 @@ void AvHHud::DrawWorldSprite(int inSpriteHandle, int inRenderMode, vec3_t inWorl
|
||||||
|
|
||||||
//DrawScaledHUDSprite(inSpriteHandle, inRenderMode, 1, theScreenX, theScreenY, theWidth, theHeight, inFrame);
|
//DrawScaledHUDSprite(inSpriteHandle, inRenderMode, 1, theScreenX, theScreenY, theWidth, theHeight, inFrame);
|
||||||
|
|
||||||
AvHSpriteSetColor(1, 1, 1, inAlpha);
|
AvHSpriteSetColor(1, 1, 1);
|
||||||
AvHSpriteSetRenderMode(inRenderMode);
|
AvHSpriteSetRenderMode(inRenderMode);
|
||||||
AvHSpriteDraw(inSpriteHandle, inFrame, theScreenX, theScreenY, theScreenX + theWidth, theScreenY + theHeight, 0, 0, 1, 1);
|
AvHSpriteDraw(inSpriteHandle, inFrame, theScreenX, theScreenY, theScreenX + theWidth, theScreenY + theHeight, 0, 0, 1, 1);
|
||||||
|
|
||||||
|
@ -1062,14 +1060,6 @@ void AvHHud::DrawOrderText(const AvHOrder& inOrder)
|
||||||
string theTranslatedLocation = theLocationOfOrder;
|
string theTranslatedLocation = theLocationOfOrder;
|
||||||
LocalizeString(theLocationOfOrder.c_str(), theTranslatedLocation);
|
LocalizeString(theLocationOfOrder.c_str(), theTranslatedLocation);
|
||||||
|
|
||||||
// tankefugl: 0000992
|
|
||||||
string theFirstLine = theLocalizedTitle;
|
|
||||||
if(theRangeDisplayString != "")
|
|
||||||
{
|
|
||||||
theFirstLine += string(" : ") + theRangeDisplayString;
|
|
||||||
}
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
Vector theScreenPos;
|
Vector theScreenPos;
|
||||||
if(AvHCUWorldToScreen((float*)theOrderLocation, (float*)&theScreenPos))
|
if(AvHCUWorldToScreen((float*)theOrderLocation, (float*)&theScreenPos))
|
||||||
{
|
{
|
||||||
|
@ -1081,6 +1071,12 @@ void AvHHud::DrawOrderText(const AvHOrder& inOrder)
|
||||||
int theR, theG, theB;
|
int theR, theG, theB;
|
||||||
this->GetPrimaryHudColor(theR, theG, theB, false, false);
|
this->GetPrimaryHudColor(theR, theG, theB, false, false);
|
||||||
|
|
||||||
|
string theFirstLine = theLocalizedTitle;
|
||||||
|
if(theRangeDisplayString != "")
|
||||||
|
{
|
||||||
|
theFirstLine += string(" : ") + theRangeDisplayString;
|
||||||
|
}
|
||||||
|
|
||||||
// Draw order (icon above world position, text below it)
|
// Draw order (icon above world position, text below it)
|
||||||
int theBaseX = theScreenPos.x;
|
int theBaseX = theScreenPos.x;
|
||||||
int theBaseY = theScreenPos.y;
|
int theBaseY = theScreenPos.y;
|
||||||
|
@ -1091,180 +1087,7 @@ void AvHHud::DrawOrderText(const AvHOrder& inOrder)
|
||||||
this->DrawHudStringCentered(theBaseX, theBaseY + 2*theStringHeight, ScreenWidth(), theTranslatedLocation.c_str(), theR, theG, theB);
|
this->DrawHudStringCentered(theBaseX, theBaseY + 2*theStringHeight, ScreenWidth(), theTranslatedLocation.c_str(), theR, theG, theB);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// tankefugl: 0000992
|
|
||||||
if (this->mDisplayOrderType == 2)
|
|
||||||
{
|
|
||||||
// this->mDisplayOrderText1 = "The commander issued an order:";
|
|
||||||
this->mDisplayOrderText1 = theFirstLine.c_str();
|
|
||||||
this->mDisplayOrderText2 = theTranslatedLocation.c_str();
|
|
||||||
}
|
}
|
||||||
// :tankefugl
|
|
||||||
}
|
|
||||||
|
|
||||||
// tankefugl: 0000992
|
|
||||||
void AvHHud::SetDisplayOrder(int inOrderType, int inOrderIndex, string inText1, string inText2, string inText3)
|
|
||||||
{
|
|
||||||
this->mDisplayOrderTime = this->mTimeOfLastUpdate;
|
|
||||||
this->mDisplayOrderType = inOrderType;
|
|
||||||
this->mDisplayOrderIndex = inOrderIndex;
|
|
||||||
this->mDisplayOrderText1 = inText1;
|
|
||||||
this->mDisplayOrderText2 = inText2;
|
|
||||||
this->mDisplayOrderText3 = inText3;
|
|
||||||
}
|
|
||||||
|
|
||||||
void AvHHud::DrawDisplayOrder()
|
|
||||||
{
|
|
||||||
const float flashLength = 1.0f;
|
|
||||||
const float fadeLimit = 6.0f;
|
|
||||||
const float fadeEnd = 2.0f;
|
|
||||||
|
|
||||||
if ((this->mDisplayOrderType > 0) && (this->mDisplayOrderTime + fadeLimit + fadeEnd) > this->mTimeOfLastUpdate && (this->GetInTopDownMode() == false))
|
|
||||||
{
|
|
||||||
float theFade = 1.0f;
|
|
||||||
if ((this->mDisplayOrderTime + fadeLimit) < this->mTimeOfLastUpdate)
|
|
||||||
{
|
|
||||||
theFade = 1.0f - (this->mTimeOfLastUpdate - (this->mDisplayOrderTime + fadeLimit)) / fadeEnd;
|
|
||||||
if(theFade < 0.0f)
|
|
||||||
{
|
|
||||||
this->mDisplayOrderType = 0;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// flash the icon for the first second
|
|
||||||
if ((this->mDisplayOrderTime + flashLength) > this->mTimeOfLastUpdate)
|
|
||||||
{
|
|
||||||
if (((int)((this->mTimeOfLastUpdate - this->mDisplayOrderTime) * 8)) % 2)
|
|
||||||
{
|
|
||||||
theFade = 0.0f;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// draw the panel
|
|
||||||
// int sprite = Safe_SPR_Load(kWhiteSprite);
|
|
||||||
|
|
||||||
int r, g, b;
|
|
||||||
GetPrimaryHudColor(r, g, b, true, false);
|
|
||||||
|
|
||||||
int theStringHeight = this->GetHudStringHeight();
|
|
||||||
|
|
||||||
// float mSelectionBoxX1 = 0.25f * ScreenWidth();
|
|
||||||
// float mSelectionBoxY1 = 0.08f * ScreenHeight();
|
|
||||||
// float mSelectionBoxX2 = mSelectionBoxX1 + 0.50f * ScreenWidth();
|
|
||||||
// float mSelectionBoxY2 = mSelectionBoxY1 + 0.08f * ScreenWidth();
|
|
||||||
|
|
||||||
// float mIconX1 = mSelectionBoxX1 + 0.01f * ScreenWidth();
|
|
||||||
// float mIconY1 = mSelectionBoxY1 + 0.01f * ScreenWidth();
|
|
||||||
// float mIconX2 = mIconX1 + 0.06f * ScreenWidth();
|
|
||||||
// float mIconY2 = mIconY1 + 0.06f * ScreenWidth();
|
|
||||||
|
|
||||||
// AvHSpriteSetRenderMode(kRenderTransAdd);
|
|
||||||
// AvHSpriteSetColor(r / 255.0, g / 255.0, b / 255.0, 0.3 * theFade);
|
|
||||||
// AvHSpriteSetDrawMode(kSpriteDrawModeFilled);
|
|
||||||
// AvHSpriteDraw(sprite, 0, mSelectionBoxX1 + 1, mSelectionBoxY1 + 1, mSelectionBoxX2 - 1, mSelectionBoxY2 - 1, 0, 0, 1, 1);
|
|
||||||
|
|
||||||
// AvHSpriteSetRenderMode(kRenderTransAdd);
|
|
||||||
// AvHSpriteSetColor(r / 255.0, g / 255.0, b / 255.0, 0.7 * theFade);
|
|
||||||
// AvHSpriteSetDrawMode(kSpriteDrawModeBorder);
|
|
||||||
// AvHSpriteDraw(sprite, 0, mSelectionBoxX1, mSelectionBoxY1, mSelectionBoxX2, mSelectionBoxY2, 0, 0, 1, 1);
|
|
||||||
|
|
||||||
float mIconX1 = 0.45f * ScreenWidth();
|
|
||||||
float mIconY1 = 0.10f * ScreenHeight();
|
|
||||||
float mIconX2 = mIconX1 + 0.10f * ScreenWidth();
|
|
||||||
float mIconY2 = mIconY1 + 0.10f * ScreenWidth();
|
|
||||||
|
|
||||||
float mTextX1 = 0.50f * ScreenWidth();
|
|
||||||
|
|
||||||
AvHSpriteSetRenderMode(kRenderTransAdd);
|
|
||||||
AvHSpriteSetDrawMode(kSpriteDrawModeFilled);
|
|
||||||
AvHSpriteSetColor(1, 1, 1, 1 * theFade);
|
|
||||||
|
|
||||||
if (this->mDisplayOrderType == 1)
|
|
||||||
{
|
|
||||||
AvHSpriteDraw(this->mTeammateOrderSprite, this->mDisplayOrderIndex, mIconX1, mIconY1, mIconX2, mIconY2, 0, 0, 1, 1);
|
|
||||||
this->DrawHudStringCentered(mTextX1, mIconY2, ScreenWidth(), this->mDisplayOrderText1.c_str(), r, g, b);
|
|
||||||
}
|
|
||||||
else if (this->mDisplayOrderType == 2)
|
|
||||||
{
|
|
||||||
AvHSpriteDraw(this->mOrderSprite, this->mDisplayOrderIndex, mIconX1, mIconY1, mIconX2, mIconY2, 0, 0, 1, 1);
|
|
||||||
this->DrawHudStringCentered(mTextX1, mIconY2, ScreenWidth(), this->mDisplayOrderText1.c_str(), r, g, b);
|
|
||||||
this->DrawHudStringCentered(mTextX1, mIconY2 + theStringHeight, ScreenWidth(), this->mDisplayOrderText2.c_str(), r, g, b);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// float mTextX1 = mIconX2 + 0.02 * ScreenWidth();
|
|
||||||
// this->DrawHudString(mTextX1, mIconY1, ScreenWidth(), this->mDisplayOrderText1.c_str(), r, g, b);
|
|
||||||
// this->DrawHudString(mTextX1, mIconY1 + theStringHeight, ScreenWidth(), this->mDisplayOrderText2.c_str(), r, g, b);
|
|
||||||
// this->DrawHudString(mTextX1, mIconY1 + theStringHeight * 2, ScreenWidth(), this->mDisplayOrderText3.c_str(), r, g, b);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
// tankefugl: 0000971
|
|
||||||
void AvHHud::DrawTeammateOrders()
|
|
||||||
{
|
|
||||||
TeammateOrderListType::iterator toErase = NULL;
|
|
||||||
cl_entity_s* theLocalPlayer = gEngfuncs.GetLocalPlayer();
|
|
||||||
|
|
||||||
const float flashLength = 1.0f;
|
|
||||||
const float fadeLimit = 6.0f;
|
|
||||||
const float fadeEnd = 2.0f;
|
|
||||||
|
|
||||||
for(TeammateOrderListType::iterator theIter = this->mTeammateOrder.begin(); theIter != this->mTeammateOrder.end(); theIter++)
|
|
||||||
{
|
|
||||||
TeammateOrderType theOrder = (*theIter).second;
|
|
||||||
int theEntIndex = (*theIter).first;
|
|
||||||
float theFade = 1.0f;
|
|
||||||
|
|
||||||
// remove the order if it has expired
|
|
||||||
if((theOrder.second + fadeEnd + fadeLimit) < this->mTimeOfLastUpdate)
|
|
||||||
{
|
|
||||||
toErase = theIter;
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
// draw the order fading away
|
|
||||||
else if((theOrder.second + fadeLimit) < this->mTimeOfLastUpdate)
|
|
||||||
{
|
|
||||||
theFade = 1.0f - (this->mTimeOfLastUpdate - (theOrder.second + fadeLimit)) / fadeEnd;
|
|
||||||
if(theFade < 0.0f)
|
|
||||||
theFade = 0.0f;
|
|
||||||
}
|
|
||||||
// else, draw the order normally
|
|
||||||
|
|
||||||
cl_entity_s* theEntity = gEngfuncs.GetEntityByIndex(theEntIndex);
|
|
||||||
if (theEntity && (theEntIndex < MAX_PLAYERS && theEntIndex >= 0) && (theEntity->index != theLocalPlayer->index))
|
|
||||||
{
|
|
||||||
if (AvHTraceLineAgainstWorld(theLocalPlayer->origin, theEntity->origin) == 1.0f)
|
|
||||||
{
|
|
||||||
vec3_t theVec;
|
|
||||||
VectorCopy(theEntity->origin, theVec);
|
|
||||||
theVec[2] += AvHCUGetIconHeightForPlayer((AvHUser3)theEntity->curstate.iuser3);
|
|
||||||
this->DrawWorldSprite(this->mTeammateOrderSprite, kRenderTransAdd, theVec, theOrder.first, kHelpIconDrawSize, theFade);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (toErase != NULL)
|
|
||||||
this->mTeammateOrder.erase(toErase);
|
|
||||||
|
|
||||||
// flash target player
|
|
||||||
if (((this->mCurrentOrderTime + flashLength) > this->mTimeOfLastUpdate) && (this->mCurrentOrderTarget > 0))
|
|
||||||
{
|
|
||||||
if (((int)((this->mTimeOfLastUpdate - (this->mCurrentOrderTime + flashLength)) * 8)) % 2)
|
|
||||||
{
|
|
||||||
cl_entity_s* theTargetEntity = gEngfuncs.GetEntityByIndex(this->mCurrentOrderTarget);
|
|
||||||
|
|
||||||
vec3_t theVec;
|
|
||||||
VectorCopy(theTargetEntity->origin, theVec);
|
|
||||||
theVec[2] += AvHCUGetIconHeightForPlayer((AvHUser3)theTargetEntity->curstate.iuser3);
|
|
||||||
this->DrawWorldSprite(this->mTeammateOrderSprite, kRenderTransAdd, theVec, this->mCurrentOrderType, kHelpIconDrawSize, 1.0f);
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
void AvHHud::DrawOrders()
|
void AvHHud::DrawOrders()
|
||||||
{
|
{
|
||||||
|
@ -2708,11 +2531,6 @@ void AvHHud::RenderCommonUI()
|
||||||
|
|
||||||
this->DrawOrders();
|
this->DrawOrders();
|
||||||
this->DrawHelpIcons();
|
this->DrawHelpIcons();
|
||||||
// tankefugl: 0000971
|
|
||||||
this->DrawTeammateOrders();
|
|
||||||
// tankefugl: 0000992
|
|
||||||
this->DrawDisplayOrder();
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
if (this->GetIsCombatMode())
|
if (this->GetIsCombatMode())
|
||||||
{
|
{
|
||||||
|
@ -4170,10 +3988,6 @@ void AvHHud::VidInit(void)
|
||||||
string theIconName = string(kHelpIconPrefix) + ".spr";
|
string theIconName = string(kHelpIconPrefix) + ".spr";
|
||||||
this->mHelpSprite = Safe_SPR_Load(theIconName.c_str());
|
this->mHelpSprite = Safe_SPR_Load(theIconName.c_str());
|
||||||
|
|
||||||
// tankefugl: 0000971
|
|
||||||
this->mTeammateOrderSprite = Safe_SPR_Load(kTeammateOrderSprite);
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
this->mEnemyBlips.VidInit();
|
this->mEnemyBlips.VidInit();
|
||||||
this->mFriendlyBlips.VidInit();
|
this->mFriendlyBlips.VidInit();
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,7 +22,7 @@ int g_msgAmmoPickup = 0, g_msgAmmoX, g_msgBattery, g_msgCurWeapon, g_msgDamage,
|
||||||
g_msgServerVar, g_msgSetGammaRamp, g_msgSetOrder, g_msgSetParticleTemplates,
|
g_msgServerVar, g_msgSetGammaRamp, g_msgSetOrder, g_msgSetParticleTemplates,
|
||||||
g_msgSetSelect, g_msgSetRequest, g_msgSetSoundNames, g_msgSetTechNodes, g_msgSetTechSlots,
|
g_msgSetSelect, g_msgSetRequest, g_msgSetSoundNames, g_msgSetTechNodes, g_msgSetTechSlots,
|
||||||
g_msgSetTopDown, g_msgSetupMap, g_msgUpdateCountdown, g_msgUpdateEntityHierarchy,
|
g_msgSetTopDown, g_msgSetupMap, g_msgUpdateCountdown, g_msgUpdateEntityHierarchy,
|
||||||
g_msgProfileInfo, g_msgNexusBytes, g_msgIssueOrder;
|
g_msgProfileInfo, g_msgNexusBytes;
|
||||||
|
|
||||||
void Net_InitializeMessages(void)
|
void Net_InitializeMessages(void)
|
||||||
{
|
{
|
||||||
|
@ -87,9 +87,6 @@ void Net_InitializeMessages(void)
|
||||||
g_msgUpdateEntityHierarchy = REG_USER_MSG( "EntHier", -1 );
|
g_msgUpdateEntityHierarchy = REG_USER_MSG( "EntHier", -1 );
|
||||||
g_msgProfileInfo = REG_USER_MSG( "ProfileInfo", 8 );
|
g_msgProfileInfo = REG_USER_MSG( "ProfileInfo", 8 );
|
||||||
g_msgNexusBytes = REG_USER_MSG( "NexusBytes", -1 );
|
g_msgNexusBytes = REG_USER_MSG( "NexusBytes", -1 );
|
||||||
// tankefugl: 0000971
|
|
||||||
g_msgIssueOrder = REG_USER_MSG( "IssueOrder", 9);
|
|
||||||
// :tankefugl
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -2027,27 +2024,3 @@ const int kPositionNetworkConstant = 25;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
// tankefugl: 0000971
|
|
||||||
#ifndef AVH_SERVER
|
|
||||||
void NetMsg_IssueOrder( void* const buffer, const int size, int& ordertype, int& ordersource, int& ordertarget )
|
|
||||||
{
|
|
||||||
BEGIN_READ( buffer, size );
|
|
||||||
ordertype = READ_BYTE();
|
|
||||||
ordersource = READ_LONG();
|
|
||||||
ordertarget = READ_LONG();
|
|
||||||
END_READ();
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
void NetMsg_IssueOrder( entvars_t* const pev, const int ordertype, const int ordersource, const int ordertarget)
|
|
||||||
{
|
|
||||||
MESSAGE_BEGIN( MSG_ONE, g_msgIssueOrder, NULL, pev );
|
|
||||||
WRITE_BYTE( ordertype );
|
|
||||||
WRITE_LONG( ordersource );
|
|
||||||
WRITE_LONG( ordertarget );
|
|
||||||
MESSAGE_END();
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
// :tankefugl
|
|
|
@ -106,7 +106,6 @@
|
||||||
void NetMsg_SetupMap_Extents( entvars_t* const pev, const string& name, const float* const min_extents, const float* const max_extents, const bool draw_background );
|
void NetMsg_SetupMap_Extents( entvars_t* const pev, const string& name, const float* const min_extents, const float* const max_extents, const bool draw_background );
|
||||||
void NetMsg_SetupMap_Location( entvars_t* const pev, const string& name, const float* const min_extents, const float* const max_extents );
|
void NetMsg_SetupMap_Location( entvars_t* const pev, const string& name, const float* const min_extents, const float* const max_extents );
|
||||||
void NetMsg_UpdateEntityHierarchy( entvars_t* const pev, const MapEntityMap& NewItems, const EntityListType& OldItems );
|
void NetMsg_UpdateEntityHierarchy( entvars_t* const pev, const MapEntityMap& NewItems, const EntityListType& OldItems );
|
||||||
void NetMsg_IssueOrder(entvars_t* const pev, const int ordertype, const int ordersource, const int ordertarget);
|
|
||||||
|
|
||||||
//BROADCAST MESSAGE TRANSMISSION
|
//BROADCAST MESSAGE TRANSMISSION
|
||||||
void NetMsg_DeathMsg( const int killer_index, const int victim_index, string& weapon_name );
|
void NetMsg_DeathMsg( const int killer_index, const int victim_index, string& weapon_name );
|
||||||
|
@ -196,7 +195,6 @@
|
||||||
void NetMsg_SetupMap( void* const buffer, const int size, bool& is_location, string& name, float* min_extents, float* max_extents, bool& draw_background );
|
void NetMsg_SetupMap( void* const buffer, const int size, bool& is_location, string& name, float* min_extents, float* max_extents, bool& draw_background );
|
||||||
void NetMsg_UpdateCountdown( void* const buffer, const int size, int& countdown );
|
void NetMsg_UpdateCountdown( void* const buffer, const int size, int& countdown );
|
||||||
void NetMsg_UpdateEntityHierarchy( void* const buffer, const int size, MapEntityMap& NewItems, EntityListType& OldItems );
|
void NetMsg_UpdateEntityHierarchy( void* const buffer, const int size, MapEntityMap& NewItems, EntityListType& OldItems );
|
||||||
void NetMsg_IssueOrder( void* const buffer, const int size, int& ordertype, int& ordersource, int& ordertarget );
|
|
||||||
|
|
||||||
#endif //AVH_SERVER
|
#endif //AVH_SERVER
|
||||||
|
|
||||||
|
|
|
@ -82,20 +82,6 @@ private:
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef vector<AvHOrder> OrderListType;
|
typedef vector<AvHOrder> OrderListType;
|
||||||
// tankefugl: 0000971
|
|
||||||
typedef enum {
|
|
||||||
TEAMMATE_MARINE_ORDER_WELD = 0,
|
|
||||||
TEAMMATE_MARINE_ORDER_FOLLOW,
|
|
||||||
TEAMMATE_MARINE_ORDER_COVER,
|
|
||||||
TEAMMATE_MARINE_ORDER_UNKNOWN,
|
|
||||||
TEAMMATE_ALIEN_ORDER_HEAL,
|
|
||||||
TEAMMATE_ALIEN_ORDER_FOLLOW,
|
|
||||||
TEAMMATE_ALIEN_ORDER_COVER,
|
|
||||||
TEAMMATE_ALIEN_ORDER_UNKNOWN
|
|
||||||
} TeammateOrderEnum;
|
|
||||||
typedef pair<int, float> TeammateOrderType;
|
|
||||||
typedef map<int, TeammateOrderType> TeammateOrderListType;
|
|
||||||
// :tankefugl
|
|
||||||
|
|
||||||
void AvHChangeOrder(OrderListType& inList, const AvHOrder& inOrder);
|
void AvHChangeOrder(OrderListType& inList, const AvHOrder& inOrder);
|
||||||
//void AvHRemovePlayerFromOrders(OrderListType& inList, int inPlayerIndex);
|
//void AvHRemovePlayerFromOrders(OrderListType& inList, int inPlayerIndex);
|
||||||
|
|
|
@ -4075,8 +4075,7 @@ void PM_UnDuck( void )
|
||||||
|
|
||||||
VectorCopy( pmove->origin, newOrigin );
|
VectorCopy( pmove->origin, newOrigin );
|
||||||
|
|
||||||
// tankefugl: remove the jump when pressing and releasing duck quickly
|
if ( pmove->onground != -1 )
|
||||||
if ( pmove->onground != -1 && pmove->flags & FL_DUCKING && pmove->bInDuck == false)
|
|
||||||
{
|
{
|
||||||
int theStandingHull = AvHMUGetHull(false, pmove->iuser3);
|
int theStandingHull = AvHMUGetHull(false, pmove->iuser3);
|
||||||
int theCrouchingHull = AvHMUGetHull(true, pmove->iuser3);
|
int theCrouchingHull = AvHMUGetHull(true, pmove->iuser3);
|
||||||
|
|
Loading…
Reference in a new issue