diff --git a/data/editor/entities.png b/data/editor/entities.png index c1ee92167..05918d24b 100644 Binary files a/data/editor/entities.png and b/data/editor/entities.png differ diff --git a/data/editor/entities_clear.png b/data/editor/entities_clear.png index 084eac0de..8da6414d9 100644 Binary files a/data/editor/entities_clear.png and b/data/editor/entities_clear.png differ diff --git a/data/editor/front.png b/data/editor/front.png index 203cd6fe0..dc3d48def 100644 Binary files a/data/editor/front.png and b/data/editor/front.png differ diff --git a/data/mapres/entities.png b/data/mapres/entities.png index 0ff78dd24..bb218daa3 100644 Binary files a/data/mapres/entities.png and b/data/mapres/entities.png differ diff --git a/src/game/mapitems.h b/src/game/mapitems.h index 25a6efad4..6624fc5d9 100644 --- a/src/game/mapitems.h +++ b/src/game/mapitems.h @@ -132,10 +132,12 @@ enum TILE_NPH, TILE_NPC_END = 88, TILE_SUPER_END, - TILE_NPH_END = 91, + TILE_JETPACK_END, + TILE_NPH_END, TILE_NPC_START = 104, TILE_SUPER_START, - TILE_NPH_START = 107,//Remember to change this in collision.cpp if you add anymore tiles + TILE_JETPACK_START, + TILE_NPH_START,//Remember to change this in collision.cpp if you add anymore tiles //End of higher tiles //Layers LAYER_GAME=0, diff --git a/src/game/server/entities/character.cpp b/src/game/server/entities/character.cpp index 750b499a0..1a4b56a38 100644 --- a/src/game/server/entities/character.cpp +++ b/src/game/server/entities/character.cpp @@ -281,7 +281,7 @@ void CCharacter::FireWeapon() bool FullAuto = false; if(m_ActiveWeapon == WEAPON_GRENADE || m_ActiveWeapon == WEAPON_SHOTGUN || m_ActiveWeapon == WEAPON_RIFLE) FullAuto = true; - if (m_pGameWorld->m_Core.m_Tuning.m_PlayerJetpack != 0.0f && m_ActiveWeapon == WEAPON_GUN) + if (m_Jetpack && m_ActiveWeapon == WEAPON_GUN) FullAuto = true; // check if we gonna fire @@ -399,7 +399,7 @@ void CCharacter::FireWeapon() Server()->SendMsg(&Msg, 0, m_pPlayer->GetCID()); - if (m_pGameWorld->m_Core.m_Tuning.m_PlayerJetpack != 0.0f) + if (m_Jetpack) TakeDamage(Direction * -1.0f * m_pGameWorld->m_Core.m_Tuning.m_PlayerJetpack, g_pData->m_Weapons.m_Hammer.m_pBase->m_Damage, m_pPlayer->GetCID(), m_ActiveWeapon); GameServer()->CreateSound(m_Pos, SOUND_GUN_FIRE, Teams()->TeamMask(Team(), -1, m_pPlayer->GetCID())); @@ -1334,6 +1334,11 @@ void CCharacter::HandleTiles(int Index) GameServer()->SendChatTarget(GetPlayer()->GetCID(),"You have infinite air jumps"); m_SuperJump = true; } + else if(((m_TileIndex == TILE_JETPACK_START) || (m_TileFIndex == TILE_JETPACK_START)) && !m_Jetpack) + { + GameServer()->SendChatTarget(GetPlayer()->GetCID(),"You have a jetpack gun"); + m_Jetpack = true; + } else if(((m_TileIndex == TILE_NPH_START) || (m_TileFIndex == TILE_NPH_START)) && !m_Core.m_Hook) { GameServer()->SendChatTarget(GetPlayer()->GetCID(),"You can hook others"); @@ -1354,6 +1359,11 @@ void CCharacter::HandleTiles(int Index) GameServer()->SendChatTarget(GetPlayer()->GetCID(), "You don't have infinite air jumps"); m_SuperJump = false; } + else if(((m_TileIndex == TILE_JETPACK_END) || (m_TileFIndex == TILE_JETPACK_END)) && m_Jetpack) + { + GameServer()->SendChatTarget(GetPlayer()->GetCID(), "You lost your jetpack gun"); + m_Jetpack = false; + } else if(((m_TileIndex == TILE_NPH_END) || (m_TileFIndex == TILE_NPH_END)) && m_Core.m_Hook) { GameServer()->SendChatTarget(GetPlayer()->GetCID(), "You can't hook others"); @@ -1714,6 +1724,7 @@ void CCharacter::DDRaceInit() m_EndlessHook = g_Config.m_SvEndlessDrag; m_Hit = g_Config.m_SvHit ? HIT_ALL : DISABLE_HIT_GRENADE|DISABLE_HIT_HAMMER|DISABLE_HIT_RIFLE|DISABLE_HIT_SHOTGUN; m_SuperJump = false; + m_Jetpack = false; m_Core.m_Jumps = 2; int Team = Teams()->m_Core.Team(m_Core.m_Id); diff --git a/src/game/server/entities/character.h b/src/game/server/entities/character.h index a76af9b78..03d93aeb9 100644 --- a/src/game/server/entities/character.h +++ b/src/game/server/entities/character.h @@ -158,6 +158,7 @@ public: bool SameTeam(int ClientID); bool m_Super; bool m_SuperJump; + bool m_Jetpack; int m_TeamBeforeSuper; int m_FreezeTime; int m_FreezeTick; diff --git a/src/game/tuning.h b/src/game/tuning.h index 7ea2bdc03..6c8c37dfe 100644 --- a/src/game/tuning.h +++ b/src/game/tuning.h @@ -45,5 +45,5 @@ MACRO_TUNING_PARAM(LaserDamage, laser_damage, 5) MACRO_TUNING_PARAM(PlayerCollision, player_collision, 1) MACRO_TUNING_PARAM(PlayerHooking, player_hooking, 1) -MACRO_TUNING_PARAM(PlayerJetpack, player_jetpack, 0.0f) +MACRO_TUNING_PARAM(PlayerJetpack, player_jetpack, 4.0f) #endif