Compile Error..

BlitzMax Forums/BlitzMax Beginners Area/Compile Error..

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.

Create a function DrawAll() on TSatellite like these:
Type TSAtellite
 ...

 Function DrawAll()
   for local t:TSatellite = eachin SatelliteList
     t.draw()
   next
 end function
end type


with TSatellite.DrawAll() you then can call that.

Its very bad OO design to iterate over a local list from outside the class actually and it defeats the purpose of classes complete (encapsulated functionality)