[04 Mar 2008] Another problem :D

Contains all messages from the Hollywood mailing list between 01/2006 and 08/2012
Locked
Andrea

[04 Mar 2008] Another problem :D

Post by Andrea »

Note: This is an archived post that was originally sent to the Hollywood mailing list on Tue, 04 Mar 2008 18:40:23 +0100

i have a little problem here when moving layers...

the code first :o)

Code: Select all

@BRUSH 1, "Hollywood.png", {LoadAlpha = True}
@BRUSH 2, "image15.jpg"

DisplayBGPic(1)
EnableLayers()

DisplayBrush(2, 16,#TOPOUT)
DisplayBrush(1, 0, 0)
i = -1013
Function p_MainLoop()
	If i < 0
		AddMove(1, #LAYER, 1, 16, i)
		i=i+1
		DoMove(1)
	EndIf
EndFunction

SetInterval(1, p_MainLoop, 1000/60)  ; 60fps

Repeat
    WaitEvent
Forever
With this code i want to scroll the layer 1 from the top outside the screen to the bottom. My image is a 256x1013 pixel jpeg. The problem i've found is that, for a while the layer scroll, then the program hangs and the debugger tells me : Internal limit encountered! Contact the author.... Line bla.. bla.. in AddMove

Any suggestions?
PEB
Posts: 576
Joined: Sun Feb 21, 2010 1:28 am

[04 Mar 2008] Re: Another problem :D

Post by PEB »

Note: This is an archived post that was originally sent to the Hollywood mailing list on Tue, 4 Mar 2008 11:20:59 -0800 (PST)

I'm not sure if this is the problem, but the Hollywood documentation suggests using ClearMove() after DoMove(). However, since you are using layers anyway, why not comment out your AddMove() and DoMove() commands, and in place of AddMove(1, #LAYER, 1, 16, i), try ShowLayer(1, 16, i)
Andrea

[04 Mar 2008] Re: Another problem :D

Post by Andrea »

Note: This is an archived post that was originally sent to the Hollywood mailing list on Tue, 04 Mar 2008 21:12:07 +0100
I'm not sure if this is the problem, but the Hollywood documentation suggests using ClearMove() after DoMove(). However, since you are using layers anyway, why not comment out your AddMove() and DoMove() commands,
Yes, with this works
and in place of AddMove(1, #LAYER, 1, 16, i), try ShowLayer(1, 16, i)
The same with the display command

Thans a lot rev :D :D
Locked