What it does
SpriteShapeNumVertices takes iSpriteIndex (an integer) and shapeID (an integer), and answers an integer. iSpriteIndex is the id of a Sprite object, the one CreateSprite returned: it is how the call knows what to act on.
Syntax
SpriteShapeNumVertices(iSpriteIndex integer, shapeID integer) → integerParameters
| Name | Type |
|---|---|
| iSpriteIndex | integer |
| shapeID | integer |
Every form returns
integer
Example · generated
image = LoadImage("assets/sprite.png", 1)sprite = CreateSprite(image)object = LoadObject("assets/media.obj")shape = LoadObjectShape(object, "assets/media.obj")DO Print(SpriteShapeNumVertices(sprite, shape)) Sync()LOOPLoadImage, CreateSprite, LoadObject and LoadObjectShape are there to give the call something to act on; SpriteShapeNumVertices is the line that matters. The DO … LOOP is not decoration: a classic BASIC program ends the moment it runs out of lines, and Sync() is what draws the frame.