1
0
mirror of https://github.com/TerryCavanagh/VVVVVV.git synced 2024-06-25 05:58:30 +02:00
Go to file
Misa 79a54f23e6 De-dupe screen transition / warping logic
I noticed that the code for going to the adjacent room when offscreen
and for warping instead if the room is warping was a bit
copy-and-pasted. To clean up the code a bit, there's now 5 separate
checks in gamelogic():

if (map.warpx)
if (map.warpy)
if (map.warpy && !map.warpx)
if (!map.warpy)
if (!map.warpx)

I made sure to preserve the previous weird horizontal warping behavior
that happens with vertical warping (thus the middle one), and to
preserve the frame ordering just in case there's something dependent on
the frame ordering.

The frame ordering is that first it will warp you horizontally, if
applicable, then it will warp you vertically, if applicable. Then if you
have vertical warping only, that weird horizontal warp. Then it will
screen transition you vertically, if applicable. Then it will screen
transition you horizontally, if applicable.

To explain the weird horizontal warp with the vertical warp: apparently
if an entity is far offscreen enough, and if that entity is not the
player, it will be warped horizontally during a vertical warp. The
points at which it will warp is 30 pixels farther out than normal
horizontal warping.

I think someone ran into this before, but my memory is fuzzy. The best I
can recall is that they were probably createentity()ing a high-speed
horizontally-moving enemy in a vertically warping room, only to discover
that said enemy kept warping horizontally.
2020-04-04 16:26:15 -04:00
.github switch position of Legal Stuff & Changes 2020-01-16 09:48:58 -05:00
desktop_version De-dupe screen transition / warping logic 2020-04-04 16:26:15 -04:00
mobile_version Fix typo "Your have unlocked" to "You have unlocked" 2020-04-04 00:20:45 -04:00
third_party Update dependencies 2020-03-12 19:31:14 -04:00
tools Adding original mapping tools for the sake of completeness 2020-01-12 19:49:24 +01:00
.gitattributes fix actionscript misclassified as angelscript 2020-01-12 15:18:45 -05:00
License exceptions.md Added Haiku links 2020-02-05 15:59:51 +01:00
LICENSE.md Updated link to Make and Play edition 2020-01-13 19:37:50 +01:00
README.md Update README.md 2020-01-10 17:45:29 +01:00

This is the source code to VVVVVV, version 2.0+. For more context about this release, see the announcement on Terry's blog!

License

VVVVVV's source code is made available under a custom license. See LICENSE.md for more details.

In general, if you're interested in creating something that falls outside the license terms, get in touch with Terry and we'll talk about it!

Authors

Versions

There are two versions of the VVVVVV source code available - the desktop version (based on the C++ port, and currently live on Steam), and the mobile version (based on a fork of the original flash source code, and currently live on iOS and Android).