array's are global when outside of functions, and when they're UDT'd (^_^)
if within a function and only want then in the function then you have to local them...
[name]() usually stands for an array, which must be declared with the "dim" (declare in memory) command prior to use - else Pro will go "WTF is this!?"
type button_t
left as word
right as word
bottom as word
top as word
active as boolean
endtype
dim arButton(255) as button_t
as your not declaring the types within the array but the possible instances of them then the array above gives you 255 buttons
and it is always good to optimised the setup of your data, as it isn't likely your screen width or screen height will ever exceed 65535 x 65535 there is no need to declare as integers - even if it does i'd suggest a dword, because screen sizes are never below 0
also i placed active as a boolean because that is either 1 yes it is or 0 no it isn't - means you can setup
#constant TRUE 1
#constant FALSE 0
then use TRUE and FALSE instead
lastly the useage is
if arButton(1).active = TRUE then dofunction()
with dofunction() as whatever you want it to do, but thats basically how you use the types... the more types attached the more (.) subs
for example
type vec3_t
x as float
y as float
z as float
endtype
type vec2_t
x as float
y as float
endtype
type Face_t
vertex as Vec3_t
skin as Vec2_t
endtype
tModel as Face_t
tModel.vertex.x = 10.0
tModel.vertex.y = 5.0
tModel.vertex.z = 60.0
tModel.skin.x = 1.0
tModel.skin.y = 0.6
thats completely random but you get the idea
Tsu'va Oni Ni Jyuuko Fiori Sei Tau!
One block follows the suit ... the whole suit of blocks is the path ... what have you found?