BLITZMAX PROFILER – CONTINUE

I did some experiments and thanks to Reflections I can – finally – save even objects in the profiler’s log.

Basically when an object is tracked any single fields is considered like a ‘normal’ variable – in the same way of any other variables (local or global) I want to record.

For example, an object TEST with two fields X and Y will generate TEXT.X and TEXT.Y as 2 new record in the profiler.

I’m working on allowing to record just one or some fields: if TEST object has X, Y, W and Z maybe I would like to track only X and not the other (or just X and Y).

Next important steps in my to-do list are field-objects: I need to find a simple way to track (or not to track) them!

So I have this syntax (subject to change of course!)

Tmonitor.AddVar("MOUSE_X",mx,100)

In this case I want to track my variable mx, assigning to it the label MOUSE_X, setting a delay – between two records – of 100 ms

Tmonitor.AddObject("Tpoint-object",p,"Tpoint","*",millisecs)

For object syntax is quite similar, but with 2 important differences

Tpoint-object is just a label, p is the object I want to track and the second Tpoint is the CLASS NAME (needed by the reflections functions/methods) – unless I find a way to bypass this !

The “*” means (at the moment) ALL THE FIELDS (probably I will allow to force the fields to track just using fieldnames separated by commas).

And even in this case millisecs means the delay.

ps: finding documentation about Reflection in BlitzMax and how to use it … is even more complicated than before!!!

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close