[solved] udt sub, access 'Me' ?

General FreeBASIC programming questions.
Post Reply
dafhi
Posts: 1641
Joined: Jun 04, 2005 9:51

[solved] udt sub, access 'Me' ?

Post by dafhi »

Is there a way I can access 'myself' in a udt sub call?

Sub Toon.Init()
ClassStats Toon.Fire
ClassStats Toon.Water
End Sub

[ thanks fxm ]
Last edited by dafhi on Sep 06, 2011 8:11, edited 1 time in total.
fxm
Moderator
Posts: 12107
Joined: Apr 22, 2009 12:46
Location: Paris suburbs, FRANCE

Re: udt sub, access 'Me' ?

Post by fxm »

dafhi wrote:Is there a way I can access 'myself' in a udt sub call?

Sub Toon.Init()
ClassStats Toon.Fire
ClassStats Toon.Water
End Sub

Code: Select all

Sub Toon.Init()
  ClassStats This.Fire
  ClassStats This.Water
End Sub
See documentation:
http://www.freebasic.net/wiki/wikka.php?wakka=KeyPgThis
Post Reply