2025-08-03 05:51 CEST

spring: develop 89c4d7a2 Diff ] Back to Repository ]
Author Committer Branch Timestamp Parent
rt rt develop 2013-11-26 19:36:49 develop 05aeac70
Changeset LuaSyncedRead:
  make Get{Unit,Factory}Commands (optionally) return just the queue's size
  (ie. without copying the entire command queue into Lua VM memory, *VERY*
  important for performance when a nugget is not interested in the commands
  themselves)

  "if #spGetCommandQueue(unitID ) == 0 then return end" --> BAD, CREATES COPY OF QUEUE
  "if spGetCommandQueue(unitID, -1, false) == 0 then return end" --> GOOD, DO THIS IF POSSIBLE
mod - rts/Lua/LuaSyncedRead.cpp Diff ] File ]