Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
19
Task/Classes/Lasso/classes.lasso
Normal file
19
Task/Classes/Lasso/classes.lasso
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
define mytype => type {
|
||||
data
|
||||
public id::integer = 0,
|
||||
public val::string = '',
|
||||
public rand::integer = 0
|
||||
|
||||
public onCreate() => {
|
||||
// "onCreate" runs when instance created, populates .rand
|
||||
.rand = math_random(50,1)
|
||||
}
|
||||
public asString() => {
|
||||
return 'has a value of: "'+.val+'" and a rand number of "'+.rand+'"'
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
local(x = mytype)
|
||||
#x->val = '99 Bottles of beer'
|
||||
#x->asString // outputs 'has a value of: "99 Bottles of beer" and a rand number of "48"'
|
||||
Loading…
Add table
Add a link
Reference in a new issue