counting types

Blitz3D Forums/Blitz3D Beginners Area/counting types

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

For example I have created 2 objects in a Type and I want to display the amount. Is the only option to create a global variable and increment it when creating a new object?

Example:

Type model
  field mesh
End Type

m.model = new model
m\mesh = blah

m.model = new model
m\mesh = blah

;main-----------

Text 10,10,"Number of models: "+ ????