Skip to content

Rework fluent linkset param builders for bulk updates, and table building #29

@gwigz

Description

@gwigz

Currently builders just compile down into calls... Which is great but limits use and conditional flows, especially for bulk updates.

$setPrimParams(LINK_THIS)
  .color(ALL_SIDES, new Vector(1, 0, 0), 1)
  .glow(ALL_SIDES, 0.5)
  .fullbright(ALL_SIDES, true)
  .link(2, (link) =>
    link.glow(ALL_SIDES, 0.2)
  )
ll.SetLinkPrimitiveParamsFast(LINK_THIS, {
    PRIM_COLOR, ALL_SIDES, vector.create(1, 0, 0), 1,
    PRIM_GLOW, ALL_SIDES, 0.5,
    PRIM_FULLBRIGHT, ALL_SIDES, true,
    PRIM_LINK_TARGET, 2,
    PRIM_GLOW, ALL_SIDES, 0.2
})

Need to come up with something, perhaps like .apply() (breaking) or $buildPrimParams → $setPrimParams (non-breaking) that provides raw table building.

May need to keep an eye on secondlife/slua#70 too.

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions