TI99 Environment

# CALL_LOCATE

Syntax

CALL_LOCATE(sprite-number,my,mx)

Description

The purpose of the LOCATE function is to move an existing sprite sprite-number to the given coordinates, my and mx. Valid function values: sprite-number = integer value between 1 and maxsprites my = integer value between 1 and 256* mx = integer value between 1 and 256 *Dot-row, my coordinates from 193 through 256 are off the bottom of the screen (sprite will not be visible). The location of the sprite is the upper left-hand corner of the character(s) which define it. All other sprite properties are retained, including velocity.

Example Code

    call_screen(2) : call_magnify(2)
    a$ ="*CALL_LOCATE!*"
    lg = fast len(a$)
    if lg > 15
       lg = 15
       a$ = fast left$(a$,lg)
    endif
    FOR I = 1 TO lg
        a = asc(mid$(a$,i,1))
        call_sprite(i,a,rnd(13)+3,1,1,0,0)
        dest = 8 + (i - 1) * 16
        for j = swidth to dest step - 3
            CALL_LOCATE(i,88,j)
            ti_sync()
        next j
    NEXT
    tiwaitkey()
    end

    Program Explanation:
    The above program converts the individual letters of a message string into sprites, and displays the sprite letters one by one across the screen from the right,
    using the Call_Locate() function.  The message can be up to 15 characters long.

Go back to ...

TI99E Commands Menu
Main Menu

Copyright © Carlos Santiago Lebron - TI99 Environment 2020