CHANGE MESH This command will change the mesh of an object limb.
Syntax
    CHANGE MESH Object Number, Limb Number, Mesh Number
Parameters
    Object Number
Integer The object number
    Limb Number
Integer The limb number
    Mesh Number
Integer The mesh number
Returns
This command does not return a value.
Description
You can use this command to animate an object that requires a sequence of fixed static meshes. The parameters must be integer values.
Example Code
    sync on

    sync rate 120

    hide mouse

    cls 0

    ObjectNumber=1

    MeshNumber=1

    LimbNumber=0

    TextureNumber=1

    load mesh "mesh.x",MeshNumber

    load mesh "newmesh.x",MeshNumber+1

    load image "iron.jpg",TextureNumber

    make object ObjectNumber, MeshNumber,TextureNumber

    if mesh exist(MeshNumber)=1 then delete mesh MeshNumber

    make mesh from object MeshNumber, ObjectNumber

    add limb ObjectNumber,LimbNumber+1,MeshNumber

    link limb ObjectNumber,0,LimbNumber+1

    offset limb ObjectNumber,1,1,0,0

    color limb ObjectNumber,LimbNumber+1,rgb(0,255,0)

    scale limb ObjectNumber,LimbNumber+1,50,50,50

    while mouseclick()=0

    set cursor 0,0

    print "press z key"

    if inkey$()="z" then change mesh ObjectNumber, LimbNumber+1, MeshNumber+1

    xrotate object ObjectNumber,wrapvalue(object angle x(ObjectNumber)+1)

    sync

    endwhile

    delete object ObjectNumber

    if mesh exist(MeshNumber)=1 then delete mesh MeshNumber

    if mesh exist(MeshNumber+1)=1 then delete mesh MeshNumber+1

    end
See also
BASIC3D Commands Menu Index