Sprite question...

Find quick help here to get you started with Hollywood
Post Reply
User avatar
Tuxedo
Posts: 355
Joined: Sun Feb 14, 2010 12:41 pm

Sprite question...

Post by Tuxedo »

Hi,
I've a simple question:

Why that work:

Code: Select all

brush1 = LoadBrush(Nil, "ram:brush1")
brush2 = LoadBrush(Nil, "ram:brush2")

CreateSprite(1, #BRUSH, brush1)
CreateSprite(2, #BRUSH, brush2)

sprite = CreateSprite(Nil, #SPRITE, 1, 2)
But that doesnt:

Code: Select all

brush1 = LoadBrush(Nil, "ram:brush1")
brush2 = LoadBrush(Nil, "ram:brush2")


sprite1 = CreateSprite(Nil, #BRUSH, brush1)
sprite2 = CreateSprite(Nil, #BRUSH, brush2)


sprite = CreateSprite(Nil, #SPRITE, sprite1, sprite2)
???

Since I cant delete the linked sprites was messy to remember all the created sprite...
Or there was a siompler way to create multiframe sprites from single brushes?
Simone"Tuxedo"Monsignori, Perugia, ITALY.
User avatar
airsoftsoftwair
Posts: 5848
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Sprite question...

Post by airsoftsoftwair »

Okay, that's a bug. As a workaround, simply use direct sprite numbers with CreateSprite(), e.g.

Code: Select all

sprite = CreateSprite(Nil, #SPRITE, 1, 2)
User avatar
Tuxedo
Posts: 355
Joined: Sun Feb 14, 2010 12:41 pm

Re: Sprite question...

Post by Tuxedo »

Ok,
tahnk you.

Keep up good work!
Simone"Tuxedo"Monsignori, Perugia, ITALY.
Post Reply