Quick Q on Types
Blitz3D Forums/Blitz3D Beginners Area/Quick Q on Types
| ||
Are Types always Global or do they have to be declared Global if you want that behaviour? (And reconfirming Arrays are always Global, yes?) |
| ||
Not quite sure what you're asking...Type MyType Field X%, Y% End TypeYou can now create instances of MyType from anywhere in your program. Var.MyType = New MyTypeVar only exists in the main program (or the function in which it was declared). Global Var.MyType = New MyTypeVar can now be used anywhere in your program. Does this help? (And reconfirming Arrays are always Global, yes?) Yup. |
| ||
Yeah, I meant a specific type instance, not a type definition. So, they are not Global by default. That's all I wnated to know. Thanks! |
| ||
You asked if types are global. That's like asking if integers are global. :) |
| ||
Hey, I don't need any help to look like a doofus, you know! :) |