mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-06 04:15:33 +00:00
Merge remote-tracking branch 'upstream/master' into osgshadow-test-vdsm
This commit is contained in:
commit
25432146f7
9 changed files with 57 additions and 33 deletions
|
@ -129,6 +129,7 @@ Programmers
|
|||
Radu-Marius Popovici (rpopovici)
|
||||
Rafael Moura (dhustkoder)
|
||||
rdimesio
|
||||
rexelion
|
||||
riothamus
|
||||
Rob Cutmore (rcutmore)
|
||||
Robert MacGregor (Ragora)
|
||||
|
|
|
@ -24,16 +24,8 @@ if (USE_QT)
|
|||
set_property(CACHE DESIRED_QT_VERSION PROPERTY STRINGS 4 5)
|
||||
endif()
|
||||
|
||||
if (APPLE)
|
||||
# OS X build process relies on this fix: https://github.com/Kitware/CMake/commit/3df5147043d83aa09acd5c9ce31d5c602efb99db
|
||||
cmake_minimum_required(VERSION 3.1.0)
|
||||
elseif (USE_QT AND DESIRED_QT_VERSION MATCHES 5)
|
||||
# 2.8.11+ is required to make Qt5 happy and allow linking QtMain on Windows.
|
||||
cmake_minimum_required(VERSION 2.8.11)
|
||||
else()
|
||||
# We probably support older versions than this.
|
||||
cmake_minimum_required(VERSION 2.6)
|
||||
endif()
|
||||
# set the minimum required version across the board
|
||||
cmake_minimum_required(VERSION 3.1.0)
|
||||
|
||||
project(OpenMW)
|
||||
|
||||
|
@ -412,7 +404,7 @@ IF(NOT WIN32 AND NOT APPLE)
|
|||
#ENDIF(BUILD_MYGUI_PLUGIN)
|
||||
|
||||
# Install licenses
|
||||
INSTALL(FILES "docs/license/DejaVu Font License.txt" DESTINATION "${LICDIR}" )
|
||||
INSTALL(FILES "files/mygui/DejaVu Font License.txt" DESTINATION "${LICDIR}" )
|
||||
|
||||
# Install icon and desktop file
|
||||
INSTALL(FILES "${OpenMW_BINARY_DIR}/openmw.desktop" DESTINATION "${DATAROOTDIR}/applications" COMPONENT "openmw")
|
||||
|
@ -446,9 +438,9 @@ if(WIN32)
|
|||
INSTALL(FILES "${OpenMW_BINARY_DIR}/openmw.cfg.install" DESTINATION "." RENAME "openmw.cfg")
|
||||
INSTALL(FILES "${OpenMW_SOURCE_DIR}/CHANGELOG.md" DESTINATION "." RENAME "CHANGELOG.txt")
|
||||
INSTALL(FILES "${OpenMW_SOURCE_DIR}/README.md" DESTINATION "." RENAME "README.txt")
|
||||
INSTALL(FILES "${OpenMW_SOURCE_DIR}/LICENSE" DESTINATION "." RENAME "LICENSE.txt")
|
||||
INSTALL(FILES
|
||||
"${OpenMW_SOURCE_DIR}/Docs/license/GPL3.txt"
|
||||
"${OpenMW_SOURCE_DIR}/Docs/license/DejaVu Font License.txt"
|
||||
"${OpenMW_SOURCE_DIR}/files/mygui/DejaVu Font License.txt"
|
||||
"${OpenMW_BINARY_DIR}/settings-default.cfg"
|
||||
"${OpenMW_BINARY_DIR}/gamecontrollerdb.txt"
|
||||
DESTINATION ".")
|
||||
|
|
|
@ -631,8 +631,8 @@ to attach them to the start of each source file to most effectively
|
|||
state the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the program's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
{one line to give the program's name and a brief idea of what it does.}
|
||||
Copyright (C) {year} {name of author}
|
||||
|
||||
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
|
||||
|
@ -652,7 +652,7 @@ Also add information on how to contact you by electronic and paper mail.
|
|||
If the program does terminal interaction, make it output a short
|
||||
notice like this when it starts in an interactive mode:
|
||||
|
||||
<program> Copyright (C) <year> <name of author>
|
||||
{project} Copyright (C) {year} {fullname}
|
||||
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
|
@ -8,12 +8,12 @@ OpenMW is a recreation of the engine for the popular role-playing game Morrowind
|
|||
OpenMW also comes with OpenMW-CS, a replacement for Morrowind's TES Construction Set.
|
||||
|
||||
* Version: 0.42.0
|
||||
* License: GPLv3 (see [docs/license/GPL3.txt](https://github.com/OpenMW/openmw/blob/master/docs/license/GPL3.txt) for more information)
|
||||
* License: GPLv3 (see [LICENSE](https://github.com/OpenMW/openmw/blob/master/LICENSE) for more information)
|
||||
* Website: http://www.openmw.org
|
||||
* IRC: #openmw on irc.freenode.net
|
||||
|
||||
Font Licenses:
|
||||
* DejaVuLGCSansMono.ttf: custom (see docs/license/DejaVu Font License.txt for more information)
|
||||
* DejaVuLGCSansMono.ttf: custom (see [files/mygui/DejaVu Font License.txt](https://github.com/OpenMW/openmw/blob/master/files/mygui/DejaVu%20Font%20License.txt) for more information)
|
||||
|
||||
Current Status
|
||||
--------------
|
||||
|
|
|
@ -657,12 +657,16 @@ namespace MWGui
|
|||
|
||||
MWWorld::Ptr player = MWMechanics::getPlayer();
|
||||
MWBase::Environment::get().getWorld()->breakInvisibility(player);
|
||||
|
||||
if (!object.getRefData().activate())
|
||||
return;
|
||||
|
||||
MWBase::Environment::get().getMechanicsManager()->itemTaken(player, object, MWWorld::Ptr(), count);
|
||||
|
||||
// add to player inventory
|
||||
// can't use ActionTake here because we need an MWWorld::Ptr to the newly inserted object
|
||||
MWWorld::Ptr newObject = *player.getClass().getContainerStore (player).add (object, object.getRefData().getCount(), player);
|
||||
|
||||
// remove from world
|
||||
MWBase::Environment::get().getWorld()->deleteObject (object);
|
||||
|
||||
|
@ -735,7 +739,7 @@ namespace MWGui
|
|||
}
|
||||
}
|
||||
|
||||
if (!found)
|
||||
if (!found || selected == cycled)
|
||||
return;
|
||||
|
||||
useItem(model.getItem(cycled).mBase);
|
||||
|
|
|
@ -50,8 +50,13 @@ bool AiPursue::execute (const MWWorld::Ptr& actor, CharacterController& characte
|
|||
|
||||
//Set the target desition from the actor
|
||||
ESM::Pathgrid::Point dest = target.getRefData().getPosition().pos;
|
||||
ESM::Position aPos = actor.getRefData().getPosition();
|
||||
|
||||
if (pathTo(actor, dest, duration, 100)) {
|
||||
float pathTolerance = 100.0;
|
||||
|
||||
if (pathTo(actor, dest, duration, pathTolerance) &&
|
||||
abs(dest.mZ - aPos.pos[2]) < pathTolerance) // check the true distance in case the target is far away in Z-direction
|
||||
{
|
||||
target.getClass().activate(target,actor).get()->execute(actor); //Arrest player when reached
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -254,6 +254,7 @@ void CharacterController::refreshHitRecoilAnims()
|
|||
|| mPtr.getClass().getCreatureStats(mPtr).getFatigue().getBase() == 0)
|
||||
&& mAnimation->hasAnimation("knockout"))
|
||||
{
|
||||
mTimeUntilWake = Misc::Rng::rollClosedProbability() * 2 + 1; // Wake up after 1 to 3 seconds
|
||||
if (isSwimming && mAnimation->hasAnimation("swimknockout"))
|
||||
{
|
||||
mHitState = CharState_SwimKnockOut;
|
||||
|
@ -338,7 +339,8 @@ void CharacterController::refreshHitRecoilAnims()
|
|||
mPtr.getClass().getCreatureStats(mPtr).setBlock(false);
|
||||
mHitState = CharState_None;
|
||||
}
|
||||
else if (isKnockedOut() && mPtr.getClass().getCreatureStats(mPtr).getFatigue().getCurrent() > 0)
|
||||
else if (isKnockedOut() && mPtr.getClass().getCreatureStats(mPtr).getFatigue().getCurrent() > 0
|
||||
&& mTimeUntilWake <= 0)
|
||||
{
|
||||
mHitState = isSwimming ? CharState_SwimKnockDown : CharState_KnockDown;
|
||||
mAnimation->disable(mCurrentHit);
|
||||
|
@ -372,21 +374,29 @@ void CharacterController::refreshJumpAnims(const WeaponInfo* weap, JumpingState
|
|||
}
|
||||
}
|
||||
|
||||
if(mJumpState == JumpState_InAir)
|
||||
{
|
||||
mAnimation->disable(mCurrentJump);
|
||||
mCurrentJump = jumpAnimName;
|
||||
if (mAnimation->hasAnimation("jump"))
|
||||
mAnimation->play(mCurrentJump, Priority_Jump, jumpmask, false,
|
||||
1.0f, (startAtLoop?"loop start":"start"), "stop", 0.0f, ~0ul);
|
||||
}
|
||||
else
|
||||
if (!mCurrentJump.empty())
|
||||
{
|
||||
mAnimation->disable(mCurrentJump);
|
||||
mCurrentJump.clear();
|
||||
if (mAnimation->hasAnimation("jump"))
|
||||
}
|
||||
|
||||
if(mJumpState == JumpState_InAir)
|
||||
{
|
||||
if (mAnimation->hasAnimation(jumpAnimName))
|
||||
{
|
||||
mAnimation->play(jumpAnimName, Priority_Jump, jumpmask, false,
|
||||
1.0f, (startAtLoop?"loop start":"start"), "stop", 0.0f, ~0ul);
|
||||
mCurrentJump = jumpAnimName;
|
||||
}
|
||||
}
|
||||
else if (mJumpState == JumpState_Landing)
|
||||
{
|
||||
if (mAnimation->hasAnimation(jumpAnimName))
|
||||
{
|
||||
mAnimation->play(jumpAnimName, Priority_Jump, jumpmask, true,
|
||||
1.0f, "loop stop", "stop", 0.0f, 0);
|
||||
mCurrentJump = jumpAnimName;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -759,6 +769,7 @@ CharacterController::CharacterController(const MWWorld::Ptr &ptr, MWRender::Anim
|
|||
, mSecondsOfRunning(0)
|
||||
, mTurnAnimationThreshold(0)
|
||||
, mAttackingOrSpell(false)
|
||||
, mTimeUntilWake(0.f)
|
||||
{
|
||||
if(!mAnimation)
|
||||
return;
|
||||
|
@ -1628,6 +1639,9 @@ void CharacterController::update(float duration)
|
|||
float speed = 0.f;
|
||||
|
||||
updateMagicEffects();
|
||||
|
||||
if (isKnockedOut())
|
||||
mTimeUntilWake -= duration;
|
||||
|
||||
bool godmode = mPtr == MWMechanics::getPlayer() && MWBase::Environment::get().getWorld()->getGodModeState();
|
||||
|
||||
|
@ -1692,7 +1706,6 @@ void CharacterController::update(float duration)
|
|||
mHasMovedInXY = std::abs(vec.x())+std::abs(vec.y()) > 0.0f;
|
||||
isrunning = isrunning && mHasMovedInXY;
|
||||
|
||||
|
||||
// advance athletics
|
||||
if(mHasMovedInXY && mPtr == getPlayer())
|
||||
{
|
||||
|
@ -1847,7 +1860,8 @@ void CharacterController::update(float duration)
|
|||
}
|
||||
else
|
||||
{
|
||||
jumpstate = JumpState_None;
|
||||
jumpstate = mAnimation->isPlaying(mCurrentJump) ? JumpState_Landing : JumpState_None;
|
||||
|
||||
vec.z() = 0.0f;
|
||||
|
||||
inJump = false;
|
||||
|
@ -1877,9 +1891,15 @@ void CharacterController::update(float duration)
|
|||
else if(rot.z() != 0.0f && !sneak && !(mPtr == getPlayer() && MWBase::Environment::get().getWorld()->isFirstPerson()))
|
||||
{
|
||||
if(rot.z() > 0.0f)
|
||||
{
|
||||
movestate = inwater ? CharState_SwimTurnRight : CharState_TurnRight;
|
||||
mAnimation->disable(mCurrentJump);
|
||||
}
|
||||
else if(rot.z() < 0.0f)
|
||||
{
|
||||
movestate = inwater ? CharState_SwimTurnLeft : CharState_TurnLeft;
|
||||
mAnimation->disable(mCurrentJump);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -196,6 +196,8 @@ class CharacterController : public MWRender::Animation::TextKeyListener
|
|||
float mSecondsOfSwimming;
|
||||
float mSecondsOfRunning;
|
||||
|
||||
float mTimeUntilWake;
|
||||
|
||||
MWWorld::ConstPtr mHeadTrackTarget;
|
||||
|
||||
float mTurnAnimationThreshold; // how long to continue playing turning animation after actor stopped turning
|
||||
|
|
Loading…
Reference in a new issue