mirror of
https://github.com/OpenFusionProject/OpenFusion.git
synced 2024-11-25 22:40:16 +00:00
changed vehicle iTimeLimit to be stored in seconds instead of miliseconds
This commit is contained in:
parent
7ba9b9a54f
commit
076f89927d
@ -611,7 +611,7 @@ void Database::getInventory(Player* player) {
|
||||
}
|
||||
|
||||
void Database::removeExpiredVehicles(Player* player) {
|
||||
uint64_t currentTime = getTimestamp();
|
||||
int32_t currentTime = getTimestamp()/1000;
|
||||
//remove from bank immediately
|
||||
for (int i = 0; i < ABANK_COUNT; i++) {
|
||||
if (player->Bank[i].iType == 10 && player->Bank[i].iTimeLimit < currentTime)
|
||||
|
@ -118,8 +118,7 @@ void NPCManager::npcVendorBuy(CNSocket* sock, CNPacketData* data) {
|
||||
// if vehicle
|
||||
if (req->Item.iType == 10)
|
||||
// set time limit: current time + 7days
|
||||
req->Item.iTimeLimit = getTimestamp() + 604800;
|
||||
|
||||
req->Item.iTimeLimit = getTimestamp()/1000 + 604800;
|
||||
|
||||
if (slot != req->iInvenSlotNum) {
|
||||
// possible item stacking?
|
||||
|
Loading…
Reference in New Issue
Block a user