seconds
Definition
-- @/lua/ge/extensions/ui/vehicleSelector/vehicleSpecifications.lua:142
seconds = function(value)
if not type(value) == 'number' then
return tostring(value)
end
return string.format("%0.2f%s", value, " s")
end,
Callers
@/lua/ge/extensions/gameplay/rally/loop/rallyLoopManager.lua
log('D', logTag, string.format('Rally start time: %.0f seconds (%.2f minutes from environment start)',
rallyStartTimeSecs, (rallyStartTimeSecs - currentTimeSecs) / 60))
@/inspector/localizedStrings.js
localizedStrings["Duration"] = "Duration";
/* The duration of the Timeline recording in seconds (s). */
localizedStrings["Duration: %ss"] = "Duration: %ss";
@/lua/common/libs/copas/copas/lock.lua
--- Creates a new lock.
-- @param seconds (optional) default timeout in seconds when acquiring the lock (defaults to 10)
-- @param not_reentrant (optional) if truthy the lock will not allow a coroutine to grab the same lock multiple times
@/lua/ge/extensions/gameplay/rally/loop/scheduleUtils.lua
-- @param currentTime: Time to compare against
-- @param tolerance: Optional tolerance in seconds (default: 0)
-- @return: true if newTime > currentTime (accounting for tolerance)
@/ui/ui-vue/src/modules/apps/rallyLoop/utils/timeFormatters.js
* Format countdown text (arrive in / late by)
* @param {number} seconds - Countdown in seconds (negative = late)
* @param {boolean} absolute - Whether to return the absolute value of the time difference
@/lua/ge/extensions/career/modules/delivery/vehicleTasks.lua
local expectedTime = (taskData.offer.data.originalDistance/12 + 30 )
log("I","",string.format("Time Taken: %0.1f seconds (expected: %0.1fs)", timeTaken, expectedTime))
@/lua/common/libs/copas/copas/semaphore.lua
-- @param max maximum number of resources the semaphore can hold (this maximum does NOT include resources that have been given but not yet returned).
-- @param seconds (optional, default 10) default semaphore timeout in seconds
-- @param start (optional, default 0) the initial resources available
@/inspector/Views/CPUTimelineView.js
let durationDisplayString = Math.floor(visibleDuration);
this._energyImpactDurationElement.textContent = WI.UIString("Duration: %ss", "The duration of the Timeline recording in seconds (s).").format(durationDisplayString);
}
@/ui/modules/apps/PoliceInfo/app.js
function setAlertText(alert) { // this text disappears after a few seconds (may need improvement)
if (!alert || alert != scope.alertText) {
@/lua/ge/extensions/gameplay/rally/loop/penalties.lua
-- actualTime: actual arrival epoch time in seconds
-- scheduledTime: scheduled epoch time in seconds (can be nil)
-- Returns: table with fields:
@/lua/vehicle/controller/vehicleController/shiftLogic/sequentialGearbox.lua
--if we were not to delay this neutral shift, the user can't get out of 1st gear due to gear change limitations of the sequential
--so only shift to neutral if the new desired gear is still neutral after 0.x seconds (ie the user actually left the H shifter in neutral and did not move to the next gear)
if newDesiredGearIndex == 0 and neutralRejectTimer > 0 then
@/lua/common/libs/timerwheel/timerwheel.lua
--
-- - `precision` (optional) precision of the timer wheel in seconds (slot size),
-- defaults to 0.050
@/lua/ge/extensions/career/modules/marketplace.lua
if marketGap < 0.15 and askingGap > 0.20 then
thinkingTime = 2.5 + math.random() * 1.5 -- 2.5-4 seconds (considering it)
elseif askingGap > 0.30 then
elseif askingGap > 0.30 then
thinkingTime = 1.0 + math.random() * 0.8 -- 1-1.8 seconds (quick rejection/counter)
elseif marketGap < 0.10 then
elseif marketGap < 0.10 then
thinkingTime = 2.0 + math.random() * 1.0 -- 2-3 seconds (fair offer, calculating)
else
else
thinkingTime = 1.5 + math.random() * 1.0 -- 1.5-2.5 seconds (normal)
end
@/lua/ge/extensions/core/jobsystem.lua
...
job.sleep(3) -- pause execution for 3 seconds (the game continues running)
...