-
-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
I tried to manipulate/modify a struct field from within (in my case to retrieve current max2d stuff like resolution, scale, ...) but somehow it is is only visible "inside" the method
SuperStrict
Framework Brl.StandardIO
Struct STest
Field x:Int
Method Fill()
Local newX:Int
FillX(newX)
x = newX
Print "Fill() x="+x
End Method
Method Modify()
x = 30
Print "Modify() x="+x
End Method
End Struct
Function FillX(value:Int Var)
value = 20
End Function
Local tests:STest[10]
tests[0].Fill()
Print "tests[0].x = " + tests[0].x
tests[0].Modify()
Print "tests[0].x = " + tests[0].x
Print "Set x=50"
tests[0].x = 50
Print "tests[0].x = " + tests[0].xOutput
Fill() x=20
tests[0].x = 0
Modify() x=30
tests[0].x = 0
Set x=50
tests[0].x = 50
Metadata
Metadata
Assignees
Labels
No labels