mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-04-28 21:07:59 +03:00
Merge branch 'travelprice' into 'master'
Some checks failed
Build and test / Ubuntu (push) Has been cancelled
Build and test / MacOS (push) Has been cancelled
Build and test / Read .env file and expose it as output (push) Has been cancelled
Build and test / Windows (2019) (push) Has been cancelled
Build and test / Windows (2022) (push) Has been cancelled
Some checks failed
Build and test / Ubuntu (push) Has been cancelled
Build and test / MacOS (push) Has been cancelled
Build and test / Read .env file and expose it as output (push) Has been cancelled
Build and test / Windows (2019) (push) Has been cancelled
Build and test / Windows (2022) (push) Has been cancelled
Rescale the base travel cost by the number of followers (#8446) Closes #8446 See merge request OpenMW/openmw!4626
This commit is contained in:
commit
cdaa63fd87
1 changed files with 3 additions and 3 deletions
|
@ -70,9 +70,6 @@ namespace MWGui
|
||||||
price = static_cast<int>(d);
|
price = static_cast<int>(d);
|
||||||
}
|
}
|
||||||
|
|
||||||
price = std::max(1, price);
|
|
||||||
price = MWBase::Environment::get().getMechanicsManager()->getBarterOffer(mPtr, price, true);
|
|
||||||
|
|
||||||
// Add price for the travelling followers
|
// Add price for the travelling followers
|
||||||
std::set<MWWorld::Ptr> followers;
|
std::set<MWWorld::Ptr> followers;
|
||||||
MWWorld::ActionTeleport::getFollowers(player, followers, !interior);
|
MWWorld::ActionTeleport::getFollowers(player, followers, !interior);
|
||||||
|
@ -80,6 +77,9 @@ namespace MWGui
|
||||||
// Apply followers cost, unlike vanilla the first follower doesn't travel for free
|
// Apply followers cost, unlike vanilla the first follower doesn't travel for free
|
||||||
price *= 1 + static_cast<int>(followers.size());
|
price *= 1 + static_cast<int>(followers.size());
|
||||||
|
|
||||||
|
price = std::max(1, price);
|
||||||
|
price = MWBase::Environment::get().getMechanicsManager()->getBarterOffer(mPtr, price, true);
|
||||||
|
|
||||||
const int lineHeight = Settings::gui().mFontSize + 2;
|
const int lineHeight = Settings::gui().mFontSize + 2;
|
||||||
|
|
||||||
MyGUI::Button* toAdd = mDestinationsView->createWidget<MyGUI::Button>(
|
MyGUI::Button* toAdd = mDestinationsView->createWidget<MyGUI::Button>(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue