Scroll Both Sides of a 2-Sided Line
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
-
LaundriTorture
- Posts: 13
- Joined: Mon Jul 25, 2005 3:48 pm
Scroll Both Sides of a 2-Sided Line
Was playing around with some of the ZDoom features and now I got to some point where I have a real problem: I have one 2-Sided Line and with the ACS command "Texture_ScrollBoth" (or whatever it is called) I can just scroll the Front side of the Line, not the backside.
Is there any way I can also scroll the backside with the opposite attributes (left = right, right = left) with ACS?
Greets,
LT
Is there any way I can also scroll the backside with the opposite attributes (left = right, right = left) with ACS?
Greets,
LT
-
LaundriTorture
- Posts: 13
- Joined: Mon Jul 25, 2005 3:48 pm
How? I gave the line an id of "2" with "Line_SetIdentification", then I added this to my script:
Or what do you mean?
*EDIT*
Okay, without the quotations it works fine! Though I have another problem, but it is hard to explain:
I have texture, its length is 636 and it is applied to several 2-sided linedefs wich have together also a length of 636, a circle, so the texture wraps around that perfectly fitting. Same goes to the backside of this lines.
Now I want to scroll the front and the back of both of the lines, the front to the left, the back to the right (the textures are translucent, so it should look as this circle is actually moving).
Ingame, the front and back of these textures are perfectly aligned, so the back structure applies to the front structure of the transparent sprites and vice versa. Same goes to DB-3DMode!
But now, when I start the scrolling via ACS, something strange happens and the whole front texture y-alignment moves up about 32 pixels or moves right about 128 pixels, so the alignment of back and front doesn'T fit anymore. No idea what is happening here.
@Zahl - This is a problem for you I think
If you need the map as a demo, I could send it to you, but it is big!
Code: Select all
Scroll_Texture_Both(2, 0, 120, 0, 0);
Scroll_Texture_Both("-2", 120, 0, 0, 0);*EDIT*
Okay, without the quotations it works fine! Though I have another problem, but it is hard to explain:
I have texture, its length is 636 and it is applied to several 2-sided linedefs wich have together also a length of 636, a circle, so the texture wraps around that perfectly fitting. Same goes to the backside of this lines.
Now I want to scroll the front and the back of both of the lines, the front to the left, the back to the right (the textures are translucent, so it should look as this circle is actually moving).
Ingame, the front and back of these textures are perfectly aligned, so the back structure applies to the front structure of the transparent sprites and vice versa. Same goes to DB-3DMode!
But now, when I start the scrolling via ACS, something strange happens and the whole front texture y-alignment moves up about 32 pixels or moves right about 128 pixels, so the alignment of back and front doesn'T fit anymore. No idea what is happening here.
@Zahl - This is a problem for you I think
-
LaundriTorture
- Posts: 13
- Joined: Mon Jul 25, 2005 3:48 pm
Here some demo image:

This image is taken when the scroll effect has already been started. The right side is still aligned correctly till the "misalignment". The left side is misaligned but the backside is also aligned correctly as you can see on the image. The "misalignment" scrolls slowly through the whole front texture until every line and front side of this "part" of the circle is misaligned.

This image is taken when the scroll effect has already been started. The right side is still aligned correctly till the "misalignment". The left side is misaligned but the backside is also aligned correctly as you can see on the image. The "misalignment" scrolls slowly through the whole front texture until every line and front side of this "part" of the circle is misaligned.
-
LaundriTorture
- Posts: 13
- Joined: Mon Jul 25, 2005 3:48 pm
- Graf Zahl
- Lead GZDoom+Raze Developer

- Posts: 49252
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
The texture rendering code doesn't properly handle negative scroll offsets. For efficiency reasons the rendering code works with unsigned variables. For Power-of-2 textures this doesn't matter but for all others negative offsets will produce incorrect results.
We have to see what Randy thinks about this but right now it's not possible to make this work properly. You might try to fiddle with negative texture offsets but if this is eventually fixed that solution will screw up for sure - and ZDoomGL can handle this properly.
We have to see what Randy thinks about this but right now it's not possible to make this work properly. You might try to fiddle with negative texture offsets but if this is eventually fixed that solution will screw up for sure - and ZDoomGL can handle this properly.
- Bio Hazard
- Posts: 4019
- Joined: Fri Aug 15, 2003 8:15 pm
- Location: ferret ~/C/ZDL $
- Contact:
- TheDarkArchon
- Posts: 7656
- Joined: Sat Aug 07, 2004 5:14 am
- Location: Some cold place
-
LaundriTorture
- Posts: 13
- Joined: Mon Jul 25, 2005 3:48 pm