Menu

#4 Sprite Image (spriteid) returns -1 in Hardware mode

v1.31
open
nobody
5
2006-07-06
2006-07-06
swagIT
No

Sprite image (spriteid) works in regular mode but in hardware mode
returns -1 for all sprites.

Is this a known bug?

'CODE BELOW===================

procedure traintest() 'checks next track based on current train direction
- returns new direction

repeat

dir = newdir

tracknumber = tracknumber +1

if sprite image (tracknumber) = 026 and dir = "w" then newdir = "n"
if sprite image (tracknumber) = 029 and dir = "w" then newdir = "s"
if sprite image (tracknumber) = 030 and dir = "w" then newdir = "w"

if sprite image (tracknumber) = 031 and dir = "e" then newdir="s"
if sprite image (tracknumber) = 028 and dir = "e" then newdir="n"
if sprite image (tracknumber) = 030 and dir = "e" then newdir="e"

if sprite image (tracknumber) = 029 and dir = "n" then newdir="e"
if sprite image (tracknumber) = 027 and dir = "n" then newdir="n"
if sprite image (tracknumber) = 031 and dir = "n" then newdir="w"

if sprite image (tracknumber) = 026 and dir = "s" then newdir="e"
if sprite image (tracknumber) = 027 and dir = "s" then newdir="s"
if sprite image (tracknumber) = 028 and dir = "s" then newdir="w"

if dir = "w" and newdir = "n" then trainwn()'train anims
if dir = "w" and newdir = "s" then trainws()
if dir = "w" and newdir = "w" then trainww()

if dir = "e" and newdir="s" then traines()
if dir = "e" and newdir="n" then trainen()
if dir = "e" and newdir="e" then trainee()

if dir = "n" and newdir="e" then trainne()
if dir = "n" and newdir="n" then trainnn()
if dir = "n" and newdir="w" then trainnw()

if dir = "s" and newdir="e" then trainse()
if dir = "s" and newdir="s" then trainss()
if dir = "s" and newdir="w" then trainsw()

print tracknumber
print sprite image (tracknumber)

until sprite col (301,601)>-1
end proc

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.