Commit Graph

817 Commits

Author SHA1 Message Date
Jonas Kulla d1ee507ec4 Vec2i, IntRect: Add unequal operator 2015-07-21 12:13:24 +02:00
Jonas Kulla 21247b18b5 Merge pull request #127 from cremno/add-sprite-bush_opacity
MRI: add Sprite#{bush_opacity,bush_opacity=} bindings
2015-07-21 12:12:24 +02:00
cremno 861d261af2 add Sprite#{bush_opacity,bush_opacity=} 2015-07-21 07:27:53 +02:00
Jonas Kulla fe6799d00b TilemapVX: Fix map viewport calculation 2015-07-10 04:58:28 +02:00
Jonas Kulla fe709b6010 Use vector math 2015-07-10 04:51:29 +02:00
Jonas Kulla 54c1107f19 FileSystem: Fix file lookup if unrelated files with same name exist
Before, even though we did match all possible extensions,
we only took the first match and tried opening it.
If we were looking for a .png image, but there was an unrelated
.txt file with the same name (as it actually happens in RTPs),
we would potentially see the .txt first, try opening it,
and fail alltogether, even though the image file existed.

Now we try opening all matching files until we find one that
we can parse.

This fixes #101.
2015-07-09 15:38:50 +02:00
Jonas Kulla 533e69275a Constify 2015-07-09 14:53:59 +02:00
Jonas Kulla e4558c9dfb Use FS::openReadRaw() where ext supplementing makes no sense
Specifically, in places where the full filename is always supplied,
eg. when reading .rxdata type files.
2015-07-09 12:58:01 +02:00
Jonas Kulla 5382cc11a3 MidiSource: Close source SDL_RWops before throwing error 2015-07-09 12:38:04 +02:00
Jonas Kulla 1e9e24e45c README: Add note about RGSS version support 2015-07-09 12:33:55 +02:00
Jonas Kulla 9acdd206f6 Vec4: Rename 'xyzHasEffect()' to something that makes sense 2015-07-07 16:07:04 +02:00
Jonas Kulla 6e176a454c Constify 2015-07-07 16:06:45 +02:00
Jonas Kulla afab51279e Graphics: Fix viewport color/flash effectiveness calculation
Fixes #121.
2015-07-07 16:06:11 +02:00
Jonas Kulla 61849a9158 GLMeta: Eliminate redundant parameter 2015-07-07 15:25:48 +02:00
Jonas Kulla 2d31d08fa6 Add some general fixes from #111 found by @chosenofbear 2015-06-18 07:21:55 +02:00
Jonas Kulla e778dc17c5 Relocate SDL_sound patches into forked repo 2015-06-18 07:11:38 +02:00
Jonas Kulla 6380a93cec Graphics: Fix ::transition() "filename" default value
The default value is an empty string, which triggers the simple
transition. Passing null is not legal (and wasn't possible in
mkxp from Ruby side anyway).

Fixes #108.
2015-06-10 13:30:26 +02:00
Jonas Kulla 064b7ac80d README: Add link to dependency kit 2015-06-03 16:01:29 +02:00
Jonas Kulla d5bacf50f5 TileAtlasVX: Fix table extents being covered by below tiles
Fixes the appearance of tables in VX, which place table
tiles on the same layer as ground tiles.
2015-05-31 20:58:05 +02:00
Jonas Kulla e4bc08e972 Fix for old, broken OpenAL-Soft headers
See 4219b91bbb
2015-05-26 01:40:53 +02:00
Jonas Kulla 88eca58268 Revert "check Ruby strings for embedded null bytes"
This reverts commit 29dfda0011.
It turned out to be a bad idea after all.
2015-05-11 23:13:02 +02:00
Jonas Kulla e72bced0f7 'snprintf()' guarantees null termination of buffer
Thanks @cremno.
2015-03-27 08:21:47 +01:00
Jonas Kulla 794e86d0ab AudioStream: Prevent MeWatch from restarting fully faded out stream 2015-03-22 09:06:29 +01:00
Jonas Kulla 7260c467b8 AudioStream: Clarify thread-safe usage of stream flags 2015-03-22 08:42:43 +01:00
Jonas Kulla 8d7166f3d2 MRI: Fix Font.name returning nil
I wish I had tests..
2015-03-16 08:36:29 +01:00
Jonas Kulla 5379511d95 Bitmap: Fix vertical alignment for some letters with outline 2015-03-04 23:34:56 +01:00
Jonas Kulla 91c9bfd0f4 Fix compilation failure inside OSX ifdef block 2015-02-26 19:44:05 +01:00
Jonas Kulla 7393f7e951 Config: Add "execName" to specify ini and rgssad filenames 2015-02-19 02:23:23 +01:00
Jonas Kulla 531441d4e3 Make audio asset decoding failures non-fatal
Matches RMXP behavior. This is also useful in case midi files
are to be played, but fluidsynth isn't available.
2015-02-17 02:09:55 +01:00
Jonas Kulla 0f91bdefea Fix indentation 2015-02-17 01:48:05 +01:00
Jonas Kulla 44eaaf5985 FileSystem: Change file lookup to match all extensions
Previously, file lookup (ie. extension supplementing) would only
try out a few predetermined extensions based on the asset type.
This was not accurate in regard to RMXP's behavior, which will
happily match "some_asset" against "some_asset.abcef" and try
to open it.

Some games make use of this quirk and rename their ogg audio files
to "*.dat" or similar to thwart users from copying them.

This change also makes it easier to read arbitrary formats
supported by SDL_image without modifying mkxp.
2015-02-17 01:42:11 +01:00
Jonas Kulla 87462fd7b0 Use more explicit vector math via method overloads 2015-02-10 17:04:00 +01:00
Jonas Kulla a4b1be1da5 Remove superfluous lines 2015-02-10 15:53:58 +01:00
Jonas Kulla c328ebee04 Typo 2015-02-10 15:53:12 +01:00
Jonas Kulla 713ea07558 SDL hints need to be set before initialization 2015-02-10 15:51:33 +01:00
Jonas Kulla b2631d4c23 Bitmap: Fix scaled blit from mega surface to texture
SDL's default blend mode for surfaces (SDL_BLENDMODE_BLEND)
renders the source surface unusable for further use.
2015-02-10 15:34:42 +01:00
Jonas Kulla 4864f63c6c Sprite: Fix visibility calculation
The previous code assumed the scene origin to always be 0,0.
2015-02-04 15:17:45 +01:00
Jonas Kulla e339964076 MidiSource: Fix some channels being mute after looping 2015-01-22 13:13:57 +01:00
Jonas Kulla 64a3ac3769 README: Add soundfont link and mark font outlines as done 2015-01-21 14:58:54 +01:00
Jonas Kulla fa0459ad93 Fix code formatting 2015-01-15 11:09:12 +01:00
Jonas Kulla 74f8c91bf4 Oops 2015-01-15 09:05:51 +01:00
Jonas Kulla 7cbe1eef94 Graphics: Improve transition "vague" parameter accuracy 2015-01-15 08:26:33 +01:00
Jonas Kulla f6604a88b8 sdl-util.h: Consider physical filesystem when opening raw files
This is necessary so games stored on external SD cards can be
run under Android.
2015-01-15 08:11:01 +01:00
Jonas Kulla c92df0ce3a EventThread: Pause OpenAL device when entering background
This requires ALC_SOFT_pause_device to be present. It stops the
alc thread from needlessly consuming CPU resources.
2015-01-15 08:07:22 +01:00
Jonas Kulla 7c6a2b2c62 Pause RGSS execution when moving into background on Android
Assuming that there is enough memory for mkxp to stay in the
background and that the OS doesn't kill the process, this should
allow smooth resuming after moving back into the foreground.

For now, EGL context loss is not handled.
2015-01-15 08:02:21 +01:00
Jonas Kulla 012d87d05a Disable accelerometer joystick emulation on Android 2015-01-15 07:21:07 +01:00
Jonas Kulla f1da585f33 Be explicit about how relative paths are resolved in mkxp.conf 2015-01-15 07:18:02 +01:00
Jonas Kulla a05a3deff6 EventThread: Factor out event discarding code 2015-01-03 20:48:31 +01:00
Jonas Kulla 6f88ddc51c Config: Move default entry values into PO_DESC macro list 2015-01-03 19:28:23 +01:00
Jonas Kulla 7003039e56 EventThread: Track touch state (maximum 4 fingers) 2015-01-03 19:18:52 +01:00