X-Git-Url: https://ruin.nu/git/?p=hbs.git;a=blobdiff_plain;f=bs%2Ffleet.cpp;h=85304bb2bfcb6e642826764749ca1bad9a2ea4be;hp=19bc3860ef51af974aee0f3c60b14542f58ecb42;hb=b308a9445cfe1883ea8068d3f4d1a04bfcff9aa8;hpb=924d4cd0f8c9c340c8ba6f2e5759fed8f0c83573 diff --git a/bs/fleet.cpp b/bs/fleet.cpp index 19bc386..85304bb 100644 --- a/bs/fleet.cpp +++ b/bs/fleet.cpp @@ -801,3 +801,21 @@ void Fleet::calculateSalvage() } } } + +////////////////////////////////////////////////////////////////////////// +// +void Fleet::resetTicks() +{ + for (FleetList::iterator i = m_Fleet.begin(); i != m_Fleet.end(); ++i) + { + if ( i->second.size() < 2) + continue; + + int temp = i->second[0]; + i->second.clear(); + + if (temp > 0) + i->second.push_back(temp); + } + resetResources(); +}