Title says it all. I searched, but I cannot find this topic mentioned anywhere.
I tried to do this:
But naturally, this doesn't work. How can I pass a variable to
a New() call to customize the variables on creation?
EDIT: Oh, and hi everybody! I've taken a 2 year hiatus from programming,
but I loved this place and I'm glad to be coding again. I used to be
"Arrant Drew", if anyone remembers or cares.
I tried to do this:
Const OCTOPUS:Int = 1 Local zorg:enemyType = New(OCTOPUS) enemyType Type enemyType Field kind:Int Method New(kindOfEnemy:Int) kind = kindOfEnemy EndMethod EndType
But naturally, this doesn't work. How can I pass a variable to
a New() call to customize the variables on creation?
EDIT: Oh, and hi everybody! I've taken a 2 year hiatus from programming,
but I loved this place and I'm glad to be coding again. I used to be
"Arrant Drew", if anyone remembers or cares.