attributes: @Material(field) resolved as @Node is; @OneOf on a string field takes words, and every registry row's value is checked against them - words on another field, or constants on a string, is an error; reseeded
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
d82dc3162f
commit
81cb992fad
10 changed files with 75030 additions and 73286 deletions
|
|
@ -32,6 +32,8 @@ program Attributes {
|
|||
@Key bind: int = 0 # the key that takes it in hand
|
||||
@Clip(model) swing: string = "swing" # the clip it plays in use
|
||||
@OneOf(VD_STORE, VD_MARINA) sold_at: int = VD_MARINA
|
||||
@Material(model) finish: string = "steel" # a material in that model
|
||||
@OneOf("box", "hull") shape: string = "box" # what it collides as: one of these words, row by row
|
||||
}
|
||||
@AppendOnly
|
||||
registry Tools of Tool as TL from "data/attr_tools.lres"
|
||||
|
|
|
|||
|
|
@ -5,4 +5,5 @@ lantern {
|
|||
seller: VD_MARINA
|
||||
weight: 0.75
|
||||
stocked_at: VD_MARINA
|
||||
shape: "hull"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
# attributes: @Node / @Clip name a field of their record that names a glTF - `handle` names no field,
|
||||
# `tag` is a plain string, and `kit` refers to a registry whose record has two models: four errors.
|
||||
# @OneOf's KITS_NONE and @Tint's TSLOT_NONE are in no part of the program: two warnings.
|
||||
# `tag` is a plain string, and `kit` refers to a registry whose record has two models.
|
||||
# @Material(tag) is the same fault; words on an int, constants on a string, and a row whose shape is
|
||||
# no word of its @OneOf are the rest: eight errors. @OneOf's KITS_NONE and @Tint's TSLOT_NONE are in
|
||||
# no part of the program: two warnings.
|
||||
program R {
|
||||
property Kit {
|
||||
key: string = ""
|
||||
|
|
@ -17,6 +19,12 @@ program R {
|
|||
@Clip(tag) swing: string = ""
|
||||
@OneOf(KITS_COUNT, KITS_NONE) which: int = 0
|
||||
@Tint(TSLOT_NONE) shade: int = 0
|
||||
@Material(tag) paint: string = ""
|
||||
@OneOf("a", "b") size: int = 0
|
||||
@OneOf(KITS_COUNT) form: string = ""
|
||||
@OneOf("box", "hull") shape: string = "box"
|
||||
}
|
||||
registry Tools of Tool
|
||||
def Tools crate { shape: "cube" }
|
||||
entry { print(KITS_COUNT) }
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue