From 2621bd16a3ad9c7119aed4170d41c5bad72185f8 Mon Sep 17 00:00:00 2001 From: bakpakin Date: Tue, 16 Jun 2015 22:51:23 -0400 Subject: [PATCH] Add tiny.getSystemEntityCount(system). --- tiny.lua | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tiny.lua b/tiny.lua index 26ba74e..c52509f 100644 --- a/tiny.lua +++ b/tiny.lua @@ -334,6 +334,11 @@ function tiny.system(table, attributes) return table end +--- Get number of Entities in the System. +function tiny.getSystemEntityCount(system) + return #(system.entities) +end + --- World functions. -- A World is a container that manages Entities and Systems. Typically, a -- program uses one World at a time.