Compare commits

...

3229 Commits

Author SHA1 Message Date
Tom Rothamel 366a09d708 Changes to get Ren'Py compiling with pygame_sdl2/sdl2. 2014-11-04 21:15:41 -05:00
Tom Rothamel 3fe3df9f23 Link to translation best practices. 2014-10-22 22:46:21 -04:00
Tom Rothamel e942545e39 changelog: Translation updates. 2014-10-21 22:33:09 -04:00
Tom Rothamel 9fe39eb8f3 Update changelog for 6.18.3. 2014-10-21 22:27:52 -04:00
Tom Rothamel b1b17bd9cc Remove translation TODOs. 2014-10-20 21:38:32 -04:00
Tom Rothamel 1b34b59f5e Merge pull request #482 from civalin/i10n/zh_TW
Traditional Chinese translation for launcher updated.
2014-10-20 21:36:25 -04:00
Tom Rothamel 719f06339c Merge pull request #481 from tlm-2501/patch-2
Updated Russian translation for preferences.rpy.
2014-10-20 21:36:07 -04:00
Tom Rothamel 7abba42bca Document showif. 2014-10-20 21:32:44 -04:00
Tom Rothamel c1120fc5b2 transform: Apply time adjustments on _hide, as well as render.
Fixes #484.

See: http://lemmasoft.renai.us/forums/viewtopic.php?p=343556#p343556
2014-10-19 23:07:10 -04:00
Tom Rothamel 7d29b8968a When in self-voicing mode, ignore {w} and {p} text tags.
These (especially the timed variants) tend to disrupt
text-to-speech. It's best to just have them speak in a
single block, whih is closest to the human speech pattern.

Fixes #483.
2014-10-19 11:40:46 -04:00
Tom Rothamel 994adf2ca5 Add the renpy.invoke_in_thread function. 2014-10-18 15:10:17 -04:00
Tom Rothamel bd55020512 Add updater.UpdateVersion.
This is a function that contacts an update server and determines
if there is an update available. It does this in a background thread,
so as to not make the game unresponsive.
2014-10-18 15:02:45 -04:00
Tom Rothamel b4f7d641b0 showif: Integrate with screen language.
This gives us a showif statement that applies the ShowIf displayable
to its children.
2014-10-17 23:12:13 -04:00
Tom Rothamel 1197cff85b showif: Rewrite showif.
We now simply deliver "appear", "show", and "hide" to the child,
rather than trying to exploit _hide. The advantage of doing it this
way is that we can preserve the hide state going into show, without
having to transfer it between transforms.
2014-10-17 22:15:53 -04:00
Tom Rothamel 5e8fc44fb3 Maintain hide_response and replaced_response over all transform renders.
This lets us simply query a transform to determine if it's blocking
hide/replaced, rather than having to update it in an unusual way.
2014-10-17 22:14:53 -04:00
Tom Rothamel 5df33b0f56 Only force us to stay in hide/replaced if a request happens.
This lets us issue "hide" to a transform by normal means, and override
it later.
2014-10-17 22:13:56 -04:00
Civa Lin fc9e826976 i10n: Traditional Chinese language for launcher updated. 2014-10-18 09:50:36 +08:00
Civa Lin e80d6f95a9 Merge branch 'master' into i10n/zh_TW 2014-10-18 09:47:33 +08:00
tlm-2501 8815e5efb8 Updated Russian translation for preferences.rpy. 2014-10-17 21:31:08 +04:00
Tom Rothamel 9874bc4dc3 WiP of ShowIf. 2014-10-16 22:54:22 -04:00
Tom Rothamel 82b597f62b Fix {Set,Toggle}ScreenVariable.
These functions were marked as pure, but weren't actually pure
functions, since the scope they update can change. This change
has them return objects, which are pure.
2014-10-16 22:41:31 -04:00
Tom Rothamel 4b35493447 The ATL on statement now takes a list of event names.
This will be useful for the upcoming showif displayable, which might
be used with transforms that contain "on start, idle:".
2014-10-15 20:17:28 -04:00
Tom Rothamel 69b203fbaa doc: Add warning about show layer and transform state.
Fixes #479.
2014-10-14 18:05:46 -04:00
Tom Rothamel 875a585e90 sl2: Use a newly-created context when predicting SLIf.
We had incorrectly used the original context, which led to the
contents of the predicted if statement showing up if the
statement was reused:

See: http://lemmasoft.renai.us/forums/viewtopic.php?f=32&t=28793
2014-10-14 17:46:32 -04:00
Tom Rothamel 935d065712 Transfer focus based on displayable replacement.
When a displayable in a screen that has focus/grab is replaced,
we transfer the focus to its replacement. This fixes a problem where
we would transfer grab only, which could lead to a permagrab condition.

Fixes #477.
2014-10-14 00:32:05 -04:00
Tom Rothamel c0c44896a8 Add _composite_parts for composite displayables.
For composite displayables (those with _main) set, this gives a list
of all components, other than the root widget, that make up the
displayable.
2014-10-13 23:55:40 -04:00
Tom Rothamel b7a9266bf3 Update changelog with new prediction stuff. 2014-10-12 13:26:42 -04:00
Tom Rothamel 8bf5f05270 While at the main menu, predict the start label.
This should provide a better experience in the start-new-game case,
which is the first thing a player will see.

Fixes #478.
2014-10-12 12:43:24 -04:00
Tom Rothamel 996d3c2fd6 Improve prediction of call/return.
We now model the return stack as part of the prediction process,
making it possible to perform prediction through a call and return
pair.

Fixes #288.
2014-10-12 01:30:01 -04:00
Tom Rothamel f68a4caec2 Check Side for correct parameters and children.
Fixes #476.
2014-10-11 22:17:44 -04:00
Tom Rothamel f06e5861e7 Bump versio to 6.18.3. 2014-10-11 17:13:07 -04:00
Daniel Luque a93f4f1f76 Merge pull request #475 from LuqueDaniel/update-es
Update es
2014-10-11 15:30:40 +02:00
Daniel Luque 572054c6e1 Update: templates/spanish/game/tl/none/common.rpy 2014-10-11 15:24:15 +02:00
Daniel Luque bc3f659f4b Update: launcher/game/tl/spanish/common.rpy 2014-10-11 15:19:24 +02:00
Tom Rothamel db63d0db4e Update changelog. 2014-10-09 22:28:02 -04:00
Tom Rothamel e7424e1140 Merge pull request #474 from civalin/i10n/zh_TW
Add Traditional Chinese translation.
2014-10-09 17:07:53 -04:00
Tom Rothamel c345b6a84c android: Log call errors to android.txt. 2014-10-08 23:21:02 -04:00
Tom Rothamel 5fd9bbe651 Pop dynamic when a lookup_return fails. 2014-10-08 20:44:01 -04:00
Tom Rothamel d19b49d418 Restore the current screen using try/catch.
This fixes a bug where the current screen could be set at an
inopportune time, causing crashes.

See: https://gist.github.com/vaendryl/97fb82b9cbee8bda0777
2014-10-08 20:17:00 -04:00
Tom Rothamel f5103f4bf9 Update the changelog. 2014-10-07 23:34:02 -04:00
Tom Rothamel dc5357c7f2 Increase the image cache size to 16 screens.
We should be able to afford this, and computers have more RAM than they used to.
2014-10-07 23:26:26 -04:00
Tom Rothamel 61f940a2f2 Config changes:
* Increase the predict lookahead.
* Make RENPY_DEBUG_IMAGE_CACHE set the default value of config.debug_image_cache.
2014-10-07 22:26:37 -04:00
Tom Rothamel b38d0edb2c Better prediction of DynamicDisplayable.
If no predict function exists, the regular DD function is called,
and what it returns is now predicted.
2014-10-07 22:19:40 -04:00
Tom Rothamel 36834b094d Ensure rpyfn is defined when loading .rpyc files. 2014-10-07 20:12:27 -04:00
Civa Lin cefdc342b6 i10n: Traditional Chinese language for template. 2014-10-07 15:54:04 +08:00
Civa Lin 1c409025e1 i10n: Traditional Chinese language for launcher 2014-10-07 15:41:41 +08:00
Tom Rothamel 29cbac1c95 Ensure that yes_thread is always defined in AndroidInterface.
Fixes the immediate problems in #472.
2014-10-06 22:16:12 -04:00
Tom Rothamel 596cc4e6b6 Display an indicator when self-voicing is enabled.
This prevents people from getting stuck in self-voicing, and reporting
it as a bug.

Fixes #471.
2014-10-06 21:46:58 -04:00
Tom Rothamel 19d52e85f1 Update docs/changelog. 2014-10-05 21:33:30 -04:00
Tom Rothamel 75789bb8f2 memory: Add the renpy.profile_rollback() function.
This profiles the amount of memory used by the rollback system.

Fixes #470.
2014-10-05 21:13:55 -04:00
Tom Rothamel 55c00a86aa memory: Ignore the renpy.store module.
It's an alias of the store module, and we want to use the store name
to make it clear what's part of Ren'Py and what's part of the game.
2014-10-05 13:35:32 -04:00
Tom Rothamel 3f4f86f0fd memory: Try to speed up profiling. 2014-10-05 00:34:54 -04:00
Tom Rothamel 81c3e0c28e memory: Use gc.get_referents to walk objects.
This is simpler and more accurage.
2014-10-05 00:12:48 -04:00
Tom Rothamel dc058298f7 memory: Add the renpy.diff_memory() function.
This prints out the difference in memory usage since the last
time it was called.
2014-10-05 00:02:25 -04:00
Tom Rothamel 4609a1139c memory: Add the renpy.profile_memory() function.
This is a function that dumps a profile of memory to memory.txt (and
stdout if it's a tty.)
2014-10-04 23:27:39 -04:00
Tom Rothamel 9b5cb37b74 Rewrite the memory profile.
We now use sys.getsizeof to consider the actual object size,
rather than simply the number of objects that exist.
2014-10-04 22:03:09 -04:00
Tom Rothamel ff0893155d focused -> mouse_focused in swdraw. 2014-10-04 17:59:45 -04:00
Tom Rothamel 127f46c1d9 Remove unnecessary translation TODOs. 2014-10-03 23:09:35 -04:00
Tom Rothamel 2edea5b052 Write script to remove translation TODOs. 2014-10-03 23:09:14 -04:00
Tom Rothamel a256ed1c1e Merge pull request #469 from renoa/patch-7
Update common.rpy
2014-10-03 23:01:01 -04:00
Tom Rothamel 54d8b5733c Merge pull request #468 from renoa/patch-6
Update front_page.rpy
2014-10-03 23:00:51 -04:00
Tom Rothamel d59e6d0d45 Merge pull request #467 from renoa/patch-5
Update preferences.rpy
2014-10-03 23:00:44 -04:00
Tom Rothamel 66d3fbd6b0 Merge pull request #466 from renoa/patch-4
Update project.rpy
2014-10-03 23:00:36 -04:00
Tom Rothamel f83f217385 Merge pull request #459 from tlm-2501/patch-1
Updated translations in front_page.rpy.
2014-10-03 23:00:07 -04:00
Tom Rothamel c0b6d2dd3e Merge pull request #451 from renoa/patch-3
Update editor.rpy
2014-10-03 22:59:56 -04:00
Tom Rothamel 42e6d3f368 sl2: Properly analyze the iteration variable of a for loop.
Since it's defined in the loop, it should be at most a local constant,
not a global constant.
2014-10-02 23:27:36 -04:00
Tom Rothamel 9e3d1db244 Do not cache renders when sizing size_groups. 2014-10-02 21:21:05 -04:00
Tom Rothamel 8f0d132104 Ignore tts errors.
Rather than letting them crash the game.
2014-10-02 20:11:57 -04:00
Tom Rothamel 3813f0dc26 Improve reporting of duplicated labels from renamed .rpycs.
Fixes #452.
2014-10-01 20:56:52 -04:00
Renoa 1cb04cd09f Update common.rpy 2014-10-01 10:34:02 +03:00
Tom Rothamel fa8d11a13c Check return value of l.rest() when an expression/statement is expected.
This prevents problems where we let a None pass into some other
part of the code:

See: <00b201cfdc7e$c7d24530$5776cf90$@gmail.com>
2014-09-30 20:28:49 -04:00
Renoa c9c74ec020 Update common.rpy
translation
2014-09-30 23:13:06 +03:00
Renoa cccd957545 Update front_page.rpy
translation
2014-09-30 23:10:14 +03:00
Renoa 938a6f3fa8 Update preferences.rpy
translation
2014-09-30 23:06:31 +03:00
Renoa ad2763a460 Update project.rpy
translation
2014-09-30 23:04:11 +03:00
Tom Rothamel 779912dd80 Update Play.selected when get_selected() to be recalled.
This fixes a problem where selected would never become correct.
2014-09-29 22:57:46 -04:00
Tom Rothamel f058d56d0f Make Play's participation in get_selected optional.
It doesn't make sense for Play on the sound channel to participate
in get_selected(), since it's very likely the sound will quickly
end.

See: http://lemmasoft.renai.us/forums/ucp.php?i=pm&mode=view&f=0&p=148211
where Play causes Ren'Py to restart the interaction repeatedly.
2014-09-29 22:42:36 -04:00
Tom Rothamel c081ad9f78 Add renpy.music.is_music().
An internal function that returns true if a channel is a music
channel, and false otherwise.
2014-09-29 22:36:25 -04:00
Tom Rothamel bbd505b378 Add a debug style property.
This is meant for Ren'Py developer use. We can look at d.style.debug
to debug a displayable.
2014-09-29 20:11:58 -04:00
Tom Rothamel 1382c299fb Mousearea now respects focus_mask.
This makes it possible to have non-rectangular mouseareas.

Fixes #457.
2014-09-28 20:53:53 -04:00
Tom Rothamel 84429c3826 Convert focus_mask into a displayable in the style system.
This allows for render caching as necessary.
2014-09-28 20:40:47 -04:00
Tom Rothamel 971e33aa97 Remove spurious debug print. 2014-09-27 21:39:02 -04:00
Tom Rothamel 9cf92c7f34 Add keyboard_focus style property.
Setting this property to False hides a button, bar, or hotspot from the
keyboard focus mechanism. This might be useful for games where we
want to hide interface from the user, like hidden object games.
2014-09-27 21:34:36 -04:00
Tom Rothamel 20ca7fb463 Random doc fixes / generated code. 2014-09-26 21:49:15 -04:00
Tom Rothamel 5834069ddf Document the character named store.
Fixes #422.
2014-09-26 21:48:26 -04:00
Tom Rothamel ee2dc4aaea Make the define statement take an optional namespace.
This is intended to let us do:

   define character.e = Character("Eileen")
2014-09-26 21:22:46 -04:00
Tom Rothamel 7057ce19a1 The say statement looks for characters in the character namespace.
This lets us have a character with the same name as an object or
variable.
2014-09-26 20:39:10 -04:00
Tom Rothamel a190738a24 Add functions to get/set the return stack.
Fixes #464.
2014-09-25 23:27:26 -04:00
Tom Rothamel 60a9589a80 Deal with formats SDL_image can't reentrantly load.
It seems like SDL_image has problems reentrantly loading some
formats, certainly GIF and maybe TGA and BMP. So we whitelist
the common formats (png and jpeg), and lock loads of the rest.

Fixes #426.
2014-09-24 21:26:20 -04:00
Tom Rothamel 2ea6291b0d Add the crop_relative transform property.
When true, makes crop relative to the size of the image.
2014-09-24 00:42:36 -04:00
Tom Rothamel 4bd9c96d9c Bump version to 6.18.2. 2014-09-23 19:06:11 -04:00
Tom Rothamel 46c1f8067c Merge pull request #461 from javimat/master
Update Spanish template
2014-09-22 10:02:03 -04:00
javimat 4deae69732 Update screens.rpy
...from the English template. With parameters in screens definitions.
2014-09-22 15:34:02 +02:00
javimat ac09cb8363 Update options.rpy
Delete English explanations (redundant)
2014-09-22 15:32:22 +02:00
Tom Rothamel b397f4b235 Stop using the RENPY_BASE environment variable.
Fixes #460.
2014-09-21 17:37:04 -04:00
Tom Rothamel 389749b221 Use redraw() to handle invalidation.
They're really the same operation, except invalidation can be
run in the middle of a render. So let's check for that, and
use a single codepath.

This fixes a bug where when something was shown twice, the
invalidate could not take.

See: twelvethousand
2014-09-21 15:51:47 -04:00
Tom Rothamel 2da32702fe Revert "Force the animation timebase for ATL in show layer."
It's no longer necessary, now that we're only adjusting
ATL time in screens.

This reverts commit 72027f7f69.
2014-09-21 00:24:29 -04:00
Tom Rothamel f6b2161ac9 Run IAP actions in a new context.
The actions (at least the purchase action) requires us be interacting,
so we can go to sleep and let play services take over to handle the
actual transaction.

This requires us to interact in the middle of a callback, so we do
an invoke_in_new_context to make that possible.
2014-09-21 00:22:50 -04:00
Tom Rothamel 6343c2cd6b Make ATL time adjustments require take_execution_state.
The ATL time adjustments only make sense after take_execution_state.
If we're in a context where take_execution_state is never called,
we don't want to do the time adjustments.

So now, we make it a requirement that take_execution_state be called
before doing time adjustments.
2014-09-20 21:52:51 -04:00
Tom Rothamel 7960b6b7be Use only the index to look up entries in an SLFor's cache.
Using the object id proved to be error prone when new objects were
created during each iteration of the list (something we support).
This also returns the behavior to what it was in 6.17.

See: Seasons of the Wolf.
2014-09-20 19:50:16 -04:00
tlm-2501 f9875d9bad Updated translations in front_page.rpy. 2014-09-21 00:35:44 +04:00
Tom Rothamel 72027f7f69 Force the animation timebase for ATL in show layer.
We really should be propagating the transform state, but there
isn't really a good way to do that at the moment. (It isn't clear
where we'd store the old state.)

This is a reasonable, if ugly, workaround.

See: http://lemmasoft.renai.us/forums/ucp.php?i=pm&mode=view&f=0&p=147158
2014-09-19 23:00:38 -04:00
Tom Rothamel da532392d9 Fix load of .rpycs during .rpy compilation.
This fixes various missing label problems.
2014-09-19 22:21:07 -04:00
Tom Rothamel b1a392e171 Properly check that all parameters have been consumed.
And do it right this time.
2014-09-19 18:47:48 -04:00
Tom Rothamel 252baf8f1e Add renpy.munge()
This is a function that munges a string beginning with __ in the
same manner that Ren'Py munges names when parsing a file.

    jump __test

and:

    jump expression renpy.munge("__test")
2014-09-18 19:53:01 -04:00
Tom Rothamel 75d41125a1 Do not predict the main_menu image.
We don't define one by default, so if the user is debugging
prediction, this will fail.
2014-09-18 19:33:31 -04:00
Tom Rothamel 76c7c2aa86 atl: Global const transforms do not need parameters to be compiled.
This prevents an error we introduced in the last release.
2014-09-18 13:44:32 -04:00
Tom Rothamel 61466cf927 Update docs. 2014-09-18 00:09:40 -04:00
Tom Rothamel 2befad5da1 Fix check of atl parameters before compile. 2014-09-18 00:00:47 -04:00
Tom Rothamel c1c046788b Add an sv character that can be used to self-voice descriptive text. 2014-09-17 23:55:41 -04:00
Tom Rothamel 1af82edd66 sl2: Propagate state into transitions added with add.
This requires a recompile.
2014-09-17 22:12:25 -04:00
Tom Rothamel 6a9835ad43 Bump version and update changelog. 2014-09-16 23:30:03 -04:00
Tom Rothamel 5402d84831 Add german template. 2014-09-16 23:28:24 -04:00
Tom Rothamel b30e7de686 sl2: Update screens that are already showing.
This matches the SL1 behavior.
2014-09-16 22:56:48 -04:00
Tom Rothamel 312d64b361 iap: Unconditionally restore purchases @ start. 2014-09-16 17:07:18 -04:00
Tom Rothamel 8bfb4d9f00 Update the who Text after display_say changes its properties.
This is necessary to make the properties take effect after the layout
has already been built.
2014-09-15 22:49:13 -04:00
Tom Rothamel 7253663eff sl2: Displayables with id can't be constant.
That's because they may be given arguments from outside the screen that
sl2 doesn't know about. Better safe then sorry, especially in a rare
case.
2014-09-15 22:47:37 -04:00
Tom Rothamel df6e8db1f1 Document Placeholder. 2014-09-15 20:20:47 -04:00
Tom Rothamel 7bc51c30db Properly document the third argument to edgescrill.
Fixes #447.
2014-09-15 20:09:47 -04:00
Tom Rothamel d2aa4adfe4 ATL transforms now begin executing when first shown.
Previously, ATL transforms began executing when the screen containing
the ATL transform was first shown, which meant that if the transform
changed over the course of screen display, a portion of the new
transform would be skipped.
2014-09-15 19:54:38 -04:00
Tom Rothamel f29df20878 script: Commit to loading a file when it parses/unpickles.
This prevents an error that was caused by when an exception in
finish_load would cause the .rpy file to load after finish_load
had already started updating data structures.
2014-09-15 00:45:46 -04:00
Tom Rothamel 57e935e1f4 Reorder methods in Script. 2014-09-15 00:12:21 -04:00
Tom Rothamel 88cb519b4d atl: Properly compute const-ness for a function statement.
Fixes #449.
2014-09-14 09:42:52 -04:00
Renoa 4a9becb351 Update editor.rpy
translated some lines
2014-09-14 14:44:24 +03:00
Tom Rothamel 0a4e788349 Use Placeholders for missing images. 2014-09-13 19:02:39 -04:00
Tom Rothamel ed9f598098 placeholder: Add Placeholder displayable.
This displays a placeholder image. The image displayed may be chosen
by the creator, or automatically determined based on the name of the
image being placeheld.
2014-09-13 18:39:30 -04:00
Tom Rothamel 529bb95a43 Ensure hiding is set on legacy ScreenDisplayables. 2014-09-12 21:37:55 -04:00
Tom Rothamel d8a945095e Ensure hiding is always an attribute of screens.
Fixes compatibility with 6.17.

See: Lovely Little Thieves 0.5
2014-09-12 21:05:39 -04:00
Tom Rothamel 77b65c7778 Set all-state Transform properties on initialization.
This lets users of a Transform access its properties before it
has been rendered or updated for the first time.
2014-09-11 09:06:39 -04:00
Tom Rothamel 2ed8af936c Check in profile_screen. 2014-09-10 22:30:35 -04:00
Tom Rothamel 3ecf7cf565 Optionally, automatically build_all on distribute if pyx changed. 2014-09-10 22:25:30 -04:00
Tom Rothamel 0902ccd28b tts: Document what_alt. 2014-09-10 21:20:42 -04:00
Tom Rothamel 2a217bf064 tts: Strip " before passing text to windows.
Windows command line argument parsing strikes again. This seems to
let text pass through in a way that makes it reasonably correct.
2014-09-10 21:10:54 -04:00
Tom Rothamel 3243f4c3ac tts: Allow the alt property of Text to take [text].
This makes it possible to wrap the text with prefixes and suffixes
on a per-Character basis, so as to more accurately convey meaning.
2014-09-10 21:00:27 -04:00
Tom Rothamel 4cf2921310 Share code between the RollForward action and behavior.
This makes the action work properly.

Fixes #436.
2014-09-09 18:20:28 -04:00
Tom Rothamel 53fc982bba Speed up style selection.
We do this by cheating heavily - avoiding re-preparing screens, and
busting the render cache. This wouldn't work for arbitrary code,
but it's good enough for the theme chooser.
2014-09-09 09:21:11 -04:00
Tom Rothamel 8a88c6d6f9 Re-add the use_cache at setstate.
This makes it possible to load a screen that uses use.
2014-09-09 08:46:00 -04:00
Tom Rothamel 136e31ada7 When a used screen takes parameters, persist its scope across interactions.
This makes sense for the new behavior of screens with parameters,
and is useful.

Fixes #194.
2014-09-08 22:59:26 -04:00
Tom Rothamel dfe32a1339 Ignore time spent not scrolling when edge scrolling.
This prevents big jumps from occuring when the mouse leaves one side
of the window, and re-enters on another side of the window.

Fixes #431.
2014-09-08 22:31:28 -04:00
Tom Rothamel bab6f8afc6 Allow a transform to have both a function and arguments.
This fixes a regression of the 6.17 behavior.

See: Jake's battle engine.
2014-09-07 22:51:00 -04:00
Tom Rothamel c0ea8ebcf2 Document use statement changes. 2014-09-07 00:11:33 -04:00
Tom Rothamel 033fcbbeaf sl2: Implement the "use <screen> id <id>" syntax.
Where sl1 used structural equality to transfer state between
screens sharing the same tag, sl2 can't do that. (Doing so would
require maintaining _name, which is expensive.)

Instead, we allow uses of screens to include an id property,
which explcitly specifies equality of used screens.
2014-09-06 23:44:54 -04:00
Tom Rothamel a2398afaf1 Update properties in Transform.default_function.
This preserves non-ATL transform behavior in the face of taking
state and execution state.

Fixes #445.
2014-09-06 20:47:10 -04:00
Tom Rothamel cacef7e71a Fix formatting of "could not find return label". 2014-09-06 20:19:42 -04:00
Tom Rothamel 54f9662bc0 Transpose grids as we render the grid.
Before this patch, we would transpose grids once, which caused a
problem where a reused grid would only be transposed once.

See: https://mail.google.com/mail/u/0/#inbox/1484b917bff1005b (Private)
2014-09-06 16:04:10 -04:00
Tom Rothamel 0fea7ee77c Use RENPY_AUTO_LOAD to override config.auto_load.
This provides an easy way to force a save load for development
purposes.
2014-09-06 14:26:30 -04:00
Tom Rothamel 1c71db539e Test that save directories are writable on Android before using them.
Relevant to #441.
2014-09-05 23:27:56 -04:00
Tom Rothamel e8a0b8413d Do not use the game-local save directory on Android.
Relevant to #441.
2014-09-05 23:18:12 -04:00
Tom Rothamel e192814d02 Error out if the base directory doesn't exist. 2014-09-05 15:21:37 -04:00
Tom Rothamel 066a6a6185 sl2: Do not take state from predicted displayables or transforms.
If the parameters to a displayable or transform change between
when a screen is predicted and when it is shown, it means that
the prediction was incorrect.

We now discard the incorrect prediction state, instead of allowing it
to influence the screen.

See: http://lemmasoft.renai.us/forums/ucp.php?i=pm&mode=view&f=0&p=144880
See: http://lemmasoft.renai.us/forums/viewtopic.php?p=338394#p338394
2014-09-04 23:05:13 -04:00
Tom Rothamel 4034f87f26 Revert take_execution_state to the 6.17 version.
This is intended to fix problems caused by the changes outside of
screens.
2014-09-04 23:05:13 -04:00
Tom Rothamel 3ee319ba9e Merge pull request #443 from LuqueDaniel/update-es
Update spanish translation
2014-09-04 08:31:42 -05:00
Tom Rothamel 4c094852e8 Various doc fixes. 2014-09-03 18:36:44 -04:00
Daniel Luque a4aef8ceb1 Update spanish translation 2014-09-03 13:54:18 +02:00
Tom Rothamel 5794e8b3b7 Fix HideInterface documentation. 2014-09-02 22:59:30 -04:00
Tom Rothamel 3ab4f62cf8 Make renpy.file() work with the with statement. 2014-09-02 21:17:40 -04:00
kyouryuukunn 7f70d22344 Merge pull request #442 from kyouryuukunn/update_japanese_template
update japanese translation
2014-09-02 23:01:13 +09:00
kyouryuukunn 4a7ca192e9 update japanese translation 2014-09-02 22:59:57 +09:00
Tom Rothamel 74fce0049c Add the OnEvent displayable to run actions on events.
By being a displayable, OnEvent is able to invoke actions even when
a screen is not being updated. This is important in the new version
of Ren'Py, which tries to avoid screen updates as much as possible.
2014-09-01 21:27:19 -04:00
Tom Rothamel 22397c225f screen: Propagate hide events to children of the screen. 2014-09-01 21:24:52 -04:00
Tom Rothamel 8f80e828c7 Do not autosave when loading an autosave file.
Doing so will screw us up, because we'll change the autsave slots
right before we load.
2014-09-01 18:20:20 -04:00
Tom Rothamel c901b4c1bd drag: Improved response to changes in position
* More accurately check for changes in position.
* Allow a change in position to override a drag_group position.
2014-09-01 15:05:40 -04:00
Tom Rothamel 2f1455351d Update doc generation to use the new location of pyanalysis. 2014-09-01 09:43:08 -04:00
Tom Rothamel 83c7eef6c8 drag: Correctly detect placement changes.
When detecting placement changes, we want to use xpos/ypos, not
self.x/self.y.
2014-08-31 23:15:17 -04:00
Tom Rothamel f29ab675ec Call run_unhovered when a drag is unhovered. 2014-08-31 22:41:43 -04:00
Tom Rothamel d4e1a1d1f3 If the placement of a drag changes, move it to the new position.
This is probably the least bad thing we can do with a drag that
has changed its placement.
2014-08-31 22:09:06 -04:00
Tom Rothamel cede3f651d Fix call to super().__init__ in Drag constructor. 2014-08-31 19:34:19 -04:00
Tom Rothamel 4ed0c8e313 atl: Try to avoid recompiling constant ATL.
This should speed things up a little by avoiding the expensive
recompile step where possible.
2014-08-31 01:42:31 -04:00
Tom Rothamel ba4c6d8b10 Add a script analysis phase.
For now, all we do in this phase it analyze ATL for const-ness.
2014-08-31 00:05:29 -04:00
Tom Rothamel 87f2975dd0 Add the ability to analyze ATL for const-ness. 2014-08-31 00:04:12 -04:00
Tom Rothamel 15717d87af transform: default_xpos -> inherited_xpos, etc.
This is a field rename to better reflect what we use the fields for,
in the hope of making code slightly more reasonable.
2014-08-30 16:04:14 -04:00
Tom Rothamel 59174e44fb Rename renpy.sl2.pyutil to renpy.pyanalysis.
It more accurately reflects what the module does, and it may be useful
outside of sl2.
2014-08-30 15:57:01 -04:00
Tom Rothamel b6778f1a9e transform: Take state in the take_state method.
Previously, we had be transferring the position state in the
take_execution_state method.
2014-08-30 14:28:54 -04:00
Tom Rothamel e693038479 take_execution_state should properly inherit xpos. 2014-08-30 14:16:43 -04:00
Tom Rothamel f1cae21fdb sl2: Force a screen update on hide.
The multiple-update-prevention was stopping us from updating the
screen on hide like we want to.
2014-08-30 12:17:30 -04:00
Tom Rothamel 33e557c04f Check that the what argument to Character.__call__ is a string. 2014-08-29 21:50:26 -04:00
Tom Rothamel 32773f3832 Ensure coordinates of drags remain integers. 2014-08-28 22:07:06 -04:00
Tom Rothamel 32a6de49c9 Allow drags to exist outside a drag_group without a drag_name. 2014-08-28 22:01:49 -04:00
Tom Rothamel 64f6038b52 sl2: Do not always treat config and style as constants.
We have a case in the wild where someone used "style" as an argument
to a screen.
2014-08-28 17:50:53 -04:00
Tom Rothamel 813ef90eb2 Remove uses of type() in store.
While a reserved word, it's the sort of thing we didn't use much,
and that might be used a lot by end users. So we'll try to avoid
adding uses of type, prefering _type instead.
2014-08-28 17:08:21 -04:00
Tom Rothamel 3ef409b4f2 Suspend self-voicing when playing voice. 2014-08-27 23:24:09 -04:00
Tom Rothamel 34ad1df5b2 Properly compare ATL contexts. 2014-08-27 22:44:32 -04:00
Tom Rothamel 41afb8e5b2 Load .rpy if .rpyc fails with an exception.
If both files exist, we prefer to load the .rpy rather than a
corrupt or obsolete rpyc.

Fixes #437.
2014-08-27 21:37:23 -04:00
kyouryuukunn 15e0d57277 Merge pull request #439 from kyouryuukunn/update_japanese_template
fix japanese template
2014-08-27 18:01:26 +09:00
kyouryuukunn 04ce5eaf09 fix japanese template 2014-08-27 18:00:42 +09:00
kyouryuukunn 130d92c5a2 Merge pull request #438 from kyouryuukunn/update_japanese_template
update japanese template
2014-08-27 16:56:56 +09:00
kyouryuukunn 504f2ff708 update japanese template 2014-08-27 16:54:22 +09:00
Tom Rothamel 99f44f7eff Add the ability to parse a screen as sl1.
This is purely to make it possible to port sl1 games up to newer
Ren'Py, without rewriting them. This shouldn't be used in new games,
and may go away at some point.
2014-08-26 21:27:57 -04:00
Tom Rothamel 0a95f50724 Update a screen on hide before copying it.
When we copy a screen, we lose the cache - but we need the cache
to propagate the state of transforms (etc) to the children of the
screen.
2014-08-26 20:11:53 -04:00
Tom Rothamel 4da7ac8af7 Preserve nearest over subsurface operation. 2014-08-25 08:05:19 -04:00
Tom Rothamel b8c6a62c8f doc: Various minor improvements. 2014-08-24 17:51:37 -04:00
Tom Rothamel 8ecc3a200f doc: IAP. 2014-08-24 17:51:26 -04:00
Tom Rothamel c8d45d3715 iap: Add Purchase and Restore actions, get_store_name function. 2014-08-24 17:19:30 -04:00
Tom Rothamel 328e389f19 Compat old screen language location. 2014-08-24 16:33:40 -04:00
Tom Rothamel 53d9a60544 Update screens once before we lock them down for a hide.
This matches 6.17 behavior, and it makes sense that a hiding screen
should show the data as of the time it was hidden.
2014-08-23 22:33:24 -04:00
Tom Rothamel 7985a39a00 Do not take transition state when a parameter changes.
When a parameter to a transition changes, we have a different
transition, so taking the state doesn't work - it means we will
be representing the state of a different transition.
2014-08-23 22:28:07 -04:00
Tom Rothamel 60ce7ca8c9 Update musicroom Play selection status.
This makes the musicroom Play action compatible with sl2's reuse
of displayables.
2014-08-22 22:34:09 -04:00
Tom Rothamel e3ee421221 Introduce renpy.substitute.
This is a new public API corresponding to renpy.substitutions.substitute.
2014-08-21 21:36:42 -04:00
Tom Rothamel d373cf93e6 Add config.transition_screens for compatibility.
Setting this to False restores compatibility with old versions of
Ren'Py, where screens would always be updated, even on the old side
of a transition.
2014-08-20 19:02:02 -04:00
Tom Rothamel 2e3f6991a2 Add self-voicing to help.html.
Fixes #424.
2014-08-19 10:17:29 -05:00
Tom Rothamel e8d78b9deb doc: Add screen optimization to the index page. 2014-08-19 00:05:09 -05:00
Tom Rothamel ca4eb8857d doc: renpy.profile_screen. 2014-08-18 23:57:03 -05:00
Tom Rothamel 91cc4aa85a doc: Include const and pure vars, add link anchors. 2014-08-18 23:36:35 -05:00
Tom Rothamel 53328bf2a8 doc: Screen prediction. 2014-08-17 23:02:39 -05:00
Tom Rothamel 6d6cc7e6c0 Merge pull request #434 from ZeikJT/master
Fixing mistakes on the Language Basics doc page
2014-08-17 12:29:04 -05:00
kyouryuukunn 411028297e Merge pull request #435 from kyouryuukunn/update_japanese_template
update japanese template
2014-08-17 15:56:03 +09:00
kyouryuukunn 7186ccc22e update japanese template 2014-08-17 15:55:02 +09:00
Tom Rothamel 4b3b9dd3f1 doc: How const optimizes screen language, const text. 2014-08-16 10:18:29 -05:00
Tom Rothamel c619ee7ef2 Add the _developer_default style.
This is needed to enter the developer menu.
2014-08-15 23:23:20 -05:00
Matias Giachino 49df5bed9c Tuple - one-item tuple text incorrect
Says they must specify a parenthesis must follow one-item special cases. The truth is a comma must follow special cases
2014-08-15 19:18:31 -07:00
Matias Giachino b3e2801f38 True, False, None section - remove trailing text 2014-08-15 19:17:08 -07:00
Tom Rothamel fa2292a811 doc: Define const and pure. 2014-08-15 11:11:54 -05:00
Tom Rothamel 3da77b1ce7 doc: Start screen optimization. 2014-08-15 09:34:02 -05:00
Tom Rothamel b89e630e77 Store the location when defining screens.
This lets us link to the screen from the inspector.
2014-08-14 23:13:51 -05:00
Tom Rothamel 03701d8c39 inspector: Clicking on a location opens it in the editor. 2014-08-14 22:56:36 -05:00
Tom Rothamel c4d41109a6 Show displayable lines numbers in the style inspector.
For sl2 only.
2014-08-14 07:25:28 -04:00
Tom Rothamel 7ef976d637 sl2: child_or_fixed should consider actual children.
It was considering the number of available children, which was
improperly considering children in if statements and so on.
2014-08-13 22:01:27 -04:00
Tom Rothamel bdc7cf062e Merge pull request #433 from LuqueDaniel/update-es
Update es
2014-08-13 07:40:45 -04:00
Daniel Luque d562fdba93 To uppercase 2014-08-13 12:36:34 +02:00
Daniel Luque 66acf402ec Updated: spanish/front_page.rpy 2014-08-13 12:30:35 +02:00
Tom Rothamel b053705869 sl2: Use implicit_add to add displayables.
This prevents us from copying transforms that already have had
take_execution_state called. This fixes a regression that caused
copied transforms to reset, and hence the show event to be fired
multiple times.
2014-08-12 19:16:15 -04:00
Tom Rothamel 8c6060b2ba sl2: Ensure screen.widgets is updated on reuse. 2014-08-11 23:28:31 -04:00
Tom Rothamel 06f5ddffbf Make XScrollValue and YScrollValue use the current screen.
This lets them deal with cases where they are reused on a copied
or hiding screen.
2014-08-11 23:21:10 -04:00
Tom Rothamel 6b259960a1 Make _current_screen valid during per_interact() and render().
This let's us defer decisions about the current screen until
closer to render time.
2014-08-11 23:18:50 -04:00
Tom Rothamel 4555020fee When putting a screen into the old state, make a copy. 2014-08-11 23:03:08 -04:00
Tom Rothamel 87d3b65f4b Fix more PyDev 3.6.0 warnings. 2014-08-11 21:14:42 -04:00
Tom Rothamel 479eac2ebb Fix PyDev 3.6.0 errors. 2014-08-11 21:03:03 -04:00
Tom Rothamel 5f80db6880 Add a script that can compare zip sizes.
This lets us attribute changes in size to particular files.
2014-08-10 19:59:39 -04:00
Tom Rothamel d66a9f0bd7 Update docs. 2014-08-10 18:23:02 -04:00
Tom Rothamel be42df7e09 Add alt text to imagemap hotspots. 2014-08-10 09:55:35 -04:00
Tom Rothamel 05b1d38e8f Try harder to find a place to return to.
When the return site exists, we simply return to it. If the return
site disappears, we look up the call site, and return to the next
node, if one exists.

If we're in developer mode, we report an error at this
point. Otherwise, we pop the stack, and try again.
2014-08-09 10:43:23 -04:00
Tom Rothamel 6f377d8253 Fix some issues with edgescroll.
* It could start on timerevent, rather than a mouse event.
* It could get the wrong edge_last_st, leading to large jumps.
2014-08-08 23:11:36 -04:00
Tom Rothamel dd02654228 distribute-made copy of screens.rpy. 2014-08-08 21:07:39 -04:00
Tom Rothamel acc82e3030 tts: Only speak text after {fast}.
This deals with extend properly.
2014-08-08 19:37:04 -04:00
Tom Rothamel 84871c65c1 Call the dynamicdisplayable function iff it has no child.
Transform may need to get the placemet, which requires a
child exist.
2014-08-07 21:34:36 -04:00
Tom Rothamel a704363c54 Make emphasize audio into a preference. 2014-08-06 23:23:23 -04:00
Tom Rothamel 86609614b8 Update name. 2014-08-06 21:47:55 -04:00
Tom Rothamel ace45f4ef0 Apply style group to detached widgets.
This seems to make sense, and fixes the sl2viewport function.
2014-08-06 21:28:44 -04:00
Tom Rothamel 2f114e59df Revert tutorial. 2014-08-05 23:35:30 -04:00
Tom Rothamel 43bed3a92b Revert options.rpy in testcases. 2014-08-05 23:26:28 -04:00
Tom Rothamel 4b3c5ecbbc sl2: Document changes. 2014-08-05 23:20:44 -04:00
Tom Rothamel d34ec5d0fd Include glib-2.0 for versions of fribidi that need it.
Fixes #303.
2014-08-04 21:20:02 -04:00
Tom Rothamel b45d9f957b Update changelog. 2014-08-04 01:01:31 -04:00
Tom Rothamel 001a5f747c voice: Deal more sensibly with the character volume being 0.
We now treat this as a mute, and do not play the voice file. This
prevents us from emphasizing voice when the user has disabled the
voice of a particular character.
2014-08-04 00:56:38 -04:00
Tom Rothamel 1d3e8e1ad7 Add the ability to emphasize certain audio channels.
When an emphasized channel is playing, all non-emphasized channels
have their volume lowered. When emphasis ends, the non-emphasized
channels resume their normal volume.

This is a generalization of (and replacement for) #360.
2014-08-04 00:40:27 -04:00
Tom Rothamel 2453eb2cbe Make reduce_volume_in_voice opt-in by creators.
This will break existing games, by changing the volumes in a way
creators will not expect. Let's make this opt in across the board.

Removed it from the various templates since voice stuff is pretty
rarely used, and shouldn't required attention from a new user.
2014-08-03 23:28:38 -04:00
Tom Rothamel 4024f4f6bd Revert "Move voice config to 00voice.rpy."
This reverts commit e612e2a168822e1e0804b825953808fefb83df7d.
2014-08-03 23:28:38 -04:00
Tom Rothamel dbefae5855 Initial run at updating the changelog. 2014-08-03 23:28:38 -04:00
Tom Rothamel a147e41609 Move voice config to 00voice.rpy.
In general, config variables that only touch common/ should only
exist in common/.
2014-08-03 23:28:38 -04:00
Tom Rothamel 724f9d91aa sl2: Fix regression reusing displayables. 2014-08-02 14:35:31 -04:00
Tom Rothamel 8f9f42352b Allow the launcher to scan/launch mac app packages.
This makes it possible to run an older mac app package with a newer
Ren'Py - to get self-voicing, for example.
2014-08-02 00:06:27 -04:00
Tom Rothamel 463d9cde79 sl2: Only reuse non-None displayables. 2014-08-01 23:53:31 -04:00
Tom Rothamel 92cae431f2 Add "Force Recompile" to the launcher.
This will be useful for people upgrading from pre-sl2 to sl2 versions
of Ren'Py, as it makes it possible to be sure all screens are using
sl2.
2014-08-01 15:47:11 -04:00
Tom Rothamel 1f93fbfd0b Use the focus system to retain grab between interactions.
With the new screen system, it's now possible to reuse the same
displayable between two interactions. Such displayables need to
retain grab until they go away, or grab is explicitly released.

This fixes a problem where a constant bar would lose focus after being
adjusted in a way that restarts the interaction, as volume sliders do.
2014-07-31 23:05:39 -04:00
Tom Rothamel f8094c21b1 Invalidate drags on child change. 2014-07-30 23:18:58 -04:00
Tom Rothamel 833cf20f56 Mark drags as focusable. 2014-07-30 23:18:43 -04:00
Tom Rothamel 581d30debb sl2: Properly get old_main. 2014-07-30 23:18:15 -04:00
Tom Rothamel 71d771d172 Store the new position in the drag_group on drag snap.
Fixes the first part of #396.
2014-07-30 22:42:37 -04:00
Tom Rothamel d6745e7492 Remove syntax error. 2014-07-30 11:08:24 -04:00
Tom Rothamel 8a66bab786 Handle android mouse release move in Ren'Py.
Previously, we were handling this in SDL. However, this conflicted
with the MOUSEMOTION merging - the other event could be moved before
the mouse release, leading to unsightly jumps, and (perhaps) the
viewport being in the wrong place.

We now synthesize the mouse release move in Ren'Py, which lets us
control the order in which it occurs.

Fixes #391.
2014-07-29 23:28:46 -04:00
Tom Rothamel 20be450e1a Mouse focus only on mouse events.
We had been using the mouse to determine focus at the start of
each interaction. We now only use the mouse to determine focus
if the last event - the event that ended the interaction - was
a mouse event.

Fixes #299.
2014-07-28 23:53:12 -04:00
Tom Rothamel 4277d2b049 Merge pull request #324 from duanemoody/master
Add application category for OS X
2014-07-28 23:26:46 -04:00
Tom Rothamel 8ddf658543 Use an adv-mode narrator for adv-mode _default_empty_window.
Fixes #330, using kyouryuukunn's second approach.
2014-07-28 23:23:34 -04:00
Tom Rothamel 3d3f437f57 Add config.autosave_on_choice.
This variable determines if Ren'Py autosaves at menus.
2014-07-28 23:04:29 -04:00
Tom Rothamel 99330bb1eb Do not save ScreenDisplayable.children.
This is recreated on load, and saving it just leads to slower save and
load times.
2014-07-28 22:57:09 -04:00
Tom Rothamel eff11fec79 sl2: Properly finish and imagemaps.
Previously, we were failing to finish the imagemaps we created, which
both leaked the md5 object and generally hurt performance.
2014-07-28 22:55:56 -04:00
Tom Rothamel af0784af3b Perform save dumps before we pickle things.
This makes config.save_dump a powerful tool for debugging pickle
problems, where previously it was only useful for finding out the size
of save files.
2014-07-28 22:54:24 -04:00
Tom Rothamel 4607b2db38 sl2: Improve prediction of screens.
This includes:

* When predicting, we do not stop on the first exception. Instead, we
  keep going, trying to predict what we can.

* This includes screen parameters and arguments as well.

* If we can't evaluate the list part of a for loop, we use [ 0 ] - in
  conjunction with the error handling, this should get us
  something. In many cases, it gets us everything important.

* Once per if statement, we predict all branches.
2014-07-27 22:53:32 -04:00
Tom Rothamel acbaa4c9ba _hide hides the hiding screen, not the not-hiding screen.
This fixes a regression that caused screens without hide transforms to
immediately become empty, even when they should have been used in an
old transition.
2014-07-27 15:00:15 -04:00
Tom Rothamel b9d4a6f6f5 If a Fixed with a layer_name does not have a scene list, do not copy it. 2014-07-26 22:34:17 -04:00
Tom Rothamel d82ff5c7d6 sl2: Track which SLNodes can have keywords.
There are certain nodes that can't have keywords, like if nodes that
occur after a python statement that defines a variable used by the if
statement.

This change ensures that we only execute the keywords() method if:

* Some keywords are present.
* Nothing precludes the keywords method from running.
2014-07-26 22:17:56 -04:00
Tom Rothamel 569f6c0f95 Add portuguese translation by mrstalker. 2014-07-26 11:15:56 -04:00
Tom Rothamel 1a5f693ccd sl2: Pop the open viewport from the ui stack. 2014-07-25 23:02:09 -04:00
Tom Rothamel 92ed019e6c sl2: Fix sl2viewport.
We now properly get the outer and inner elements for all sl2viewports.
2014-07-24 23:08:21 -04:00
Tom Rothamel ebbca682f7 Make autosave_on_quit apply to autosave on load. 2014-07-24 10:39:07 -04:00
Tom Rothamel 33f2c0670d Merge pull request #338 from kyouryuukunn/autosave_before_load
autosave before load
2014-07-23 23:02:58 -04:00
Tom Rothamel 7f85657c0a Add config.autosave_on_quit.
This variable lets us control if Ren'Py autosaves when entering the
quit or main menu prompts.
2014-07-23 21:01:35 -04:00
Tom Rothamel c24b99a0a6 Do not convert the screenshot to the screen's format.
The screen's format may not be the for RGBA format we expect surfaces
to be in when we load them into textures. This would cause
FileCurrentScreenshot to break.

Fixes #314.
2014-07-21 23:27:23 -04:00
Tom Rothamel c2a2572aec Reduce over-passing of show arguments to nvl screen.
We would pass say_vbox_properties, which is only used in pre-screens
code. When iterating through a say_list containing multiple
lines of text, we could use say_args from a previous line.
2014-07-20 23:16:31 -04:00
kyouryuukunn dd5796a59d Merge pull request #419 from kyouryuukunn/update_japanese_template
update japanese template
2014-07-21 11:57:49 +09:00
kyouryuukunn 280ef1c396 update japanese template 2014-07-21 11:56:58 +09:00
Tom Rothamel a2a48e4603 Merge pull request #358 from kyouryuukunn/pass_show_args
NVLCharacter now passes show_ arguments to the nvl screen.
2014-07-20 21:49:07 -04:00
Tom Rothamel 52413479a6 Merge pull request #354 from kyouryuukunn/character_volume
Make voice volume adjustable on a per-character basis.
2014-07-20 21:38:57 -04:00
Tom Rothamel 919bbbca87 Merge pull request #388 from renoa/patch-2
Update Arabic template translation.
2014-07-20 21:36:27 -04:00
Tom Rothamel 9c8a4e17f3 Track mouse and keyboard focuse separately. Make joy depend on key.
This more accurately models how one would expect the joystick to work
on Linux.

Fixes #402.
2014-07-20 21:34:27 -04:00
Tom Rothamel cb359e8a45 When a default_focus appears, if nothing is focused, focus it.
This fixes #417, an issue that was causing problems when the default
focuse only appeared at the end of a transition.
2014-07-20 19:23:30 -04:00
Tom Rothamel 20bfd1298f Update android packaging doc to represent the latest approach. 2014-07-19 21:28:05 -04:00
Tom Rothamel 108ca1f981 Launcher language selection improvements.
* Sort alphabetically.
* Turn "_" into " ".
* Add scrollbar.
2014-07-19 21:03:30 -04:00
Tom Rothamel 8573bb76f9 Merge pull request #404 from LuqueDaniel/update-es
Update es
2014-07-19 20:30:19 -04:00
Tom Rothamel 1176d159af Use name_only when extending a string-named character.
Fixes #408.
2014-07-19 20:25:16 -04:00
Tom Rothamel f554e19a1a Move the code for accessing a character into its own function.
This will make it easier to change in the future.
2014-07-19 20:24:55 -04:00
Tom Rothamel be17f9cc6b Nearest neighbor filtering.
This takes the form of the "nearest" transform property. When the
transform property is true, blits use nearest-neighbor filtering.
2014-07-19 00:05:56 -04:00
Tom Rothamel bdf788b5eb Add config.adjust_view_size.
This is optionally a function that returns the size of the OpenGL
viewport in which Ren'Py draws the game. Having this a callback makes
it possible to constrain the sizes of the game window.

For example, this makes it possible to limit the viewport to integer
multiples of the starting window size, as requested in #406.
2014-07-18 23:25:33 -04:00
Tom Rothamel 27cd90d6db Merge pull request #409 from kyouryuukunn/fix_doc
fix doc
2014-07-18 21:24:03 -04:00
Tom Rothamel 60b8ee46a1 Add renpy.count_{,seen_}_dialogue_blocks().
These are functions to count the number of dialogue blocks and the
number of seen dialogue blocks in the game. This makes it possible
to give an indication of how much of the game text the player has
seen.
2014-07-18 00:07:08 -04:00
Tom Rothamel 7e533fbb8f Fix regression in the handling of insensitive buttons.
The focusable field was not being set correctly, which made the button
participate in the focus mechanism and get the idle background when
it should have been insensitive.
2014-07-17 22:57:51 -04:00
Tom Rothamel 329ff9fc5c Clean up last merge a bit. 2014-07-16 22:02:44 -04:00
Tom Rothamel 980104b35e Merge pull request #377 from HikkeKun/master
Small fix for newline_indent behavior.
2014-07-16 21:48:50 -04:00
Tom Rothamel e51000c947 Fix name conflict in android code. 2014-07-16 21:46:06 -04:00
Tom Rothamel ef69a69a3f Limit when we supply the image parameter to the say screen.
It's normally only used for compatability with older games, and
isn't documented, nor is is present in the say screen.
2014-07-16 21:17:32 -04:00
Tom Rothamel c4880e33f3 Add parameter lists to screens in documentation and screens.rpy.
This is to make everything conform to the new best practices.
2014-07-16 21:09:55 -04:00
Tom Rothamel 00d3da2040 Fix two bugs in lint.
Fixes #415, in which show would check all attributes, when partial
would do.

Fixes #416, in which lint would check disabled old_substitutions.
2014-07-15 23:34:16 -04:00
Tom Rothamel 895350ed4d Limit scope of used screens with parameters.
Used screens that take parameters now run isolated from their parent
context. This lets us treat global const variables as constant,
without having to worry about the parent scope redefining them.
2014-07-15 22:53:25 -04:00
Tom Rothamel f97b59c414 sl2: Take args and kwargs into account when finding a screen to reuse. 2014-07-14 23:36:28 -04:00
Tom Rothamel 62e85b728c sl2: Do not treat screen parameters as constant.
Our definition of constant includes field access, indexing, etc. Since
a screens parameter might be mutable (a list, for example), we can't
treat it as const in the general case.
2014-07-14 23:34:08 -04:00
Tom Rothamel ead4e44d80 sl2: Give constants to parameterized screens.
We can analyze parameterized screens more thoroughly than
non-parameterized screens, since the parameters limit what can
be overridden in the screens' scope.
2014-07-13 19:56:14 -04:00
Tom Rothamel 0b5a54f0f8 Deal with problems that occur when we have no glyphs in a line. 2014-07-13 17:03:50 -04:00
Tom Rothamel 626981c349 Do not call the DynamicDisplayable function on per_interact.
It's not necessary, and can cause problems since st and at are not
correct.
2014-07-13 16:13:31 -04:00
Tom Rothamel bed9699983 sl2: Only treat a function as pure if it's also const.
This lets us redefine a const function and get away with it.
2014-07-13 01:10:01 -04:00
Tom Rothamel dc97bdb194 sl2: Extend local/global const analysis to slast.
This brings us to the point where we can run the launcher using
the local/global const analysis.
2014-07-13 00:17:15 -04:00
Tom Rothamel f6df843499 sl2: More work to distingush local const from global const. 2014-07-12 21:07:48 -04:00
Tom Rothamel 46ba33dde1 iap: Add missing import. 2014-07-11 23:59:35 -04:00
Tom Rothamel 1a969be8fd iap: Separate product names and identifiers.
Each product has a name, used to identify it. This name may be
different from the names used in the various app stores, which can be
specified independently.
2014-07-11 23:42:22 -04:00
Tom Rothamel c8de62c682 iap: Bugfixes. 2014-07-11 23:29:55 -04:00
Tom Rothamel 4197f10d18 Fix link to keytool. 2014-07-11 08:54:35 -04:00
Tom Rothamel c403d13119 iap: Start work on high-level IAP framework.
This code runs, but hasn't been tested yet.
2014-07-10 23:50:37 -04:00
Tom Rothamel 9b4ec3206c Merge pull request #413 from kyouryuukunn/gallery_nav
enable customizing the look of gallery navigation
2014-07-09 20:35:54 -04:00
kyouryuukunn 61da5d93ec rename gallery_nav to gallery_gavigation 2014-07-10 08:17:20 +09:00
kyouryuukunn 1486932b49 enable customizing the look of gallery navigation 2014-07-10 08:08:53 +09:00
Tom Rothamel 4e5199b6a1 Add gallery testcase. 2014-07-08 18:18:38 -04:00
Tom Rothamel 2e8494a2c8 Re-prepare screens when rebuilding styles. 2014-07-08 18:18:12 -04:00
Tom Rothamel f753db5862 sl2: Introduce three levels of const-ness.
This lets us distinguish compile-time constants from expressions
that are const within a single screen.
2014-07-08 18:11:37 -04:00
kyouryuukunn 18d4039aa1 Merge pull request #411 from kyouryuukunn/update_japanese
update japanese
2014-07-08 19:32:12 +09:00
kyouryuukunn 1125cc4b32 update japanese 2014-07-08 19:29:39 +09:00
Tom Rothamel 137e71c461 Fix comparison of gallery actions. 2014-07-07 23:10:29 -04:00
Tom Rothamel 027099daad Deal with the first image in gallery button being locked.
Fixes #410, and adds a test case for the gallery.
2014-07-07 23:08:50 -04:00
Tom Rothamel c6472da521 Update changelog.
Conflicts:
	sphinx/source/changelog.rst
2014-07-06 18:01:42 -04:00
Tom Rothamel aedd0273a4 Ignore .rpyc files that cannot be loaded.
This makes it possible to version down if the .rpy file exists and
do not use any newer features.
2014-07-06 17:56:29 -04:00
Tom Rothamel 6872f3db62 Revert parameterization of launcher screens.
We want to be able to pass in arbitrary arguments, so we can sub
them into text.
2014-07-06 00:24:27 -04:00
kyouryuukunn 8311fafeb4 fix doc 2014-07-06 12:25:12 +09:00
Tom Rothamel 7cba90c0d0 Add the selected parameter to the common screen. 2014-07-05 21:31:36 -04:00
Tom Rothamel 36c9df4353 Distribute the project given to android_build.
This fixes a bug where we would distribute the current project
instead of the one supplied on the command line, causing things
not to work.
2014-07-05 20:26:07 -04:00
Tom Rothamel 4705aa2b6f sl2: Fix fixed.
The SL fixed statement was calling renpy.display.layout.Fixed with
the layout parameter. Since Fixed also supplied a layout parameter
we'd get a crash.
2014-07-05 10:19:06 -04:00
Tom Rothamel 5ae2ae3075 Remove constant offsets from video timestamps.
We had previously been assuming the audio started at 0, while
respecting the video PTS. If the PTS of the first video frame was
non-zero, this would lead to the video being delayed behind the audio
and never catching up.

Fixes #386.
2014-07-04 21:16:01 -04:00
Tom Rothamel b45998fdec sl2: Fix FieldValue equality. 2014-07-03 19:15:36 -04:00
Tom Rothamel 4c273f6a3b sl2: Fix analysis of Python if statements. 2014-07-03 19:15:19 -04:00
Tom Rothamel 0098a41633 sl2: Version the screen language cache.
This ensures that when we prepare screens - such as after a language
change - the cache is dropped. If we don't do this, sl2 can use old
values for displayable arguments and const displayables.
2014-07-02 22:03:20 -04:00
Daniel Luque 20b80bb706 project to lowercase 2014-07-02 12:08:28 +02:00
Daniel Luque 3327378d4f Updated spanish/preferences.rpy 2014-07-02 12:03:19 +02:00
Daniel Luque 7cc4820e96 Updated spanish/front_page.rpy 2014-07-02 11:59:40 +02:00
Tom Rothamel 725ba33062 Merge pull request #403 from kyouryuukunn/fix_MusicRoom
Fix selected status in musicroom.
2014-07-01 23:31:31 -04:00
Tom Rothamel f85b13642b Merge pull request #325 from kyouryuukunn/list_of_action
If a list of Actions contains SensitiveIf or SelectedIf, those take precedence over other actions.

This also introduces the new SensitiveIf action.
2014-07-01 22:44:07 -04:00
Tom Rothamel 95dd481b3a Rename Chinese_Simplified -> simplified_chinese.
This makes the naming similar to the other languages we support.
2014-07-01 22:36:52 -04:00
Tom Rothamel 479a13f5fc Remove text from Chinese translation, per:
https://github.com/renpy/renpy/pull/365#issuecomment-44358481
2014-07-01 22:33:01 -04:00
Tom Rothamel 1fb9fe7bb8 Remove TODOs from simpified chinese translation. 2014-07-01 22:32:29 -04:00
kyouryuukunn 3daae9b0f0 add SetCharacterVolume 2014-07-02 11:28:41 +09:00
Tom Rothamel 4fa044fbc0 Remove +x bit from Chinese translation. 2014-07-01 22:22:05 -04:00
Tom Rothamel 2c676c2fc2 Fix license on DroidSansFallback.ttf.
According to

    https://github.com/android/platform_frameworks_base/tree/master/data/fonts ,

the Droid fonts are under the Apache license.
2014-07-01 22:21:07 -04:00
Tom Rothamel d0ad2d924f Merge pull request #365 from huanxuantian/system-translations-chinese
Chinese (Simplified) translation of launcher.
2014-07-01 22:17:57 -04:00
Tom Rothamel 02a1447837 The voice system should ignore interactions caused by window
show/hide/auto.

Based on a pull request by kyouryuukunn.
2014-07-01 22:03:45 -04:00
Tom Rothamel 2422e2c477 Merge pull request #360 from kyouryuukunn/reduce_volume_in_voice
reduce bgm volume during voice playing
2014-07-01 21:49:35 -04:00
Tom Rothamel 2ae0592486 Merge pull request #397 from renpy/template-replace-symlink
Copy target files of symbolic links
2014-07-01 21:47:26 -04:00
Tom Rothamel 56fc7f8603 Report autoreload as part of the window title. 2014-07-01 21:32:59 -04:00
Tom Rothamel dbe1ccc29e Merge pull request #383 from kyouryuukunn/fix_doc
fix doc
2014-06-30 22:30:15 -04:00
Tom Rothamel 02e2916a82 Merge pull request #401 from renpy/my-tts
config.tts_function to support user defined TTS processor
2014-06-30 22:25:09 -04:00
Tom Rothamel 2e6a836e2d Mark less names as const.
Do not mark transforms that aren't intended for use in screens - but
may have names that would be common for screen parameters - as const.

This should improve compatibility with older screens.
2014-06-30 22:22:41 -04:00
Tom Rothamel 5f671d9990 Ignore profile_screen.txt when distributing. 2014-06-30 21:50:58 -04:00
Tom Rothamel 4286cdca0e Make the parameters to the default screens.rpy to be explicit. 2014-06-30 21:49:22 -04:00
Tom Rothamel 6793a176e0 Launcher screens take an explicit parameter list.
This fixes a problem where sl2 was considering the "default"
parameter const.
2014-06-30 21:47:07 -04:00
Tom Rothamel 4f790bdc11 Properly mark parameters as non-const. 2014-06-30 21:46:45 -04:00
Koichi Akabe cc841c5f52 Move the process managiment into default_tts_function 2014-07-01 02:06:08 +09:00
Koichi Akabe 53d3039ee8 Add tts_function config to support user defined TTS function 2014-06-30 23:58:13 +09:00
Tom Rothamel f2d69c078e Ignore tmp/ directory when navigating .rpy files. 2014-06-30 00:13:07 -04:00
Tom Rothamel ce76ab25f6 Include Ren'Py with android distributions.
RAPT will now use this version of Ren'Py, which can include patches
by the creator.

Fixes #368.
2014-06-30 00:03:57 -04:00
Tom Rothamel a8c0cc096c Add some self-voicing support to the launcher. 2014-06-28 21:55:26 -04:00
Tom Rothamel 60a6f6adfc Add a large-fonts mode to the launcher.
Fixes #399.
2014-06-28 21:43:17 -04:00
Tom Rothamel c471e3ff26 Generate lists of const and pure variables. 2014-06-28 21:12:07 -04:00
Tom Rothamel 249ebb8b0c sl2: Flag more things pure. 2014-06-28 17:19:43 -04:00
Tom Rothamel 24de1990ce Fix typo. 2014-06-28 17:18:41 -04:00
Tom Rothamel 8cac7510ee Invalidate, rather than redraw, on Transform.set_child.
This prevents a redraw from unconditionally occuring when the
child is changed - we only want the change to occur if we're
not already in a redraw.
2014-06-28 00:10:01 -04:00
Tom Rothamel fae51e39bd sl2: Make sl2 the default screen language. 2014-06-27 23:07:31 -04:00
Tom Rothamel 4c94285195 sl2: Analyze screen parameters. 2014-06-27 22:58:44 -04:00
Tom Rothamel 0a6797340f sl2: Let the user dump the results of const analysis. 2014-06-27 18:15:03 -04:00
Tom Rothamel e3f2c70144 sl2: Make defines and transforms pure.
They should be, and this should help make more things const.
2014-06-27 17:42:48 -04:00
Tom Rothamel 6c97478a81 sl2: Flag renpy.<name> as pure functions, when appropriate. 2014-06-27 09:44:37 -04:00
Tom Rothamel 738321cc4e sl2: Pure functions should also be constants. 2014-06-27 09:23:22 -04:00
Koichi Akabe 2990efac7a Copy target files of symbolic links 2014-06-27 21:48:16 +09:00
Tom Rothamel 31419d103b sl2: Perform const/not-const analysis on Python code. 2014-06-26 22:50:19 -04:00
Tom Rothamel 57b6d6124b Keep the source of PyCode objects around.
We're no longer as memory-limited as we once were, and this makes
the source available for code analysis, when necessary.
2014-06-26 22:49:17 -04:00
Tom Rothamel a01f3b8432 sl2: Analyze sl2 statements (not including python). 2014-06-25 17:29:48 -04:00
Tom Rothamel 76477f103e sl2: Frameworks for fixed-point analysis.
This doesn't do anything yet, but provides the structure for constant
analysis.
2014-06-24 22:07:48 -04:00
Tom Rothamel 394c19b9c2 sl2: Encapsulate code analysis into a single object.
This is in preparation for analyzing const/non-const inside a screen.
2014-06-23 22:19:04 -04:00
kyouryuukunn c159dcce30 pass show_args to 'nvl' screen 2014-06-23 23:22:55 +09:00
Tom Rothamel 50d8f356e2 sl2: Fix debug. 2014-06-22 23:38:17 -04:00
Tom Rothamel 366257119b sl2: Screen profiling debugging.
This entails writing information about the decisions we make when
creating the displayables comprising the screen.
2014-06-22 23:32:41 -04:00
Tom Rothamel 64159e840b Basic framework for profiling screen execution. 2014-06-22 22:02:32 -04:00
Tom Rothamel 680131beb3 Simplify ScreenDisplayable._hide and make it work with sl2. 2014-06-21 10:57:31 -04:00
Tom Rothamel 857a5a06b5 sl2: Migrate grab. 2014-06-20 23:03:33 -04:00
Tom Rothamel 4dab5e849b Allow RevertableDict to be past as the properties argument to Style.
Fixes #323.
2014-06-19 21:45:45 -04:00
Tom Rothamel 925cd35947 Merge pull request #384 from kyouryuukunn/Function
Add Function action, which calls a function with arguments.
2014-06-19 21:14:24 -04:00
Tom Rothamel 17b77dcce2 Remove spurious code. 2014-06-19 08:40:02 -04:00
Tom Rothamel 96260b4ec8 sl2: Pass default keyword arguments to the displayable.
This is required so we can pass the layout argument to MultiBox,
which makes the distiniction between fixed, horizontal, and vertical
layouts when the style does not.
2014-06-18 23:08:17 -04:00
Tom Rothamel 16d361c714 Document self-voicing, generate doc includes. 2014-06-18 20:23:42 -04:00
Tom Rothamel 738f93b156 tts: Speak bar text immediately. 2014-06-18 00:19:02 -04:00
Tom Rothamel 23b03ea790 tts: Allow the user to unfocus all widgets.
This will read out the default text.
2014-06-17 23:45:20 -04:00
Tom Rothamel 6a27c02a9b tts: Add a new linear focus ordering.
This allows one to navigate through all of the displayables on the
screen with the cursor keys, without having to do 2-d navigation,
which is what Ren'Py does by default.
2014-06-17 23:35:14 -04:00
Tom Rothamel d1f6132637 tts: Add self-voicing text to file actions. 2014-06-17 20:29:01 -04:00
Tom Rothamel c612db1551 tts: Read non-prefs labels.
We want to read yesno_label, for example.
2014-06-17 20:28:56 -04:00
kyouryuukunn d5e8e70d7c fix 2014-06-17 12:58:57 +09:00
kyouryuukunn 724cae119b update 2014-06-17 12:56:07 +09:00
Tom Rothamel 845d318a44 tts: Make nvl-mode compatible with tts.
This involves using alt to disable speaking of already-spoken text.
2014-06-16 21:36:14 -04:00
Tom Rothamel 28ec3f2326 Directly invoke platform-specific TTS commands.
Pyttsx would try to invoke TTS from the python process, which
required a ton of dependencies. (Pyobjc and win32api) We now
use subprocess to run platform-specific executables, passing
the text to speak on the commands line.
2014-06-16 21:31:34 -04:00
Tom Rothamel f7e763f8a8 tts: Make self voicing a preference. 2014-06-15 22:52:03 -04:00
Tom Rothamel 8e5c2a1532 tts: Make the alt property available in sl1 and sl2. 2014-06-15 20:18:00 -04:00
Tom Rothamel 077ae1b609 tts: Self-voicing improvements.
* Generate alt text only when voice is enabled.
* Allow the text of the children to be interpolated into alt text.
* Alt text for the preferences screen.
2014-06-15 15:56:18 -04:00
Tom Rothamel 179301421c tts: Initial implementation of self-voicing. 2014-06-15 13:23:46 -04:00
Tom Rothamel 88439529e4 Merge pull request #361 from oshi-shinobu/renpy-it
Added Italian translations for launcher and template
2014-06-15 11:34:11 -04:00
Tom Rothamel 74b7cbe06c Make SL2 screens copy displayables during transitions.
This required several fixes, including making sure copy_on_change works
and copying constant displayables if a change to the scope causes a Text
to change its contents.
2014-06-14 22:38:29 -04:00
Tom Rothamel 4d8144d320 Fixes to make transitions and screens work together.
This currently only works for sl1 screens, as sl2 screens are
over-agressively reusing displayables.
2014-06-14 20:56:04 -04:00
Tom Rothamel 251cfacb22 Implement ScreenDisplayable._in_old_scene(). 2014-06-13 18:22:57 -04:00
Tom Rothamel b9a47a2bb8 Merge pull request #389 from renpy/fix-doc-vbk
Fix typos in the documentation
2014-06-13 13:08:10 -04:00
Koichi Akabe 9a06636789 Fix many typos in the documentation
Following documents are checked:
* skins
* sprites
* statement_equivalents
* store_variables
* style
* style_properties
* text
* thequestion
* thequestion_nvl
* trans_trans_python
* transforms
* transitions
* translation
* udd
* updater
* voice
2014-06-14 01:43:21 +09:00
Koichi Akabe 413c2dee85 Fix many typos in the documentation
Following documents are checked:
* label
* language_basics
* license
* menus
* modes
* movie
* nvl_mode
* other
* persistent
* problems
* python
* quickstart
* reserved
* rooms
* save_load_rollback
* screen_actions
* screen_python
* screen_special
* screens
* side_image
2014-06-14 01:21:12 +09:00
Koichi Akabe a7000ffb14 Fix many typos in the documentation
Following documents are checked:
* developer_tools
* dialogue
* display_problems
* displayables
* displaying_images
* distributor
* drag_drop
* editor
* environment_variables
* file_python
* incompatible
* index
* input
* keymap
2014-06-14 00:41:47 +09:00
Koichi Akabe 76b7b471a4 Fix many typos in the documentation
Following documents are checked:
* android
* android-packaging
* atl
* audio
* build
* cds
* changelog
* character_callbacks
* conditional
* config
2014-06-14 00:11:50 +09:00
Renoa 97000fd87a Update screens.rpy
fixed the path where Ren'Py had the wrong path for the arabic font AdvertisingBold.ttf which created an error message while trying to access "Options" from the inside the game.
2014-06-13 16:27:19 +03:00
Tom Rothamel f639a201a6 Add ui.implicit_add for internal use.
This is a function that takes displayables that are being implicitly
added to a widget by ChildOrFixed. We do not want to copy transforms
added this way, which we had been doing, causing problems.
2014-06-13 00:35:17 -04:00
Tom Rothamel b63be138d5 Mark buttons with an action (but not clicked) as Focusable.
This lets Ren'Py transfer focus to them at the start of an interaction,
preventing hovered actions from being called repeatedly.
2014-06-12 23:30:44 -04:00
Tom Rothamel 55a45c54be Further optimization. 2014-06-12 12:27:36 -04:00
Tom Rothamel 2fc9c3d4c0 Optimize MultiBox._in_old_scene.
We now only use the newly-created boxes if at least one displayable
has changed. Otherwise, we don't bother, preferring to use the old
box (which likely has been cached).
2014-06-12 01:00:30 -04:00
Tom Rothamel ef9cffdbf6 Implement MultiBox._in_old_scene(). 2014-06-12 00:41:14 -04:00
Tom Rothamel c3a87909ce Add Displayable._in_old_scene().
This is a method that can copy layers and screens when they're being
used as the old_widget in a transition.
2014-06-11 18:37:34 -04:00
Koichi Akabe 3d553e31f0 Fix typo in doc: translatoon -> translation 2014-06-11 17:42:32 +09:00
Tom Rothamel fa1d3b7e21 sl2: Implement copy_on_change functionality.
This will copy displayables when their children change, which will
eventually let us use transitions to show changes in screen state.
2014-06-10 17:52:36 -04:00
Tom Rothamel e6dc0aa644 Merge pull request #385 from LuqueDaniel/update-es
Update-es
2014-06-09 08:29:05 -04:00
Daniel Luque 0994579c2a Added new string 2014-06-09 12:29:27 +02:00
kyouryuukunn 45e1854786 add Function Action 2014-06-09 17:54:50 +09:00
kyouryuukunn 7897a9c369 fix doc 2014-06-09 17:26:45 +09:00
Tom Rothamel 7fa4517439 sl2: Only pass scope to a displayable it it uses the scope. 2014-06-08 10:37:37 -04:00
Tom Rothamel 8a69b0c03f play sound / queue sound should respect loop parameters.
Fixes #378.
2014-06-07 21:02:58 -07:00
Tom Rothamel 0a3ca8bc3a Prompt the user to back up their project.
Brought to you by citizens against data loss.
2014-06-07 21:24:35 -04:00
Tom Rothamel ab4951d08c Window show None should not use config.window_show_transition.
And similary for window hide None and config.window_hide_transition.

Fixes #381.
2014-06-06 21:53:28 -07:00
Tom Rothamel c7de8a8b50 Merge pull request #379 from kyouryuukunn/fix_doc
fix doc about LiveComposite
2014-06-06 23:08:42 -04:00
Tom Rothamel 635ccdf130 Add the uses_scope property to Text.
This tells us if we need to update the text when the scope changes.
2014-06-05 23:21:10 -04:00
kyouryuukunn 246888c794 fix doc about MoveTransition 2014-06-05 16:50:31 +09:00
Tom Rothamel 845d78df2e Properly encode unicode strings in exceptions.
Previously, if a non-ascii unicode string was in an exception,
we'd fail to encode the exception and crash.
2014-06-05 00:28:28 -04:00
Nobody Really a325ffff22 Fixed very minor typos 2014-06-04 15:50:46 +02:00
kyouryuukunn 6372563998 fix doc about LiveComposite 2014-06-04 21:16:36 +09:00
Nobody Really 91c46649e1 Removed TODO and duplicates, added README.html 2014-06-04 00:07:52 +02:00
Helloise 5f920b5b0a Small fix for newline_indent behavior.
Now should work as described in documentation ( http://www.renpy.org/doc/html/style_properties.html#style-property-newline_indent )
2014-06-03 22:39:00 +04:00
Tom Rothamel 689d3acc63 Use list_logical_lines to scan for translations.
This will properly handle comments, and so fixes #363.
2014-06-03 08:42:12 -04:00
Tom Rothamel 6fe2f8afa2 Fix queuing of unicode filenames.
Fixes #369, again.
2014-06-02 22:33:46 -04:00
Tom Rothamel 776ea299c3 Properly format style names for lint.
Fixes #367.
2014-06-02 18:16:15 -04:00
Nobody Really 1580502949 Fixed screens.rpy 2014-06-02 20:27:33 +02:00
Tom Rothamel c092d687d7 Transform: Fix and optimize argument parsing.
Transform had a problem parsing arguments with underscores in the
name, like transform_anchor. That's been fixed.

Transform also did a lot of allocation for rare cases, such a
Transform being given an argument with a style prefix,
like hover_xpos. This has been optimized in order to reduce
the amount of allocation required.
2014-06-01 23:42:30 -04:00
Tom Rothamel a5301ec50c Add an 'events' transform property.
This determines if events will be passed to the child of the
transform. This allows one to prevent events from being passed
to the old_widget in an ATL transform.
2014-06-01 22:49:26 -04:00
Tom Rothamel d0e01f5c9c Transform.set_child should update the transform's children.
This lets us pass events to a new child when the child changes.
2014-06-01 22:28:03 -04:00
Tom Rothamel c717c42b13 Encode PSS_play extension using UTF-8.
This prevents a crash that occurs when a unicode filename is passed
to PSS_play.

Fixes #369, thanks to everyone for tracking this down.
2014-06-01 10:39:24 -04:00
Tom Rothamel 65ed8f87b0 Get rid of _predict_screens.
This has been obsoleted by the new code.
2014-05-31 22:59:12 -04:00
Tom Rothamel 0f2b67745c New functions for continuously predicting displayables and screens. 2014-05-31 22:56:32 -04:00
Tom Rothamel 30ce6b5033 Add __hash__ to Image and Solid. 2014-05-31 22:07:22 -04:00
Tom Rothamel d6768da6c8 Predict show screen and call screen statements with arguments.
This is a behavior change, and a potentially dangerous one, since it
could execute arguments with side effects multiple times. But those
should be rare, this provides a nice performance boost, and users
will be able to disable prediction using the new nopredict clause.
2014-05-30 21:29:22 -04:00
Tom Rothamel 6c8e997cf2 Fix prediction of argument-containing screens.
We were passing the arguments incorrectly, which prevented them from
working.
2014-05-30 21:28:49 -04:00
Tom Rothamel 62458fa036 Fix regression: Set Text.dirty before we use it. 2014-05-30 08:31:28 -04:00
Tom Rothamel bcf47fd43a Fix prediction of screens without arguments.
Fixes #370, at least partially.
2014-05-29 23:17:45 -04:00
Tom Rothamel 39b168eda9 Do not wait for an event to occur to proceed with prediction. 2014-05-29 23:17:25 -04:00
Tom Rothamel 80130db047 Do not redraw Text if it hasn't been drawn at least once. 2014-05-29 23:09:27 -04:00
Tom Rothamel 2942ddc53d Merge pull request #373 from Shizmob/master
Only consider unique image attributes when determining best match.
2014-05-29 21:19:53 -04:00
Shiz b127da3a41 Only consider unique image attributes when determining best match. 2014-05-30 03:18:27 +02:00
Tom Rothamel 0375b7cf1a Merge pull request #372 from Shizmob/master
Restart interaction when MixerValue value changes.
2014-05-29 17:40:09 -04:00
Shiz 294e6611ef Restart interaction when MixerValue value changes.
This allows UIs which rely on the mixer value for other UI elements to
be properly updated as the value changes.
2014-05-29 23:37:32 +02:00
Tom Rothamel c03d1fddd1 Fix dump of non-ASCII defines. 2014-05-28 22:47:35 -04:00
Tom Rothamel 59e3eecb92 sl2: Ensure exceptions in screens work.
This means clearing out the various gui stacks if an exception occurs.
2014-05-28 21:45:52 -04:00
Tom Rothamel 0e11a964cc Fix XScrollValue and YScrollValue.
These have been broken since we started deferring get_adjustment()s.
2014-05-28 21:34:14 -04:00
Tom Rothamel 3744a729b3 Make renpy.get_widget() accept a ScreenDisplayable.
This makes it possible to do:

    self.screen = renpy.current_screen()

and later:

    renpy.get_widget(self.current_screen, "name")
2014-05-28 21:33:25 -04:00
Tom Rothamel 9dafe56266 Allow non-ascii identifiers to be used as character names.
There are a couple of caveats here, since non-ascii identifiers
can't be used in python code.

* The names must be defined with the define statement.
* The names can't be accessed in python code.

Stil, something like:

    define 彁 = Character("Boy who is not able satisfactorily to explain what a Hrung is, nor why it should choose to collapse on Betelgeuse Seven")

    彁 "Don't forget your towel."

should work.
2014-05-27 22:42:39 -04:00
Tom Rothamel a705f46018 sl1: Fix label and textbutton.
Now that we're creating the widgets directly, we need to apply the
function wrapper to the results of _label and _textbutton.
2014-05-27 21:13:56 -04:00
Tom Rothamel 1bf516bd79 Fix transform_anchor to work with anchors of type absolute. 2014-05-27 19:14:25 -04:00
Tom Rothamel 533b22e9d8 Remove accidentally included text. 2014-05-27 17:43:22 -04:00
huanxuantian 94e1681802 Chinese_Simplified translation for ren'py launcher 1.3c release
orgin version:0.98a
current version:1.3c
least update date:2014-5-27
2014-05-27 19:05:44 +08:00
Tom Rothamel bee2a91d3d sl2: sl2viewport no longer uses ChildList. 2014-05-26 23:50:18 -04:00
Tom Rothamel 1c80515112 sl2: More optimizations. 2014-05-26 23:34:19 -04:00
Tom Rothamel 6eec5cd454 sl2: Various minor optimizations 2014-05-26 23:11:02 -04:00
Tom Rothamel 263a2d4c51 sl2: Allow the use of cprofile to profile the screen implementation. 2014-05-26 22:27:28 -04:00
Tom Rothamel 042a87b2ce sl2: Prepare screens ahead of time. 2014-05-26 21:58:19 -04:00
Tom Rothamel c823bef1c6 Add the ability to profile various phases of a screen's life. 2014-05-26 21:15:40 -04:00
Tom Rothamel c7e5856fdb sl2: Store the location the displayable was created at. 2014-05-25 23:42:52 -04:00
Tom Rothamel 1d3a8a0459 sl2: Fix cache.children issues. 2014-05-25 23:42:08 -04:00
Tom Rothamel 77ae9668b8 sl2: Store the children of displayables in the cache.
This means we don't have to re-add them all the time, and prevents
clear from being called for no-child displayables.
2014-05-25 22:43:53 -04:00
Tom Rothamel a964d2fc9a Merge pull request #355 from kyouryuukunn/fix_doc8
Fix get_playing doc
2014-05-25 10:09:05 -04:00
kyouryuukunn 27ecb992e9 fix doc 2014-05-25 23:07:41 +09:00
Tom Rothamel fd3c89c3ff Allow ImageButtons to not have children.
Since ImageButtons do not use their child, it makes sense to not
require one - especially since _clear() will occasionally remove
it.
2014-05-24 23:35:20 -04:00
huanxuantian c7bae1eee8 Signed-off-by: huanxuantian <huanxuantian@msn.cn>
Chinese_Simplified translation for ren'py launcher
Created by huanxuantian
Translate by huanxuantian
Translation version 1.3.b
update to github on 2014-5-25 sun
2014-05-25 09:52:36 +08:00
Tom Rothamel a45df6e964 sl2: Fix regression in imagemap.
The _reuse() method would clear out the fixed during reuse,
which would remove the ground from the imagemap.
2014-05-24 17:48:43 -04:00
Tom Rothamel 905b0e0534 Simple expressions take words as field names.
This lets one use a keyword (like transform) as a field name.
2014-05-23 22:00:34 -04:00
Tom Rothamel bfeae69e5e Screen language keywords (incl. at) take comma separated expressions. 2014-05-23 21:59:38 -04:00
Tom Rothamel 1e0b224ccc Fix sl1 and sl2 pass statements.
Neither ever worked, despite being part of SL design from the
beginning.
2014-05-22 23:00:29 -04:00
Tom Rothamel 1fc90fb3b5 sl2: Add slast.SLOn.
Since on doesn't create a displayable, it makes sense to handle it
differently rather than complicating SLDisplayable.
2014-05-22 22:18:45 -04:00
Tom Rothamel bebbc73210 Update screens at most once per interaction. 2014-05-21 23:52:54 -04:00
Tom Rothamel 9615971e2e Store and use the cache of predicted screens.
This will generally let us show the screen a lot faster.
2014-05-21 23:49:25 -04:00
Tom Rothamel 55f8782da9 Fix all errors and warnings reported by pydev 3.5.
The predefinition directory (predef) needs to be added to the Ren'Py
interpreter in PyDev for this to work.
2014-05-21 22:13:11 -04:00
Tom Rothamel 651da7e487 Add shift+P to profile once.
This restarts the interaction, and then reports the amount of time
it took to do so. This can give us an idea of how much (if any)
performance is being improved by the new screens code.
2014-05-21 09:22:48 -04:00
Tom Rothamel 248793923a sl2: Fix bar handling.
We have to figure out the style in the sl2 code so the context is
available to the code that gets the bar style.
2014-05-20 23:18:39 -04:00
Tom Rothamel 66e07d6e9b sl2: Fix handling of tuple patterns in SLFor. 2014-05-20 21:28:53 -04:00
Tom Rothamel 079d311228 sl2: Use eval and exec directly in execute and keywords code.
For performance reasons.
2014-05-19 23:42:53 -04:00
Tom Rothamel afb1da6248 sl2: Fix const on if statements. 2014-05-19 23:34:13 -04:00
Tom Rothamel 72c1aa0f8d Improve profiling and control screen prediction with an envvar. 2014-05-19 23:32:51 -04:00
Tom Rothamel b4b7fcfc26 Mark config and style as constants. 2014-05-19 23:32:21 -04:00
Tom Rothamel 372d8cb748 Fix __repr__ on displayable - encode unicode. 2014-05-19 23:31:06 -04:00
Tom Rothamel 6ee38b1817 Fix --compile. 2014-05-19 23:30:39 -04:00
Tom Rothamel ee24f4f96d Import os before running os.startfile. 2014-05-19 18:49:37 -04:00
Tom Rothamel 16ae08345e A regression prevented insensitive buttons from working. 2014-05-18 23:11:33 -04:00
Tom Rothamel e651810ade Do not attempt to resize a 0-width or 0-height displayable.
This prevents a divide-by-zero.
2014-05-18 21:10:39 -04:00
Tom Rothamel ec59eef066 sl2: Make the version of screen language used configurable.
For now, this is controlled by an environment variable.
2014-05-18 20:06:14 -04:00
Tom Rothamel f8f147ad30 Add --compile and --lint arguments.
--compile compiles the script before doing anything else.

--lint is a backwards compatable way of invoking the lint
command. We've been parsing it as an argument for a while, but it
didn't work.
2014-05-18 17:41:57 -04:00
Tom Rothamel d50c922c87 sl2: Transforms take a child parameter, while transforms just take an argument. 2014-05-17 22:21:45 -04:00
Tom Rothamel d0bbf09783 Reset Viewport and Input when first shown.
This supports reuse, by eliminating state state from these
displayables.
2014-05-17 08:57:54 -04:00
Tom Rothamel d69c59beca Get a new adjustment from bars on each interaction.
This lets us reuse the Bar objects, and yet update the object in
the face of changing data.
2014-05-16 23:43:36 -04:00
Tom Rothamel b3a1571038 Evaluate button role and sensitivity per-interaction.
This lets us reuse buttons, and still update the role/sensitivity
as the actions dictate.
2014-05-16 08:46:27 -04:00
Nobody Really d91f9ce376 Added Italian translations for launcher and template 2014-05-16 12:23:38 +02:00
Tom Rothamel ee1295c98b sl2: Implement constant displayables.
These are displayables that have constant arguments and constant
children, and hence where the same displayable can alwaye be used.  We
use a very fast path for these displayables (simply retrieving them
from the cache), and avoid evaluating their children entirely.
2014-05-16 00:05:00 -04:00
Tom Rothamel 94cc959880 sl2: Do not pass keywords intended for a displayable to its parent.
Due to inheritance of SLBlocks, we had the problem that

    frame:
        textbutton "test" xysize (100, 100)

Would pass the xysize parameter to both the textbutton and the frame.
2014-05-15 09:10:05 -04:00
Tom Rothamel 1c7685550d sl2: Use object identity and count in slfor. 2014-05-15 08:41:57 -04:00
Tom Rothamel 37f5738b86 sl2: Update the scope when we reuse a displayable. 2014-05-14 22:56:29 -04:00
Tom Rothamel bde2cf84f7 sl2: Redraw cleared displayables.
If we don't do this, we won't actually show the changes.
2014-05-14 21:57:13 -04:00
Tom Rothamel e393d647f0 Allow auto to take images as well as image filenames. 2014-05-13 18:42:07 -04:00
Tom Rothamel 1d534a6162 Add renpy.image_exists, a function that makes it possible to tell
if an image exists.
2014-05-13 18:11:09 -04:00
Tom Rothamel 0cbc06a241 Make more Displayables comparable. 2014-05-12 22:49:48 -04:00
Tom Rothamel 911f179631 An object should be equal to itself. 2014-05-12 22:11:21 -04:00
Tom Rothamel 043a2c7213 Make styles comparable. 2014-05-12 22:11:05 -04:00
Tom Rothamel 87073bcd0b render cache: use id(d) as the key.
This is needed so we can start defining __eq__ on various
displayables, even when we don't want them being considered the same
by the cache.
2014-05-12 21:17:01 -04:00
kyouryuukunn 9e895e2575 reduce bgm volume during voice playing 2014-05-12 16:13:23 +09:00
Tom Rothamel eec2d6e7d6 Annotate more functions as pure. 2014-05-11 22:04:20 -04:00
Tom Rothamel 44a8128326 The define statement now marks variables as const. 2014-05-11 09:15:47 -04:00
Tom Rothamel 292e24b640 Annotate BarValues for purity and equality. 2014-05-10 23:28:07 -04:00
Tom Rothamel a37c841d16 Merge pull request #341 from kyouryuukunn/DictValue
Add DictValue
2014-05-10 23:15:44 -04:00
Tom Rothamel 878bde34fc Annotate actions for purity and equality. 2014-05-10 22:47:07 -04:00
Tom Rothamel 6e49ed1a15 New renpy.const and renpy.pure functions.
These allow one to declare variables const and functions/classes pure,
for the purpose of sl2.
2014-05-10 22:04:50 -04:00
Tom Rothamel 2c6c97b27a sl2: Pass the main displayable to replaces=. 2014-05-09 21:26:21 -04:00
Tom Rothamel 143cb26ae3 sl2: Add viewport and the concept of a main displayable.
Viewport was broken with sl2, so we now have a compatible
implementation.

Several screen language things are implemented as composite
displayables. For example, a textbutton consists of a Text
and a Button, and a viewport scrollbars "both" consists of
a Side, two Bars, and a Viewport.

The main displayable (stored in _main on the outer displayable) is the
displayable we add children to, and return for get_widget.
2014-05-09 21:18:55 -04:00
Tom Rothamel 2d1af033f8 sl2: Improve reuse.
* SLFor now reuses the cache.
* SLDisplayable no longer clears composite displayables.
2014-05-08 23:56:19 -04:00
Tom Rothamel 1abb87e2a2 sl2: The result of a pure function called with constants is constant. 2014-05-08 23:51:20 -04:00
Tom Rothamel a53eb8b3ce Fix doc typo in queue_event.
Thanks, KiloTango.
2014-05-07 21:59:51 -04:00
Tom Rothamel 26ea3fb14e Fix changelog. 2014-05-07 21:50:55 -04:00
Tom Rothamel 3232620a12 Add 6.17.6 changelog. 2014-05-07 21:38:58 -04:00
Tom Rothamel 28fbf90342 Only enable config.rtl in the launcher iff Arabic is the language.
This is a workaround for #351, which only seems to manifest on certain
Macs, and hence is proving hard to actually fix. At least with this
change, it will only show up when switching to Arabic. (And may not
show up at all, as it may have something to do with filesystem
encodings.)
2014-05-07 20:30:22 -04:00
Tom Rothamel 8f7a2acba5 Extend tkaskdir to handle non-ASCII directories. 2014-05-06 21:53:26 -04:00
Tom Rothamel f50726b5ce Edit a bit. 2014-05-06 21:13:42 -04:00
Tom Rothamel 94d11b0e01 Merge pull request #344 from kyouryuukunn/update_doc
add doc about translations for the launcher
2014-05-06 21:12:04 -04:00
Tom Rothamel 71ef71611b Improve wording of sl/sl2 syntax errors.
Fixes #348.
2014-05-05 21:43:59 -04:00
Tom Rothamel 3da1b368e0 Merge pull request #349 from LuqueDaniel/update-es
Update Spanish translation.
2014-05-05 09:30:40 -04:00
Tom Rothamel 4fea47f3f2 Add Korean translation, by Baekansi. 2014-05-05 09:25:56 -04:00
Daniel Luque 00a92329dd Update launcher/game/tl/spanish/android.rpy 2014-05-05 08:31:38 +02:00
Tom Rothamel fe79eb948f sl2: Reuse displayables where possible.
Reusing a displayable is possible when we realize that the positional
and keyword arguments of the displayable are the same. We can also
reuse the transform if we apply the same transform to the
displayable.
2014-05-04 23:23:41 -04:00
Tom Rothamel e85c0ade0f Add _clear methods to containers.
This facilitates reuse of the underlying displayable.
2014-05-04 21:55:28 -04:00
Tom Rothamel 45c6eb156f sl2: Persist the cache. 2014-05-03 21:09:56 -04:00
Tom Rothamel e45a935c7e sl2: Fix parsing layouts. 2014-05-03 20:19:50 -04:00
Tom Rothamel 094c07ce3c Add screen profiling.
For now, this is intended for Ren'Py development use, so we can
see if sl2 is actually making things faster, as optimizations are
implemented.
2014-05-02 22:39:48 -04:00
Tom Rothamel 1d3a14bc99 Add a German Translation of the launcher. (By NoJoker) 2014-05-02 15:29:27 -04:00
Tom Rothamel 7aa971a978 Add project.json to Arabic template. 2014-05-01 22:46:49 -04:00
Tom Rothamel d0b3ba90f2 Various Arabic fixes. 2014-05-01 22:45:51 -04:00
Tom Rothamel 45b8cb3051 Update documentation for 6.17.5. 2014-05-01 21:22:18 -04:00
Tom Rothamel 4829a32c29 Fix save_directory in arabic translation. 2014-05-01 18:14:46 -04:00
Tom Rothamel e355c451e5 Properly set up the context after a warp occurs. 2014-04-30 18:19:54 -07:00
Tom Rothamel 3301f8c87b Fix --warp.
Fixes #345.
2014-04-30 18:03:40 -07:00
Tom Rothamel 13c4c97e59 Improved memory debugging. 2014-04-29 21:42:21 -07:00
Tom Rothamel 6355e0d623 Re-initialize the cache after shift+R.
Fixes a major memory leak, where textures would be placed in a
stopped cache and never deallocated.
2014-04-29 21:40:40 -07:00
Tom Rothamel 94f0ff71a1 Pause defaults to only setting a checkpoint if delay is not set.
This fixes an issue where renpy.pause(0) would effectively block
rollback, since there would be no time for the rollback to occur.
(The same issue occurs when pausing for a short time.)
2014-04-28 23:26:45 -04:00
kyouryuukunn 3e966d308f add doc about translations for the launcher 2014-04-29 11:52:48 +09:00
Tom Rothamel 2c49d5902d Add/use the renpy.object.Sentinel class.
This is a class that can be used to create sentinel objects. Even if
we pickle and unpickle an object of this class, it remains the same
object, as far as the 'is' operator is concerned.

This fixes a problem with the shift+R module backups. (The same
problem 9dec1f32ab tried to fix.)
2014-04-28 22:17:43 -04:00
Tom Rothamel 816d60eae0 Merge pull request #333 from renoa/master
add arabic translation
2014-04-28 17:47:32 -04:00
Tom Rothamel be258d878d Merge pull request #335 from kyouryuukunn/fix_doc3
fix doc
2014-04-28 17:46:36 -04:00
Daniel Luque 92c4c68942 Add new tl 2014-04-28 14:30:07 +02:00
kyouryuukunn fc25414deb Merge pull request #343 from kyouryuukunn/update_japanese_template
Update japanese template
2014-04-28 20:03:11 +09:00
kyouryuukunn 137e8ba77d update the japanese translation for launcher 2014-04-28 20:01:17 +09:00
kyouryuukunn 0a26eeaa7e update japanese_template 2014-04-28 18:58:28 +09:00
Tom Rothamel 9dec1f32ab Do not backup / restore flag singletons.
The reload backup process would back up singletons, but not functions
and methods that used those singletons as default arguments. The
result was that the singletons would change identity, but not
the default arguments - and the code using them would fail in
odd ways.

An example problem this caused is
http://lemmasoft.renai.us/forums/viewtopic.php?p=320775#p320757 .
2014-04-27 22:44:34 -04:00
Tom Rothamel 499762aad4 atl: Properly transfer child_st_offset, raw_child, and debug.
The major problem fixed here is one where if a transform was
replaced (like one in a screen would be), it would not know that
the old child was being shown. This would prevent the
"<displayable> with <transition>" ATL construct from doing
anything.

Fixes #340.
2014-04-27 19:52:42 -04:00
Tom Rothamel 6cac00a688 Remove raspi stuff. 2014-04-27 01:40:29 -04:00
Tom Rothamel 37d31a6f85 Add raspberry pi and x11 egl modes.
The raspi one somewhat works (it has problems, such as positioning the
window in the wrong place), but the slowness of the raspi system make
using it problematic.

The x11 mode hasn't been tested.
2014-04-27 01:28:16 -04:00
Tom Rothamel 116d344519 Rename eg_gl to egl_none, since it's really used in cases where we're not managing egl. 2014-04-26 23:13:21 -04:00
Tom Rothamel 6739a9a268 Make it easier to add EGL support. 2014-04-26 14:16:33 -04:00
Tom Rothamel 96058a9de3 Get things building on Raspberry Pi.
Right now, we can run Ren'Py, but at an unusably slow speed.
2014-04-26 13:53:45 -04:00
Tom Rothamel b6e71f20c2 Add a new debug ATL property.
This can be accessed in the Ren'Py internals to dump particular
transforms that are having problems.
2014-04-25 22:04:50 -04:00
Tom Rothamel ebd9274776 Add RENPY_TIMEWARP.
This environment variable, if set, makes time itself run faster or
slower. (Well, at least inside the game.)
2014-04-25 21:41:32 -04:00
kyouryuukunn f3a52917cd add DictValue 2014-04-25 16:57:46 +09:00
Tom Rothamel f24379aec6 sl2: Report tracebacks using the screen lines they originate on. 2014-04-24 19:19:52 -04:00
Tom Rothamel 49fa961502 Do not back up renpy.display.presplash.
This prevents an issue with copying modules that only occurs when
presplash is present.
2014-04-23 21:48:23 -04:00
Tom Rothamel 3abba0c7e9 sl2: Supply location to SLDefault. 2014-04-23 21:46:16 -04:00
Tom Rothamel ab00c6a876 sl2: Annotate the ast nodes with locations. 2014-04-22 23:44:30 -04:00
Tom Rothamel 769a65467a Only change the reported traceback if it is not the proximate cause
of the error.
2014-04-22 19:25:04 -04:00
Tom Rothamel 62c66b3794 Various fixes to the documentation. 2014-04-22 19:20:35 -04:00
Tom Rothamel 19889c7457 Remove unused functions. 2014-04-22 19:08:27 -04:00
Tom Rothamel bc3ee8667c Rewrite tracebacks.
We now use the .report_traceback method whenever it's available to
produce nicer-looking tracebacks. (Previously, we only used it
for the simple tracebacks, and only for Contexts.)
2014-04-21 23:54:05 -04:00
Tom Rothamel d2c6f47299 Break up bootstrap.py.
The traceback code went into renpy.error, while the memory dump code
went into renpy/memory.py.
2014-04-21 22:18:59 -04:00
Tom Rothamel 16a4019a40 raise_at_location: A function that raises a traceback at a given location. 2014-04-20 13:38:32 -04:00
Tom Rothamel ec37eb9a84 sl2: Direct path for use.
This makes the ast of the used screen available to the using screen,
allowing for potential optimizations.
2014-04-20 13:13:57 -04:00
Tom Rothamel 96d4440960 sl2: SLScreen is now a SLBlock.
We also now properly handle parsing SLScreen keywords.
2014-04-20 12:38:15 -04:00
kyouryuukunn 738f939f2e Merge pull request #337 from kyouryuukunn/update_japanese_template
Update japanese template
2014-04-20 22:13:14 +09:00
kyouryuukunn cc4591848f autosave before load 2014-04-20 22:03:57 +09:00
Renoa 57afa2ca46 Update android.rpy 2014-04-20 15:02:49 +03:00
Tom Rothamel 7b3072983f Fix regression in times for children of transformed layers.
The regression was introduced by dd4d3410a6,
and shows up in the Sunrider tutorial battle, when the PACT ships
attack with missiles.

The problem was that we were adjusting the times improperly - using
AdjustTimes to make the adjustment. Instead, we want the MultiBox
containing the layer to make the adjustment (which it does when
layer_name is set). This is because the MultiBox handles start
and animation times that are not the time at which the layer
was shown.
2014-04-19 21:40:56 -04:00
Tom Rothamel b1ae62b45f Add environment variables to skip main_menu and splashscreen.
These are RENPY_SKIP_MAIN_MENU and RENPY_SKIP_SPLASHSCREEN.
2014-04-19 18:48:09 -04:00
Renoa dc80ec27e1 Update common.rpy 2014-04-19 19:41:36 +03:00
Renoa 17ef16b3c3 Update distribute.rpy 2014-04-19 19:31:11 +03:00
Renoa 7fdd823745 Update front_page.rpy 2014-04-19 19:30:56 +03:00
Renoa 1cfba7a745 Update preferences.rpy 2014-04-19 19:30:39 +03:00
Renoa 2942dd3390 Update new_project.rpy 2014-04-19 19:30:13 +03:00
Renoa 3afa5e5944 Update project.rpy 2014-04-19 19:29:49 +03:00
Renoa d7b463a445 Update updater.rpy 2014-04-19 19:29:17 +03:00
kyouryuukunn 123dd8d0c7 update japanese template 2014-04-19 20:16:41 +09:00
kyouryuukunn 98d66242c4 update japanese template 2014-04-19 20:09:17 +09:00
Tom Rothamel 205efcccdd Fix typo. 2014-04-18 23:53:03 -04:00
kyouryuukunn 23e7301b6d fix doc 2014-04-19 12:15:51 +09:00
Tom Rothamel 711f7bb608 sl2: Pass arguments to use_screen. 2014-04-18 22:55:09 -04:00
Tom Rothamel b4271b6b7b Deduplicate argument evaluation code. 2014-04-18 22:34:09 -04:00
Tom Rothamel d3b7a84bcd sl2: Initial implementation of use.
This doesn't support arguments yet, and passes everything through to
use_screen. But it does successfully let one include SL2 and SL1
screens inside an SL2 screen.
2014-04-17 23:11:13 -04:00
Renoa 278eb7f522 Create updater.rpy 2014-04-17 13:45:54 +03:00
Renoa 6349eff9b7 Create translations.rpy 2014-04-17 13:45:42 +03:00
Renoa 2518af39ca Create style.rpy 2014-04-17 13:45:28 +03:00
Renoa 85457996d4 Create project.rpy 2014-04-17 13:45:17 +03:00
Renoa 73ca7320b4 Create preferences.rpy 2014-04-17 13:45:05 +03:00
Renoa 8c3903cb04 Create new_project.rpy 2014-04-17 13:44:51 +03:00
Renoa f02bf4e826 Create navigation.rpy 2014-04-17 13:44:38 +03:00
Renoa f591a66dda Rename choose_theme to choose_theme.rpy 2014-04-17 13:44:17 +03:00
Renoa 5cde6f1eb4 Create interface.rpy 2014-04-17 13:43:50 +03:00
Renoa 24959e2e0a Create front_page.rpy 2014-04-17 13:43:37 +03:00
Renoa 9d2858f558 Create editor.rpy 2014-04-17 13:43:23 +03:00
Renoa cdd045f30d Create distribute_gui.rpy 2014-04-17 13:20:17 +03:00
Renoa 80a0031ab5 Create distribute.rpy 2014-04-17 13:20:01 +03:00
Renoa 9d01fe5d81 Create common.rpy 2014-04-17 13:19:39 +03:00
Renoa 198e7aaa43 Create choose_theme 2014-04-17 13:19:25 +03:00
Renoa 98d7e022fe Create android.rpy 2014-04-17 13:19:09 +03:00
Renoa 9091a0fea0 Create add_file.rpy 2014-04-17 13:18:42 +03:00
Renoa ad91211ca1 Create about.rpy 2014-04-17 13:18:25 +03:00
Renoa 083e69f826 Create script.rpy 2014-04-17 13:17:24 +03:00
Renoa 43124767b9 Create screens.rpy 2014-04-17 13:17:12 +03:00
Renoa 1cc4b21275 Create options.rpy 2014-04-17 13:16:59 +03:00
Renoa 63cf67e078 Create screens.rpy 2014-04-17 13:16:18 +03:00
Renoa 32ff178ae7 Create common.rpy
testing how to add Arabic translation to the templates in Renpy
2014-04-17 13:16:01 +03:00
Tom Rothamel 6b48d71a1e Implement renpy.queue_event.
This queues an event by name. For example, renpy.queue_event("dismiss")
will act like dismiss has been pressed.

This is intended to make it easier to interface Ren'Py with custom
controllers.
2014-04-16 20:20:14 -07:00
Tom Rothamel 77533e042f Renumber user events.
User event 32 seems too high, and we no longer need to reserve space
for PSS events.
2014-04-16 20:17:53 -07:00
Tom Rothamel 97ef93855e Uncomment screen2. 2014-04-16 20:17:15 -07:00
Tom Rothamel 42e9b0f81a Revert changes caused by 6.17 merge. 2014-04-15 20:41:24 -04:00
Tom Rothamel bc213c48fd Add renpy.clear_keymap_cache. 2014-04-15 20:38:47 -04:00
Tom Rothamel ced53fe72a Leave disabled file pacges.
This kicks in if we're on the auto or quick pages, and a creator
sets has_autosave or has_quicksave to false.
2014-04-14 21:31:54 -04:00
Tom Rothamel df7eef44ce Make imagemap_button inherit from hotspot, remove modern uses of imagemap_button. 2014-04-14 21:23:59 -04:00
Tom Rothamel c9f935d008 Docs. 2014-04-13 20:29:29 -07:00
Tom Rothamel 7937e7e103 Disable SL2. 2014-04-13 23:04:19 -04:00
Tom Rothamel 0b8045f7b6 Make autoreload configurable, and default it to off. 2014-04-13 23:02:25 -04:00
Tom Rothamel bc8ca388af Mark this as version 6.17. 2014-04-13 22:45:04 -04:00
Tom Rothamel 101b0c62d1 Merge pull request #321 from javimat/master
Update Spanish translation of the Template and the Launcher
2014-04-13 22:40:07 -04:00
Tom Rothamel ab70f0f11b Update to use newer RAPT. 2014-04-13 16:01:58 -04:00
Tom Rothamel cfd3331ede Fix problem with MoveTransition and multiple interactions.
The problem would manifest when we did something like
$ renpy.transition(move), and restarted the interaction. We had been
creating a MultiBox with a layers dict, which would adjust the times
for its children. When shown as part of the second interaction, the
times would be reset to 0, and the move would appear to restart.

By getting rid of the layers dict, we prevent this the adjustment
of times from occuring, and things work as expected.
2014-04-12 21:48:37 -07:00
Tom Rothamel db8dc43ab9 Remote ADB connect interface.
It's now possible to enter the address to connect to.
2014-04-11 23:38:37 -04:00
Tom Rothamel 9b571dc8ce Add support for connecting to remote ADB. 2014-04-11 17:11:46 -04:00
Tom Rothamel 2a3e691305 Make fit_first fit images bigger than the screen.
It's only used for imagemaps, and it makes sense for an imagemap to
be bigger than the screen. (For example, if you put it into a
viewport.)
2014-04-10 21:11:55 -04:00
Tom Rothamel 0ba7f0011a Add _bar and _vbar styles.
The _bar style being missing was a regression. Fixes #326. Fixes #327.
2014-04-09 22:06:08 -04:00
Tom Rothamel f8d051f2cd Pass all hyperlink URLs to the web browser, not just http URLs. 2014-04-08 11:46:46 -04:00
Tom Rothamel 1f877be8a3 Automatically use background thread for screenshots.
If we try to take a screenshot outside of the display thread, we
segfault. This ensures that can't happen.

Fixes #329.
2014-04-07 23:11:01 -04:00
Tom Rothamel 4ebde6fc38 sl2: Store transforms and transfer state. 2014-04-06 20:48:35 -04:00
Tom Rothamel e53c1673dc sl2: Pass locals to py_eval_bytecode. 2014-04-06 20:47:54 -04:00
Tom Rothamel c745bc47e3 Add replaces to timer. 2014-04-05 22:50:02 -07:00
Tom Rothamel c601a0ff2b sl2: Implement replaces for displayables. 2014-04-05 22:44:42 -07:00
Tom Rothamel 681efdf8fa Do not back up data on Android.
Since we won't reload it, there's not point. And android has some
arbitrary system-specific stuff that can't be pickled.
2014-04-05 01:17:28 -04:00
Tom Rothamel 4d8859ec79 Detect the Amazon Fire TV, and set the "firetv" screen
variant if we find one.
2014-04-05 01:16:58 -04:00
Tom Rothamel a3cbf14ede sl2: Implement the on statement. 2014-04-04 18:06:06 -04:00
kyouryuukunn 4f13cb73b0 fix selected status in musicroom 2014-04-04 19:41:58 +09:00
kyouryuukunn 61a37f225c If SensitiveIf is in a list of Actions, it is uesd to check sensitive 2014-04-04 19:31:46 +09:00
kyouryuukunn 379b340210 If SelectedIf is in a list of Actions, it is uesd to check selected 2014-04-04 19:23:07 +09:00
Tom Rothamel 5f3dba9725 Use hotspot as the style for hotspots.
This fixes a problem where we'd inherit padding from the button
style, which could cause the hotspots to show up in odd places.

This would only occur if ui.hotspot was called directly - so almost
never in actual code.
2014-04-03 21:54:32 -04:00
Tom Rothamel f16cc57d52 sl2: Add add. 2014-04-03 20:59:07 -04:00
Tom Rothamel 61cbc9e6c7 sl2: Implement child_or_fixed behavior. 2014-04-03 00:21:35 -04:00
Tom Rothamel 5867d4f7ac sl2: Add imagemaps.
These don't work, due to incorrect handling of displayables that
take one child.
2014-04-02 23:47:12 -04:00
Tom Rothamel cc92d83fd6 sl2: Evaluate keywords and children separately.
This is necessary for us to have imagemap statements. The imagemap
needs the keywords to be evaluated, and the imagemap needs to be
created before the keywords can be created.
2014-04-02 23:22:44 -04:00
duanemoody 298e4ae2de Add application category for OS X
The Applications folder in OS X is large and installers tend to expect apps to stay where they were placed (i.e. the root of /Applications). Since Lion, there's been application category metadata for View --> Arrange by Application Category but if the metadata's not in info.plist, the app gets sorted into "Other" at the bottom. 

https://developer.apple.com/library/Mac/releasenotes/General/SubmittingToMacAppStore/#//apple_ref/doc/uid/TP40010572-CH16-SW8 (this applies to all Mac apps, not just those installed through App Store).
2014-04-02 13:43:37 -07:00
Tom Rothamel 436f4f2c8b Document various NVL-mode config variables. 2014-04-01 23:11:48 -04:00
Tom Rothamel 4af52c43a4 Add layer selection to menu/choice and NVL.
Adds config.say_layer, config.menu_layer, and config.nvl_layer to
select layers for the various screens.
2014-04-01 22:51:50 -04:00
Tom Rothamel 984448ae4f Add a show_layer parameter to Character.
This makes it possible to choose the layer the say screen appears
on, which might be necessary for side images and so on.
2014-04-01 22:17:20 -04:00
Tom Rothamel 7cae393d72 Fix a style-related memory leak.
When unbuilding styles, we would deallocate the cache, but not XDECREF
the contents of the cache, leading to a crash. This fixes the problem.
2014-03-31 23:05:34 -04:00
Tom Rothamel 667676f55b Fix memory leaks on reload.
The big fix was to de-init the draw module before deallocating it,
which is what frees up textures. There are a lot of smaller fixes
here as well.
2014-03-30 16:13:12 -04:00
Tom Rothamel 2ff748c5e1 Re-initalize modules rather than reloading them entirely.
This prevents memory leaks through reloaded modules, and should
make reload faster. (It doesn't eliminate all memory leaks,
however.)
2014-03-29 23:52:33 -04:00
Tom Rothamel 65513fb8d7 Make the layout functions (Fixed, VBox, Hbox, and Grid) pickleable.
The Displayables were, but the constructor functions weren't.
This fixes that by turning the functions into classes.
2014-03-29 23:51:28 -04:00
Tom Rothamel 992d9ca419 Fix prediction of windows and bars.
The style rewrite prevented direct access to prefixed styles,
which caused prediction not to work. With this change, we
handle the prediction in cython, which has access to
prefixed and unprefixed styles.
2014-03-28 21:46:39 -04:00
Tom Rothamel bc02b71c76 Reset the styles before reloading. 2014-03-27 22:29:49 -07:00
javimat 01cccefcc1 Update common.rpy 2014-03-27 23:51:41 +01:00
javimat c2e71a4b31 Update new_project.rpy 2014-03-27 23:48:03 +01:00
javimat f86b91f29a Update common.rpy 2014-03-27 23:43:43 +01:00
javimat 7836e58608 Update common.rpy 2014-03-27 23:40:30 +01:00
javimat eddab9a802 Update screens.rpy
Simplifying comments (deleting the English ones).
Changing to the new style language.
2014-03-27 23:39:00 +01:00
Tom Rothamel f6fa2d391f sl2: Add the default statement. 2014-03-26 22:41:29 -04:00
Tom Rothamel e119633cc6 Implement the pass statement. 2014-03-25 23:51:59 -04:00
Tom Rothamel aa9a2461cc Add set_projects_directory and get_projects_directory commands.
These let users set the projects directory from the command line,
which is useful if they don't have python-tkinter installed.
2014-03-25 19:04:15 -04:00
Tom Rothamel 71555a229e sl2: Parse multi-line Python statements. 2014-03-24 23:31:20 -04:00
Tom Rothamel 3b009de99c sl2: Parse one-line python statements. 2014-03-24 23:15:19 -04:00
Tom Rothamel 92b00df7af sl2: Improve sl2.
Largely, got the code written yesterday working.
2014-03-24 22:19:17 -04:00
Tom Rothamel bbf671555f sl2: Untested implementation of the for statement. 2014-03-24 00:03:27 -04:00
Tom Rothamel 929a1e916e If a non-existent screen is loaded, replace its contents with Null.
This can happen with some game changes, especially when changing
config.developer = True to False. Rather than crashing in this
case, we display an empty screen.

Fixes #320.
2014-03-23 19:12:25 -04:00
Tom Rothamel e6e2761396 Process common keywords in SL2:
* style_group, with styles.
* id
* at
2014-03-22 22:12:30 -04:00
Tom Rothamel 1412429d23 Add textbutton and label to sldisplayables. 2014-03-21 17:52:35 -04:00
Tom Rothamel 6210907701 Cleanup various PyDev warnings. 2014-03-21 15:40:11 -04:00
Tom Rothamel d8c2d743bd Add more displayables to sl2. 2014-03-20 23:50:28 -04:00
Tom Rothamel 5181b90473 sl2: Implement the if statement.
As a new feature, the if statement can apply to keyword arguments
as well as other statements.
2014-03-20 01:26:52 -04:00
Tom Rothamel ed5b914c12 Share parser code between ScreenParser and DisplayableParser. 2014-03-19 22:27:11 -04:00
Tom Rothamel 9e9611be7d sl2: Finish what's needed to have a screen run SL2 code.
With this, we can display the simplest screens.
2014-03-18 23:17:11 -04:00
Tom Rothamel 967abe7bd2 sl2: Implement execute for SLBlock and SLDisplayable. 2014-03-17 20:47:09 -07:00
Tom Rothamel 0c3ce7955c sl2: Prepare SLBlocks.
This prepares keyword arguments and children.
2014-03-17 23:21:51 -04:00
Tom Rothamel 7c1a7465d5 sl2: Evaluate positional arguments.
Constant positional arguments are evaluated during a prepare phase,
while non-constant arguments are evaluated at runtime. (When a mix
of arguments is given, they are combined.)
2014-03-16 21:03:37 -07:00
Tom Rothamel ef894d3040 Note that libavresample-dev is now required. 2014-03-16 15:35:29 -04:00
Tom Rothamel 8c823cc638 sl2: Start creating an AST. 2014-03-15 23:14:58 -04:00
Tom Rothamel 0920d32457 Hook up more of the screen language parsing. 2014-03-14 23:19:54 -04:00
Tom Rothamel 5c4650bce1 Correct transition documentation. 2014-03-13 23:10:37 -04:00
Tom Rothamel 65f3e0cef9 Move sl2 into its own package, tie it to parser.
This introduces the "screen2" statement, which is a temporary way of
accessing the sl2 stuff until it's ready to take over.
2014-03-13 23:07:16 -04:00
Tom Rothamel 0835958d92 Quit if the player hits quit while we're executing a prior quit.
This is in alternative to the current behavior, which opens
multiple quit windows if the user clicks slowly.

Double-clicking quit still exits.
2014-03-12 22:18:15 -04:00
Tom Rothamel 4aae1808ed Prefer main_menu to renpy.context()._main_menu. 2014-03-11 11:09:19 -04:00
Tom Rothamel dd4d3410a6 Adjust times for children of tranformed layers.
If we don't do this, the children will be shown at the timebase
of the layer at_list, which cause huge problems if the children
themselves are being transformed.
2014-03-10 23:14:54 -04:00
Tom Rothamel 0212094b9d Make shift+R toggle autoreload.
There's also an indicator, although its look needs to be revised.
2014-03-09 20:59:43 -04:00
Tom Rothamel 1b69f5930c Protect the safe mode stuff with a try/except.
It does some wierd direct keyboard access stuff that might change
in future versions of windows or linux, so this seems like a
reasonable bit of paranoia.
2014-03-08 08:53:54 -05:00
Tom Rothamel 1be159692b On windows, use ctypes to check if we should enter safe mode.
Fixes #316. It looks like using pygame to detect keypresses on an
unmapped window is now broken, perhaps since the most recent
pygame upgrade.
2014-03-07 22:10:38 -05:00
Tom Rothamel be0c6e6262 Avoid reinitializing the pygame window on Ren'Py reload.
This provides for a smoother reload process, by avoiding the window
disappearing and reappearing, potentially changing place and causing
focus issues.
2014-03-06 23:20:22 -05:00
Tom Rothamel 0e7e9ccced Initial implementation of autoreload.
This is a feature that scans for changes in file existence and times.
If a file changes, this triggers a restart of Ren'Py, reloading the
script and game.
2014-03-05 22:16:40 -05:00
Tom Rothamel 06d9557e4d Rewrite missing images in terms of screens and styles.
This makes it possible to customize the missing image indicator,
which is useful if it conflicts with the background of the game.
2014-03-03 22:35:51 -05:00
Tom Rothamel dd150047a6 Word-like operators have to end at word boundaries.
This prevents us from parsing strings like "8 insensitive" as "8 in
sensitive", and then failing when we go to eval it.

Fixes http://lemmasoft.renai.us/forums/viewtopic.php?f=32&t=25510
2014-03-02 22:03:38 -05:00
Tom Rothamel 838c8862a5 Finish documenting the functions in renpy.exports. 2014-03-02 21:53:47 -05:00
Tom Rothamel de5c0a8d9c Keymap fixes.
* Add toggle_music back in, because creators depend on the most obscure
  parts of Ren'Py.
* Update documentation.
2014-03-01 16:45:22 -05:00
Tom Rothamel 362759fdfb Remove debug print. 2014-03-01 16:45:17 -05:00
Tom Rothamel aed9864f26 Add missing comma, fixes selected_hover_ and selected_insensitive prefixes. 2014-03-01 16:45:11 -05:00
Tom Rothamel 378d0cab7b Fix docs. 2014-03-01 10:52:35 -05:00
Tom Rothamel 11107dcbdd Always reset l.init, not only on exceptions. 2014-02-28 17:43:41 -05:00
Tom Rothamel bb711f187e Merge commit 'ecd1ccf'
Conflicts:
	renpy/__init__.py
2014-02-28 16:31:28 -05:00
Tom Rothamel ecd1ccf0e7 Minor doc fixes. 2014-02-28 16:25:14 -05:00
Tom Rothamel d89d4f4f94 Bump version. 2014-02-28 16:20:41 -05:00
Tom Rothamel cd2029e759 Add the "translate <language> style <style>:" statement.
This is a localized equivalent of the style statement.
2014-02-28 16:19:11 -05:00
Tom Rothamel c50e91e970 More error checking for projects directory. 2014-02-28 16:18:38 -05:00
Tom Rothamel d7482744e8 Fix renpy.input documentation.
Fixes #296.
2014-02-28 16:18:38 -05:00
Tom Rothamel 7cc5cfcbae Ignore arguments passed into RevertableObject.__new__.
Some versions of Python ignore them, others do not. We ignore them
ourselves to be on the safe side.
2014-02-28 16:18:38 -05:00
Tom Rothamel 918158fcae It listing directories fails, treat it as if the directory was empty. 2014-02-28 16:18:38 -05:00
Tom Rothamel 23e2f4f0a8 Document translate style. 2014-02-28 16:18:38 -05:00
Tom Rothamel 25a6ec4ce6 Update the Japanese launcher & tutorial to use translate style. 2014-02-28 16:18:38 -05:00
Tom Rothamel 96351b039c More error checking for projects directory. 2014-02-28 16:17:01 -05:00
Tom Rothamel bcfc7d1d89 Fix renpy.input documentation.
Fixes #296.
2014-02-27 21:22:47 -05:00
Tom Rothamel e33bb7a3ae Ignore arguments passed into RevertableObject.__new__.
Some versions of Python ignore them, others do not. We ignore them
ourselves to be on the safe side.
2014-02-27 19:52:07 -05:00
Tom Rothamel 924da674c6 It listing directories fails, treat it as if the directory was empty. 2014-02-26 23:10:43 -05:00
Tom Rothamel 8e58ce8617 Document translate style. 2014-02-26 22:43:36 -05:00
Tom Rothamel 6274355089 Update the Japanese launcher & tutorial to use translate style. 2014-02-26 22:13:17 -05:00
Tom Rothamel 13d74b8d56 Add the "translate <language> style <style>:" statement.
This is a localized equivalent of the style statement.
2014-02-26 22:12:35 -05:00
Tom Rothamel 8f1ec59948 Expand is_constant to encompass names. 2014-02-25 21:58:39 -05:00
Tom Rothamel fccef8c639 Re-update version. 2014-02-25 20:31:59 -05:00
Tom Rothamel 0c04e5e861 There's no need to add RAPT anymore. 2014-02-24 23:13:05 -05:00
Tom Rothamel 6f328c8984 Version 6.17.1. 2014-02-24 22:30:23 -05:00
Tom Rothamel 61d2ad2202 I18n fixes and translatable console.
Merge remote-tracking branch 'origin/system-translations' into maintenance/6.17
2014-02-24 22:23:10 -05:00
Tom Rothamel 93acff591f Use double colons to show code correctly.
Merge remote-tracking branch 'origin/doc-doublecolon' into maintenance/6.17
2014-02-24 22:22:34 -05:00
Tom Rothamel 314446cffd We don't have a key if local.properties is missing. 2014-02-24 22:21:08 -05:00
Koichi Akabe e5186a7d63 Update Japanese translation for console 2014-02-24 16:40:21 +09:00
Koichi Akabe aaba96b31e Make console translatable 2014-02-24 16:40:01 +09:00
Koichi Akabe ca1f9855fa Use __() to show translated texts of the position picker 2014-02-24 16:39:49 +09:00
Koichi Akabe 3c6eb040f8 use double colons to show codes correctly 2014-02-24 14:28:40 +09:00
Tom Rothamel 856a99c3f2 Merge branch 'maintenance/6.17' 2014-02-23 23:52:01 -05:00
Tom Rothamel 959434f404 Safely list directories outside the Ren'Py base directory.
Directories in the projects directory might contain filenames
that aren't representable in the system encoding. We now
ignore these directories, rather than throwing an exception.
2014-02-23 23:41:17 -05:00
Tom Rothamel 435ef3f5b6 Documentation updates. 2014-02-23 22:47:37 -05:00
Tom Rothamel e5d39cf4de Make single_track and shuffle exclusive of each other.
Merge remote-tracking branch 'kyouryuukunn/musicroom' into maintenance/6.17
2014-02-23 21:57:04 -05:00
Tom Rothamel c03fa98992 Merge branch 'maintenance/6.17' 2014-02-22 22:36:03 -05:00
Tom Rothamel 195d3eb8e2 Add documentation of show layer.
Merge remote-tracking branch 'kyouryuukunn/show_layer' into maintenance/6.17
2014-02-22 22:35:26 -05:00
kyouryuukunn f6a2e7ed1f Document about show layer 2014-02-23 12:16:02 +09:00
kyouryuukunn cb3bc2341f update japanese 2014-02-22 22:02:54 -05:00
kyouryuukunn dcc38c3ab6 update japanese 2014-02-22 22:02:43 -05:00
kyouryuukunn d37188abfe Merge pull request #305 from kyouryuukunn/update_japanese
Update Japanese translation
2014-02-23 11:59:40 +09:00
kyouryuukunn b97ec70769 update japanese 2014-02-23 11:55:26 +09:00
kyouryuukunn aaec19d784 update japanese 2014-02-23 11:53:21 +09:00
Tom Rothamel c44ef66bcb Ensure the projects directory is valid before using it.
See #304.
2014-02-22 18:34:31 -05:00
Tom Rothamel 104e46bb45 Ensure the projects directory is valid before using it.
See #304.
2014-02-22 18:33:45 -05:00
kyouryuukunn 4da70a637c Change single_track and shuffle exclusive 2014-02-22 16:00:36 +09:00
Tom Rothamel e10325aa7d Write function that determines if a python expression is constant.
This will be improved as incremental screen language work
continues, but this is a start.
2014-02-22 01:18:46 -05:00
Tom Rothamel c0f4395a53 Bump version. 2014-02-21 21:56:44 -05:00
Tom Rothamel fd6f59e39a Fix typos. 2014-02-20 23:41:12 -05:00
Tom Rothamel de69ac7843 Update changelog. 2014-02-19 02:02:25 -05:00
Tom Rothamel a6174993d1 Merge pull request #297 from renpy/fix-doc
fix doc error ("width" -> "height" in ysize description)
2014-02-18 22:58:46 -05:00
Koichi Akabe d263552a79 fix doc error ("width" -> "height" in ysize description) 2014-02-18 17:15:41 +09:00
Tom Rothamel e67f671fe6 Fsdecode tail output.
This is stdout for the android tools, which is likely to be encoded
using the local encoding, at least when filenames are involved.
2014-02-17 21:29:58 -05:00
Tom Rothamel bee097f3cd Document store variables. 2014-02-16 16:06:53 -05:00
Tom Rothamel 61c2fc4e49 Revert "Return to the main menu on right click from load, save, prefs, etc."
This reverts commit 5bff9be02c.
2014-02-15 22:38:55 -05:00
Tom Rothamel 6f7398e4ae Improve prediction of side images. 2014-02-15 01:11:22 -05:00
Tom Rothamel 5f1e49978b Properly update the prediction info.
This lets us predict more than one image.
2014-02-15 00:22:59 -05:00
Tom Rothamel 564a82c187 Do not call missing_show during image prediction. 2014-02-14 23:41:00 -05:00
Tom Rothamel ea2243ea86 Predict partial image specifications.
Fixes #293.
2014-02-14 00:49:59 -05:00
Tom Rothamel 4be828ede3 A character should only stop skipping if it causes an interaction.
Fixes #294.
2014-02-13 23:08:10 -05:00
Tom Rothamel 88e14a14d8 Pass the results of a UserStatement predict to the predicition code.
Fixes #292.
2014-02-12 21:52:22 -05:00
Tom Rothamel b583d53f61 Document window auto. 2014-02-11 19:14:27 -05:00
Tom Rothamel fa79703f09 Implement window auto. 2014-02-10 23:29:21 -05:00
Tom Rothamel e122d22ef8 Add config.statement_callbacks.
These are functions that are called at the start of each statement,
with the statement name.
2014-02-10 23:24:56 -05:00
Tom Rothamel 34c070d37b Factor the window statements out into their own file, and
move the guts of _window_show and _window_hide into
functions.
2014-02-10 20:14:37 -05:00
Tom Rothamel b9c5f2f988 Rename window_during_transitions to show_empty_window.
We were already using window_during_transitions for an obsolete
function, and the preference controls all versions of this, rather
than just during transitions.
2014-02-09 21:21:31 -05:00
Tom Rothamel adb4ab80db Merge pull request #290 from vbkaisetsu/template-ja-translation
update Japanese translation of template
2014-02-09 11:12:02 -05:00
Tom Rothamel b55e36853e Update and fix documentation. 2014-02-08 18:21:10 -05:00
Koichi Akabe 46c547a9b0 update Japanese translation of template 2014-02-08 16:43:21 +09:00
Tom Rothamel 6c753a4a09 Remove window auto, adjust semantics of window during transitions.
This is separating the two functions out, since window during
transitions is useful with window show/window hide, and the
auto function should probably trigger window show/window hide.
2014-02-08 00:08:52 -05:00
kyouryuukunn 88417761ee Add Preference window during transitions 2014-02-07 23:31:08 -05:00
Tom Rothamel 5bff9be02c Return to the main menu on right click from load, save, prefs, etc.
Alternative implementation of #289.
2014-02-06 23:31:21 -05:00
Tom Rothamel de4c50bb2a Update changelog. 2014-02-05 22:16:20 -05:00
Tom Rothamel 5895fbcced The focus_mask style property can now as an argument a callable.
If the callable returns true, the displayable should be focused.
This lets us avoid an RTT.
2014-02-05 22:12:33 -05:00
Tom Rothamel 5fc7f32b5a Add new keywords to screenlang and sphinx. 2014-02-05 22:09:34 -05:00
Tom Rothamel a30500d665 Fix spanish translation. 2014-02-05 06:08:26 -05:00
Tom Rothamel 9cd9e126a2 Merge pull request #287 from javimat/master
Update Spanish translation
2014-02-04 16:56:18 -08:00
Tom Rothamel 6d7da4f882 Report an error if an imagebutton can't find its idle image. 2014-02-04 19:53:46 -05:00
Tom Rothamel bffa96a344 Use the unexpanded size of text when checking for overflows.
Fixes #286.
2014-02-03 19:49:51 -05:00
javimat 393df20e44 Update common.rpy 2014-02-03 10:09:03 +01:00
javimat 6acf2605bb Update common.rpy 2014-02-03 10:06:42 +01:00
javimat bd1524c362 Update common.rpy 2014-02-03 09:57:58 +01:00
javimat d9db6cc96a Update project.rpy 2014-02-03 09:49:55 +01:00
javimat 1f004edc6a Update distribute.rpy 2014-02-03 09:49:25 +01:00
javimat d6b9ea81de Update common.rpy 2014-02-03 09:48:55 +01:00
javimat d869f67126 Update common.rpy 2014-02-03 09:48:13 +01:00
javimat 92630baa6e Update options.rpy 2014-02-03 09:46:06 +01:00
Tom Rothamel e8adc17543 Make the fonts used by A White Tulip customizable. 2014-02-02 15:11:09 -05:00
Tom Rothamel d72a03aeb4 Add xsize, ysize, and xysize style properties.
These allow users to directly set the size of resizable
displayables.

The names are chosen so they don't conflict with height, width, and
size, which are already in use.
2014-02-01 17:33:26 -05:00
Tom Rothamel f5e75a7c4c Set the default template to english.
This fixes a bug that occurs when no template is selected.
2014-01-31 16:50:33 -05:00
Tom Rothamel 2aa92d02d3 Backup launcher styles (in Russian translation). 2014-01-31 16:37:36 -05:00
Tom Rothamel b04e511767 Fix location of logo. 2014-01-31 16:33:47 -05:00
Tom Rothamel 34616cdbd3 Fix sphinx build. 2014-01-30 22:22:09 -05:00
Tom Rothamel dfccf93175 Check for invalid characters when building distributions. 2014-01-30 22:03:26 -05:00
Tom Rothamel 34a62d74b5 Demo show layer. 2014-01-30 21:53:39 -05:00
Tom Rothamel 41c48a5941 Copy screens.rpy. 2014-01-29 22:06:44 -05:00
Tom Rothamel c4f2d2894b Allow testcases to be automated with a command line argument.
(This is to support test_all.py.)
2014-01-29 21:42:00 -05:00
Tom Rothamel fc77c0e0ec Use the nightly url for DLC, when on the nightly channel.
If we don't do this, the DLC won't be able to download, or might
be out of date.
2014-01-28 22:22:50 -05:00
Tom Rothamel 99fa4e9c15 Remove unused import. 2014-01-28 20:26:58 -05:00
Tom Rothamel 913a1078df Update copyright to 2014.
Also:

* Include the copyright in .rpy files.
* Fix missing copyrights.
* Add the BOM to .rpy/.rpym files that were missing it.
2014-01-27 22:58:15 -05:00
Tom Rothamel ed5e38727c Check BOM presence/absence. 2014-01-27 22:58:03 -05:00
Tom Rothamel 28a5d5fcf2 Check for the presence of the license as well as the copyright. 2014-01-27 22:35:07 -05:00
Tom Rothamel a96e9614c4 Update copyright scripts for new organization, 2014. 2014-01-27 22:17:46 -05:00
Tom Rothamel 598d4faea0 Add console and image load log to developer menu.
To get the console to work, changed the developer menu into a modal
screen that runs in the current context. Changed everything else to
work with this.
2014-01-27 00:19:12 -05:00
Tom Rothamel 3776ec0ef7 Bring the changelog up to date. 2014-01-26 23:09:31 -05:00
Tom Rothamel 8a2546a83c Fix problem introduced by rebase.
Since I don't know how to git.
2014-01-26 16:38:45 -05:00
Daniel Luque 566cb0f1cf Move: launcher/game/scrollbar_center.png 2014-01-26 16:36:31 -05:00
Daniel Luque 6fee9e81e9 Remove images 2014-01-26 16:36:31 -05:00
Daniel Luque 5ef6952c95 Change skins documentation. 2014-01-26 16:36:31 -05:00
Daniel Luque 366306b8cc The images has been moved to the "images".
launcher/game/background.png -->  launcher/game/images/background.png
launcher/game/checkbox_empty.png -->  launcher/game/images/checkbox_empty.png
launcher/game/checkbox_full.png -->  launcher/game/images/checkbox_full.png
launcher/game/logo.png --> launcher/game/images/logo.png
launcher/game/logo32.png -->  launcher/game/images/logo32.png
launcher/game/pattern --> launcher/game/images/pattern.png
launcher/game/vscrollbar_center.png -->  launcher/game/images/vscrollbar_center.png
launcher/game/winddow.png -->  launcher/game/images/window.png
2014-01-26 16:36:31 -05:00
Tom Rothamel 7d74ff010c Convert screens.rpy to using the style statement. 2014-01-26 12:47:19 -05:00
Tom Rothamel bb2a80f5e8 Allow the init statement to combine with any other statement.
This allows "init 1 define", "init 1 image", "init 1 style" and
other constructs to be one-liners.
2014-01-26 12:11:25 -05:00
Tom Rothamel 0c31f22fb4 Deal with set_parent. 2014-01-26 11:42:40 -05:00
Tom Rothamel fb74356541 Styles changelog. 2014-01-26 00:09:43 -05:00
Tom Rothamel ee18baed5e style.fixed and style.image should inherit from default.
Not _default.
2014-01-25 23:32:30 -05:00
Tom Rothamel 9f8b327aa8 Document new styles.
Apart from a lot of writing, this consisted of breaking the style
docs up into two files, one for the statements and python, and
a second one for the properties.
2014-01-25 23:24:38 -05:00
Tom Rothamel ba34df1a2e Add layers to appropriate MoveTransition results.
This fixes a problem that occured when a modal screen (that raised
IgnoreLayers) was placed inside a MoveTransition.
2014-01-25 00:17:17 -05:00
Tom Rothamel 35584ebcba If tkaskdir fails, explain why. 2014-01-24 23:31:36 -05:00
Tom Rothamel dedc3af9d4 Re-create .pyo files with documentation before building docs. 2014-01-23 22:46:35 -05:00
Tom Rothamel 57652ce002 Implement the "auto-forward after click" preference.
If true, a click will take Ren'Py out of auto-forward mode. The
default is false, and clicks will take Ren'Py out of auto-forward
mode.
2014-01-23 22:32:05 -05:00
Tom Rothamel 1f4f5e5030 Remove "Style Hierarchy" screen.
This doesn't work with the new style implementation, and it is
redundant to the new style inspector.
2014-01-22 22:15:47 -05:00
Tom Rothamel 0a6a43e139 Back out translation of the Style Test screen. 2014-01-22 22:06:18 -05:00
Tom Rothamel f930a2addb Merge pull request #278 from LuqueDaniel/update-es
Update Spanish translation and more
2014-01-22 18:41:27 -08:00
Tom Rothamel 77f3ba0198 Add the "show layer" statement.
This wraps the renpy.layer_at_list function, which allows one to apply
transforms to entire layers. The show layer statement currently takes
at lists and ATL.
2014-01-22 00:58:13 -05:00
Tom Rothamel 7dd98cd421 Backwards compatibility for Frame. 2014-01-21 12:28:09 -05:00
Tom Rothamel 3ebf9d4b28 Ignore layers that do not exist when clearing layers. 2014-01-21 11:56:00 -05:00
Tom Rothamel eefc1412fa Merge pull request #276 from antoinentx/patch-2
create french translation
2014-01-20 20:59:31 -08:00
Tom Rothamel a0f38b9442 Ignore traceback.txt and errors.txt files when distributing Ren'Py. 2014-01-20 23:50:28 -05:00
Tom Rothamel 123e96b872 Detect the names of templates to compile.
Since we have so many of them. World domination - achieved.
2014-01-20 23:43:27 -05:00
Daniel Luque 14672d6f9b Update translation common.rpy 2014-01-20 13:54:49 +01:00
Daniel Luque ccc950a703 Fixed some errors caused by commit aee59b6 2014-01-20 13:10:04 +01:00
Daniel Luque aee59b6a05 More, Make translatable developer.rpym 2014-01-20 13:03:55 +01:00
Daniel Luque 1a5345f089 Make translatable "Developer Menu" title
Make translatable renpy/common/_developer/developer.rpym line 44
2014-01-20 12:48:24 +01:00
Daniel Luque 6ee705dd21 Update translation template spanish 2014-01-20 12:35:32 +01:00
Daniel Luque fe197216b9 Update translation common.rpy 2014-01-20 12:34:56 +01:00
Daniel Luque 462730fcae Update translation updater.rpy 2014-01-20 11:53:25 +01:00
Daniel Luque 972da30f8c Update translation project.rpy 2014-01-20 11:37:53 +01:00
Daniel Luque 5f07ce8c32 Update translation android.rpy 2014-01-20 09:49:58 +01:00
Tom Rothamel 1940c98e67 Syntax-hilight style as a keyword. 2014-01-19 23:41:34 -05:00
Tom Rothamel c1f8a23f17 Add the android_build subcommand to the launcher.
This provides a way of invoking the new Android build process from
the launcher.
2014-01-19 23:29:32 -05:00
Tom Rothamel 7da459ae63 Make the nightly channel available through the updater. 2014-01-19 22:29:32 -05:00
Tom Rothamel 9125823bc9 Properly handle non-acceptance of Android terms and conditions. 2014-01-19 21:24:24 -05:00
Tom Rothamel 188a0bac0a Fix re-launching of Ren'Py. 2014-01-19 21:24:02 -05:00
Tom Rothamel 7d33f1663c Use the DLC system to download RAPT. 2014-01-19 21:13:47 -05:00
Tom Rothamel d3c075e11f Update .gitignore. 2014-01-19 00:51:16 -05:00
Tom Rothamel 2c984ed8f5 Include the common directory in the android distribution.
This prevents us from having to include common/ twice,
once in Ren'Py and once in RAPT.
2014-01-19 00:26:58 -05:00
Tom Rothamel 7f3563bcb0 Do not use "experimental" as a distribution name.
We use it for a symlink, and using it twice led to problems.
2014-01-19 00:25:37 -05:00
Tom Rothamel a6ab0e84e6 Fix SDK writing. 2014-01-18 18:32:00 -05:00
Tom Rothamel d40dc4acc6 Build RAPT before distribute. Supply path to Ren'Py to RAPT build.
The former is in preparation to distributing RAPT as part of Ren'Py.

The latter is so that we can build RAPT as part of a nightly build.
2014-01-18 18:15:24 -05:00
Tom Rothamel d9d8eb4175 Report errors when launching a waited-on project fails. 2014-01-17 23:20:33 -05:00
Tom Rothamel 18df24da42 Fix vertical scrollbar in error messages. 2014-01-17 23:03:46 -05:00
Tom Rothamel 99f4b021d3 Simple expressions can now include operators. 2014-01-17 00:02:50 -05:00
Tom Rothamel 19bc668e0a Convert to using the style statement. 2014-01-16 23:10:57 -05:00
Tom Rothamel fe0a6a8e47 Correctly parse multi-line property assignments. 2014-01-16 23:10:39 -05:00
Tom Rothamel d8c51b32b2 Error out if a style is too complex.
A style is too complex if inheritance goes more than 100 layers
deep. The most common reason for this is likely that there's a
loop in the style inheritance graph.
2014-01-15 23:51:14 -05:00
Tom Rothamel 92b1a67e4a Convert 00style.rpy to using style statements.
As part of this, move the list styles into the developer.rpym file.
2014-01-15 23:47:08 -05:00
Tom Rothamel 5a41588969 Initialize the root of the style hierarchy. 2014-01-15 23:46:16 -05:00
Tom Rothamel 749236868a Allow style names to be keywords.
We have some style names, like transform, that correspond to
keywords.
2014-01-15 23:45:20 -05:00
Tom Rothamel c741f0cded Use the style statement to define styles. 2014-01-15 22:06:21 -05:00
Tom Rothamel 638ecbbd2a Add support for style.create. 2014-01-15 22:06:11 -05:00
Tom Rothamel 697664de8f Use the style statement to define styles in _errorhandling.rpym. 2014-01-14 18:32:24 -05:00
antoinentx b66379b203 Create screens.rpy 2014-01-14 19:22:29 +01:00
antoinentx 92492d1198 Create common.rpy 2014-01-14 19:22:08 +01:00
antoinentx a325ea8bff Create script.rpy 2014-01-14 19:21:35 +01:00
antoinentx 4b3627a1e3 Create screens.rpy 2014-01-14 19:20:52 +01:00
antoinentx 44ea36b475 Create options.rpy 2014-01-14 19:19:38 +01:00
antoinentx 1348a53fa8 Create README.html 2014-01-14 19:18:50 +01:00
antoinentx c34c8ebd3c Create project.json 2014-01-14 19:18:20 +01:00
Tom Rothamel e2650d11dd Deal with .take() and .clear() 2014-01-14 01:04:49 -05:00
Tom Rothamel a73abc82e3 Script to turn python styles into style statements. 2014-01-14 00:54:30 -05:00
Tom Rothamel d08933ce88 Fixes to newer code to work when building RAPT. 2014-01-12 23:20:10 -05:00
Tom Rothamel 09ca171e81 Log more progress information to android.txt. 2014-01-12 23:18:02 -05:00
Tom Rothamel 7affd8cfbb Deal with unicode TODOS. 2014-01-12 20:30:02 -05:00
Tom Rothamel 73763275fb Fix termination. 2014-01-12 19:39:28 -05:00
Tom Rothamel 9d93ef10b5 Store say_attributes as part of the context.
A problem was reported that Ren'Py would crash on a shift+R
reload. It turned out that while displaying the reload message,
Ren'Py would use the attributes from the previous say statement.

This fixes that.
2014-01-12 14:57:26 -05:00
antoinentx 6fd7fd89e5 Create updater.rpy 2014-01-12 14:35:29 +01:00
antoinentx 3fa1dbe10e Create translations.rpy 2014-01-12 14:34:46 +01:00
antoinentx f52735ef53 Create style.rpy 2014-01-12 14:34:22 +01:00
antoinentx 50988a167b Create project.rpy 2014-01-12 14:33:55 +01:00
antoinentx 60232028c2 Create preferences.rpy 2014-01-12 14:33:33 +01:00
antoinentx f1384edaf5 Create new_project.rpy 2014-01-12 14:33:06 +01:00
antoinentx bed8233afe Create navigation.rpy 2014-01-12 14:32:40 +01:00
antoinentx a1fd8c6d1c Create interface.rpy 2014-01-12 14:32:00 +01:00
antoinentx 8868d6c99a Create front_page.rpy 2014-01-12 14:31:38 +01:00
antoinentx 293b191739 Create editor.rpy 2014-01-12 14:30:49 +01:00
antoinentx ce4ebffd69 Create distribute_gui.rpy 2014-01-12 14:30:13 +01:00
antoinentx b08a0daa10 Create distribute.rpy 2014-01-12 14:29:36 +01:00
antoinentx 3bd0557948 Create common.rpy 2014-01-12 14:29:11 +01:00
antoinentx 5ceb663fb3 Create choose_theme.rpy 2014-01-12 14:28:26 +01:00
antoinentx 8c684678c9 Create android.rpy 2014-01-12 14:27:54 +01:00
antoinentx 8749f3d178 Create add_file.rpy 2014-01-12 14:27:21 +01:00
antoinentx a001313516 create french translation 2014-01-12 14:20:45 +01:00
Tom Rothamel 4fc8554384 Tweak sunflower-slow-drag.ogg.
* Trim silence at the start and end.
* Compress the volume, to make the quiet parts a little louder, and vice versa.
2014-01-11 15:27:34 -05:00
Tom Rothamel 91f0b8452a Report missing _renpy, and offer a suggestion on what to do about it. 2014-01-11 11:59:42 -05:00
Tom Rothamel d1d71b8065 Remove old style code. 2014-01-11 11:49:04 -05:00
Tom Rothamel 96929bce42 Return an error code to the os when an exception occurs. 2014-01-11 11:39:18 -05:00
Tom Rothamel 3c38654a8b Remove obsolete module version checking code. 2014-01-11 11:28:51 -05:00
Tom Rothamel baeb458879 Merge pull request #275 from tlm-2501/master
Fix some comments in options.rpy, and a typo in the docs.
2014-01-10 21:00:09 -08:00
Tom Rothamel 7ecb7a36a0 Deal with a rollback after retain_after_load.
It's not enough to simply discard the rollback information on
retain_after_load, we need to retain it and roll it back when
the next rollback occurs.
2014-01-10 23:51:29 -05:00
Tom Rothamel a688687736 Check in images used in testcases. 2014-01-09 23:49:53 -05:00
Tom Rothamel 32c904935b Check in generated docs. 2014-01-09 23:49:33 -05:00
Tom Rothamel 1484505bd4 Document renpy.retain_after_load(). 2014-01-09 23:48:57 -05:00
Tom Rothamel cba6a15dda Do not strip docstrings in run.sh. 2014-01-09 23:47:50 -05:00
Tom Rothamel c4cc830b7a Implement renpy.retain_after_load()
This does not rollback data that is changed between the current
statement and the next checkpoint. The main use case is to be able
to save while a screen is displayed using call screen.

For example, a user can be assigning points to a character in a
screen, save, load, and have the same points assigned.
2014-01-09 22:45:45 -05:00
tlm-2501 e83ec927de Fix another typo in android-packaging.rst
APs -> APKs.
2014-01-09 12:59:34 +03:00
tlm-2501 caa9ebc25c Fix typo in docs (android-packaging.rst)
Changed "android.keyring" to "android.keystore" to represent the valid filename.
2014-01-09 12:40:37 +03:00
tlm-2501 9175fad5c1 theme.roundrect is no logner the only theme. Fixed options.rpy accordingly. 2014-01-09 11:49:01 +04:00
tlm-2501 13d8861459 Fixed... another typo in options.rpy. Whoops. 2014-01-09 11:47:52 +04:00
tlm-2501 7e7525e3d3 Merge branch 'master' of https://github.com/tlm-2501/renpy 2014-01-09 11:47:28 +04:00
tlm-2501 6e789307ef Fixed typos in options.rpy of the English template. 2014-01-09 11:46:57 +04:00
tlm-2501 ec8308b82c Fixed typo in options.rpy of the English template. 2014-01-09 11:44:52 +04:00
Tom Rothamel f5efeec320 Merge pull request #272 from tlm-2501/master
Russian translation.
2014-01-08 19:46:39 -08:00
Tom Rothamel 649fda046c Rename place_images -> get_image_bounds, add testcase. 2014-01-08 22:45:42 -05:00
Tom Rothamel dcd829931c Remove the shift+Y binding to dump styles.
It wasn't used all that much, and it's made redundant by the new
style inspector.
2014-01-08 22:22:37 -05:00
Tom Rothamel d63f5ba134 Run functional testcases w/o human intervention. 2014-01-08 00:54:04 -05:00
Tom Rothamel 647c1a026b Fix indexed styles in lint. 2014-01-07 23:54:17 -05:00
Tom Rothamel 3ea8d6a368 Better error handling for style properties.
When a style property is invalid, we report the name of the
style and the name of the property.
2014-01-07 23:36:36 -05:00
Tom Rothamel 625a6afb1f Fix lint to work with the new style system. 2014-01-07 23:36:11 -05:00
Tom Rothamel 9d8ccec0ee Ignore spurious PyDev warnings. 2014-01-07 21:58:42 -05:00
Tom Rothamel 32554bf5e6 Merge pull request #262 from vbkaisetsu/fix-doc
fix line breaking
2014-01-06 18:52:35 -08:00
Tom Rothamel a03c4d6f39 Merge pull request #265 from CensoredUsername/master
added extra arguments for the screen to ShowMenu()
2014-01-06 18:52:27 -08:00
Tom Rothamel eeefba5a45 Save persistent data to disk before we suspend on android.
This is needed because we might be killed by suspend. If we're killed,
we'll reload the game, but persistent data (incl preferences) will be
lost - unless we save it.
2014-01-06 21:50:49 -05:00
tlm-2501 22d87d62d6 Added a Russian template for a new game. 2014-01-07 05:31:42 +04:00
tlm-2501 8a1d6cd934 Added Russian translation for the launcher. 2014-01-07 04:27:17 +04:00
Tom Rothamel 5769fbfb5a Fix get_text_style.
It didn't handle default correctly.
2014-01-05 23:16:24 -05:00
Tom Rothamel 6912acaa3d Quote newlines in Text.__unicode__. 2014-01-05 22:42:40 -05:00
Tom Rothamel 1df3f281fd Add the ability to inspect a style and display the properties
that contribute to the displayable.
2014-01-05 22:33:49 -05:00
Tom Rothamel f1c0df3156 Allow viewports shrink to fit their content.
This only occurs when the viewports have xfill or yfill set
to False.
2014-01-05 20:21:02 -05:00
Tom Rothamel 6c5c1ff1bd Hide the Fixed immediately inside a screen.
It's not that interesting, since it's always there and never has
properties.
2014-01-05 00:54:07 -05:00
Tom Rothamel e37c0ac09b Use slightly nicer names for screens. 2014-01-05 00:24:52 -05:00
Tom Rothamel c0572eb996 Redesign style inspector into displayable inspector. 2014-01-04 23:41:39 -05:00
Tom Rothamel 1b745a9c21 Split _developer.rpym into multiple modules. 2014-01-04 22:37:54 -05:00
Tom Rothamel cc855e3573 Merge pull request #269 from vbkaisetsu/default-env
Please set "cython" to RENPY_CYTHON
2014-01-04 16:35:20 -08:00
Tom Rothamel 7089bb2d95 Merge pull request #270 from LuqueDaniel/update-es
Update Spanish translation
2014-01-04 16:33:50 -08:00
Koichi Akabe 256d33e20f set "cython" as a default variable of RENPY_CYTHON 2014-01-04 18:56:11 +09:00
Daniel Luque d6b66629e0 Replace string
Replace: "Pantalla guardada como" --> "Captura de pantalla guardada como"
2014-01-04 07:01:11 +01:00
Daniel Luque d813a1b58f Adds new strings
Add new strings related to commit 7f6c8ef
2014-01-04 06:48:21 +01:00
Tom Rothamel 7f6c8efb57 Display blurb each time we launch a game.
For now, these blurbs teach users about keyboard features, like
shift+R and shift+O.
2014-01-03 23:41:22 -05:00
Tom Rothamel af5420c949 Add Style.inspect()
This is a method that, when called on a style, returns a list giving,
for each parent of the style:

* The name of the parent.
* A dictionary that, for each property that affects the inspected
  style. gives the property name and its value.
2014-01-03 01:09:31 -05:00
Tom Rothamel 5b28bc1bcd Generate information used by style inspection. 2014-01-03 01:09:00 -05:00
Tom Rothamel 42d5d62575 Add a variant clause to the style statement.
This lets us use different styles for different variants. For example,
we can use a style for touch devices that increases the size of
buttons, so the player can touch them.
2014-01-02 01:27:35 -05:00
Tom Rothamel 525657843c renpy.variants can check for a list of variants. 2014-01-02 01:27:16 -05:00
Tom Rothamel c4b15d9c84 Improvements to the style statment.
* The take clause takes properties from another style.
* The clear clause deletes all properties.
* The del clause deletes one property.
2014-01-02 00:42:27 -05:00
Tom Rothamel 099f3d5cc8 Make the style statement more renpythonic.
It can now be written on a single line, or on multiple lines
with a block of property/value pairs.
2014-01-01 13:50:51 -05:00
Tom Rothamel 07b4407f03 Export sets of style property names, so we can test against
them.
2014-01-01 11:23:36 -05:00
Tom Rothamel e8adb1b30b style statement: More checking. 2014-01-01 11:23:24 -05:00
Tom Rothamel 8995873089 Initial implementation of the style statement.
This is a statement that adds syntax (in the usual Ren'Py form of word
<expr>) for defining styles.

Happy new year.
2014-01-01 00:44:53 -05:00
Tom Rothamel cda0083a3e Add renpy.styleclass to builds. 2013-12-31 23:42:43 -05:00
Tom Rothamel e32eae2946 Ensure the output of generate_style is deterministic.
This prevents us from regenerating the files, and ensures that
ccache always gets the same file.
2013-12-31 23:41:46 -05:00
Tom Rothamel b6a1c28bfc Generate code in binary mode. 2013-12-31 22:24:14 -05:00
Tom Rothamel 457673a3bb Create the gen directory if it doesn't exist. 2013-12-31 22:00:46 -05:00
Tom Rothamel 10f2620590 Generate the styles files upon checkout. 2013-12-31 21:43:50 -05:00
Tom Rothamel 9d9c924d82 Update README.rst. 2013-12-31 00:26:28 -05:00
Tom Rothamel 23a7f8d00d Merge branch 'master' of github.com:paulmorio/renpy 2013-12-30 23:34:55 -05:00
Tom Rothamel 259c010d4e Fix get_text_style. 2013-12-30 23:25:58 -05:00
Tom Rothamel b728d85b00 Use RENPY_CC and RENPY_LD environment variables during build.
One use of this might be to enable ccache if it's known to
be available.
2013-12-30 21:50:27 -05:00
Tom Rothamel bf1e3af046 Fixes to styles.
* Only set the style name if it's not already set. This is for
  compatibility with the way the old style code did it.

* Do not auto-create styles beginning with _. This prevents us
  from accidentally creating a style that inherits from a
  non-underscore style.
2013-12-29 23:00:40 -05:00
Tom Rothamel bfb8bbfc29 Allow styles to be pickled. 2013-12-29 22:58:29 -05:00
Tom Rothamel 259dd579eb Ignore missing music after rollback.
Not style-related, but this was needed to load old saves so I could
test style loading.
2013-12-29 20:54:01 -05:00
Tom Rothamel 8554a64c8b More style improvmements:
* activate_sound and hover_sound are now their own style properties,
  and work again.
* Other than that, we ignore the various selected_activate and activate_
  style properties.
2013-12-29 14:48:16 -05:00
Tom Rothamel 36c8ed2648 Many minor fixes to the new style system.
Together, these are enough to get Ren'Py starting up.
2013-12-29 02:00:14 -05:00
Tom Rothamel a02ee4cef0 Replace the old style system with the new style system. 2013-12-29 00:07:41 -05:00
Tom Rothamel 5e337bb971 Add various style functions used by other modules.
These haven't been tested - I'm checking them in so I can rename things.
2013-12-28 22:22:45 -05:00
Tom Rothamel 4e2916c3f0 Implement style property retrieval with inheritance. 2013-12-27 23:19:35 -05:00
Tom Rothamel c4ebac7fcf Build all styles. 2013-12-27 23:04:46 -05:00
Tom Rothamel 01899980a5 Add some style unit tests. 2013-12-26 23:48:30 -05:00
Tom Rothamel 11c4f64f9d Implement style naming.
This includes the StyleManager class and style indexing.
2013-12-26 23:47:46 -05:00
M v H 0334c56441 added extra arguments for the screen to ShowMenu() 2013-12-27 03:22:31 +01:00
Tom Rothamel f63731d18d Implement Style.set_prefix. 2013-12-26 01:18:17 -05:00
Tom Rothamel 33c07fc986 Add various fields to the pxd. 2013-12-26 01:17:57 -05:00
Tom Rothamel 7a398bc847 Break styleaccel up into two files.
The new styleclass.pyx file contains the Style class. We compile it
separately since it's huge, and changes rarely.
2013-12-25 23:56:32 -05:00
Tom Rothamel e9dbadab56 Build styles and retrive attributes from a single style. 2013-12-25 00:16:11 -05:00
Tom Rothamel 622bfa44fb Start generating the Style class.
The style class has properties supporting set and delete for each
prefixed style property.
2013-12-24 16:35:25 -05:00
Tom Rothamel 73cfd1b29c Fix renpy.import_all()
Doing:

    import renpy; renpy.import_all()

now works, so we can use it in test code.
2013-12-24 16:16:41 -05:00
Tom Rothamel eae987f665 Generate style property functions.
These are functions that take the value being assigned to a style,
process it if necessary, and assign it to each style's cache.
2013-12-24 01:02:47 -05:00
Tom Rothamel bcd95d937c Add style properties and synthetic properties to generate_styles. 2013-12-23 22:24:39 -05:00
Tom Rothamel 87fea5b4c7 Start work on style generation code.
First off, we create a list of prefixes and the order in which
they are stored.
2013-12-23 22:02:03 -05:00
Koichi Akabe ee29f1c2c0 fix typo 2013-12-23 14:31:25 +09:00
Tom Rothamel 995d483072 Add renpy.place_image.
This returns the bounding box containing an image that's currently
being shown.

Fixes #255, or at least the underlying request.
2013-12-22 23:00:40 -05:00
Tom Rothamel 5a209b0384 Add Preferences("display", "any window").
This is selected when in any windowed mode, and changes back to the previous
window size.
2013-12-21 12:27:40 -05:00
Tom Rothamel db6911da6d Change the tutorial music to Sunflower Slow Drag.
This was the music used (as a midi file) for the very oldest versions
of the Ren'Py.

We use a 1994 recording by the US Marine Band, taken from
Wikipedia. It's public domain due to age (of the original) and due to
being the work of the US Government (for the recording).
2013-12-21 11:10:37 -05:00
Tom Rothamel 2e2d29b0f5 Do not include binary files in the source distro.
Fixes #256.
2013-12-20 23:59:23 -05:00
Koichi Akabe 77fc911f7e fix line breaking 2013-12-20 14:44:42 +09:00
Tom Rothamel a4f659387f QuickSave shouldn't take a screenshot while in a menu.
Fixes #251.
2013-12-19 23:12:57 -05:00
Tom Rothamel 33a452dab6 Merge pull request #261 from vbkaisetsu/fix-doc
fix typos
2013-12-19 20:01:19 -08:00
Koichi Akabe d9b4d916c8 fix typos 2013-12-20 12:55:21 +09:00
Tom Rothamel 599cc25f7c Fix documentation.
Thanks to Koichi Akabe for the proofreading.
2013-12-18 23:27:12 -05:00
Tom Rothamel 4054cd1c72 Add the pixel_width property to input.
This allows one to limit the width of an input field to a certain
number of pixels.

Fixes #254.
2013-12-18 23:14:22 -05:00
Tom Rothamel eb1f96ad20 Merge pull request #259 from kyouryuukunn/fix_doc
fix typo
2013-12-16 19:44:41 -08:00
kyouryuukunn c1d1a766c7 fix typo 2013-12-16 18:51:11 +09:00
Tom Rothamel 2cb7632e96 Fix sense of environment-encoding test. 2013-12-16 01:35:12 -05:00
Tom Rothamel e14464081e Report NO_RAPT before NO_JDK.
On Windows, RAPT is responsible for detecting the JDK. If RAPT is
missing, the JDK will also be reported missing - even if it's
installed.

Changing the reporting order makes this less confusing.
2013-12-15 22:02:20 -05:00
Tom Rothamel 49fa613b48 Fix typo that broke Android.
We copied script_version.rpy onto script_version.rpyc, which
made things fail to start on Android.
2013-12-15 20:22:17 -05:00
Tom Rothamel c7dca40479 Document alternate. 2013-12-14 14:51:33 -05:00
Tom Rothamel d9d7801a50 When ignoring a touch, move the "mouse" offscreen.
This will cause any focused button to lose focus until the user
touches the screen again.
2013-12-14 02:23:39 -05:00
Tom Rothamel 44edd1c723 Invoke the alternate action on longpress. 2013-12-14 00:48:44 -05:00
Tom Rothamel a46ddc9e55 Add an alternate action to Button.
On devices that support it, an alternate action is triggered by
right-click.
2013-12-13 00:27:58 -05:00
Tom Rothamel c12560fed3 Merge pull request #257 from LuqueDaniel/fix-rmtree
Fix delete the tmp directory
2013-12-12 06:08:10 -08:00
Daniel Luque f7dbfeec3f Fix delete the tmp directory 2013-12-12 12:33:00 +01:00
Tom Rothamel 2b44ffe0e2 Add FileCurrentScreenshot.
This is a displayable that accesses the screenshot stored by
FileTakeScreenshot or ShowMenu.

Fixes #253.
2013-12-11 23:09:38 -05:00
Tom Rothamel 643fe8928b More documentation and flagging as undocumented. 2013-12-10 19:04:25 -05:00
Tom Rothamel a6f9d787ef Document NoRollback as class, not function. 2013-12-09 23:17:54 -05:00
Tom Rothamel cf993a71da Document renpy.map_event. 2013-12-09 23:07:37 -05:00
Tom Rothamel 8f9ecee00a Ignore errors in OpenDirectory. 2013-12-09 22:23:40 -05:00
Tom Rothamel 8ffe6eaad4 Document NoRollback. 2013-12-09 22:16:16 -05:00
Tom Rothamel 3256bd10b7 Remove renpy.toggle_music.
Fixes #252.
2013-12-08 11:42:55 -05:00
Tom Rothamel 2b5bf3055e Fix bug where Reply would not properly evaluate locked=None. 2013-12-07 23:55:31 -05:00
Tom Rothamel 51743d03e6 Check in inc/disp_grid. 2013-12-07 23:54:41 -05:00
Tom Rothamel 50fdc88754 Document Grid. 2013-12-07 16:38:21 -05:00
Tom Rothamel f04f3e7961 Ensure that all generated documentation is included. 2013-12-06 23:23:56 -05:00
Tom Rothamel d38e96dfac Check documentation for unused includes. 2013-12-06 21:14:03 -05:00
Tom Rothamel d09f5764bd Documentation. 2013-12-06 20:40:48 -05:00
Tom Rothamel 608a55b942 Allow Ren'Py to compile with freetype 2.5.1.
Fixes #250.
2013-12-05 22:41:30 -05:00
Tom Rothamel 0141ef770e Change list_saved_games as well.
Thanks, zorexx.
2013-12-04 22:50:51 -05:00
Tom Rothamel d936a9a28b scan_saved_game should use _save_name, not _extra_info. 2013-12-04 11:24:28 -05:00
Tom Rothamel bc941d4e7a Link variables and classes in the reserved names list. 2013-12-03 20:31:06 -05:00
Tom Rothamel a777919dcf Adjust how default_afm_enable works.
Previously, it set afm_enable on every startup. Now when afm_enable
is not None, afm_enable is persisted.
2013-12-02 21:39:36 -05:00
Tom Rothamel 73c9479474 Default preferences.mouse_move to enabled.
If a creator decides to use MouseMove, it should work by default.
2013-12-01 19:22:15 -05:00
Tom Rothamel 179af6dffb Simplify the actions so there's just MouseMove. 2013-12-01 19:21:49 -05:00
Tom Rothamel 8cab84384b Do not block during mouse moves. 2013-12-01 19:18:19 -05:00
Tom Rothamel 92e0e32c83 Merge pull request #233 from kyouryuukunn/set_mouse_pos
Functions and actions to set the mouse position.
2013-12-01 13:44:43 -08:00
Tom Rothamel 0f73bda3a5 Fix distribution script in case where we're at a tag.
When we're exactly at a base revision, the description relative to the
tag is missing some components.
2013-11-30 12:28:30 -05:00
Tom Rothamel 1a19c95b60 Bump version to 6.17.0. 2013-11-30 12:13:15 -05:00
Tom Rothamel 2269a3a70c Remove unneeded warnings. 2013-11-29 16:19:09 -05:00
Tom Rothamel afa4d561c6 Bump version. 2013-11-29 15:45:31 -05:00
Tom Rothamel b0524459b6 Generate script_version.rpy. 2013-11-29 15:43:05 -05:00
Tom Rothamel 5142810101 Open the android.txt log file in an editor when an Android build fails. 2013-11-28 10:04:17 -05:00
Tom Rothamel 365544d62f Classify the new Android files. 2013-11-28 00:29:34 -05:00
Tom Rothamel 3e77dafbc7 Document the image files used in Android packaging. 2013-11-28 00:26:42 -05:00
Tom Rothamel ec45a88c61 Only write documentation if changed.
This might lead to a slight speedup in sphinx, which seems to cache
unchanged files.
2013-11-25 22:32:56 -05:00
Tom Rothamel 9c6b3ca4d0 Add menu docs. 2013-11-25 22:32:49 -05:00
Tom Rothamel d4eefdc3ab Document renpy.display_menu as a statement equivalent. 2013-11-25 22:24:30 -05:00
Tom Rothamel 2771c25f37 Clean up unused textures.
This limits how much texture memory Ren'Py can use. (Previously,
texture memory was limited, but to an impractically large size.)
2013-11-24 20:33:51 -05:00
Tom Rothamel 46137dd7cf Use a set of texture numbers, rather than a list.
This makes it easier to deallocate textures, an eventual goal.
2013-11-23 18:20:04 -05:00
Tom Rothamel 006efeb15f Document renpy.transition. 2013-11-23 00:19:40 -05:00
Tom Rothamel 3b18174c8c Fix typo. 2013-11-21 21:54:00 -05:00
Tom Rothamel e50f3147a9 Bump version to 6.16.2. 2013-11-21 21:38:08 -05:00
Tom Rothamel 145b33bd3d Update changelog for 6.16.2. 2013-11-21 21:30:40 -05:00
Tom Rothamel edc5b84082 Merge pull request #248 from javimat/master
Fixed pseudo-typo in Spanish options.rpy
2013-11-21 18:16:01 -08:00
javimat d99c52614c Spanish translation of the comments in screens.rpy 2013-11-21 17:03:41 +01:00
javimat 39e626cca3 Fix pseudo-typo options.rpy
The new Spanish grammar (2009-2011) doesn't allows a tilde in the adverb 'solo'.
2013-11-21 15:38:35 +01:00
javimat cf848e8d2f Merge pull request #2 from renpy/master
updating my fork
2013-11-21 06:29:58 -08:00
Tom Rothamel 0a6f6ae8d3 Merge pull request #247 from LuqueDaniel/master
Update Spanish translation.
2013-11-21 06:04:02 -08:00
Daniel Luque fde580d67d Update translation: templates/spanish/README.html. 2013-11-21 13:37:20 +01:00
Daniel Luque dde4c3fee3 Now templates/spanish/README.html uses utf-8.
Add label meta charset with utf-8.

Replaces "&oacute;" --> "ó"
Replaces "&aacute;" --> "á"
Replaces "&uacute;" --> "ú"
Replaces "&iacute;" --> "í"
2013-11-21 13:21:43 +01:00
Daniel Luque 461d1a2ef5 Fix typo. 2013-11-21 12:52:35 +01:00
Tom Rothamel 28ccb37b58 Merge pull request #245 from kyouryuukunn/fix_document
fix doc
2013-11-20 21:02:30 -08:00
kyouryuukunn e36908d9e5 fix doc 2013-11-21 13:58:10 +09:00
Tom Rothamel 63c94e7987 Allow interface.error() to work when label=None.
Fixes #230.
2013-11-20 23:47:32 -05:00
Tom Rothamel 41767642f4 Fix a weird case in parse error handling. 2013-11-20 23:31:50 -05:00
Tom Rothamel e33987183a Fix various minor problems with the quickstart doc.
Fixes #225.
2013-11-20 23:28:36 -05:00
Tom Rothamel 32c4029b4b Merge pull request #244 from javimat/master
Translate comments in Spanish template (and some typos)
2013-11-20 18:10:50 -08:00
javimat fec8125ae3 Fix Spanish comments on options.rpy 2013-11-21 02:19:16 +01:00
javimat c368a70d0b Translate comments on options.rpy 2013-11-21 02:14:40 +01:00
javimat 70a3a3c454 Fix typo 2013-11-21 01:14:02 +01:00
javimat 17d4933ff6 Translate comments on script.rpy 2013-11-21 01:08:24 +01:00
javimat 774cb588d1 Update screens.rpy 2013-11-21 01:04:50 +01:00
javimat 1e68f0e583 Fix typo: renpy.music.register_channel 2013-11-21 01:00:49 +01:00
javimat e911f5a2d0 More translation of the comments in options.rpy 2013-11-21 00:49:29 +01:00
javimat abd473a384 Traduciendo options.rpy 2013-11-21 00:09:34 +01:00
javimat 43143e69eb Update screens.rpy 2013-11-20 23:42:03 +01:00
javimat 43f6c19b1e Merge pull request #1 from renpy/master
Updating my fork
2013-11-20 14:35:26 -08:00
javimat 2e97d84c5b Update screens.rpy 2013-11-20 19:04:11 +01:00
javimat 6132dde743 Update options.rpy 2013-11-20 19:03:24 +01:00
javimat 613f7c0511 Update options.rpy 2013-11-20 18:53:52 +01:00
javimat 572c829179 Using PROJECT_NAME
Changed:
config.window_title = u"PROJECT_NAME"
config.name = "PROJECT_NAME"
in lines 38 and 45
2013-11-20 11:03:36 +01:00
javimat 533b969d5c Using PROJECT_NAME
Changed:
config.window_title = u"PROJECT_NAME"
config.name = "PROJECT_NAME"
in lines 26 and 30
2013-11-20 11:01:26 +01:00
javimat 177b0c0bde config.name = "PROJECT_NAME"
Changed:
config.window_title = u"PROJECT_NAME"
config.name = "PROJECT_NAME"
in lines 26 and 30
2013-11-20 10:59:22 +01:00
Tom Rothamel dde25cfcc7 Fix typo. 2013-11-19 23:13:37 -05:00
Daniel Luque 85e86fe406 Merge pull request #242 from LuqueDaniel/update-sp-translation
Update Spanish translation.
2013-11-19 05:31:43 -08:00
Daniel Luque abaf4056dd Replaced 'Abrir' and 'Grabar'. I think it's better to use 'Cargar' and 'Guardar 2013-11-19 14:19:45 +01:00
Daniel Luque 32a0e92b69 Replaced 'incluye' -> 'incluir': launcher/game/tl/spanish/preferences.rpy 2013-11-19 13:55:28 +01:00
Tom Rothamel 7d4a1d7532 Merge pull request #241 from javimat/patch-1
Update updater.rpy
2013-11-18 08:40:32 -08:00
javimat 9031bf8100 Update updater.rpy
Two typos corrected.
2013-11-18 17:39:10 +01:00
Tom Rothamel 8c4b21ad62 Merge pull request #239 from javimat/patch-1
Update distribute.rpy
2013-11-18 08:01:37 -08:00
Tom Rothamel 8e21344356 Merge pull request #240 from vbkaisetsu/launcher-ja
update Japanese translation of launcher
2013-11-18 08:01:22 -08:00
javimat b3620191d8 Update distribute.rpy 2013-11-18 13:14:42 +01:00
javimat 8ecdef81c9 Update distribute.rpy 2013-11-18 12:20:21 +01:00
Tom Rothamel 43db399352 Merge pull request #237 from LuqueDaniel/translation-no-jdk
Added Spanish translation.
2013-11-17 06:07:19 -08:00
Daniel Luque 798dd075ba Added translation for: launcher/game/android.rpy:13 2013-11-17 14:12:51 +01:00
Daniel Luque 6794e5fa36 Updated line number: launcher/game/tl/spanish/android.rpy 2013-11-17 14:01:26 +01:00
Koichi Akabe 799716565c update Japanese translation of launcher 2013-11-17 11:22:45 +09:00
Tom Rothamel de15d2045f Merge pull request #226 from javimat/master
Spanish template
2013-11-16 17:37:13 -08:00
Tom Rothamel 219767251c Merge pull request #227 from LuqueDaniel/master
Ren'Py Launcher translated into Spanish, based on Japanese translation.
2013-11-16 17:29:59 -08:00
Tom Rothamel 5272af0b06 Require a 32-bit JDK on windows. Warn the creator if it doesn't exist. 2013-11-16 19:40:15 -05:00
Tom Rothamel 2325691fcb Fix newest_slot when regexp=None.
Forgot to check for this case.
2013-11-16 00:43:47 -05:00
Tom Rothamel 2f072f4a26 Save improvements.
* Do not cycle saves if the user says no to quicksave.
* Rescan immediately after a save.
* Ensure scan_saved_game always returns a valid result.

Fixes #236, hopefully.
2013-11-16 00:40:42 -05:00
kyouryuukunn e57842386c fix doc 2013-11-14 14:37:33 +09:00
Tom Rothamel 09d682cd23 Merge pull request #229 from kyouryuukunn/get_mouse_pos
add renpy.get_mouse_pos()
2013-11-13 20:11:33 -08:00
morio b03f96a756 Fix for smaller issues, will work on second major issue soon 2013-11-13 23:29:13 +00:00
kyouryuukunn 4d553c9db6 add MouseMove and MouseJump action 2013-11-13 18:58:00 +09:00
kyouryuukunn 61f09261d4 add renpy.set_mouse_pos() 2013-11-13 18:11:34 +09:00
Tom Rothamel b38551eef8 Fix fast skipping. 2013-11-12 18:49:31 -05:00
kyouryuukunn 79cf7df614 add renpy.get_mouse_pos() 2013-11-13 02:15:25 +09:00
Daniel Luque e2eecee1d8 Added translation for game/front_page.rpy:122 2013-11-12 13:11:37 +01:00
Daniel Luque 2d51144c43 Added translation for game/preferences.rpy:146 2013-11-12 13:08:19 +01:00
Daniel Luque d4565981b1 Fix typo /launcher/game/tl/spanish/updater.rpy 2013-11-12 12:55:13 +01:00
Daniel Luque e0ffeeea2a Fix typo /launcher/game/tl/spanish/translations.rpy 2013-11-12 12:49:36 +01:00
Daniel Luque a8e83dc58c Fix typo /launcher/game/tl/spanish/project.rpy 2013-11-12 12:47:13 +01:00
Daniel Luque ea6666185a Fix typo /launcher/game/tl/spanish/preferences.rpy 2013-11-12 12:41:43 +01:00
Daniel Luque efe70fad93 Fix typo /launcher/game/tl/spanish/new_project.rpy 2013-11-12 12:39:01 +01:00
Daniel Luque f4fec843e1 Fix typo /launcher/game/tl/spanish/navigation.rpy 2013-11-12 12:33:26 +01:00
Daniel Luque fadbe0e226 Fix typo /launcher/game/tl/spanish/interface.rpy 2013-11-12 12:30:39 +01:00
Daniel Luque 69068c8720 Fix typo /launcher/game/tl/spanish/editor.rpy 2013-11-12 12:23:30 +01:00
Daniel Luque f7960006cc Fix typo /launcher/game/tl/spanish/distribute_gui.rpy 2013-11-12 12:14:28 +01:00
Daniel Luque fb214d9ab8 Translation changed /launcher/game/tl/spanish/android.rpy 2013-11-12 12:07:48 +01:00
Daniel Luque d5d68632e7 Fix typo /launcher/game/tl/spanish/android.rpy 2013-11-12 12:03:08 +01:00
Daniel Luque b5ec036687 Fix typo /launcher/game/tl/spanish/add_file.rpy 2013-11-12 11:31:55 +01:00
Tom Rothamel 3e1a5c18a9 Make string translatable. 2013-11-11 22:56:15 -05:00
Tom Rothamel b480580399 Templates can now be seen in the launcher.
This means that it will be possible to use "Generate Translations" to
update a template when Ren'Py changes.
2013-11-11 22:50:22 -05:00
Tom Rothamel 2822624e85 Decode TODO lines.
This allows for non-ASCII TODO lines.
2013-11-11 21:37:21 -05:00
javimat 205019a769 Create README.html 2013-11-11 15:18:22 +01:00
javimat 3d935e164d Create project.json 2013-11-11 15:17:46 +01:00
javimat 915fc5d6d8 Create script.rpy 2013-11-11 15:17:11 +01:00
javimat 3b60108c7a Create screens.rpy 2013-11-11 15:16:30 +01:00
javimat c624331af5 Create options.rpy 2013-11-11 15:15:56 +01:00
javimat 1e096ec479 Create screens.rpy 2013-11-11 15:14:54 +01:00
javimat d9ba99962c Create common.rpy 2013-11-11 15:13:47 +01:00
Daniel Luque 6e3cd02fdc Ren'Py Launcher translated into Spanish, based on Japanese translation. 2013-11-11 15:08:32 +01:00
Tom Rothamel 98520d6d74 Various changes to make nightly builds possible. 2013-11-10 23:57:33 -05:00
Tom Rothamel 5085b1300b Fsencode the path to the update directory.
This should help make the updater work on non-ASCII systems.
2013-11-09 22:12:41 -05:00
Tom Rothamel 88275fa716 Use correct variable to access preferences.
Fixes a bug when config.default_language is set.
2013-11-09 14:53:53 -05:00
Tom Rothamel ce752343ca Document that video playback is supported on Android. 2013-11-09 12:36:39 -05:00
Tom Rothamel f74fb6ab29 Merge pull request #224 from DragoonHP/patch-1
Fix Doc
2013-11-09 06:36:28 -08:00
DragoonHP 7b185e022a Fix Doc 2013-11-09 10:47:39 +05:30
Tom Rothamel f9523a63f3 Use renpy.sh to generate documentation includes. 2013-11-08 20:51:36 -05:00
Tom Rothamel 524d9a77a2 Change the command line we use to run Ren'Py on Linux/Mac.
We remove one -O from the python command line. This prevents python
from removing docstrings, which means we can now use renpy.sh to
generate the documentation includes.
2013-11-08 20:49:22 -05:00
Tom Rothamel 7362261469 Ensure the environment contains only encoded strings.
Fixes #222.
2013-11-08 20:42:46 -05:00
paulmorio bf98392005 Forgot final line on README 2013-11-08 13:39:31 +00:00
paulmorio 037686e7a1 More installation options for sphinx and cython if global rights. 2013-11-08 13:27:13 +00:00
morio 9df83fb0ae Format and look for README 2013-11-08 13:22:29 +00:00
morio 1486757426 Fixed codeblocks for new README 2013-11-08 13:18:46 +00:00
morio b9671f7c77 README altered to show more information and options in building renpy 2013-11-08 13:10:47 +00:00
Tom Rothamel f95ff022d4 Allow the title of the input prompt to be translated.
Fixes #221.
2013-11-07 18:02:25 -05:00
Tom Rothamel 25661cf69e Bump version to 6.16.1. 2013-11-07 17:41:45 -05:00
Tom Rothamel c2cb614750 Flag a string as translatable.
This doesn't have any actual effect, but makes the code read
better. That's because "Test" is already translated in a bunch
of other places.
2013-11-06 21:50:10 -05:00
Tom Rothamel e326c8d66e Document rare problems that can be worked around. 2013-11-06 21:30:22 -05:00
Tom Rothamel 030edbd5d8 Check in generated file. 2013-11-05 23:04:55 -05:00
Tom Rothamel 4bab0874b7 Document some functions. 2013-11-05 23:04:24 -05:00
Tom Rothamel 26b5b3a315 Update generated documentation. 2013-11-04 22:33:56 -05:00
Tom Rothamel bc94ee0cfa Use the build mechanism to build android distributions.
This allows creators to use build.classify to exclude files from
an Android distribution, or specify that files are Android-only.
2013-11-04 22:13:12 -05:00
Tom Rothamel a7aba0642b Do not fail if a module import can't be decoded as utf-8. 2013-11-03 21:04:26 -05:00
Tom Rothamel 956b9aff4a Merge pull request #218 from kyouryuukunn/fix_doc4
Fix doc4
2013-11-03 16:23:38 -08:00
kyouryuukunn 25bea3444f fix doc 2013-11-04 08:55:01 +09:00
kyouryuukunn 71ea4caeb9 fix doc 2013-11-04 08:46:33 +09:00
Tom Rothamel 9d354bfcf9 Merge pull request #216 from kyouryuukunn/fix_doc4
fix doc
2013-11-03 15:41:20 -08:00
kyouryuukunn b548b851ce fix doc 2013-11-04 08:37:20 +09:00
Tom Rothamel 6d2faf0d02 Fix typo.
Thanks to xavimat for the report.
2013-11-03 10:19:59 -05:00
Tom Rothamel 154c9f9d4a Merge pull request #214 from vbkaisetsu/fix-typo
fix typo
2013-11-03 07:11:15 -08:00
Koichi Akabe 579701cd30 fix typo 2013-11-03 23:53:33 +09:00
Tom Rothamel aacbd640e0 Support for building an android-suitable distribution.
This is the first step in using the build system to select the files
that will be included in an Android package.
2013-11-03 09:12:51 -05:00
Tom Rothamel 01e8296661 Add android package build information. 2013-11-02 23:45:19 -04:00
Tom Rothamel 32f2fc8126 Properly generate options.rpy for the japanese template.
The japanese template includes the build stuff, which also needs
to be updated when it's used to create a game.
2013-11-02 22:46:10 -04:00
Tom Rothamel 076e342f65 Fix a deadlock.
When the auto-save thread kicked off at the end of the game, it could
sit there waiting for a screenshot that would never be taken. This
fixes that, both by taking the screenshot and adding timeouts
that should prevent eternal pauses.
2013-11-02 21:59:24 -04:00
Tom Rothamel b186a703e2 Deal with symlinks leading to renpy.sh. 2013-11-01 18:11:08 -04:00
Tom Rothamel c9bfd1e377 Merge pull request #212 from vbkaisetsu/fix-typo-n-style
fix typos and style
2013-11-01 11:33:12 -07:00
Koichi Akabe 3365a073cb fix typos and style 2013-11-01 14:10:29 +09:00
Tom Rothamel 33e615bbf2 More use of templates directory. 2013-10-31 23:22:57 -04:00
Tom Rothamel a1adafa600 Merge pull request #211 from kyouryuukunn/update_translation2
update translation
2013-10-31 20:16:39 -07:00
kyouryuukunn 153d435571 update translation 2013-11-01 12:11:10 +09:00
Tom Rothamel 6a8ad2e80c Update the changelog to reflect the new translations. 2013-10-31 23:05:34 -04:00
Tom Rothamel 1395aba079 Minor editing of Japanese template. 2013-10-31 22:51:03 -04:00
Tom Rothamel 54e89492f3 Change the template selection message. 2013-10-31 22:32:22 -04:00
Tom Rothamel a69bb2edfa Fix after_checkout.sh. 2013-10-31 22:17:58 -04:00
Tom Rothamel b4b5a5fa59 Update console.bat, which provides a quick hacky way to run Ren'Py
in the windows console.
2013-10-31 22:15:17 -04:00
Tom Rothamel 389f3de5f4 Update .gitignore. 2013-10-31 22:14:59 -04:00
Tom Rothamel d457b345d7 Remove unused code from distribute.py. 2013-10-31 22:11:08 -04:00
Tom Rothamel ace21dca93 Generate the correct file. 2013-10-31 22:07:48 -04:00
Tom Rothamel 6d72e96bc2 Move the templates into the templates directory. 2013-10-31 22:03:40 -04:00
Tom Rothamel f4f6cd1215 Merge pull request #209 from kyouryuukunn/add_template-jp
add template-jp
2013-10-31 17:56:32 -07:00
Tom Rothamel 7de6e764a5 Merge pull request #208 from kyouryuukunn/update_translation
Update japanese translation
2013-10-31 17:56:15 -07:00
kyouryuukunn 4c9a56de23 Also translate screens.rpy 2013-11-01 09:27:43 +09:00
kyouryuukunn e54a18e4ad fix Japanese translation 2013-11-01 08:24:37 +09:00
kyouryuukunn 4183e60fc7 fix Japanese translation 2013-11-01 08:22:07 +09:00
kyouryuukunn b25d19509c use None language 2013-10-31 23:29:58 +09:00
kyouryuukunn d6c1444432 fix README.html in template-jp 2013-10-31 23:23:17 +09:00
kyouryuukunn edd1222e0e Update japanese translation 2013-10-31 22:08:59 +09:00
kyouryuukunn c0106e8bee add template-jp 2013-10-31 21:50:03 +09:00
Tom Rothamel 99be725ede Copy MTLc3m into the launcher directory.
It's possible to have the launcher without the tutorial or vice versa,
and some Linux distros package Ren'Py in this way. Copying the font
file ensures we work in this case.

This will increase the size of the zip file, but probably not of
the 7z or tar.bz2.
2013-10-31 07:54:44 -04:00
Tom Rothamel b0d04c3eac Remove executable bit from non-executable files. 2013-10-31 07:42:16 -04:00
Tom Rothamel b463732c42 Merge pull request #206 from kyouryuukunn/allow_translate_lancher
add the japanese translation for launcher
2013-10-31 04:39:41 -07:00
kyouryuukunn 5827121db5 fix 2013-10-31 17:04:19 +09:00
kyouryuukunn 7994a28363 remove #TODO from translation files 2013-10-31 16:56:04 +09:00
kyouryuukunn f6a9cb92b2 add make_style_backup in japanese/style.rpy 2013-10-31 13:10:01 +09:00
Tom Rothamel 446a6a640f Add the make_style_backup function, which needs to be
called from translations.

This ensures that we preserve the translation styles when
updating the theme.
2013-10-30 23:04:11 -04:00
Tom Rothamel 570a85e472 Change the default default_afm_time.
This makes the default behavior the one that's been used in all
quick_menu based games.
2013-10-30 21:53:32 -04:00
Tom Rothamel f1f6c84758 Merge pull request #204 from kyouryuukunn/change_options
Change options.rpy.
2013-10-30 17:44:51 -07:00
Tom Rothamel 3acf232631 Merge pull request #205 from vbkaisetsu/free-font
Replace mikachan with Motoya L cedar.

Fixes #186.
2013-10-30 16:43:07 -07:00
Tom Rothamel 0a2a2b35fe Merge pull request #200 from kyouryuukunn/enable_translation
Enable translation of  editor information in the launcher.
2013-10-29 19:51:36 -07:00
Tom Rothamel 0eedc523bb Allow the None language to have translations generated.
When we get "None" as the name of the language to generate translation
for, we generate it for the None language. We only generate string
translations, as that's the only thing that makes sense to translate
in the None language.

Fixes #203.
2013-10-29 22:37:42 -04:00
Koichi Akabe 5f59f4e126 remove mikachan license 2013-10-29 20:56:59 +09:00
kyouryuukunn 9d6f1e5110 add some transition configs to options.rpy 2013-10-29 20:39:59 +09:00
kyouryuukunn fc653f265c move default_afm_time and default_afm_enable from screens.rpy to options.rpy 2013-10-29 20:33:46 +09:00
Koichi Akabe 0f32739675 replace mikachan and vl-gothic with motoya 2013-10-29 19:11:05 +09:00
kyouryuukunn a333bcdc44 add the japanese translation for lancher 2013-10-29 18:14:59 +09:00
Tom Rothamel 3c3be23f1f Fix typo. 2013-10-28 23:52:33 -04:00
Tom Rothamel 6b91fb9847 Fix incorrect variable name. 2013-10-28 10:58:27 -04:00
Tom Rothamel 2219e4aebf Add missing comma. 2013-10-27 22:19:01 -04:00
Tom Rothamel 97b9c02aa8 Explicity document translate None.
This can be used to translate the interface when a game is
not originally written in English.
2013-10-27 22:07:39 -04:00
Tom Rothamel 864c959b4d List the new documentation pages, so people can find them. 2013-10-27 21:56:48 -04:00
Tom Rothamel 1a873b2d6a Re-organize file access functions. 2013-10-27 21:48:05 -04:00
Tom Rothamel e3d20823ae Document character callbacks.
Hey, that gets rid of the last long-standing warning in the
documentation build process. Bully!
2013-10-27 21:35:18 -04:00
Tom Rothamel 069b679e7d Move some things around in documentation. 2013-10-27 21:09:43 -04:00
Tom Rothamel 82b28baf87 Document conditional statements. 2013-10-27 21:03:52 -04:00
Tom Rothamel ffc150e569 Document the python statements. 2013-10-27 20:22:59 -04:00
Tom Rothamel 7bb1b85b66 Actually fix the doc warnings. 2013-10-27 20:22:21 -04:00
Tom Rothamel 827f597e07 Fix various doc errors/warnings. 2013-10-27 19:01:45 -04:00
Tom Rothamel b3f5e0c964 Generate an index of reserved names. 2013-10-27 18:45:10 -04:00
Tom Rothamel 3dec76ecf4 Remove linux-isms from doc build scripts. 2013-10-27 18:03:36 -04:00
Tom Rothamel 897caf7abc Edit environment variable documentation. 2013-10-27 18:00:12 -04:00
Tom Rothamel 0cac58e4a0 Edit keymap documentation. 2013-10-27 17:48:06 -04:00
Tom Rothamel cce422709b Check in source.
* Check in generated inc files.
* Fix permissions on .rst files.
2013-10-27 17:24:46 -04:00
Tom Rothamel b4d68fdb85 Document creator-defined statements.
Starting with the previous documentation, edited it, and
moved the various functions used into the public Ren'Py
API.
2013-10-27 17:18:29 -04:00
Tom Rothamel 1acf4e1243 Merge pull request #189 from kyouryuukunn/add_doc3
Add doc3
2013-10-27 08:22:23 -07:00
Tom Rothamel bb53094f66 Merge pull request #193 from kyouryuukunn/fix_message
Fix missing wxPython message.
2013-10-26 17:01:39 -07:00
Tom Rothamel 3d840f5c6d Properly deliver the error message when no build packages are selected.
Fixes #197.
2013-10-26 19:59:53 -04:00
Tom Rothamel db332a1f0f Merge pull request #191 from kyouryuukunn/allow_translate_voice_sustain
Allow the translation of "Voice Sustain".
2013-10-26 09:50:22 -07:00
Tom Rothamel 443a9001f5 Merge pull request #198 from vbkaisetsu/fix-doc
fix doc that doesn't contain needed line break
2013-10-26 09:49:06 -07:00
Tom Rothamel b7f9ad1808 Merge pull request #196 from xiongchiamiov/port-after-checkout
Port after_checkout.sh to non-Linux Unixes
2013-10-26 09:47:55 -07:00
Koichi Akabe 5aa7658cdf fix doc that doesn't contain needed line break 2013-10-26 22:21:01 +09:00
James Pearson 5dd2fae7a9 Port after_checkout.sh to non-Linux Unixes
`after_checkout.sh` has been using `readlink(1)` to get an absolute path (with
no symlinks) to the renpy root directory.  Unfortunately, `readlink -f` is a
GNU extension, and thus unavailable on the BSDs, including OS X.

There are[0] a number of options for those systems.  While an exec out to
Python seems like overkill (and is, in fact, a bit slow on my system), the
delay is small enough to not be a problem in a one-time script like this.
Additionally, it seemed silly to include a dozen-line shell function just for
this one usage.  Plus, we know for certain the user has Python, because
otherwise they couldn't run Ren'Py. ;)

I included the parens around `print` just to make sure it works with both
Python 2.x and 3.x.  I doubt this matters, but I figured I might as well.

If we stop caring about resolving symlinks, this entire line can be replaced
with `$PWD##*`. [1]

[0]: http://stackoverflow.com/q/1055671/120999
[1]: http://stackoverflow.com/a/1371283/120999
2013-10-25 22:51:48 -07:00
kyouryuukunn 3a5e571aea add doc about showing a window during a transition 2013-10-26 13:19:45 +09:00
Tom Rothamel 5ee03ed977 Reset _voice.tlid at each interaction.
This prevents voice sustain from carrying over through restarts,
as well as other potential minor problems.
2013-10-25 22:53:23 -04:00
Tom Rothamel 6710463318 Make installing the SDK conditional on RAPT being installed. 2013-10-25 21:15:41 -04:00
Tom Rothamel 893d36d4a3 Build RAPT as part of the Ren'Py release process.
This helps prevent me from accidentally forgetting to make a
RAPT release when Ren'Py code is updated.
2013-10-25 20:54:45 -04:00
Tom Rothamel 8f8b7e1fd9 Lock disk access. 2013-10-24 22:05:16 -04:00
Tom Rothamel e46c78fb36 Allow config.auto_voice to be a function.
This allows the patter to be changed when a translation is
being used, for example.
2013-10-24 21:39:08 -04:00
kyouryuukunn 5fd25efe0b allow_translate_lancher 2013-10-25 08:24:44 +09:00
kyouryuukunn 4d2f567bc4 enable translation of lancher 2013-10-24 22:01:23 +09:00
kyouryuukunn 0aa5016758 fix message 2013-10-24 20:25:19 +09:00
kyouryuukunn aac6291147 fix 2013-10-24 15:16:53 +09:00
Tom Rothamel 3cd4c18d6a Document text rendering change. 2013-10-23 23:10:19 -04:00
Tom Rothamel fe4bad7c11 Add mikachan license. 2013-10-23 22:55:55 -04:00
Tom Rothamel 251dbb2dee Mention the Japanese translation in the changelog. 2013-10-23 22:42:40 -04:00
Tom Rothamel 2ed6b14dc2 Remove files that are no longer needed. 2013-10-23 22:42:17 -04:00
Tom Rothamel a5162ac666 Fix question when overwriting a save. 2013-10-23 22:37:24 -04:00
Tom Rothamel 2a0adb3dbf Deal with {#comment} text tags. 2013-10-23 22:03:08 -04:00
kyouryuukunn 7edfe2cca8 add doc some statements equivalents 2013-10-24 01:13:02 +09:00
kyouryuukunn 757ecb37b4 add doc some pages 2013-10-24 01:12:37 +09:00
kyouryuukunn 0ebcd4a7f3 add doc about after_warp and some functions 2013-10-24 01:12:11 +09:00
kyouryuukunn ef1e6b0676 add the doc the page about creator defined statements 2013-10-24 01:10:10 +09:00
kyouryuukunn db94d03b64 move the window statement to displaying_images 2013-10-24 01:09:10 +09:00
kyouryuukunn 87b994b67a add the doc the page about developer tools and some functions 2013-10-24 01:08:40 +09:00
kyouryuukunn e5064f0794 add the doc the page about key maps 2013-10-24 00:55:22 +09:00
kyouryuukunn 6751172cfe add the doc the page about environment variables 2013-10-24 00:54:56 +09:00
Tom Rothamel 6c0d7802d9 Fix bad rst.x 2013-10-22 22:47:35 -04:00
Tom Rothamel ab7fd52fbd Fix syntax highlighting. 2013-10-22 22:45:44 -04:00
Tom Rothamel c6cb66dc61 Check in the generated docs. 2013-10-22 22:29:48 -04:00
Tom Rothamel 4b5ff75412 Document MultiPersistent. 2013-10-22 22:27:53 -04:00
Tom Rothamel 6dd5724be1 Split persistent out into its own rst file. 2013-10-22 22:11:13 -04:00
Tom Rothamel 32f3bbb67d Edit the label documentation. 2013-10-22 19:58:39 -04:00
Tom Rothamel 51cca16196 Merge pull request #188 from kyouryuukunn/add_doc3
More documentation from kyouryuukunn
2013-10-22 16:31:37 -07:00
kyouryuukunn 1fa87f753e add doc about init statement 2013-10-23 01:12:22 +09:00
kyouryuukunn 48cc2ae4cf add doc about special labels 2013-10-23 01:07:26 +09:00
kyouryuukunn e463c886cc add the doc about pause statement 2013-10-23 00:04:30 +09:00
kyouryuukunn 2efb7058f8 fix doc 2013-10-22 23:22:04 +09:00
kyouryuukunn 1c582ab21a add the doc persistent data 2013-10-22 23:14:33 +09:00
kyouryuukunn 4f30e7ac85 fix movie 2013-10-22 22:59:01 +09:00
kyouryuukunn 0e223e4c7a move renpy.call from other to statement_equivalents 2013-10-22 22:52:12 +09:00
kyouryuukunn b431d32825 move renpy.rollback from other to rollback 2013-10-22 22:49:15 +09:00
kyouryuukunn 8f41a8be99 add the doc the page about label 2013-10-22 22:47:27 +09:00
Tom Rothamel e9b260aae9 Merge pull request #187 from vbkaisetsu/fix-doc
fix reverted documentation errors
2013-10-22 06:41:39 -07:00
Koichi Akabe 2505af9985 fix reverted documentation errors
3fde29f reverted b074038 and 835fe5d because prior commits fixed auto generated files.
This commit fixes original rpy files.
2013-10-22 22:36:54 +09:00
kyouryuukunn 18fff449f3 add the doc the define statement 2013-10-22 21:51:43 +09:00
kyouryuukunn cc437eb47c add doc about base and game directorys 2013-10-22 20:45:51 +09:00
kyouryuukunn 14cd7e71b4 fix doc 2013-10-22 20:15:58 +09:00
kyouryuukunn 03499adffc add the doc the movie page 2013-10-22 20:12:26 +09:00
kyouryuukunn c738e39268 fix doc 2013-10-22 18:25:41 +09:00
Tom Rothamel 922af0d651 Testcase for vertical text.
This includes a pattern showing the center of the screen, and
vertical text starting at the center of the screen.
2013-10-22 00:50:13 -04:00
Tom Rothamel bfe91ab358 Center input prompts. 2013-10-22 00:47:12 -04:00
Tom Rothamel 0cfe13e214 Fix detection of RAPT when a .zip file exists in the Ren'Py directory. 2013-10-22 00:12:35 -04:00
Tom Rothamel 1246258f73 Use new screens for template. 2013-10-22 00:12:22 -04:00
Tom Rothamel 9655ef6a0d Merge pull request #184 from kyouryuukunn/fix_doc
fix doc
2013-10-21 20:22:17 -07:00
Tom Rothamel 3fde29fecd Edit audio.rst, and generate docs. 2013-10-21 23:09:42 -04:00
Tom Rothamel 04d5f374ef Merge pull request #185 from kyouryuukunn/add_doc2
Add documentation for audio statements.
2013-10-21 18:34:35 -07:00
Tom Rothamel acf0207f12 Re-init importer after a shift+R reload. 2013-10-21 21:09:25 -04:00
kyouryuukunn 2ebc6fb26e add index.rst audio page 2013-10-21 23:26:11 +09:00
kyouryuukunn 1c1c70e951 add doc audio page 2013-10-21 23:23:10 +09:00
kyouryuukunn 3ff3054f5d add doc about extend 2013-10-21 21:53:01 +09:00
kyouryuukunn eee003c184 fix doc 2013-10-21 21:49:42 +09:00
Tom Rothamel 661a884566 Encode the environment before using it.
This allows us to launch on windows.
2013-10-20 20:20:26 -04:00
Tom Rothamel e35860c235 Merge pull request #181 from kyouryuukunn/add_doc
Add doc about centered, vcentered, the play statement and the window statement
2013-10-20 13:38:37 -07:00
Tom Rothamel abfbebe996 Add disclaimer about vertical text. 2013-10-20 16:38:11 -04:00
Tom Rothamel 075555c294 Merge branch 'devel' of github.com:renpy/renpy into devel 2013-10-20 16:22:23 -04:00
Tom Rothamel 30eb973810 Add the renpy.is_seen function. 2013-10-20 16:15:36 -04:00
Tom Rothamel e60d332de6 Merge pull request #180 from kyouryuukunn/enable_translate
enable translate about screenshot
2013-10-20 13:12:05 -07:00
Tom Rothamel 835fe5db03 Merge pull request #182 from kyouryuukunn/fix_doc3
fix document
2013-10-20 13:11:34 -07:00
Tom Rothamel 9705ff7837 Merge pull request #183 from vbkaisetsu/tutorial-translation
update Japanese translation for tutorial game
2013-10-19 22:42:40 -07:00
Koichi Akabe 56aea76e25 update Japanese translation for tutorial game 2013-10-20 14:38:00 +09:00
Tom Rothamel f90ce46577 Use the (horizontal) lineskip as the advance value for vertical text.
This is an attempt at improving #179.
2013-10-20 00:51:46 -04:00
Tom Rothamel 5355f87e1d Deal with fonts with odd bounding-boxes.
Some truetype fonts have bounding boxes that contain the origin. (This
may be becuase of font design, auto-hinthing, or anti-aliasing.) We
deal with these fonts by rendering all the available pixels, even
those to the left of the origin.

This may make the actual area drawn to the screen bigger than the
displayable itself, so we deal with that when necessary.

Fixes #34.
2013-10-19 23:50:51 -04:00
kyouryuukunn fd3d21229b fix document 2013-10-20 03:03:31 +09:00
kyouryuukunn 1c819fec4d fix document 2013-10-20 02:44:44 +09:00
kyouryuukunn 1256909852 add doc about say statement with transition 2013-10-20 02:32:53 +09:00
kyouryuukunn cf933f2b37 add doc about window show hide 2013-10-20 02:14:55 +09:00
kyouryuukunn f3031a3cab add doc about the play statement 2013-10-20 02:13:18 +09:00
kyouryuukunn ddf5e82bd5 enable translate about screenshot 2013-10-19 11:04:38 +09:00
Tom Rothamel 95184394a4 Bump version to 6.16.0, and give it the name "In the Arena". 2013-10-18 21:27:23 -04:00
kyouryuukunn 8fbea7d329 add doc about centered and vcentered 2013-10-19 10:22:08 +09:00
Tom Rothamel 7fd9de354f Merge pull request #178 from kyouryuukunn/fix_document2
Fix documentation.
2013-10-18 17:27:37 -07:00
Tom Rothamel 70f5d97aef Document some bugfixes.
(I don't think it's worth going through and including them all.)
2013-10-17 23:35:12 -04:00
Tom Rothamel 1e8813e668 Document non-bugfix changes. 2013-10-17 23:23:21 -04:00
kyouryuukunn b07403855c fix document 2013-10-17 16:37:17 +09:00
Tom Rothamel 3ca12ea1d6 Start work on changelog. 2013-10-16 22:54:34 -04:00
Tom Rothamel 5ce0347e54 Merge pull request #176 from kyouryuukunn/fix_document
fix documentation about register_style_preference
2013-10-16 07:59:35 -07:00
kyouryuukunn ec2104d656 fix document about register_style_preference 2013-10-16 16:42:54 +09:00
Tom Rothamel e686b1228a Stop a playing movie while returning to the main menu. 2013-10-15 22:51:51 -04:00
Tom Rothamel 2667268f0d Merge pull request #173 from vbkaisetsu/rm-doc-ja-info-in-ja
remove doc-ja info in Japanese documentation
2013-10-15 19:48:32 -07:00
Tom Rothamel d3e5341c2d Fix problems with shift+R reloading. 2013-10-15 22:45:40 -04:00
Tom Rothamel 878aae6686 Use subtitle layout for the yes/no label text.
This prevents us from having widows when it's placed on two lines.
2013-10-15 22:36:54 -04:00
Tom Rothamel 2df74bb052 Make the rollback action sensitive iff Ren'Py can rollback. 2013-10-15 22:36:23 -04:00
Tom Rothamel 66f73ab014 Rearrange quick menu.
* Make the order more consistent.
* Add rollback ("Back")
* We don't need to make F.Skip so easy to disable - it's no worse
  than normal skip when skip unseen is off.
2013-10-15 22:24:30 -04:00
Tom Rothamel 8b7ccada49 Fast skip's get_sensitive should respect skip_unseen. 2013-10-15 22:22:16 -04:00
Tom Rothamel 27845de14b Require confirmation for fast skipping. Add to quick menu. 2013-10-15 22:16:19 -04:00
Tom Rothamel d59b550e04 Add the ability to ask for confirmation beofre skipping. 2013-10-15 20:29:42 -04:00
Tom Rothamel 4f26fd98a0 Tweak the test for slow skipping.
(config.skipping = True can also be used to turn on slow skipping.)
2013-10-15 20:05:03 -04:00
kyouryuukunn e3fe09a1ae distinguish fast and skip about get_selected() 2013-10-15 21:25:22 +09:00
Koichi Akabe 657b072ffa remove doc-ja info in Japanese documentation
Japanese doc information shouldn't be shown in Japanese, and it should be untranslatable text.
This commit adds two tags: language_LANGUAGE and gettext to support it.
2013-10-15 19:47:57 +09:00
Tom Rothamel def9865849 Store st properly in musicroom.
This prevents us from constantly resetting the last_playing
value, which caused many problems.
2013-10-14 21:55:38 -04:00
Tom Rothamel 98cff70eaf Fix typo. 2013-10-14 00:14:31 -04:00
Tom Rothamel 0c4eb467fe Make run.sh build in a different directory.
This prevents run.sh from conflicting with the official build.
2013-10-14 00:08:02 -04:00
Tom Rothamel 3e6ed73769 Add build.destination.
This lets us select the directory Ren'Py will build distributions
into.
2013-10-13 23:54:07 -04:00
Tom Rothamel 6c29701b0d Add a stop_action to the music room. 2013-10-13 20:25:08 -04:00
Tom Rothamel 273dbf780e If we can't get the date of a file, use now. 2013-10-13 20:20:02 -04:00
Tom Rothamel 35831b0ba7 MusicRoom support single track, loop, and shuffle options.
Also, add some testcases for MusicRoom.
2013-10-13 15:47:55 -04:00
Tom Rothamel 275f56a384 Yet another fix. 2013-10-13 01:43:39 -04:00
Tom Rothamel dbb6551d20 Today is not my night. (Fix previous commit.)0 2013-10-13 01:38:21 -04:00
Tom Rothamel 6d74eecc5c Also handle bad times. 2013-10-13 01:33:27 -04:00
Tom Rothamel eae4fd3f1b Add an error message if we can't stat a file going into a zip package. 2013-10-13 01:20:29 -04:00
Tom Rothamel 687b3ad1cd Merge pull request #163 from kyouryuukunn/hide_voice_preferences
Hide voice preferences if has_voice is false.
2013-10-12 08:45:57 -07:00
Tom Rothamel def04ec41c Right-click (the game_menu keys) answers no to a yes/no question
See the discussion at #166.
2013-10-11 23:04:13 -04:00
Tom Rothamel cdbc67f3d5 Do not save when renpy.store.main_menu is true.
We're using renpy.store.main_menu as the flag to tell us we're in
the main menu.
2013-10-11 00:43:08 -04:00
Tom Rothamel 2fd4f04bd8 Remove now-obsolete code. 2013-10-11 00:42:53 -04:00
Tom Rothamel 2edbd375fd Preserver store.main_menu when we enter a sub-menu from the main menu. 2013-10-11 00:42:14 -04:00
Tom Rothamel d685c3963a Fix code analysis problems. 2013-10-11 00:41:25 -04:00
Tom Rothamel 4218e2d950 Replace g. with gallery. in the _gallery screen.
Caught by kyouryuukunn here: https://github.com/renpy/renpy/pull/169#issuecomment-26032735
2013-10-10 23:14:50 -04:00
Tom Rothamel f96a6eee04 Regenerate documentation; Add link to Japanese documentation. 2013-10-10 10:42:09 -04:00
Tom Rothamel 12650ae9f7 Rewrite the gallery to allow us to advance forwards and backwards,
including advancing between buttons.
2013-10-10 00:37:55 -04:00
Tom Rothamel 9dee75e243 Merge pull request #168 from kyouryuukunn/gallery2
add gallery Previous,Next,Close,EnablePreview actions
2013-10-08 15:08:30 -07:00
Tom Rothamel e9a2579a64 Document Expansion APKs. 2013-10-08 17:57:10 -04:00
kyouryuukunn 7ca20972af change design of "_gallery" 2013-10-08 18:57:57 +09:00
Tom Rothamel 3b6c187ad1 Add support for placing google play info into the game script,
so it can be edited into the android code.

Also, various minor improvements.
2013-10-07 23:59:50 -04:00
Tom Rothamel c4e50aa700 More android documentation. 2013-10-07 21:55:07 -04:00
kyouryuukunn 4736b75cc7 change EnablePreview to ToggleSlideshow 2013-10-08 00:01:17 +09:00
kyouryuukunn 775a007a41 use "gallery" screen in place of "_gallery" if exist 2013-10-07 23:56:28 +09:00
kyouryuukunn ae64c83d01 add gallery Previous,Next,Close,EnablePreview actions 2013-10-07 22:06:00 +09:00
Tom Rothamel 723622b7f5 Expand LGPL correctly.
Fixes #167.
2013-10-07 01:27:18 -04:00
Tom Rothamel 7903ee1235 Update the Android documentation. 2013-10-07 01:16:20 -04:00
Tom Rothamel da6629c210 Move default preferences to their own section; document new defaults. 2013-10-06 22:12:51 -04:00
Tom Rothamel a994adfed7 Bars switch to the selected_hover when they're activated. 2013-10-06 10:55:57 -04:00
kyouryuukunn 66fc4eb85e also hide voice preferences in tutorial 2013-10-06 12:13:24 +09:00
Tom Rothamel 04d4a113ac Merge branch 'fix_and_unify_autosave' of github.com:kyouryuukunn/renpy into devel
This puts the checks as to if we can autosave into loadsave, rather than
scattering them in various places in the code.
2013-10-05 22:59:41 -04:00
kyouryuukunn fd6417bc3c hide voice preferences if has_voice is False 2013-10-06 11:49:59 +09:00
Tom Rothamel 74eee18415 Merge pull request #162 from vbkaisetsu/credit-indent
take care of indents in credits
2013-10-05 19:49:29 -07:00
Tom Rothamel d5d27062d7 Merge branch 'common_quit_process' of github.com:kyouryuukunn/renpy into devel
This always calls _quit (and quit if it exists) on quit, and it calls
_confirm_quit when the close button is clicked.
2013-10-05 21:44:59 -04:00
Tom Rothamel 4983e581ba Set config.has_voice to False by default.
At least until more than a few games have voices.
2013-10-05 21:02:53 -04:00
Tom Rothamel ab37f35cf8 Change the defaults for wait_for_voice and voice_sustain. 2013-10-05 20:54:29 -04:00
Tom Rothamel 4a4fbb9b3f Merge branch 'preferences.voice_sustain' of github.com:kyouryuukunn/renpy into devel 2013-10-05 20:37:24 -04:00
Tom Rothamel 9b2617e48c Merge pull request #161 from kyouryuukunn/rename_wait_voice
rename preferences("wait voice") to preferences("wait for voice")
2013-10-05 14:23:42 -07:00
kyouryuukunn 80c2d4cee2 rename preferences("wait voice") to preferences("wait for voice") 2013-10-06 03:03:38 +09:00
Tom Rothamel 6255511d02 Change the English name of wait_voice to "Wait for Voice." 2013-10-02 20:38:02 -04:00
Tom Rothamel e61ccaa6c8 Merge branch 'preferences.wait_voice' of github.com:kyouryuukunn/renpy into devel
Addds the wait_voice preference, which lets the user decide if auto-forward
mode will wait for voice to finish before advancing.
2013-10-02 20:31:11 -04:00
Tom Rothamel a2f31d5798 Use the relauch code to relaunch Ren'Py after a directx upgrade.
Fixes #159.
2013-10-01 23:19:03 -04:00
Tom Rothamel 29f22d1e79 Check in generated documentation. 2013-10-01 23:15:17 -04:00
Koichi Akabe fe78160055 take care for indents in credits 2013-10-02 10:20:41 +09:00
Tom Rothamel ba5d433dd1 Tweak the format of the translation documentation. 2013-10-01 19:59:04 -04:00
Tom Rothamel 3516bfc3c5 Merge pull request #158 from vbkaisetsu/doc-credits
add credits for documentation
2013-10-01 16:41:07 -07:00
Tom Rothamel 17fa9b6a14 Merge pull request #160 from kyouryuukunn/fix_document_slideaway
Fix documentation.
2013-10-01 16:36:55 -07:00
kyouryuukunn d0a8ab1976 fix_document 2013-10-01 19:29:09 +09:00
Tom Rothamel 051ca25fe7 Changes to persistence.
Automatically saving persistent data may be too slow (and might cause
a laptop's hard drive to spin up), so we now save it at shutdown or
when renpy.save_persistent is called.

We also allow creators to register a merge function that's called when
loading updated persistence data from disk.
2013-10-01 00:32:31 -04:00
Tom Rothamel 3e097905e3 Merge persistent data.
If a persistent updates while this code is running, we merge in
the data from that file, and restart the interaction.
2013-09-30 01:20:21 -04:00
Koichi Akabe d516731d24 set ??? as translator if translator-credits is not set 2013-09-29 14:30:34 +09:00
Koichi Akabe 2ddd430484 add credits for documentation 2013-09-29 13:57:54 +09:00
Tom Rothamel 099c8a53d3 Add NullAction.
This is used to make a button responsive to hover and unhover,
even if it doesn't have an action.
2013-09-28 23:43:58 -04:00
Tom Rothamel dcbf0d05e5 Merge pull request #156 from kyouryuukunn/fix_music_room
Fix music room.
2013-09-27 19:42:31 -07:00
kyouryuukunn dd70a48e3f fix_music_room 2013-09-28 10:16:06 +09:00
Tom Rothamel fe954a9e33 Export renpy.display.behavior.run as run_action, and make the music
room use it.
2013-09-27 18:05:58 -04:00
Tom Rothamel 5f5791a8e3 Add an action argument to MusicRoom.add, giving a list of actions
to be run when the music plays.
2013-09-27 18:00:14 -04:00
Tom Rothamel 1c90ce4dea Defer persistent loads. 2013-09-26 23:57:45 -04:00
kyouryuukunn 8bbd3a0000 add MusicRoom.add action keyword argument 2013-09-27 00:00:40 +09:00
Tom Rothamel 72e430ef49 Add persistent data to save locations; use for saving persistent.
Also, safely save normal save data.
2013-09-26 00:27:29 -04:00
Tom Rothamel 1c017a7589 Minor changes. 2013-09-24 23:20:53 -04:00
Tom Rothamel b9836c3eaa Move the preferences object into preferences.py. 2013-09-24 22:07:01 -04:00
kyouryuukunn 479f45f46f add preferences.voice_sustain 2013-09-25 10:53:36 +09:00
kyouryuukunn e3204944f6 add preferences.wait_voice 2013-09-25 10:41:57 +09:00
Tom Rothamel debcd2043b Merge branch 'master' into devel 2013-09-23 23:50:02 -04:00
Tom Rothamel b57ceed621 Deal with VIDEORESIZE events after mode changes on windows. 2013-09-23 23:48:43 -04:00
Tom Rothamel e6e0e80527 Deal better with text strings of insane lengths.
We now only display the first 8192 pixels of the text, but that's
better than crashing.

Fixes #141.
2013-09-23 21:24:47 -04:00
Tom Rothamel 3c0b350a4f Allow fast skipping to begin in the main menu.
Merges branch 'fast_skip_by_preference' of github.com:kyouryuukunn/renpy into devel
2013-09-23 19:43:43 -04:00
Tom Rothamel b9a065d48a Add a default for Transform.child_size.
Fixes #112.
2013-09-23 19:36:20 -04:00
kyouryuukunn c00e5abf80 set quit_action to ui.gamemenu(_quit_prompt) if more than v6.15.7 2013-09-23 11:56:00 +09:00
kyouryuukunn 2b3e06bf6d add quit label as the common quit process 2013-09-23 11:54:25 +09:00
Tom Rothamel 293b165aef After_rollback isn't a function. 2013-09-22 20:51:59 -04:00
Tom Rothamel 3dbbb3129c Merge branch 'master' into devel 2013-09-22 19:46:19 -04:00
Tom Rothamel 7b5378fcf1 Merge branch 'fix_screenshot' of github.com:kyouryuukunn/renpy into devel 2013-09-22 19:44:15 -04:00
Tom Rothamel 0e9d90e761 Merge pull request #131 from vbkaisetsu/fix-doc-errors
Fix documentation and jp translation errors.
2013-09-22 16:43:05 -07:00
Tom Rothamel d6acab6bd4 Merge pull request #149 from antoinentx/patch-1
Allow accent in the PATH of Ren'Py directory
2013-09-22 16:20:30 -07:00
Tom Rothamel b6096f6e95 Merge pull request #122 from kyouryuukunn/do_autosave_in_menu
Force autosave on menus and input.
2013-09-22 16:19:34 -07:00
Tom Rothamel 84f2da4a27 Add FileNewest, a function that is True for the newest file slot. 2013-09-21 23:32:03 -04:00
Tom Rothamel 3f6dfcb08e Rewrite the file actions.
The file actions now use the new save slot api, and there's a new
SaveJson function that can returns JSON information from a save
file.
2013-09-21 15:27:31 -04:00
Tom Rothamel f68e38b011 Add a new slot-based API over the new save slot stuff. 2013-09-21 14:35:53 -04:00
Tom Rothamel 7bb92310b5 Write json into save files.
This provides a way to associate arbitrary information with Ren'Py
save files. (For example, we could store which character's route
we're on, or scoring information.)

This introduces config.save_json_callbacks, which contains callback
functions that add information to the json callbacks.
2013-09-21 13:34:57 -04:00
Tom Rothamel ebab397625 Merge branch 'master' of github.com:renpy/renpy into devel 2013-09-20 23:20:43 -04:00
Tom Rothamel 776c0c2eb0 Merge pull request #136 from kyouryuukunn/has_quicksave
Change the default for config.has_quicksave to True.
2013-09-20 20:18:38 -07:00
kyouryuukunn c4bf9c07ca do autosave in menu and input 2013-09-20 18:17:48 +09:00
kyouryuukunn 8d8703bec6 set has_quicksave to False for old vertion 2013-09-20 11:42:53 +09:00
kyouryuukunn cdfb2a162e config.has_quicksave defaults to True 2013-09-20 11:42:53 +09:00
kyouryuukunn 842116e037 don't take_screenshot menu 2013-09-20 11:42:49 +09:00
kyouryuukunn 12403dab26 don't autosave during replay 2013-09-20 11:42:46 +09:00
kyouryuukunn 0dcb0e9fad unify checks for autosave about if in main menu or not 2013-09-20 11:42:46 +09:00
kyouryuukunn 450740318c fix autosave_frequency 2013-09-20 11:42:44 +09:00
kyouryuukunn 455940abda can also fast_skip by menu. 2013-09-20 11:42:41 +09:00
Tom Rothamel 38e2d1aaa9 Merge branch 'master' into devel 2013-09-19 21:35:36 -04:00
Tom Rothamel 8b640426a2 Merge pull request #137 from kyouryuukunn/toggle_page
add FilePageNext and FilePagePrevious a toggle function
2013-09-19 18:34:07 -07:00
Tom Rothamel 19a8c5512e Remove spurious variable from the namespace. 2013-09-18 23:12:12 -04:00
Tom Rothamel 9c50bce587 Remove os from the global namespace. 2013-09-18 23:06:01 -04:00
Tom Rothamel 3f06c505ce Document automatic voice. 2013-09-18 00:08:15 -04:00
Tom Rothamel 04e5b93f91 Normalize spacing. 2013-09-17 23:45:07 -04:00
Tom Rothamel 052ed5c8e3 Add the _auto_voice screen, which displays the file that the auto
voice system is trying to play.
2013-09-17 23:42:30 -04:00
Tom Rothamel 881a1a684f Implement config.auto_voice.
This uses the translation ids to look for a voice file, and
if found, plays the appropriate voice file.
2013-09-17 23:22:56 -04:00
Tom Rothamel 5bb41aa035 Add config.default_language, a non-sticky way to change the language
the game uses.
2013-09-16 23:34:49 -04:00
Tom Rothamel 62c69c8357 Fast skipping skips over renpy.pause.
Also, modified Skip(fast=True) to be enabled even if we haven't
read through the current scene.
2013-09-16 23:23:53 -04:00
Tom Rothamel 93c4da6216 Restart the interaction when a save cache slot changes.
This means that the load/save screens will live update when
a savefile appears or disappears.
2013-09-16 22:32:33 -04:00
Tom Rothamel 40cedc59cb Implement the scan thread for FileLocation.
The scan thread will scan the directory, getting mtimes. If a file
has changed its mtime (or appeared or disappeared), we clear out
the cached slot.
2013-09-16 22:15:54 -04:00
Tom Rothamel 3e44420023 Add a thread for scanning save locations. 2013-09-16 00:11:45 -04:00
Tom Rothamel 16aacb8fef Move the savelocation stuff into its own file. 2013-09-15 19:22:29 -04:00
Tom Rothamel 96a6d8cf3f unlink, rename, and cycle_saves now use the new location system. 2013-09-15 01:03:11 -04:00
Tom Rothamel 4e2d68bb4a Use the location system for load and can_load. 2013-09-15 00:09:24 -04:00
Tom Rothamel b3c96949d9 Make save scanning use locations.
This involves routing save slot listing and mtime/extra_info/screenshot
creation through the location system.
2013-09-14 23:45:22 -04:00
Tom Rothamel ac421dd971 Properly deal with percent-subtitutions in extend.
Fixes #150.
2013-09-13 23:27:58 -04:00
Tom Rothamel 97d7cf4f91 Test if a save location is active.
If we're installed to Program Files on Windows, the game-specific save
location is disabled since we can't write to it.
2013-09-12 23:51:30 -04:00
antoinentx cdfe0a5e9a Allow accent in the PATH of Ren'Py directory
Before the change, you get an uncaught exception when there is an accent in the Path. With that change, it works.
2013-09-12 18:11:09 +02:00
Tom Rothamel 170286d6ce Deal with python compile errors that contain non-ascii characters. 2013-09-11 23:28:11 -04:00
Tom Rothamel 5efa00294c No longer require the key exist for SetDict. 2013-09-11 21:02:13 -04:00
Tom Rothamel 1b47b4b420 Merge branch 'devel' of github.com:renpy/renpy into devel 2013-09-11 19:20:29 -04:00
Tom Rothamel 2868b5c12e Fix analysis problems caused by Persistent move. 2013-09-10 21:14:32 -04:00
Tom Rothamel 4cd7fbf7be Save to multiple locations.
The new MultiLocation lets us save to multiple locations. We now save
both to the user's save directory and a game-local save directory.

Also, refactored the save location in FileLocation into its own
method.
2013-09-10 18:24:42 -04:00
Tom Rothamel 1ed8555b4e Introduce new save location system.
While only used for saves at the moment, this system will eventually
let us use multiple locations.

This also introduces the SaveRecord object, which is where save data
is stored before we write it to disk.
2013-09-10 01:19:21 -04:00
Tom Rothamel a7655a6809 Remove the .pot files from source control.
These are generated files, so we probably don't want to put them
in git.
2013-09-08 23:13:19 -04:00
Tom Rothamel cd64333364 Allow the auto-save thread to free-run.
Now that we're almost always running on a multi-core device, there's
little reason not to just run the auto-save thread whenever we want.

This also will make some of the new save stuff simpler.
2013-09-08 23:11:40 -04:00
Tom Rothamel 4de7b7c504 Ensure Persistent exists in game, for backwards compatibility. 2013-09-08 02:46:50 -04:00
Tom Rothamel df4634bb6a Unicode-safety for extracted text. 2013-09-08 01:50:25 -04:00
Tom Rothamel fa338784d9 Add dialogue extraction GUI. 2013-09-08 01:25:14 -04:00
Tom Rothamel ca501350e1 Exclude extracted dialogue from builds. 2013-09-08 01:11:27 -04:00
Tom Rothamel db597d3a2b Add the dialogue command, which uses the translation system to
dump the game's dialogue to a file.
2013-09-08 01:07:46 -04:00
Tom Rothamel 49b3ba9e34 Add the _clear method to Persistent, providing a way to clear the
persistent data from within the game.

Also, move Persistent into persistent.py.
2013-09-07 23:48:48 -04:00
Tom Rothamel d7bdbe0420 Move things over to persistent.py
I'll be moving the Persistent class in there shortly.
2013-09-07 23:12:37 -04:00
Tom Rothamel 86f9c2e0fb Merge pull request #145 from vbkaisetsu/sphinx-gettext
Add documentation translation support.
2013-09-06 06:36:35 -07:00
Tom Rothamel c7d4b3e45a Merge pull request #143 from kyouryuukunn/fix_document2
Fix documentation.
2013-09-05 22:21:22 -07:00
Tom Rothamel 1bbe821474 Move MultiPersistent into its own file.
This cleans up loadsave for the new load/save system.
2013-09-06 00:10:11 -04:00
Tom Rothamel f9d46b15c8 Hotbars should be replaced.
Fix by Elmiwisa, from http://lemmasoft.renai.us/forums/viewtopic.php?f=32&t=23081.
2013-09-04 21:39:48 -04:00
kyouryuukunn 8d80e6399a fix document 2013-09-04 14:49:11 +09:00
kyouryuukunn e2ec6a57ff fix document 2013-09-04 14:39:26 +09:00
kyouryuukunn 661466df50 change 'toggle' to 'wrap' 2013-08-30 17:19:59 +09:00
kyouryuukunn 2d45112fc4 add FilePageNext and FilePagePrevious a toggle function 2013-08-30 17:19:58 +09:00
Tom Rothamel bf4b6c6dcd Merge pull request #134 from kyouryuukunn/fix_spell_miss
Use exit_yesno_prompt when exiting a yesno_prompt layout.
2013-08-29 20:42:49 -07:00
Tom Rothamel 170aa7fd79 Merge pull request #138 from kyouryuukunn/fix_spellmiss2
Fix duplicate code for Preference("skip", ...)
2013-08-29 20:41:58 -07:00
Tom Rothamel 825ad67c6e Merge pull request #140 from kyouryuukunn/fix_document
Fix documentation of Stop action.

It was the same as Play.
2013-08-29 20:40:32 -07:00
kyouryuukunn cfd2c66ea4 fix the document of Stop action 2013-08-30 00:40:29 +09:00
Tom Rothamel 323258443f Remove debug print. 2013-08-28 23:34:22 -04:00
Tom Rothamel e7c45601de Various android-related changes.
Get things running on OS X, and deal with missing java.
2013-08-28 23:06:47 -04:00
kyouryuukunn 61a18e8a0d fix spellmiss 2013-08-28 19:18:43 +09:00
Koichi Akabe 2c5b292888 update translation template and add missing files 2013-08-27 22:28:34 +09:00
Koichi Akabe 8a7538338f merge with trunk 2013-08-27 22:23:46 +09:00
Koichi Akabe c088bd776e fix spelling errors and invalid line breaking 2013-08-27 21:56:25 +09:00
Tom Rothamel 7a2232ee46 Remove debugging prints. 2013-08-27 01:39:05 -04:00
Tom Rothamel d52067a8d2 Run expensive operations (unpacks, file copies, and tars) in a
background thread.
2013-08-27 01:33:27 -04:00
Tom Rothamel 821344d0f2 Deal with empty strings, remove print. 2013-08-26 23:51:38 -04:00
Tom Rothamel 2536f989c7 Fixes to get working on Windows. 2013-08-26 23:15:27 -04:00
Tom Rothamel 828cb7dc3b Lexer.advance should return True and False.
This is documented in 000statements.rpy.
2013-08-24 10:35:32 -04:00
Tom Rothamel eac8b86fcf Use the text color for console output. 2013-08-24 00:51:41 -04:00
Tom Rothamel ef13f95cc2 Android improvements.
* Status feedback.
* Tooltips.
* Easy way to edit DownloaderService.java.
2013-08-23 00:02:10 -04:00
Tom Rothamel 3fa528cca1 Deal with \r when tailing output. 2013-08-22 01:07:17 -04:00
Tom Rothamel 585d2185bc The android install_sdk command works. 2013-08-22 00:59:39 -04:00
kyouryuukunn 817c43ed75 fix the spell miss in involke_yesno_prompt 2013-08-21 17:59:11 +09:00
Tom Rothamel ba75191d37 Downloader progress & android integration. 2013-08-21 00:12:32 -04:00
Tom Rothamel df8dfa0ddb Add a threaded downloader class.
This class supports getting progress and cancellation.
2013-08-20 23:55:36 -04:00
Tom Rothamel 093269ebcd Let the user cancel expensive operations. 2013-08-20 00:54:06 -04:00
Tom Rothamel 556ab591f9 Add a refresh button. 2013-08-19 23:50:14 -04:00
Tom Rothamel a91727c886 Minor code cleanups. 2013-08-19 22:58:16 -04:00
Tom Rothamel ff567918b1 Documentation inc changes (mostly whitespace-related). 2013-08-19 00:15:37 -04:00
Tom Rothamel e4f16f0d4e Documentation changes. 2013-08-19 00:15:24 -04:00
Tom Rothamel 98f3488520 Display text output while running android build commands. 2013-08-19 00:14:59 -04:00
Koichi Akabe ac7830ff50 update translation template 2013-08-09 20:43:31 +09:00
Koichi Akabe 12d60b81b8 merge with trunk 2013-08-09 20:36:48 +09:00
Koichi Akabe 8744787348 fix documentation errors
fix Japanese translation
2013-08-09 07:43:37 +09:00
Tom Rothamel fb37b423bd Add the ability to tail a file to the launcher.
Start work on running android processes.
2013-08-06 23:45:21 -04:00
Tom Rothamel 5e171a3ac9 Add _with_none to renpy.call_screen. 2013-08-04 20:44:23 -04:00
Tom Rothamel f8ffb1641f Create a GUI interface for Android.
Right now, we're able to configure an android build through the
launcher.
2013-07-29 10:56:52 -04:00
Tom Rothamel eb86123a47 Add interface.choice, which allow the launcher to ask a question. 2013-07-28 23:25:39 -04:00
Tom Rothamel cd1e6e7766 Ensure _main_menu is always set on the context. 2013-07-23 23:39:15 -04:00
Tom Rothamel 2fa5056ffd Cache compiled conditions for ConditionSwitch.
Previously, were re-compiling the expressions each time the
ConditionSwitch ran, which was leading to performance problem
when there was an absurdly large number of conditions.
2013-07-22 09:06:40 -04:00
Tom Rothamel ebe6b092a7 Allow _Config to be loaded.
This prevents SetVariable(config, "something", True) from causing a
problem. (This code is still not a good idea.)
2013-07-21 23:56:54 -04:00
Tom Rothamel 78a37292cc Add tooltips to describe the emulators. 2013-07-21 14:55:19 -04:00
Tom Rothamel 749a83d28b Basic android launcher screen, including the ability to launch
"emulators".
2013-07-21 14:41:44 -04:00
Tom Rothamel 91a8aa22b7 Fix autosave. 2013-07-20 12:40:10 -04:00
Tom Rothamel f7084cc07b Merge pull request #113 from kyouryuukunn/improve_autosave
Improve autosave
2013-07-18 18:56:00 -07:00
kyouryuukunn fa900941d5 Also check autosave() 2013-07-17 17:22:37 +09:00
kyouryuukunn 4da5cea54c Don't check when return the main menu 2013-07-17 17:11:35 +09:00
kyouryuukunn d83ab22d45 don't do the autosave in the main menu 2013-07-17 17:11:35 +09:00
kyouryuukunn c1229f65a1 Also do the autosave when return to the main menu 2013-07-17 17:11:34 +09:00
Tom Rothamel 8b8bf8d6aa Merge pull request #117 from kyouryuukunn/sensitive_of_skip
disable Skip if skip_unseen is false and in unseen
2013-07-16 18:21:05 -07:00
Tom Rothamel 08200cb5e8 Merge pull request #119 from kyouryuukunn/improve_fast_skip
Make fast-skipping stop when encountering unseen text, if skip_unseen is False.
2013-07-16 18:20:36 -07:00
Tom Rothamel bce5bb7d14 Display an indicator showing the TV-unsafe area. 2013-07-14 21:52:47 -04:00
kyouryuukunn f07fed4804 disable Skip if skip_unseen is false and in unseen 2013-07-15 10:39:43 +09:00
Tom Rothamel 8112bd6af4 Code to emulate a TV-based device.
Right now, this tries to emulate an OUYA console.
2013-07-14 20:27:06 -04:00
Tom Rothamel e0443512e6 Implement the touch-screen emulator.
This more-or-less emulates an android device.
2013-07-14 19:55:28 -04:00
Tom Rothamel cbfe972ace Start work on interface emulator. 2013-07-14 19:03:33 -04:00
kyouryuukunn e078700af9 stop fastskip in unseen 2013-07-15 03:08:08 +09:00
Tom Rothamel 0c74863be9 Remove spurious whitespace. 2013-07-14 12:00:15 -04:00
Tom Rothamel 2779280b83 Make ADVCharacter.__str__ handle dynamic characters. 2013-07-14 11:36:16 -04:00
Tom Rothamel 176c86a73e Merge pull request #120 from ckoepp/master
Added __str__ to ADVCharacter class
2013-07-14 08:32:57 -07:00
Christian Koepp 694c2d9e85 added __str__ to ADVCharacter class 2013-07-14 09:57:26 +02:00
Tom Rothamel 7fd7dba118 Fix rollback in Android movie playback. 2013-07-14 01:29:58 -04:00
Tom Rothamel b998b4c967 Add video playback for Android. 2013-07-14 01:06:29 -04:00
Tom Rothamel 206eb4d2cb Update docs. 2013-07-12 22:59:26 -04:00
Tom Rothamel bbee178ff9 Merge pull request #115 from kyouryuukunn/add_funcs_to_MusicRoom
Add funcs to music room
2013-07-12 19:54:27 -07:00
Tom Rothamel 67775552b5 Improve the gallery get_fraction function. 2013-07-12 22:50:23 -04:00
Tom Rothamel 54f02890cb Merge pull request #114 from kyouryuukunn/add_gallery_fraction
add Gallery get_fraction
2013-07-12 19:35:03 -07:00
Tom Rothamel b7bce5efd2 OUYA detection, and a new set of variants, based on Android screen sizes. 2013-07-07 19:47:49 -04:00
Tom Rothamel 8f13c8e37a Fix renpy.list_files when accessing an android APK.
Fixes #116.
2013-07-07 15:49:50 -04:00
kyouryuukunn eccc452d80 add MusicRoom TogglePlay 2013-06-29 12:43:48 +09:00
kyouryuukunn 7a1c36f8db add MusicRoom random play 2013-06-29 12:42:23 +09:00
kyouryuukunn 654095786e add Gallery get_fraction 2013-06-29 10:52:57 +09:00
Tom Rothamel c12adecf9f Bump versions. 2013-06-26 08:05:53 -04:00
Tom Rothamel fc6013c5de Use the correct shader program for imageblends. 2013-06-26 07:57:29 -04:00
Tom Rothamel 3dd9f07fe2 Add changelog. 2013-06-26 07:53:04 -04:00
Tom Rothamel 5308fdd0b8 Skip sets proper values for config.skipping.
This:

* Displays the skip indicator.
* Allows for fast (to-next-menu) skipping.
* Fixes #97.
2013-06-24 22:37:49 -04:00
Tom Rothamel 273d1e296c Apply drag-drop fix. (Thank you, Kinsman.)
Fixes #99.
2013-06-24 22:24:10 -04:00
Tom Rothamel 152af7dc7b Changes to improve compatibility with very old Ren'Py games.
These were required to get the Ren'Py 5.0 demo to run. (You'll need
to create a script_version.rpy file set to (5, 0, 0) to get things
actually working.)
2013-06-20 17:58:15 -04:00
Tom Rothamel 43b34f22a3 Bump version. 2013-06-17 20:22:49 -04:00
Tom Rothamel 3330b451d0 Build on android-8. 2013-06-17 20:22:38 -04:00
Tom Rothamel 5290296952 Print the android savedir to stdout/logcat.
I just have the feeling this will come in handy one day.
2013-06-17 01:58:14 -04:00
Tom Rothamel 8fc784aef5 Place logs and traceback.txt into renpy.config.logdir.
On android, this is always placed on external storage, so we can
get to it.
2013-06-17 01:51:19 -04:00
Tom Rothamel 110c8b890b Change the search path for saves on android.
We look in:

* The public directory used by very old RAPT versions.
* The private directory used by newer RAPT versions.
* The getExternalFilesDir directory, used by the newest RAPT versions.

This means that saves will now be placed in a public place, so they
can be copied and otherwise shared.
2013-06-17 01:36:27 -04:00
Tom Rothamel b6c686d770 Do not looks for assets on the android filesystem.
In recent RAPTs we won't put anything there. What's worse, older games
might have left files there, which will interfere with our newer
code.
2013-06-17 00:07:54 -04:00
Tom Rothamel 6358db88ff Never invoke the editor on android. 2013-06-17 00:07:44 -04:00
Tom Rothamel b2611fd613 Use different shaders for clipping and no-clipping cases.
The clipping support in the shaders causes a noticable performance
hit on Android, and is rarely used. This fixes that in the common
case.
2013-06-16 22:25:46 -04:00
Tom Rothamel 5eb3af0188 Update android packaging docs to match the new RAPT. 2013-06-10 01:45:13 -04:00
Tom Rothamel ad71c17f77 Prevent import recursion that took place if utf-8 was not imported
before the Ren'Py loader was initialized.

This actually happend on Android.
2013-06-10 01:36:52 -04:00
Tom Rothamel 0d7dec8e4e Merge pull request #109 from JaHIY/master
add a variable set the minimum number of component in automatic_images
2013-06-07 20:26:29 -07:00
Tom Rothamel 112fbbfc08 Return the correct value from renpy.call_in_new_context. 2013-06-07 23:02:15 -04:00
JaHIY 4ee5240c72 change config.automatic_images_minimum_component to
config.automatic_images_minimum_components
2013-06-07 22:29:34 +08:00
JaHIY 025e359394 Now developers can set the minimum number of component 2013-06-07 20:04:31 +08:00
Tom Rothamel 143bcfad08 Enable minimize and quit shortcuts in the launcher. 2013-06-05 10:11:27 -04:00
Tom Rothamel a39ebd13e0 Check in the changelog. 2013-06-04 23:43:42 -04:00
Tom Rothamel e7c0a5f19f Check in problems.rst. 2013-06-03 23:26:46 -04:00
Tom Rothamel f0b03dc426 Add the Flatten displayable to Ren'Py. 2013-06-03 23:24:53 -04:00
Tom Rothamel 3d2ad79b6b Document additive blending. 2013-06-03 23:04:13 -04:00
Tom Rothamel 9f28a93c56 Deal with r.over in the sprite manager. 2013-06-03 23:00:25 -04:00
Tom Rothamel 386dd1d799 Deal (improperly) with additive blending in the software renderer.
When additive blending is 1.0, the software renderer will not
display an image. This is probably preferable to the image
displaying incorrectly, since they're likely to be effect
images.
2013-06-03 22:55:28 -04:00
Tom Rothamel e85ebf3a50 Add additive blending to Transform. 2013-06-03 22:30:05 -04:00
Tom Rothamel 81eb2e6f42 Additive blending in the GL renderer.
This commit adds in the backend support, for varying the additive
blending factor.

Additive blending will not be added to the (mostly obsolete) software
renderer. Instead, added a way to test if the current renderer
supports additive blending.
2013-06-03 22:11:29 -04:00
Tom Rothamel 9d021a2ec1 Bump version to 6.15.5. 2013-06-02 23:32:06 -04:00
Tom Rothamel 439fac65e2 Remove assert statements.
Thes won't run when optimization is enabled, which is the default
for Ren'Py. It's better to eliminate them entirely, so we have
the same configuration in testing and production.
2013-06-02 20:46:19 -04:00
Tom Rothamel dee484a16b Error message fix. 2013-06-02 16:57:16 -04:00
Tom Rothamel 90457d6f20 Fix translation problem.
Returned the wrong value when we used RENPY_UPDATE_STRINGS
to translate a string with a {#translation_comment} in it.
2013-06-02 13:42:16 -04:00
Tom Rothamel 245c30d7a7 Force font autohinting.
This was the behavior of of Ren'Py until switching to Freetype 2.4. The
autohinter more resembles the older Ren'Pys, seems to produce better
forms on most fonts, and fixes spacing issues on broken fonts.
2013-05-27 23:39:07 -04:00
Tom Rothamel 81b28293ca Allow * in classification patterns to match directories as well as
files.

Fixes #106.
2013-05-26 00:10:08 -04:00
Tom Rothamel 392f71b214 Use secure permissions in zip and tar files.
Previously, we used 666 and 777, and expected the user's umask to take
care of adjusting the permissions. Unfortunately, info-zip overrides
the umask, writing world-writable files to disk.

Thanks to Spiky Caterpillar for the bug and the fix.
2013-05-23 00:37:26 -04:00
Tom Rothamel 257a5281ed Make use of avresample optional.
This lets us compile on platforms that do not support it, using
the old audio_resample code.
2013-05-21 00:25:09 -04:00
Tom Rothamel d44f70a145 Revert "Update ffdecode.c to work with newer libav."
This reverts commit 1ffd4f97fc.
2013-05-21 00:00:45 -04:00
Tom Rothamel ec9198f25d Fix one more deprecation with newer libav. 2013-05-20 23:54:37 -04:00
Tom Rothamel 1ffd4f97fc Update ffdecode.c to work with newer libav.
This gets rid of deprecation warnings when building ffdecode.c, and
adds a dependency on the avsample library.
2013-05-20 23:28:14 -04:00
Tom Rothamel e8968252ab Skip whitespace before default parameters and arguments.
Fixes #101.
2013-05-06 22:58:34 -04:00
Tom Rothamel ae618ddd76 Allow the creator to cancel out of create file and generate translation.
Fixes #100.
2013-05-04 12:24:30 -04:00
Koichi Akabe 73d36d34c8 update translation templates 2013-04-21 18:31:44 +09:00
Koichi Akabe 4126b0574a merge with trunk 2013-04-21 18:15:26 +09:00
Tom Rothamel 005aa1a64c Read assets from an expansion file if one is available on Android. 2013-04-14 22:51:55 -04:00
Tom Rothamel a63231d36f Merge branch 'master' into android 2013-04-13 23:06:26 -04:00
Tom Rothamel db530f7def Document config.start_callbacks. 2013-04-07 20:00:47 -04:00
Tom Rothamel 627261f51d Clarify what the Ren'Py license applies to. 2013-04-07 19:43:58 -04:00
Tom Rothamel d080b71f29 Make exclude_empty_directories deal with non-terminal directories. 2013-04-07 11:13:00 -04:00
Tom Rothamel 0a62195625 Update changelog, document problems. 2013-04-06 23:11:51 -04:00
Tom Rothamel 571bb43459 Bump version to 6.15.4. 2013-04-06 23:00:10 -04:00
Tom Rothamel 817b9d5c9f Fix race condition in the updater.
If the update finished while we were checking progress, zsync
wouldn't rename the file and the update would fail.
2013-04-06 22:55:30 -04:00
Tom Rothamel 6f3fa9bf8d Make loads after rollback non-greedy.
A greedy load after rollback can roll-back through with statements,
which are turned into with None statements until the start of the
next interaction. (Which is sensible behavior for the rollback
case, but fails when an after_load transition is scheduled.)

Fixes #95.
2013-04-06 21:13:47 -04:00
Tom Rothamel 2de5a7d9f7 Add build.exclude_empty_directories variable. 2013-04-06 20:58:10 -04:00
Tom Rothamel d26f1a65e8 Add the ability to include empty directories to the zip format.
Per http://lemmasoft.renai.us/forums/viewtopic.php?f=32&t=2023
2013-04-06 18:31:59 -04:00
Tom Rothamel 667c2e59d3 Do not set the window size while entering/leaving fullscreen mode. 2013-04-06 17:52:12 -04:00
Tom Rothamel b4411a027f Fix documentation issues.
Fixes #89.
2013-04-06 13:53:20 -04:00
Tom Rothamel 142831ec44 Remove duplicated docs.
Fixes #90.
2013-04-06 13:19:48 -04:00
Tom Rothamel 2dd58759de Remove extraneous debug print. 2013-04-04 19:06:55 -04:00
Tom Rothamel 866f3a11b2 Use nogil_copy to copy surfaces.
Previously, we used the angle copy function to copy surfaces, which
used the pygame blit function. The pygame blit function was more
complex and held the GIL while blitting, and led to slowdowns in
loading.

Nogil_copy appears to be safe for Ren'Py, which doesn't use software
surfaces.
2013-04-04 12:13:56 -04:00
Tom Rothamel 8a2d779320 Spend less time with the image cache locked.
The image cache is no longer locked for expensive operations,
such as image loads. While this may cause us to load an image
twice (in rare circumstances), it also lets us preload images
without blocking loads frome the main thread.
2013-04-04 03:22:36 -04:00
Tom Rothamel 2ef8cd4c3f Remove obsolete renpy_font module. 2013-04-02 23:42:21 -04:00
Tom Rothamel 88ec1e66e6 Use rwobject.c that's included in pygame, rather than building
our own.
2013-04-02 23:40:32 -04:00
Tom Rothamel f6bfeefc8e Merge branch 'master' into android 2013-04-02 20:05:55 -04:00
Tom Rothamel bbdf9023fe Check in tkaskdir. 2013-04-02 20:05:34 -04:00
Tom Rothamel b0070122f8 Merge branch 'master' into android 2013-03-31 21:42:49 -04:00
Tom Rothamel ad51bfb30f Kick off preload thread at the start of image prediction, rather
than the end of an interaction.

Kicking it off at the end of the interaction lead to bad behavior
where the start of the next interaction would fight with the
preload thread for the image cache lock.
2013-03-31 17:56:16 -04:00
Tom Rothamel d15ae51825 New add.py script that combines the old add.sh and tag.py scripts,
and also does the dl symlinking.
2013-03-30 12:51:03 -04:00
Tom Rothamel 2efa265983 Bump version. 2013-03-30 11:50:21 -04:00
Tom Rothamel cc6513c93a Paranoia regarding cases where Transform.event is called before
Transform.render.

Closes #87.
2013-03-29 23:40:41 -04:00
Tom Rothamel a81865484c Ensure that we render displayables before passing events to them,
even if video is playing.
2013-03-29 23:34:11 -04:00
Tom Rothamel d70eb13cb0 Wait until a frame is available before drawing the screen while
displaying full-screen video.

Fixes #85.
2013-03-29 23:18:00 -04:00
Tom Rothamel 4b5d94eeb9 Re-offset a viewport if its size changes before the first event has
been processed.

This is necessary to deal with the way a size may offer the viewport
a smaller area than initially necessary, once scrollbars take up
some space.

Fixes #88.
2013-03-29 20:32:51 -04:00
Tom Rothamel 5674a4ddac Produce an error when dealing with logical lines longer than 64K
characters in size.

Line parsing can be N**2, so this turns a really slow error into one
that takes a reasonable amount of time.
2013-03-29 00:28:13 -04:00
Tom Rothamel 5bb6483ab4 When a page is given specified to FileSave, use it to determine
if the action should be sensitive.

This was preventing QuickSave from working when the default file page
was set to auto.

Fixes #82.
2013-03-29 00:15:14 -04:00
Tom Rothamel f62e4b6eb7 Add more protection to pygame.event.post statements.
Fixes #86.
2013-03-28 23:46:30 -04:00
Tom Rothamel c54a613393 Bars only run hover and unhover actions once. 2013-03-28 22:57:12 -04:00
Tom Rothamel 2c4be00267 Ensure image fonts include U+200B, since we need that for
input to work.
2013-03-27 21:04:29 -04:00
Tom Rothamel 0b8c22e0d8 Sort SpriteManager sprites by their zorder.
Thanks to Kinsman for the fix.
2013-03-27 10:11:45 -04:00
Tom Rothamel 65a7dca95f Fix random segfaulting related to TTF lookup tables, especially on shift+R.
The segfaulting occured when a TTF Font contains a GSUB table with a
Lookup type other than one. This caused us to initialize a data
structure that represents the lookup table, but never fill it in.

Rarely, one of these tables would hava field initalized to 1 or 2. In
that case, we'd try to free associated data that was never properly
initialized, and we'd crash.

The fix was to intialize the data structures before use.
2013-03-27 00:06:48 -04:00
Tom Rothamel fdcfaface0 Do inexpensive prediction while displaying frames.
This involved breaking the prediction coroutine, and the context
prediction routine up further. By predicting one statement at a time,
we can interleve predicitions with frame display, and prevent
dissolves or ATL transforms from starving the image predictor, at
least in simple (non-screen) cases.
2013-03-26 00:58:33 -04:00
Tom Rothamel 5f08884b52 Predict images used in ATL transforms that are part of show/scene
statements.
2013-03-25 23:36:46 -04:00
Tom Rothamel 3595eee11c Prevent memory leaks via the rollback log.
Before this change, code that created and then immediately modified a
list, dict, set, or object that was rollback-able would cause a small
memory leak until the end of the interaction.
2013-03-24 23:51:13 -04:00
Tom Rothamel b33eb54c34 Bound the layout cache size.
This helps ensure that code that creates many text objects in a
single interaction will now consume unbounded memory if it lets
those Text objects be GCed.
2013-03-24 23:49:02 -04:00
Tom Rothamel c86fc743bc Change memory profile to show the differen between the number of
objects at each call.
2013-03-24 23:48:39 -04:00
Tom Rothamel 10b82603b9 Do not translate the who-prefix or who-suffix if new-style
subsititutions are disabled.
2013-03-23 20:13:04 -04:00
Tom Rothamel 1a1ae36299 Quit the display when doing a forced resize (like when clicking the
Window preference.)

This prevents the possibility of spurious resize events, and also
prevents the black bars from appearing on the screen after such
a resize.
2013-03-20 23:26:36 -04:00
Tom Rothamel cc004c00f0 Merge branch 'master' into android 2013-03-19 23:30:51 -04:00
Tom Rothamel cda96afd14 Ensure an over-full video queue can't starve the audio queue,
and vice-versa.
2013-03-19 00:04:18 -04:00
Tom Rothamel 966630ea16 Write .zip files out in large chunks.
Previously, we would load entire files into RAM, compress the entire
file, and write out the compressed data. This was breaking down on
large .rpas, hence the change.
2013-03-17 18:42:19 -04:00
Tom Rothamel 8c746bdccc Work around fonts that don't have the ZWSP (U+200b) character.
We use ZWSP in input so we properly size an empty line. Some fonts
do not include this character, and replace it with an undefined
character glyph (often a square).

This fix prevents Ren'Py from rendering the ZWSP, making the
problem invisible to the user.
2013-03-16 22:49:34 -04:00
Tom Rothamel 4fac7da3bb Start work on documenting the python statements. 2013-03-10 23:32:44 -04:00
Tom Rothamel 4045958cd2 Bump version. 2013-03-09 23:11:51 -05:00
Tom Rothamel 45155a9ff4 Use python+tkinter to prompt for the projects directory.
Fixes #77.
2013-03-09 23:02:21 -05:00
Tom Rothamel 83ad789654 Improve OpenGL ES2 support. 2013-03-08 23:44:10 -05:00
Tom Rothamel 21eaa5ee9c Merge branch 'master' into android 2013-03-08 21:31:50 -05:00
Koichi Akabe e2bc9aa6d0 update translation templates 2013-03-08 20:05:53 +09:00
Koichi Akabe 670721ac52 merge with trunk 2013-03-08 20:02:42 +09:00
Tom Rothamel 69bcd84d5d Fix doc typos.
Thanks, Koichi.
2013-03-08 00:57:07 -05:00
Tom Rothamel 7357fa4c5b Allow the music room to loop tracks, rather than advancing them. 2013-03-07 11:38:32 -05:00
Tom Rothamel d51c768112 Document renpy.input. 2013-03-06 22:44:28 -05:00
Tom Rothamel 32ae4fef3a Bump version. 2013-03-04 10:09:20 -05:00
Tom Rothamel fd5ee77f1c Force use of shaders on android.
The auto-detect code fails on ES.
2013-03-04 01:15:56 -05:00
Tom Rothamel b9acbfccd7 Changes required to support android.
The new android support uses GL2, so we need to change some defines
to use it.
2013-03-04 00:00:08 -05:00
Tom Rothamel d05059e64d Stop ongoing transitions when we enter a new context.
A minor performance improvement, which also prevents the side-effects
of the new code being surrounded by old transitions.
2013-03-03 01:08:10 -05:00
Tom Rothamel bc80e38bb5 Change how we compensate for times in a restarted move transition.
The previous method was causing problems where when we created
a new screen under a transition, the new screen would get the
wrong creation time.
2013-03-03 00:48:29 -05:00
Tom Rothamel 838233a68f Doc fix. 2013-03-02 21:27:35 -05:00
Tom Rothamel 6968d973a6 Fix compatibility between OldMoveTransition and define.move_transitions.
Fixes #74.
2013-03-02 12:28:53 -05:00
Tom Rothamel 199f6aa70c Include the language as part of a rollback copy.
This prevents us from running the language change code whenever we
do a rollback when a non-default language is enabled.

Fixes #73.
2013-02-28 22:30:29 -05:00
Koichi Akabe e195ea5221 update translation template 2013-02-28 22:41:41 +09:00
Koichi Akabe ea1ebb4bba merge with trunk 2013-02-28 22:40:44 +09:00
Tom Rothamel b7e33bb2b9 Documentation fix. 2013-02-28 00:01:44 -05:00
Tom Rothamel d2d777be0c Doc fix. 2013-02-27 23:59:49 -05:00
Tom Rothamel 4c924b4971 Documentation fix. 2013-02-27 23:55:41 -05:00
Tom Rothamel ddd4a1a4ea Fix mistake. 2013-02-27 23:54:57 -05:00
Tom Rothamel c68f240061 Fix more launch options. 2013-02-25 09:42:49 -05:00
Tom Rothamel 5d9d4955ff Allow symlinks to renpy.py. 2013-02-25 09:26:35 -05:00
Tom Rothamel fb4eeaaaeb Update sphinx docs. 2013-02-24 22:51:49 -05:00
Tom Rothamel a0b04c2d99 Allow ffdecode.c to compile with ffmpeg.
Patch thanks to Maks Verver.
2013-02-24 22:32:28 -05:00
Koichi Akabe 6a60039aac update translation template 2013-02-25 09:07:56 +09:00
Koichi Akabe 96485ec8d0 merge with trunk 2013-02-25 09:05:30 +09:00
Tom Rothamel 86b38b5e40 Add load and save commands to the console. 2013-02-23 22:04:14 -05:00
Tom Rothamel 2e6ff091e2 Implement config.console_callback. 2013-02-23 21:42:36 -05:00
Tom Rothamel e91972589c Change the console activation key to shift+O only.
The backtick key invokes IMEs, which can confuse Ren'Py.
2013-02-23 21:26:05 -05:00
Tom Rothamel eb5a8b8beb Fix translation documentation problems reported by Koichi. 2013-02-22 23:55:15 -05:00
Tom Rothamel e1320c4661 Restart interaction on FieldValue change. Add VariableValue. 2013-02-21 23:57:05 -05:00
Tom Rothamel 2db0d397a6 Add a README that shows up on github. 2013-02-21 23:05:30 -05:00
Tom Rothamel 7f85af9c54 The after checkout script can now copy the files necessary to run
Ren'Py from a built Ren'Py.
2013-02-21 22:23:45 -05:00
Tom Rothamel 3a981be8c6 Delete obsolete scripts. 2013-02-21 21:01:18 -05:00
Tom Rothamel 95b51dae6f Style _default for the Japanese translation. 2013-02-20 23:01:59 -05:00
Tom Rothamel 9eef533e8a Edit all no longer opens TL files. 2013-02-20 22:43:05 -05:00
Tom Rothamel 8e4930d031 Run python with -E flag.
This ignores a PYTHONPATH the user has lying around for some other reason.
2013-02-20 22:40:31 -05:00
Koichi Akabe 2b9621e7cf add translation template 2013-02-21 10:01:56 +09:00
Koichi Akabe 747bf2c3c1 add gettext target to support documentation translation 2013-02-21 09:56:19 +09:00
Tom Rothamel e398518bd1 Do not modify the meta path on shift+R. 2013-02-19 23:54:32 -05:00
Tom Rothamel 48bdab0ed5 Don't use non-existent field in console. 2013-02-19 23:50:28 -05:00
Tom Rothamel ab122f92ad Allow the user to type { and } at the console. 2013-02-19 23:40:43 -05:00
Tom Rothamel ef0b374959 Fix space quoting in renpy.sh. 2013-02-19 22:29:36 -05:00
Tom Rothamel dbfc04afc4 If pythonw doesn't exist, launch with sys.executable. 2013-02-18 23:00:51 -05:00
Koichi Akabe 7d6687f46f update Japanese translation 2013-02-18 22:35:20 -05:00
Tom Rothamel f8483ec22e Add shift+O as a way of invoking the console. 2013-02-18 22:01:23 -05:00
Tom Rothamel 0b690bbe43 Add the __ function, which immediately translates a string. 2013-02-18 21:25:45 -05:00
Tom Rothamel 871aa08f41 Ensure that _restart is set, even if we restart at the main menu. 2013-02-18 21:07:03 -05:00
Tom Rothamel e2c2e2e841 Defer the import of pygame.macosx.
This seems necessary to get it to import on OS X 10.6.8.
2013-02-18 19:32:19 -05:00
Tom Rothamel ba9dfa8f4c Make the translation code unicode-safe.
Also, put a TODO before each translation.
2013-02-17 22:11:13 -05:00
Tom Rothamel cad5b436e5 Doc update. 2013-02-17 18:55:11 -05:00
Tom Rothamel 312fdcea96 Remove Ren'Py 7 mention from tutorial; add edgescroll demo. 2013-02-17 17:51:10 -05:00
Tom Rothamel 518a969aab Fix bug in edgescroll that prevented scrolling from happening while the mouse was being moved. 2013-02-17 17:50:47 -05:00
Tom Rothamel e6687bd7b8 Run zsync in the update directory.
At least on mac, it seems to want to write files to the current
directory. By default that's the root directory, and hence
problematic.
2013-02-17 14:24:51 -05:00
Tom Rothamel 74260589f4 Do not package debug output. 2013-02-17 13:51:23 -05:00
Tom Rothamel aefd6e6a9e Tweak mac and windows /lib build patterns. 2013-02-17 11:44:50 -05:00
Tom Rothamel 58e60ee148 Fix editra build rules. 2013-02-17 01:28:49 -05:00
Tom Rothamel fdc2b21e0b When the RSA module is missing, do not offer an update. 2013-02-17 00:20:19 -05:00
Tom Rothamel 9d6c15e10b Send stdout and stderr to null when we don't have stdout or stderr.
This is the case when running on windows under pythonw (the default).
2013-02-16 22:48:27 -05:00
Tom Rothamel f271d3890b Use python.exe to launch projects on windows. 2013-02-16 21:11:07 -05:00
Tom Rothamel 69a4a29014 Remove obsolete windows build files. 2013-02-16 12:39:30 -05:00
Tom Rothamel f72771c026 Write lint.txt in ascii mode, so the files we produce can be read
on windows.
2013-02-15 21:47:10 -05:00
Tom Rothamel d2e05c481f Change how we define eruby_ja.
This lets it be linted properly.
2013-02-15 21:42:53 -05:00
Tom Rothamel f999cfc2c7 Translate the date format string into Japanese. 2013-02-15 01:02:20 -05:00
Tom Rothamel 6c7812b8a4 Remove locale support.
It didn't work on windows, since windows locales work using the ANSI
code page, and there's no way to get them to use UTF-8 or unicode.
(Also, having multiple locale names is asking for problems.)
2013-02-15 00:55:06 -05:00
Tom Rothamel b841358e22 Merge branch 'fix-error-ruby-ja' of https://github.com/vbkaisetsu/renpy into devel 2013-02-15 00:28:51 -05:00
Koichi Akabe 3419343e85 fix errors around ruby 2013-02-15 13:40:00 +09:00
Tom Rothamel 917fc68e27 Document the new mac requirements. 2013-02-14 23:28:53 -05:00
Tom Rothamel fadd0279a8 Add the optimize option to the distribute command line. 2013-02-14 23:28:37 -05:00
Tom Rothamel bbcc75dd2d More changelog updates. 2013-02-14 22:55:17 -05:00
Tom Rothamel f0b44d8c02 Update changelog. 2013-02-13 23:34:35 -05:00
Tom Rothamel eddf89697d Add the renpy.end_interaction function.
This creates an exception that ends the current interaction. This can
be used in the render and event methods of a creator-defined
displayable.
2013-02-13 22:00:09 -05:00
Tom Rothamel 92a155c780 Implement the renpy.set_locale method, which translation use to set the locale.
Modify the japanese translation of the tutorial to use it.
2013-02-13 15:51:56 -05:00
Tom Rothamel 6661e6e058 As part of a new approach to locales, rename back to japanese. 2013-02-13 15:08:06 -05:00
Tom Rothamel 68c49a9aa1 Merge pull request #67 from vbkaisetsu/i18n-confirm-n-locale
Please merge i18n-confirm-n-locale
2013-02-13 10:59:52 -08:00
Koichi Akabe 1ae7d4bd54 update font glyphs
The following is new glyph: U+672A
2013-02-13 17:25:25 +09:00
Koichi Akabe 8330ef062e update translation to support changing locale
fix font location
2013-02-13 16:55:53 +09:00
Koichi Akabe 5493ba998e change the locale when the language is changed 2013-02-13 16:35:11 +09:00
Koichi Akabe ed59d8a351 update Japanese translation 2013-02-13 13:38:00 +09:00
Koichi Akabe 077def41ae use _ function for confirmation messages 2013-02-13 13:32:54 +09:00
Tom Rothamel 7480a33eaf Make the file slot info translatable. 2013-02-12 17:59:18 -05:00
Tom Rothamel 4e1e8832cc Allow for tutorial-only sections of screens.rpy.
We generate template/game/screens.rpy from tutorial/game/screens.rpy -
but now, the tutorial version has the language preference in it. We don't
want the language preference to be in the default template, so we use
distribute.py to filter it out.
2013-02-12 17:51:15 -05:00
Tom Rothamel fe290a42c1 Do not distribute the launcher/game/themes directory.
This doesn't exist in git, but I use it to test the launcher theming
support - eliminating it means I don't have to remember to delete
the directory.
2013-02-12 17:37:57 -05:00
Tom Rothamel 54ae627ed2 Improve lint to count words and characters by language, and to count images and screens. 2013-02-12 16:59:10 -05:00
Tom Rothamel a3d30e9012 Update the VL-Gothic license file to include all relevant info. 2013-02-12 12:35:00 -05:00
Tom Rothamel 021e9c6335 Move VL-Gothic files into tl/japanese 2013-02-12 12:34:45 -05:00
Tom Rothamel 3833f01f2d Merge pull request #58 from vbkaisetsu/tutorial-i18n-l10n-ja
Merge japanese translation of tutorial game.
2013-02-12 06:50:22 -08:00
Tom Rothamel 2060dc288e Remove obsolete voice readme file. 2013-02-12 09:48:46 -05:00
Tom Rothamel fe10a1d57e Voice documentation. 2013-02-12 09:34:56 -05:00
Tom Rothamel 563e50334c Various voice actions:
* SetVoiceMute - sets the mute of a voice tag.
* ToggleVoiceMute - toggles the mute of a voice tag.
* VoiceReplay - replays the current voice.
2013-02-12 00:41:05 -05:00
Tom Rothamel a630c1daa4 Adjust indentation level. 2013-02-12 00:24:40 -05:00
Tom Rothamel 97380ceae6 Bring the voice mute code to the point where it works. 2013-02-12 00:20:34 -05:00
Tom Rothamel 7f8a4ec63d Various improvments to the voice mute support that was
just merged in.
2013-02-12 00:03:28 -05:00
Tom Rothamel 88eaf9ad53 Merge branch 'voice_enhancement' of git://github.com/odysseystudio/renpy into devel 2013-02-11 23:36:18 -05:00
Koichi Akabe 0e8a7f4b30 add license information for VLGothic 2013-02-11 23:59:46 +09:00
Koichi Akabe 42cd424723 add light-weight font based on VL Gothic 2013-02-11 22:53:55 +09:00
Tom Rothamel d7319907e8 Update the copyright notices to reflect the new year. 2013-02-10 21:41:51 -05:00
Tom Rothamel 3c942cfea1 Rename release. 2013-02-10 21:15:40 -05:00
Tom Rothamel 2884b93971 For clarity's sake, import time from distribute.rpy. 2013-02-10 07:41:36 -05:00
Tom Rothamel 494f445b33 Also call the before_restart code on load.
For the same reasons.
2013-02-09 23:57:16 -05:00
Tom Rothamel f23299fc9a Prevent old screens from updating while the game is restarting.
This prevents an issue that was triggered by an old screen hanging
around during a game restart, but that screen using a variable that
is no longer defined after game start.
2013-02-09 23:45:10 -05:00
Tom Rothamel d53f00a55a Remove incorrect uses of NotImplemented.
Which isn't an exception - it's a return value.
2013-02-08 22:38:40 -05:00
Tom Rothamel 89315c90e8 Wrap a list's rmul operation.
This fixes #65, a bug where [1, 2, 3] * 4 would produce a RevertableList,
but 4 * [1, 2, 3] would produce an unwrapped list (that doesn't
participare in rollback).
2013-02-08 22:32:26 -05:00
Tom Rothamel 3fedc41772 Rename the pythonw executable to use executable_name.
This has the nice behavior that the game we're running winds up being
called <game>, rather than python.
2013-02-06 22:56:30 -05:00
Tom Rothamel da4db2e4a2 Moves/fixes to work with new windows packaging. 2013-02-03 23:25:12 -05:00
Tom Rothamel 7e0f611279 Build mac apps + distribution.
A bunch of small changes, but the big one here is that we now generate
the mac app from scratch, using the plist creation code that was
checked in earlier.
2013-02-02 23:41:58 -05:00
Tom Rothamel 56ff162681 Search for Ren'Py when launched from a mac app. 2013-02-02 00:46:31 -05:00
Tom Rothamel 0eebc91e3d Fix renpy.sh so it works. 2013-02-01 23:28:41 -05:00
Tom Rothamel 284dc98394 Improvements to mac support.
* Write out a correct Info.plist
* Allow renpy.sh to call the new darwin build.
* Call the argv emulator.
2013-02-01 01:55:43 -05:00
Tom Rothamel f11928f91f Basic info.plist writer. 2013-01-30 23:56:50 -05:00
Tom Rothamel 1bcbdc1411 Add viewport edge scrolling.
This is a mode where the viewport automatically scrolls when the mouse
approaches the viewport's edges.

Fixes #17.
2013-01-29 23:26:36 -05:00
Tom Rothamel 19067d10ea Fix last commit. 2013-01-29 17:38:00 -05:00
Tom Rothamel e53c9f596b Make nvl hide and nvl show switch the mode used by window hide and
window show.

Since otherwise, it looks bad.
2013-01-29 17:22:23 -05:00
Tom Rothamel 970420e275 Make key repeat configurable.
Also, use the compat mechanism to disable it for old games, since
there's a small-but-not-zero chance it could break something.
2013-01-27 11:07:16 -05:00
Tom Rothamel 9d3d2877d9 Remove unnecessary code from renpy.sh. 2013-01-26 23:34:25 -05:00
Tom Rothamel 32af9095cb Add the transform_around style property.
Fixes #63.
2013-01-26 00:22:04 -05:00
Tom Rothamel ea6304f4bc Implement the guts of the transform_anchor transform property.
This transforms the anchor using the same matrix as the rest of
the transform, essentially allowing the point around which the
image rotates/zooms to be specified.
2013-01-26 00:02:26 -05:00
Tom Rothamel 695a804813 Tweak side image attribute handling, so it works w/ menus.
Fixes #59.
2013-01-24 11:18:40 -05:00
Tom Rothamel 88d23f22a4 Prevent the time inside an ATL transform from ticking backwards.
This could happy in various cases, such as when the show and hide
operations were called. The result is that the time inside an
interpolate could go massively negative, and we'd get overly-long
delays and other artifacts.
2013-01-24 00:49:00 -05:00
Tom Rothamel 754b6dc069 Don't invert the bar keys when bar_invert is true.
(We already inverted the value, so inverting the keys is redundant.)
2013-01-23 19:39:15 -05:00
Tom Rothamel b72466a1e3 Set keys to repeat. 2013-01-23 19:24:57 -05:00
Tom Rothamel d7d7795b99 Fix a regression that prevented load from working. 2013-01-23 19:17:03 -05:00
Tom Rothamel f4c03d58c9 Force tar times to be integers. 2013-01-22 13:44:03 -05:00
Tom Rothamel 431231ed68 Ensure that the start and end segments of Text are always included
in the list of segments that are shown to the user.

Fixes #60.
2013-01-21 14:59:51 -05:00
Tom Rothamel 34521e8656 Fix mmx bug on mac; remove obsolete script. 2013-01-20 23:47:25 -05:00
Koichi Akabe 16765ff731 Fix wrong translation 2013-01-20 23:11:33 +09:00
Koichi Akabe 2e59973c8d Fix wrong translation 2013-01-20 22:58:37 +09:00
Koichi Akabe e0277b2b59 Add style for translation 2013-01-20 22:12:21 +09:00
Koichi Akabe 91ddb05f27 Add Japanese translation 2013-01-20 21:44:17 +09:00
Koichi Akabe 70b215054d Use a map instead of str.lower() for translation 2013-01-20 21:08:58 +09:00
Koichi Akabe afe596eb7d Use _ function to support i18n in tutorial game 2013-01-20 17:30:06 +09:00
Tom Rothamel 811f04e783 Add Yes/No menu transitions. 2013-01-18 11:25:04 -05:00
Tom Rothamel 38543b0979 More documentation improvements. 2013-01-17 23:54:13 -05:00
Tom Rothamel 0574b03aeb Update changelog to reflect 6.15 work. 2013-01-17 23:31:47 -05:00
Tom Rothamel 460ccfcacb Call slow_done if a character is called with slow text disabled.
This triggers the slow text callback, which might be needed to end
something called in one of the other callbacks. (For example, the
PW-style beeping speech.)
2013-01-16 22:53:27 -05:00
Tom Rothamel 50e0f04b9a Remove warnings. 2013-01-16 11:13:04 -05:00
Tom Rothamel 77bc0f095f Remove eclipse warnings. 2013-01-16 11:12:42 -05:00
Tom Rothamel 064e7f544a Make code match the docs. 2013-01-16 01:25:24 -05:00
Tom Rothamel 06f329ae3b Document tailoring. 2013-01-16 01:23:33 -05:00
Tom Rothamel d05283200b Add the renpy.language_tailor function.
This lets the user tailor the linebreaking algorithm even further by
changing the unicode line breaking classes of individual characters.
2013-01-16 01:21:47 -05:00
Tom Rothamel d700c3ea17 Linebreaking improvements.
* Update the linebreaking to the algorithm and tables in unicode 6.2.
* Implement japanese-strict, japanese-normal, and japanese-loose breaking methods.
2013-01-16 00:47:55 -05:00
Tom Rothamel 3c381320c0 Properly style input screen. 2013-01-14 20:45:33 -05:00
Tom Rothamel 876d07f467 Import the decimal module, so it's included w/ Ren'Py. 2013-01-14 18:18:54 -05:00
Tom Rothamel 691adcb82d Expose the child style property to the screen language.
It was exposed before, but not as a style property. So it didn't work
as well as it could have.
2013-01-13 23:58:08 -05:00
Tom Rothamel 0321b19eaa Move box_reverse and order_reverse into the styles.
This makes it at least moderately plausible that a translation can
change them.
2013-01-13 23:42:31 -05:00
Tom Rothamel 02a84d71a6 Swap the width and height when rendering vertical text. 2013-01-13 22:03:03 -05:00
Tom Rothamel 504a81b86a Remove changelog from git. 2013-01-13 21:03:47 -05:00
Tom Rothamel 0baf603f90 Remove dse from Ren'Py repository. 2013-01-13 14:33:43 -05:00
Tom Rothamel 7593b7a3e3 Remove renpygame from renpy repo. 2013-01-13 14:32:56 -05:00
Tom Rothamel b07a146f27 Dlc test script. 2013-01-13 14:25:37 -05:00
Tom Rothamel 2eee59c530 Add back support for .rpt translation files. 2013-01-13 14:22:11 -05:00
Tom Rothamel 9b50b5bdb5 Translation generation improvements:
* Include commented code as part of the generated translations.
* Generate empty translation statements.
2013-01-13 13:38:11 -05:00
Tom Rothamel 4911348396 Implement the {#...} text tag, to distinguish translatable strings. 2013-01-12 22:32:42 -05:00
Tom Rothamel 2a9759e7d2 Fix a regression that caused us to constantly queue up redraw events. 2013-01-12 22:09:06 -05:00
Tom Rothamel 4366e29c05 ATL xoffset and yoffset now take floats.
Also, document them.
2013-01-12 20:55:39 -05:00
Tom Rothamel c612eef65d Do not try to execute python early code that won't compile.
This prevents a Ren'Py error from masking the original syntax error.
2013-01-12 12:41:51 -05:00
Tom Rothamel 48cd830628 Recompute scene list index after _hide.
Closes #45.
2013-01-11 12:47:54 -05:00
Tom Rothamel 7be08a2e2d renpy.loadable should check in .apk packages. 2013-01-10 22:17:56 -05:00
Tom Rothamel 3d4def2072 Prevent a widget from being grabbed if it's part of a screen
that is being hidden.
2013-01-10 21:57:45 -05:00
Tom Rothamel 259ef699d4 Make bar key bindings reflect bar_invert and bar_vertical. 2013-01-10 20:27:44 -05:00
Tom Rothamel 2a79d00726 Fix screen call/show without arguments. 2013-01-10 20:14:38 -05:00
Tom Rothamel eb27efd9e0 Allow the screen language use statement to pass positional parameters. 2013-01-10 00:31:57 -05:00
Tom Rothamel c94ce0ac7d Screens accept parameters via _args and _kwargs.
Calls to screens supply parameters via those variables.
2013-01-10 00:24:07 -05:00
Tom Rothamel 0acd9a38fa Allow screen language screens to accept parameters. 2013-01-10 00:00:39 -05:00
Tom Rothamel 5a0a60e8ba Factor parameter acceptance code into its own function. 2013-01-09 23:57:55 -05:00
Tom Rothamel 02854ef0a0 Deal with meaningless code from older games that could cause a crash
in 6.14.
2013-01-08 10:28:40 -05:00
Tom Rothamel 62e5b63229 Remove launcher2. 2013-01-07 23:57:20 -05:00
Tom Rothamel c2c537baa2 Add the "Add script file" command to the launcher. 2013-01-07 23:56:45 -05:00
Tom Rothamel 89223eb90f Document launcher skinning. 2013-01-06 23:08:49 -05:00
Tom Rothamel 2ba95ea13b Generate checkbuttons from colors in theme. 2013-01-06 22:11:05 -05:00
Tom Rothamel e4af56c5ae launcher: Add basic themeing support. 2013-01-06 21:54:50 -05:00
Tom Rothamel 5accf191dc If we can't create the tmp directory, use tempfile to make one. 2013-01-06 18:41:56 -05:00
Tom Rothamel a011e15e14 Implement the japanese-alternate language.
This breaks before and after every wide character, which emulates
the algorithm used by Japanese visual novels.

This was discussed at:
http://lemmasoft.renai.us/forums/viewtopic.php?p=242978#p242978
2013-01-06 13:55:15 -05:00
Tom Rothamel 2c9b67c87e Don't use vertical in font_replacement_map, as it would be a
non-backwards-compatible change.
2013-01-05 22:46:48 -05:00
Tom Rothamel 895c8f2dde Document vertical text. 2013-01-05 22:43:24 -05:00
Tom Rothamel 47e5f54776 Document box_reverse and order_reverse. 2013-01-05 22:21:00 -05:00
Tom Rothamel 13ff44ec32 Add order_reverse to vbox, hbox, and fixed.
This reverses the order in which child displayables are blitted to
the screen.
2013-01-05 22:02:09 -05:00
Tom Rothamel 8d03df8553 Implement box_reverse.
This reverses the order of an hbox or vbox's children. For example, in
a box_reversed hbox, the first child will be rightmost, and the last
child will be leftmost.
2013-01-05 21:21:00 -05:00
Tom Rothamel 5bdac85eab Vertical text integration.
Vertical text is now automatically rotated to the vertical
orientation.

Add the vtext image and vcentered character, which are the
vertical-text equivalents of image text and centered.
2013-01-05 14:15:38 -05:00
Tom Rothamel f391f2d9c6 Merge branch 'master' of git://github.com/vbkaisetsu/renpy into devel
This adds vertical text support.
2013-01-05 11:10:14 -05:00
Tom Rothamel ebebd6c6b9 Update translation documentation. 2013-01-05 00:10:30 -05:00
Tom Rothamel e7b4a1d156 Merge remote-tracking branch 'ren/patch-5' into devel 2013-01-04 22:24:32 -05:00
Tom Rothamel a93d083cce Change the comments generated by the translator. 2013-01-03 23:50:25 -05:00
Tom Rothamel c38d6c07f7 Change the identifier generation scheme.
It now includes the label, and will generate a unique identifier for
the repetitions of code within a label.
2013-01-03 23:45:01 -05:00
Tom Rothamel 0d1a6f1926 Add hide clause to parsing of Label.
The hide clause will be used with translations, to avoid taking the
label name into account when generating the translation identifier.
2013-01-02 23:48:58 -05:00
Tom Rothamel b6e86ec2f2 Translate only a single line of dialogue at a time. 2013-01-02 23:38:02 -05:00
Tom Rothamel d867e5a578 Transform fixes:
* Taking execution state now works with nested Transforms.
* An ATL transform will take the child of the Transform it replaces,
  if it has no child of its own.
2013-01-02 22:08:34 -05:00
Tom Rothamel 8fd52a383e Fix a bug where the cache can grow uncontrollably.
This error hits when the cache is over-full - we used to bail out
early, and never call the cleanout code. This fixes that.
2013-01-01 00:49:11 -05:00
Tom Rothamel 44c73da13b Re-enable image cache. 2013-01-01 00:39:08 -05:00
Tom Rothamel 79daaf3387 Install a stub keymap as part of error handling.
This fixes a regression in parse error handling.
2012-12-31 22:41:45 -05:00
Tom Rothamel 6ccb9bc261 Prevent prediction from starving redraw/timer events.
The problem we had was that the REDRAW and TIMEEVENT events weren't
scheduled until the prediction coroutine was run. When prediction was
taking a while, the events wouldn't cancel it.

This manifiested as slow skipping, among other problems.
2012-12-29 22:52:30 -05:00
Tom Rothamel 5f6608e43a Have proper nosave for screens.
Previously, the nosave was typoed. This over-saved the screens,
and lead to very large save files.
2012-12-29 22:51:03 -05:00
Tom Rothamel dbdf3f1b61 "Fix" save dump.
Once in a while, we can get a weirdly reduced object. This ignores
those objects.
2012-12-29 22:50:19 -05:00
Tom Rothamel 39bc31ede3 Fix skipping keymap. 2012-12-29 22:48:32 -05:00
Tom Rothamel 07eaf04454 Minor fixes to console. 2012-12-29 22:46:52 -05:00
Tom Rothamel c77be46006 Adjust help and look of input line. 2012-12-29 12:37:15 -05:00
Tom Rothamel 5be1d2dee8 Add recall support to the console. 2012-12-29 12:28:11 -05:00
Tom Rothamel b04b095055 Console changes:
* Add commands.
* Eliminate debug prefix from names.
* Remove now-obsolete code.
2012-12-29 10:20:41 -05:00
Tom Rothamel 0a26b7bdff Implement various console commands. 2012-12-29 00:48:56 -05:00
Tom Rothamel 2755ac54db Console runs Ren'Py and Python code. 2012-12-28 23:00:54 -05:00
Tom Rothamel e7155dae52 Add exception handling. 2012-12-28 01:06:42 -05:00
Tom Rothamel b499c5b7bc More fixes, such as forgetting the label once we've called it. 2012-12-28 00:11:47 -05:00
Tom Rothamel 30e06d21b7 Fix rollback/context bug. 2012-12-27 23:55:50 -05:00
Tom Rothamel c01b910aa5 Run Ren'Py code with some error handling. 2012-12-27 23:42:25 -05:00
xRenx 748920b136 Update sphinx/source/translations.rst
Just corrected a couple of typos (one was in some sort of hash, edited 'm' out).
2012-12-27 18:42:56 +00:00
Tom Rothamel e07fbd55cb Assign serial numbers consectuively between files.
This lets us be sure that we never create the same name twice in
a single process of Ren'Py, even if load_string is called in
quick succession.
2012-12-24 01:39:47 -05:00
Tom Rothamel 6cf01c4261 Add the ability to load a string into Ren'Py as a script file. 2012-12-24 01:37:44 -05:00
Tom Rothamel afdb276473 Switch how we run the debug console.
The console now runs in the main context, at least when it's
started in the main context.
2012-12-23 23:26:33 -05:00
Tom Rothamel 445d16bde6 Add non-greedy rollback.
Greedy rollback rolls back as far as it can without crossing a
checkpoint. Non-greedy rollback rolls back to the start of
the checkpoint statement, or the start of the current
statement if we're in a statement.

(This is used by the console to get back to the start of the
current statement.)
2012-12-23 23:23:11 -05:00
Tom Rothamel 3d9f73500c Back out rollback option due to problems.
The problem is that when we have two rollbackable contexts sharing
a store, variable changes in the inner context aren't rolled back
when a rollback occurs in the main context.
2012-12-23 21:46:41 -05:00
Tom Rothamel 165e3490fc Work on console.
This version converts the console from UI functions to screens,
and adds support for rolling back lines of input.
2012-12-22 23:59:22 -05:00
Tom Rothamel 7ab1a9b6d8 Call_in_new_context takes an _rollback argument.
This determines if rollback is allowed in the new context.
2012-12-22 23:56:49 -05:00
Tom Rothamel 526e44dbae Remove unnecessary loop from main, which prevented the game
from ending with a return.
2012-12-22 17:30:36 -05:00
Tom Rothamel f33f5fad35 Persist viewport range across a viewport replacemet cycle.
This prevents viewports from resetting to 0 when replaced.
2012-12-22 14:40:29 -05:00
Tom Rothamel ee36c66333 Encode the translation properly when hashing it. 2012-12-19 15:32:37 -05:00
Tom Rothamel fc6c7e7549 Add back config.game_menu_action. 2012-12-19 15:32:25 -05:00
Tom Rothamel eb4b3613cd Check in new debug console.
Thanks: Shiz, C, and delta.
2012-12-17 23:57:29 -05:00
Tom Rothamel 2859390ff7 Check in file deletions and changes. 2012-12-17 23:51:00 -05:00
Tom Rothamel 654c648feb Reorganize the unweildy 00screens.rpy file into 9 new files. 2012-12-17 23:49:15 -05:00
Tom Rothamel ad07fa19d7 Finish breaking 00library.rpy out into multiple parts. 2012-12-17 23:03:46 -05:00
Tom Rothamel 4d1cb10fd3 Move default config.keymap into 00keymap.rpy. 2012-12-17 09:57:30 -05:00
Tom Rothamel d936b0f482 Start refactoring common:
* Reassigned the init priorities.
* Started splitting 00library.rpy into multiple files.
2012-12-17 00:38:47 -05:00
Tom Rothamel 915b67758a Move the common directory to renpy/common. 2012-12-16 21:51:38 -05:00
Tom Rothamel 16b152ddf8 Document replay mode. 2012-12-16 21:32:22 -05:00
Tom Rothamel 3cc56f5c9d Don't translate 'a' and 'q' - it doesn't work. 2012-12-16 18:25:33 -05:00
Tom Rothamel ac69e0e45b Rename memory->replay, so that there's no confusion with functions that
manage computer memory.
2012-12-16 18:24:15 -05:00
Tom Rothamel e0f53d1030 More work on memories.
Implemented the EndMemory exception, EndMemory action, and
renpy.end_memory, which together end the current memory if we're in
memory mode.
2012-12-15 14:36:12 -05:00
Tom Rothamel 4e8eafe92e Memory Support and rollback changes/fixes.
This adds initial support for the memory mode, where we replay
a scene in a new context.

This requires a bunch of changes to rollback, so that it is possible
to rollback a context other than context[0]. Most notably,
RestartException has been replaced by RestartContext and
RestartTopContext.

This also fixes a bug where the rollback_limit was being decremented
even when a checkpoint wasn't reach. This manifiested as a reduced
amount of rollback, especially at the start of the game.
2012-12-15 14:10:36 -05:00
Tom Rothamel 263fd588af Allow run.sh to be scripted. 2012-12-15 14:10:22 -05:00
Tom Rothamel fac0b5af94 Add NoRollback to the default store. 2012-12-09 22:05:18 -05:00
Tom Rothamel 02a266f2d7 Add the ability to back up and restore the entire store. 2012-12-09 13:41:00 -05:00
Tom Rothamel 392df791ee Make the main_menu variable available even when we're not in the menu
context.
2012-12-08 15:30:35 -05:00
Tom Rothamel fa797518c1 Document translations. 2012-12-08 14:51:36 -05:00
Tom Rothamel 1791824b14 Add menu/string translations. 2012-12-08 11:16:02 -05:00
Tom Rothamel 407f37dd9e Add translation documentation. 2012-12-08 10:55:54 -05:00
Tom Rothamel af50b50110 Let the creator configure the name of the translation directory.
"Let the bikeshed-painting begin!"
2012-12-04 22:46:28 -05:00
Tom Rothamel 1af7616961 Actually check in the launcher translation support. 2012-12-04 22:46:14 -05:00
Tom Rothamel 0d8100c1d8 Add translation support to the launcher.
There's two parts to this. First off, there's a new "Generate
Translations" option, which lets the creator or translator generate
the translation files. Then, I added the ability to change the language
the launcher itself uses.
2012-12-04 22:33:48 -05:00
Tom Rothamel 9b8ab5430c Mark various statements as translatable. 2012-12-03 00:13:42 -05:00
Tom Rothamel d7e325ba89 The loader will look for translation-specific filenames
when loading images, music, etc.
2012-12-03 00:13:42 -05:00
Tom Rothamel cae94fe7eb The imagemap cache should take the current language into account, to
ensure that if the image is translated, the cache will be updated or
ignored.
2012-12-03 00:13:42 -05:00
Tom Rothamel bbb50748e4 Fix translate python statement. 2012-12-03 00:13:42 -05:00
Tom Rothamel c34253c6af Stop translate on exception; prevent double translation; make prefix/suffix translatable. 2012-12-03 00:13:42 -05:00
Tom Rothamel a027dd6579 Change the language option so it triggers the new translate
mechanism.
2012-12-03 00:13:42 -05:00
Tom Rothamel 4a5cdd31f4 Add menu choices to the list of strings to be translated. 2012-12-03 00:13:42 -05:00
Tom Rothamel 83703f757f Add a rot13 filter for translations. 2012-12-03 00:13:42 -05:00
Tom Rothamel 58f68de94a Translations can be activated. 2012-12-03 00:13:42 -05:00
Tom Rothamel 963dfd0c62 Scanning scripts to generate string translations. 2012-12-03 00:13:42 -05:00
Tom Rothamel cd7f00b9e3 Fix argument parsing.
Previously, the project and command were optional, which led to problems
when a required command argument was missing.
2012-12-03 00:13:42 -05:00
Tom Rothamel 0c0b560321 Implement string_scan function.
This scans a file for translatable strings.
2012-12-03 00:13:42 -05:00
Tom Rothamel 3c31888f54 Add the !t conversion type.
This type allows us to write [value!t], to get a translation of
value.
2012-12-03 00:13:41 -05:00
Tom Rothamel 1f057d8945 String translation support.
This removes the old .rpt support, and replaces it with a translate
string statement. The RENPY_UPDATE_STRINGS statement now writes
a .rpy file containing the new strings.
2012-12-03 00:13:41 -05:00
Tom Rothamel a28e207511 Write out translates. 2012-12-03 00:13:41 -05:00
Tom Rothamel 35dd42a9f9 Infrastructure to write translation files. 2012-12-03 00:13:41 -05:00
Tom Rothamel 9cb00851aa Encode say strings properly. 2012-12-03 00:13:41 -05:00
Tom Rothamel 73f4ae8d28 We can now translate blocks of text. 2012-12-03 00:13:41 -05:00
Tom Rothamel 5e0edd9d95 Chain translation blocks together; add a new EndTranslate block. 2012-12-03 00:13:41 -05:00
Tom Rothamel dfbb5aa79e Parser changes.
* Add translate statement.
* Add nointeract clause to say statement.
2012-12-03 00:13:41 -05:00
Tom Rothamel 62d9bbf522 Initial support for automatic addition of translate nodes.
This adds a new pass to script loading, one where Ren'Py iterates
through the script and groups say statements and translatable user
statements into translate blocks.
2012-12-03 00:13:41 -05:00
Tom Rothamel e832d56310 Start implementation of translation. 2012-12-03 00:13:41 -05:00
Tom Rothamel 45fc6fb1b2 Merge branch 'devel' of github.com:renpy/renpy into devel 2012-12-03 00:12:39 -05:00
Koichi Akabe be39d4c825 Merge with trunk 2012-10-31 22:53:09 +09:00
Tom Rothamel 7baf6559ed When doing error handling, we only build the styles needed for
error handling.

This prevents consistency error in styles (for example, a style inheriting from an undefined style) from causing a crash.
2012-10-29 19:47:41 -04:00
Tom Rothamel 13ee3550f9 Fix LiveTile range() problems.
LiveTile could crash with an error if the child render size or
displayable size were not integers.
2012-10-29 18:38:56 -04:00
Tom Rothamel 4f63b6f2e0 Hide shouldn't stop prediction. 2012-10-17 22:09:40 -04:00
Tom Rothamel 536d765359 Add the voice_tag parameter to Character, and config.voice_tag_callback.
To support the new voice tag feature, character gains a voice_tag
parameter, and the new config.voice_tag_callback variable comes into
existence. When a character speaks, config.voice_tag_callback is
called with that character's voice tag.
2012-09-17 19:50:51 -04:00
Albert Westra 20c4dcac26 Fix a couple ID10T Errors 2012-09-17 09:20:31 -07:00
Albert Westra 58bd1a7bde Added elif to a if line 2012-09-16 22:07:25 -07:00
Albert Westra bacb4f067d Added Comments in 00screen.rpy;
Added :doc: comment in chracter;
and Added voice_tag requirement in 00voice.rpy.
2012-09-16 22:01:43 -07:00
Albert Westra e4d82fcfc2 Add README to state what I am doing 2012-09-12 22:36:30 -07:00
Tom Rothamel 754f457574 Merge branch 'feature-font-group' 2012-09-12 23:11:28 -04:00
Tom Rothamel 96984da285 Remove use of renpy.game.args.warp.
This is the last use of a command-line argument in code that isn't
part of the run command. We can now start a Ren'Py game with a
command other than the run command.
2012-09-12 22:53:56 -04:00
Tom Rothamel 1d1d1cb405 Merge branch 'master' into devel 2012-09-11 22:55:45 -04:00
Tom Rothamel 6beb2ed831 Make Language() use deferred rollback. 2012-09-11 22:54:16 -04:00
Tom Rothamel 80ac28bd07 Implement deferred rollback.
This allows a rollback to begin in a menu, but not take effect until the
user returns to the top-level context.
2012-09-11 22:52:56 -04:00
Tom Rothamel e4e39cdfeb Ensure rollback respects rollback_limit. 2012-09-11 22:52:08 -04:00
Tom Rothamel 25c03ae410 When rolling back, roll back to the the rollback immediately after
the previous checkpoint.

This allows all the code that makes up the current screen to be re-run
when a rollback occurs.
2012-09-11 19:02:13 -04:00
Tom Rothamel 7ef4449fc1 Merge branch 'feature-font-group' into devel 2012-09-11 01:29:11 -04:00
Tom Rothamel 2c728bc9a4 Bump version. 2012-09-11 01:28:40 -04:00
Tom Rothamel b1353fdfcc Document font groups. 2012-09-11 01:13:32 -04:00
Tom Rothamel 3a3cad9fd4 Integrate FontGroup with subsegment.
This gets the FontGroup code working.
2012-09-11 00:24:30 -04:00
Tom Rothamel a573008ef1 Ignore attempts to play None as sound/music.
This is a minor behavior change. Before this, renpy.play would stop
the playing sound if called with None - which is the default in a lot
of circumstances.
2012-09-09 22:47:23 -04:00
Tom Rothamel 6e6784a5e7 Implement FontGroup.
This lets us register a group of fonts, with each covering a portion
of the unicode character space. A string can then be segmented based
on this, dividing it up into runs of characters using various fonts.
2012-09-07 00:21:06 -04:00
Tom Rothamel cf22336e3a Add subsegment method to TextSegment.
This gives a textsegment the ability to decide to break itself up
further based on the contents of the text supplied to it.
2012-09-06 23:11:45 -04:00
Tom Rothamel 72a8e029ad Fix RAPT docs. 2012-09-04 22:29:38 -04:00
Tom Rothamel 4142473dc0 A few more fixes to the Android packaging docs. 2012-08-28 20:16:14 -04:00
Tom Rothamel 6e2bb81a1c Merge remote-tracking branch 'remotes/ren/patch-3' 2012-08-28 19:42:32 -04:00
Tom Rothamel dd4fc916ec Remove unnecessary use of AVFormatParameters in dead code. 2012-08-28 19:13:25 -04:00
xRenx 8e755eb157 Update sphinx/source/android-packaging.rst
Changed some wordings, expanded on some points, added screenshots and a Troubleshooting section.
2012-08-27 19:28:21 +02:00
Tom Rothamel b33b9628fd Ensure ffdecode.c can compile with the libav that we're distributing
with Ren'Py.
2012-08-26 15:05:55 -04:00
Tom Rothamel b9a6dfea88 Move to an O(n) algorithm for detecting store changes.
The problem is that python seems to generate two kinds of code to
access module globals. Variable access in the global scope uses object
methods, and so setitem and delitem are called. But when a global
is accessd from a function, the dict is accessed directly, and so
we can't intercept them.

This means that the new O(1) method of determining what changed in
the store is massively broken.

Ren'Py now uses an O(n) method of detecting store changes, which
is what we used in 6.13, modified to support multiple stores.
2012-08-24 17:46:31 -04:00
Koichi Akabe be69bd95af Use underline_position for vertical sideline calculation
This change is optimized for full width characters
2012-08-24 16:50:42 +09:00
Tom Rothamel e16489fc5e Fix build of source package. 2012-08-23 23:10:49 -04:00
Tom Rothamel 1b0c5477f4 For safety's sake, make util.walk decode its arguments. 2012-08-23 22:34:42 -04:00
Tom Rothamel d85565910d Turn the projects directory into unicode, if it's not already. 2012-08-23 22:30:07 -04:00
Tom Rothamel 1201924c28 Still more video playback fixes.
* Always display the first frame of a video.
* Improve sync at the start of a video.
* Update the Movie displayable on a regular basis, even if a movie isn't playing. (This
  lets a movie start playing later.)

Fixes #24.
2012-08-23 22:13:25 -04:00
Tom Rothamel 02be062444 Deal with more problems with video playback:
* Accept the libav default for the number of threads to use for decoding.
* Only allocate a surface if the video stream exists.
2012-08-23 21:11:14 -04:00
Tom Rothamel 7a113712e1 Remove excess debugging print. 2012-08-23 20:14:09 -04:00
Tom Rothamel c046a7fd56 Make the locking scheme in PSS.py more similar to the one in Ren'Py
6.13.

This fixes crashing bugs that may have been caused by data structures
being updated while the audio callback is being run in the background.

The big change between 6.13 and this is that playing_name is now
protected by a mutex. PSS_playing_name only tries to grab this mutex,
and doesn't grab the SDL audio lock, preventing it from blocking if
video decoding is too far behind.
2012-08-22 22:42:03 -04:00
Tom Rothamel 07c1599821 Fix a race condition on audio start. 2012-08-22 21:27:30 -04:00
Tom Rothamel 9d5154b50a Fix a crash that can occur if Ren'Py doesn't know the (in-file)
location of an imagemap.

Fixes #20.
2012-08-20 21:24:27 -04:00
Tom Rothamel 3982c45886 Quote square brackets in some developer functionality.
Fixes #19.
2012-08-20 21:17:06 -04:00
Tom Rothamel 90772350fb Copy renpy-ppc.zip into the download directory. 2012-08-20 21:15:15 -04:00
Koichi Akabe bc19194c58 Use bbox.yMax instead of horiBearingY for simulation
If the height of the glyph is small, horiBearingY returns
a non-expected value for vertical layout simulation, but bbox.yMax
returns the same value for all glyphs.
2012-08-20 17:18:35 +09:00
Tom Rothamel fd250df032 Add support for producting direct downloads (not through the updater)
of editor dlc.
2012-08-19 09:47:04 -04:00
Tom Rothamel 9ea3c36a88 Bump version to 6.14.1. 2012-08-19 08:40:07 -04:00
Koichi Akabe 62ac5b09b1 Get GSUB table regardless of FT_HAS_VERTICAL 2012-08-19 21:04:06 +09:00
Koichi Akabe 9ccc66da0e Fix position calcuration on vertical layout simulaton 2012-08-19 15:33:54 +09:00
Koichi Akabe 1d6ec0fcfd Simulate vertical layout if the font doesn't support it 2012-08-19 13:25:40 +09:00
Koichi Akabe d9510a7569 Simulate vertical layout if the font doesn't support it 2012-08-19 13:24:51 +09:00
Koichi Akabe 5412165427 Add vertical style
* Add vert and horiz text tag
 * Add ttgsubtable to get vertical glyphs
 * Inherit vertical style on ruby and hyperlink
2012-08-19 10:17:37 +09:00
Tom Rothamel 4cc4cae8bb Allow Ren'Py to be build in virtualenvs, as well as with PYTHONPATH set. 2012-08-17 11:50:47 -04:00
Tom Rothamel d4d9543019 Format license.rst using plain text, so we don't syntax-highlight
a bunch of source code licenses.
2012-08-16 20:55:30 -04:00
Tom Rothamel bf2cf5b5e3 Add support for producing an experimental distribution of Ren'Py. 2012-08-16 20:54:56 -04:00
Tom Rothamel 99cf00ad54 Deal with Windows-style paths in the launcher and navigation dump code. 2012-08-16 17:21:39 -04:00
Tom Rothamel 0ddb47ce6d Condition log close on the log being open. 2012-08-16 09:27:34 -04:00
Tom Rothamel 52f6898ffd Ensure that we can build with ANGLE and on ES-based platforms. 2012-08-15 22:05:57 -04:00
Tom Rothamel cc8d2823cd Use BGRA/UNSIGNED_INT_8_8_8_8_REV on PC-like platforms.
This fixes #16, a performance bug where lousy Intel drivers would take
forever to do glTexSubImage when RGBA/UNSIGNED_BYTE were the format and
type.
2012-08-14 23:18:38 -04:00
Tom Rothamel 03e09f45c0 Quote strings in navigation. 2012-08-09 23:05:29 -04:00
Tom Rothamel 061a04cd84 Enable the underlay when movies are playing.
Now that movies stop when a new context is entered, there's no reason
not to do this. fixes #13.
2012-08-09 22:35:38 -04:00
Tom Rothamel 0b555d73ab Deal with the case where a size_group is not defined.
This should never happen in a normal case - but it seems to have
occured during error handing. So we deal with it.
2012-08-09 22:09:03 -04:00
Tom Rothamel c05606aa94 Only check for render leaks if we haven't handled a traceback.
When we error-handle a failure that occurs while rendering, it's
possible that one or more Renders will be kept alive in a
traceback. This prevents us from giving the render-leak warning in
this case.
2012-08-09 21:54:23 -04:00
Tom Rothamel 98a37cb84f Make move transitions respect time warp. 2012-08-09 21:38:02 -04:00
Tom Rothamel 94f2fa7a9a Invoke dxwebsetup with os.startfile.
On 64-bit windows, with a space in the path, I was getting a command
line prompt.
2012-08-09 21:21:33 -04:00
Tom Rothamel 1cf9bb29ab Add warnings about python code in screens. 2012-08-09 21:20:03 -04:00
Tom Rothamel 771311a955 Only stop the movie on set_mode if the software renderer is being used.
A movie stop is necessary when the software renderer is being used
because setting the mode will kill the surface that the movie is
drawing to. In GL mode, we use a different surface, so a reset
isn't necessary.
2012-08-09 00:31:09 -04:00
Tom Rothamel a647a670a4 Have a go at making ffdecode work better with ffmpeg.
This involved dealing with some name changes where libav kept both
names without deprecation.
2012-08-09 00:18:14 -04:00
Tom Rothamel 00e0dfb5c7 Remove the vast majority of compiler warnings when compiling the
video and audio systems.
2012-08-09 00:11:43 -04:00
Tom Rothamel e1f5a7e9de Eliminate use of deprecated functions in ffplay.c. 2012-08-09 00:06:03 -04:00
Tom Rothamel e959d3e694 Use the GPU to scale movies.
This makes it possible to render movies on the Atom without frying the
CPU.
2012-08-08 23:35:36 -04:00
Tom Rothamel affd6d986f Merge pull request #15 from xRenx/patch-2
Update common/00themes.rpy
2012-08-08 17:33:11 -07:00
xRenx f30f82262f Update common/00themes.rpy
Changed http://renmazuo-.deviantart.com to http://x-Ren-x.deviantart.com/ as I changed my username on deviantArt.
2012-08-08 20:23:10 +02:00
Tom Rothamel 39e17a5872 Simplify premultipy().
This makes it run faster on in-order platforms like the
Atom. Premultiply was turning out to be a resource hog on video
playback.
2012-08-08 00:48:18 -04:00
Tom Rothamel b2c3480b8e Change _button to use the old (6.13.12) amie2 theme. 2012-08-06 22:49:11 -04:00
Tom Rothamel f822e9a0e9 Stop using MMX on 32-bit linux.
Lucid's 32-bit c compiler is miscompiling transform32_mmx. Since
that's not used for much in the OpenGL path, it's been disabled.
2012-08-06 22:34:44 -04:00
Tom Rothamel 4238849c4b Update the changelog. 2012-08-06 00:55:33 -04:00
Tom Rothamel 23ad4f0140 Remove unnecessary checks in the Choice... actions.
We had been checking that the _chosen dict was non-empty in ChoiceJump
and ChoiceReturn actions. This wasn't necessary given the logic of the
program, and failed in the case of a game that hadn't been played
before.

Fixes http://lemmasoft.renai.us/forums/viewtopic.php?p=214590#p214590
2012-08-06 00:52:01 -04:00
Tom Rothamel de85018794 Merge pull request #11 from apricotorange/master
Port the NVL tutorial from the wiki to Sphinx
2012-08-05 20:54:31 -07:00
Tom Rothamel cfa85aeb37 Video sync and other video improvements.
We now generally synchronize video to wall time. We adjust this
synchronization slowly if we're slightly out of sync with the audio,
or by a lot if we're way out of sync.

This ensures that the frame rate remains stable even if the times of
audio decode vary a bit.

We also now support the Movie displayable again.
2012-08-05 23:36:33 -04:00
Tom Rothamel f81fdd55e2 Cancelling projects path selection uses the old path.
Previously, it would reset things to the default path.
2012-08-05 10:59:01 -04:00
Tom Rothamel 5a8cf4c4ed Remove obsolete sync code. 2012-08-05 02:28:19 -04:00
Tom Rothamel 98292a2dc3 Remove subtitle-related code from ffdecode.c. 2012-08-05 02:13:08 -04:00
Tom Rothamel 1f16af50aa Rewrite video playback.
Previously, video playback was done using SDL events. This was at best
laggy, as the time it took for an SDL event to be delivered was up to
30 ms. Worse, if an event was ever lost, video playback would stop,
packets would queue up, and eventually audio playback (and Ren'Py
itself) would crash.

In the new approach, when a video is playing Ren'Py polls the video
system for new frames. Busy-waiting (with short sleeps to give control
to the decoder threads) ensures that frames are draw promptly, and
so the buffers can't fill up.

This code doesn't explicitly address latency, so that's a wash.
2012-08-05 01:24:42 -04:00
Tom Rothamel f24af00189 Allow the upload of large surfaces as a single texture.
Previously, we limited the maximum size of a texture that Ren'Py could
deal with to 512, and mandated the textures were 66% full. In the movie
case - with a lot of texture uploads - this was bad news, as making new
textures is slow on an intel GPU. So now, we can ask for a big texture
to be created in a single chunk.

Also, we now use 1024px textures, instead of being limited to 512px.
2012-08-05 01:21:13 -04:00
Tom Rothamel 704546149c Redo the way we lock in PSS.
This prevents Ren'Py from crashing when video playback is too slow,
but doesn't prevent frames from piling up.
2012-07-31 23:31:17 -04:00
Tom Rothamel 259e4bbb9b Update run.sh so it can work with a renpy-deps build. 2012-07-30 23:29:02 -04:00
Tom Rothamel 004a05a49b Speed up skipping when possible. 2012-07-30 12:58:44 -04:00
Tom Rothamel 1a91b29cf5 Remove obsolete edit.py files that can confuse the new launcher. 2012-07-30 00:03:15 -04:00
Tom Rothamel 79b2f36088 Re-read version number after we generate it, so we wind up with
the correct version number in the end.
2012-07-29 22:20:30 -04:00
Tom Rothamel 8b52a0c515 Add functions that allow for a list of save games such that the
user is able to add new save slots to the list.
2012-07-29 22:11:31 -04:00
Tom Rothamel 01689987d5 Remove debug print. 2012-07-29 19:40:31 -04:00
Tom Rothamel 9b9b8aed61 Skip template prompt if only one template exists. 2012-07-29 19:36:54 -04:00
Tom Rothamel 325299f342 renpy.game_get_runtime only returns time from the main context. 2012-07-29 19:32:57 -04:00
apricotorange 3384fc378f Port the NVL tutorial from the wiki to Sphinx. 2012-07-28 22:06:35 -07:00
apricotorange 6b66f3cce8 Port the NVL tutorial from the wiki to Sphinx. 2012-07-28 21:44:45 -07:00
Tom Rothamel d3e54853d6 Make the updater more robust when files already exist. 2012-07-29 00:27:46 -04:00
Tom Rothamel 6aa927c39a Force arguments to Grid to be integers.
Analogue passes floats to Grid, which passes them to range(), which changed
its behavior in python 2.7 to crash when it gets something other than an
integer.
2012-07-28 23:55:37 -04:00
Tom Rothamel d70374a5c0 Explicitly look for the correct tag when computing vc_version. 2012-07-26 23:41:10 -04:00
Tom Rothamel 67c4b55663 Fix rollback of - well, everything but stores.
I'm not sure how the restored code - which is right out of 6.13 -
went missing.
2012-07-26 00:38:06 -04:00
Tom Rothamel 0cbb4a6c0e Improve #TODO handling a bit.
* Suffix multiple TODOs with numbers.
* Give a more obvious message if no TODOs were found.
2012-07-25 22:47:04 -04:00
Tom Rothamel 6f063c92de Merge pull request #9 from edwin-v/scan_todo_for_launcher_v2
Added a todo list to the launcher navigation section.
2012-07-25 19:04:20 -07:00
Tom Rothamel 5504397bb8 Merge pull request #10 from xRenx/patch-1
Update sphinx/source/android-packaging.rst
2012-07-25 18:46:07 -07:00
xRenx 08a15c417d Update sphinx/source/android-packaging.rst
Just mentioned the links for those downloads are below, as some users might follow the guide in order.
2012-07-25 22:16:24 +02:00
Edwin ff05b590be Added a todo list to the launcher navigation section. 2012-07-25 21:04:20 +02:00
Tom Rothamel eb603088ae Move the projects scrollbar to the right so people know what it is. 2012-07-25 00:12:18 -04:00
Tom Rothamel 1363792d17 Exit the update channel preference when a button is clicked; Hide it
entirely if updating is not possible.
2012-07-25 00:10:31 -04:00
Tom Rothamel 21ef05b0fa Be a little more paranoid about missing editors. 2012-07-25 00:00:35 -04:00
Tom Rothamel 7b34af584f Input should ignore all keypresses it handles.
It ignored unicode events, but backspace, left, and right were
not consumed, and could be passed to other functions.
2012-07-24 23:14:25 -04:00
Tom Rothamel 4b5ec57624 Changes to front page:
* "Script Navigation" -> "Navigate Script"
* Add lines underneath Edit Script and Open Directory, so they don't
  look like buttons themselves.
2012-07-24 22:54:22 -04:00
Tom Rothamel ccf3ce6f5b Merge branch 'master' of github.com:renpy/renpy 2012-07-24 20:36:49 -04:00
Tom Rothamel 0fff7e9bbe Merge pull request #7 from JakeStaines/master
Added function into theme-choosing to modify screens.rpy; now changes file-picker rows to suit AWT where appropriate.
2012-07-24 17:30:47 -07:00
Tom Rothamel 90bda7dd23 Unlink partial zsync downloads. 2012-07-24 20:14:14 -04:00
Tom Rothamel f845f787ad Fix Update to work. 2012-07-24 20:07:40 -04:00
Tom Rothamel c16774c325 Add debug_sound change to changelog. 2012-07-24 20:07:11 -04:00
JakeStaines c2842286c7 Added function into theme-choosing to modify screens.rpy; now changes file-picker rows to suit AWT where appropriate. 2012-07-24 00:15:34 +01:00
Tom Rothamel ee8744b490 Exclude files from the distribution. 2012-07-22 22:25:40 -04:00
Tom Rothamel f14c68d047 New tagging script. 2012-07-22 22:10:05 -04:00
Tom Rothamel be76ab63e8 Merge pull request #5 from JakeStaines/master
Fixed White Tulip vbar to be full when at 100%, instead of empty.
2012-07-22 18:38:20 -07:00
Tom Rothamel ea825dfe23 Minor changes to the tutorial game script. 2012-07-22 21:32:48 -04:00
Tom Rothamel a0c87efac8 Minor change to the wording of the updater messages. 2012-07-22 21:32:35 -04:00
Tom Rothamel b55bad9e27 Do not hide the mouse due to inactivity when in the launcher. 2012-07-22 21:03:18 -04:00
Tom Rothamel 72af1de7e6 Fix problems where, after a relaunch, the default editor would not
be scanned or set.
2012-07-22 21:00:18 -04:00
Tom Rothamel 85e07b8cb8 Make the temporary directory before each launch.
This fixes a bug where, if a project existed already, the user could
try to launch it, and it would try to create navigation.json in a
directory that didn't exist.
2012-07-22 20:23:56 -04:00
Tom Rothamel 55c4369d6e Do not change line endings when updating options.rpy upon the creation
of a new game.
2012-07-22 20:08:56 -04:00
Tom Rothamel d860378a73 Show a slider for the volume in choose_theme. 2012-07-22 19:29:51 -04:00
JakeStaines 1943a31628 Fixed White Tulip vbar to be full when at 100%, instead of empty. 2012-07-22 23:45:01 +01:00
Tom Rothamel d7a26f722f Developer mode fixes.
* Quote style inspector output so it won't cause a crash if special
  characters are included.
* Fix a typo on the theme test screen.
2012-07-22 18:06:30 -04:00
Tom Rothamel 9af1b75fda Merge pull request #4 from JakeStaines/master
Added new bar style to A White Tulip theme; cleaned up a couple of minor graphical issues with the sliders and scrollbars.
2012-07-22 14:53:54 -07:00
Tom Rothamel 4787441d1f End skipping when entering a menu. 2012-07-22 17:52:49 -04:00
Tom Rothamel 9b47c3c4fd Ensure that display_menu passes the same items list to screens as it
did in previous releases.
2012-07-22 17:19:51 -04:00
Tom Rothamel 5c63e14ae7 Launcher changes/fixes.
* Error handling in the empty project name case.
* Ask the user to create a theme upon creating a new project.
2012-07-22 15:54:08 -04:00
Tom Rothamel ca606112bc Append to update log. 2012-07-22 15:28:57 -04:00
Tom Rothamel e0f1fe2847 If we can't do a file operation while Ren'Py is running, try it
again the next time Ren'Py starts.
2012-07-22 15:17:24 -04:00
Tom Rothamel 2179a13ea5 Fix updater in the case where things can't be renamed.
For some reason, font files fall into this category.
2012-07-21 22:30:57 -04:00
JakeStaines 4873db2a6a Added new bar style to A White Tulip theme; cleaned up a couple of minor graphical issues with the sliders and scrollbars. 2012-07-22 00:41:44 +01:00
Tom Rothamel 6768f9da67 Deal with windows's file separators. 2012-07-21 09:36:09 -04:00
Tom Rothamel 1a10e6d4e7 Add ctypes by default.
It's used by EasyDialogs, and probably good to keep around.
2012-07-21 09:35:26 -04:00
Tom Rothamel 2159888b07 Add some modules used by older code to the default store. 2012-07-21 09:34:57 -04:00
Tom Rothamel 478135fe56 Rename __dirty to __spdirty.
In 6.13.11, __dirty was a boolean. In 6.13.12, it change to an object with
a field - but loading a 6.13.11 game would overwrite that, causing crashes.
Having a totally new variable fixes the problem.
2012-07-21 08:30:59 -04:00
Tom Rothamel 701bfcb23a Re-raise original exception if exception handling is disabled
or fails.
2012-07-21 08:30:07 -04:00
Tom Rothamel 3d0b9b14c8 Try a different approach to dealing with out-of-range values.
Edwin's fix at 81c265c didn't work when an adjustment was ranged more
than once, with smaller and larger values, as it would shrink to fit
the smaller value. This version applies the in-range check when the
value is accessed.
2012-07-20 23:43:35 -04:00
Tom Rothamel ad73b70c9e Add AWT to the theme chooser. 2012-07-20 23:35:27 -04:00
Tom Rothamel c04826f663 Remove unused parameter from __AWTBullet. 2012-07-20 23:17:13 -04:00
Tom Rothamel 9bcb811bb2 Add the "A White Tulip" theme.
Credits:

Coding: Jake Staines (http://www.eviscerate.net/)
Graphics: Ren (http://renmazuo-.deviantart.com/)
Font: Andrew Paglinawan (www.andrewpaglinawan.com)
2012-07-20 23:15:33 -04:00
Tom Rothamel 61d403f032 Restore the ability to launch Ren'Py from the command line on
Mac OS X.

A user had mentioned to me that he had asked about this.
2012-07-20 00:33:41 -04:00
Tom Rothamel 7651a34206 Improve the error message produced when an empty string is used
as a displayable.
2012-07-20 00:11:41 -04:00
Tom Rothamel f2334d05fd Add editor-specific error messages for Editra on Linux and for jEdit. 2012-07-20 00:06:19 -04:00
Tom Rothamel 20a98290bd Delete .update.json files if we're not building an update. 2012-07-19 23:47:50 -04:00
Tom Rothamel 870db9d610 Ignore .Editra directories that happen to be lying around. 2012-07-19 23:12:44 -04:00
Tom Rothamel 7ef94349bd Quicksaves should not become the newest save. 2012-07-19 20:51:03 -04:00
Tom Rothamel 987e38e2e1 Merge pull request #2 from StephenChan/docs-improvements
Docs improvements
2012-07-19 17:29:56 -07:00
Tom Rothamel 547dbf5e16 Merge pull request #3 from edwin-v/fix_adjustment_set_range
Correct value when it exceed the new range.
2012-07-19 17:28:30 -07:00
Tom Rothamel 9e7c373d58 Remove saybehavior from launcher.
It was too easy to click through a screen we wanted to read while
expecting to focus the launcher.
2012-07-18 23:21:37 -04:00
Tom Rothamel c271293b8b Add zsync and the Artistic License to LICENSE.txt. 2012-07-18 23:18:54 -04:00
Tom Rothamel eed02c98c5 Add normalization script. 2012-07-18 23:12:59 -04:00
Tom Rothamel c08400cee4 Add BOM and normalize line endings of all script files. 2012-07-18 23:12:00 -04:00
Tom Rothamel 99bf5c7e29 Add or update copyright notices. 2012-07-18 23:00:32 -04:00
Tom Rothamel 3ee7f91523 Update incompatible changes. 2012-07-18 22:52:18 -04:00
Tom Rothamel 3715590a19 Bring changelog up to date. 2012-07-18 22:46:53 -04:00
Edwin 81c265ce46 Correct value when it exceed the new range. Fixes bug: https://bugs.launchpad.net/renpy/+bug/722422 2012-07-18 21:31:59 +01:00
Tom Rothamel 112788b597 Fix generation of .7z.exe. 2012-07-18 00:11:37 -04:00
Tom Rothamel 6b58675000 Add the renpy.call function.
This function terminates the current Ren'Py statement, calls a label,
and passes control to the statement following the current statement.
2012-07-17 22:28:41 -04:00
SleepKirby a0872d1cdc Docs proofreading. 2012-07-17 02:06:32 -07:00
SleepKirby 1cad8b6c1e Add many ref links to the Configuration Variables documentation. 2012-07-17 01:36:42 -07:00
SleepKirby 4a25c62fe4 Fix several documentation typos and minor mistakes. 2012-07-16 00:40:19 -07:00
Tom Rothamel 113716bfd3 Fix argument order for zsynmake.
On the mac, positional arguments seem to have to come after flags
2012-07-15 23:45:42 -04:00
Tom Rothamel 282b315c77 Store documentation patterns in a variable.
Instead of ignoring them entirely.
2012-07-15 21:46:51 -04:00
Tom Rothamel 91b541617e Match xbit and documentation patterns against filename with / prefixed.
This makes all pattern matching consistent.
2012-07-15 21:46:24 -04:00
Tom Rothamel 82f634f98e Include python standard library into the linux builds.
Use the right directory name for it.
2012-07-15 21:06:35 -04:00
Tom Rothamel 25068cb249 Fix errors on archiving.
The problem was that we were using rollbackable lists and dicts in
our archive, before the rollback system was ready.
2012-07-15 20:57:02 -04:00
Tom Rothamel 81047a4375 Archive files in the_question.
This is used to test archiving on multi-plaform builds.
2012-07-15 20:56:40 -04:00
Tom Rothamel d90d91f484 Give the user a place to go if they ignore errors in the launcher. 2012-07-15 18:52:33 -04:00
Tom Rothamel f113661745 Only offer rollback to the user if rollback is enabled. 2012-07-15 18:52:14 -04:00
Tom Rothamel b87ba78b9f Deal with the case where downloading an editor fails. 2012-07-15 18:49:06 -04:00
Tom Rothamel 60241ad0f3 Allow the game itself to define patters as to what is and is not
executable.

We use this to apply the xbit to Editra.
2012-07-15 18:33:10 -04:00
Tom Rothamel 01471d51c5 Fix im.matrix.colorize to actually work. 2012-07-15 16:06:54 -04:00
Tom Rothamel 8ba8b92d79 Fix typo in docs.
Thanks to horstjens for reporting it.
2012-07-14 22:46:09 -04:00
Tom Rothamel e12935ed38 Mention that Editra does not support IMEs. 2012-07-14 22:04:20 -04:00
Tom Rothamel c0ce664d7c Fix typo preventing the update button from showing up. 2012-07-14 21:34:39 -04:00
Tom Rothamel 39c06631bf Only include script version if it's not already in the project.
This lets one rebuild a project aimed at an older version of Ren'Py
with a newer version, while retaining compatibility.
2012-07-14 21:20:57 -04:00
Tom Rothamel de3fd83810 Basic windows developer docs. 2012-07-14 21:00:20 -04:00
Tom Rothamel 015389dfeb Use a different method of getting zsync progress.
Zsync only produces output when its stdin is a terminal, which isn't
the case on windows. Attempts to recompile it to change this
behavior proved fruitless.

So instead, we look at the downloaded file, and see how closely it
matches the correct file. (By downloading a list of hashes for each
64k block in the correct file.)
2012-07-14 20:54:42 -04:00
Tom Rothamel da69ef70bd Change the paths that we get msvcrt and zsync from. 2012-07-14 20:45:14 -04:00
Tom Rothamel 2a47037f7e New way to upload to the server. 2012-07-14 20:44:29 -04:00
Tom Rothamel 3fb7aace9c Merge pull request #1 from edwin-v/input_caret_position
Changed Input caret reference to zero at beginning.
2012-07-10 18:54:39 -07:00
Edwin 1a33949a5b Changed Input caret reference to zero at beginning. 2012-07-10 00:53:25 +02:00
Tom Rothamel 4ea4a22ec9 Set WMCLASS to a game-specific hint, so Unity can match it. 2012-07-09 00:05:21 -04:00
Tom Rothamel 55c50e62f1 Document fixed rollback. 2012-07-08 23:26:48 -04:00
Tom Rothamel 2b5ebc443e Apply Edwin's fix_rollback patch.
This adds renpy.fix_rollback, a function that forces the user to make
the same choice after rolling back.
2012-07-08 22:42:25 -04:00
Tom Rothamel 705a9556e7 Rewrite the image load log in terms of DynamicDisplayable
Restarting an interaction on a timer is more expensive than we
want.
2012-07-08 21:35:04 -04:00
Tom Rothamel ce1d05b019 Fixes to presplash to make it work. 2012-07-08 20:48:34 -04:00
Tom Rothamel fb8151f656 Fix problem with transformed Frames when the software renderer is used. 2012-07-08 20:20:30 -04:00
Tom Rothamel eb90c6a4e3 Move the opengl log into the games' base directories. 2012-07-08 17:15:08 -04:00
Tom Rothamel 33ecff8633 Enable debug_sound by default when in developer mode. 2012-07-08 16:37:52 -04:00
Tom Rothamel fdf7bd8112 Add about screen to launcher. 2012-07-08 16:25:33 -04:00
Tom Rothamel 8dd4ac2259 Various options changes.
- Add icon.
- Disable saving.
- Disable sound.
- Disable underlay.
- Disable rollback.
- Disable log.
- Disable game menu.
2012-07-08 16:00:55 -04:00
Tom Rothamel eafc62936c Preferences work.
* Update channel selector.
* Gl enable/disable.
* Console output enable/disable.
2012-07-08 15:47:49 -04:00
Tom Rothamel a6991d4950 Add tuple parameter to renpy.version, which returns the version as
as a tuple.
2012-07-08 00:26:06 -04:00
Tom Rothamel 6be3c59c0f Special methods (like __init__) should not be treated as private. 2012-07-08 00:22:57 -04:00
Tom Rothamel d961dd609b Distribute Ren'Py using the launcher.
To make builds more convenient, functionality was added to the
launcher to allow the command line tool to not build updates,
and to build a subset of packages.
2012-07-08 00:19:12 -04:00
Tom Rothamel 0a71291e24 Bump version to 6.14.0. 2012-07-07 21:42:49 -04:00
Tom Rothamel 7ec34e80ed Update build_exe to blacklist packages and include zsync. 2012-07-07 21:24:58 -04:00
Tom Rothamel a124dce48c Always use -OO when launching Ren'Py, so we always run with .pyo files. 2012-07-07 00:13:34 -04:00
Tom Rothamel fe191f364a Search for zsync in the correct places. 2012-07-07 00:13:09 -04:00
Tom Rothamel 9fd83f56c6 Include all methods in code navigation, not just classes by their
__init__ methods.
2012-07-06 23:37:41 -04:00
Tom Rothamel bdaa617f65 Back-compat for input changes. 2012-07-06 23:32:21 -04:00
Tom Rothamel 1b93566780 Merge patch from Edwin that adds left-right arrow support to the
input displayable.
2012-07-06 23:15:34 -04:00
Tom Rothamel b10af0a3d1 Updater documentation. 2012-07-06 23:10:16 -04:00
Tom Rothamel b19fe5788b Clean the module on build; check for errors. 2012-07-06 23:09:31 -04:00
Tom Rothamel e8729a086d Include files used by argparse. 2012-07-06 23:08:25 -04:00
Tom Rothamel 9f96864edb Include base64_codec, used by the crypto stuff. 2012-07-05 01:04:42 -04:00
Tom Rothamel ae9c2a0af7 DLC bug fixes. 2012-07-05 00:57:54 -04:00
Tom Rothamel 76ba294af3 DLC-based editor install.
When the user goes to edit something and no editor has been selected,
the launcher will prompt the creator to select an editor. If the editor
selected is not installed, it will be downloaded and installed.
2012-07-05 00:30:11 -04:00
Tom Rothamel 0be10220b3 Add DLC support to launcher and updater. 2012-07-04 14:27:40 -04:00
Tom Rothamel d27549bfdb Add support for building dlc-only and multi-format packages.
More specific control over what's built is needed for the Ren'Py
build - why not give it to regular users?
2012-07-04 01:25:53 -04:00
Tom Rothamel 63d7ee70e0 Save the update.json file to allow for DLC. 2012-07-04 00:11:56 -04:00
Tom Rothamel 350af3ccd9 Add documentation for the new build system. 2012-07-02 00:28:58 -04:00
Tom Rothamel cfa355d944 Make focus grab migration work with viewports. 2012-07-01 22:22:28 -04:00
Tom Rothamel 1bb2a49479 Add side_* properties to viewports.
This allows us to position the side object created with scrollbars.
2012-07-01 22:21:08 -04:00
Tom Rothamel ed05c4b98c When possible, retain a grab through an interaction restart.
Previously, an interaction restart would unconditionally break the
grab.
2012-07-01 21:34:35 -04:00
Tom Rothamel b39bb13527 Fix the way we adjust times in MultiBox to account for a multibox
that is created at a non-zero st.

This is the case for the box created by a MoveTransition.
2012-07-01 20:58:00 -04:00
Tom Rothamel 8484b63c2d Initial go at a tool that displays image loads on the screen.
It works right now, but interferes with transitions because it
restarts the interaction multiple times a second.
2012-07-01 19:03:33 -04:00
Tom Rothamel 58d0f71df1 Rewrite MoveTransition, changing the API.
Movetransition now interpolates the positions of the image
in the before and after cases. This means that if the image is
moving in one or both of the cases, it will be moved between the
two locations.

The new movetransition uses transforms to specify where to move
to and from, rather than factory functions.

It's easier to use, but somewhat less flexible.

The old move transition is around as OldMoveTransition, and compat
will swap it in based on the script version.
2012-07-01 16:05:57 -04:00
Tom Rothamel f6e9262b0e Only do fancy error handling (gui errors, open in editor) when the
game is using the default "run" command.
2012-07-01 13:29:50 -04:00
Tom Rothamel bf2da27703 Fix pydev warnings.
Among other things, removed the renpy.subprocess module in favor
of importing subprocess and adjusting sys.modules.
2012-07-01 13:18:33 -04:00
Tom Rothamel 9c9864528d Revert to the amie2 theme from 6.13. 2012-06-28 08:18:50 -04:00
Tom Rothamel 23f3636fbb Build Ren'Py distributions with Ren'Py.
I'll be wrapping this in a script later, but the basics of a Ren'Py
build can now be performed with the distribute command built into
the launcher.
2012-06-28 00:06:09 -04:00
Tom Rothamel b84d9e5ca0 Change the name of the launcher project. 2012-06-28 00:05:50 -04:00
Tom Rothamel 9b030c2297 Deal with the case where we have a project.Select action for
a project that doesn't exist.

We now just show it as insensitive and unselected, rather than
crashing.
2012-06-28 00:04:57 -04:00
Tom Rothamel 98c4ed746d Replace launcherinfo.py with project.json where appropriate. 2012-06-28 00:03:23 -04:00
Tom Rothamel 09e2cbd45c Rename the launchers.
This entailed a minor change in bootstrap.rpy so Ren'Py could find the
game directory of the old launcher4.
2012-06-27 22:35:08 -04:00
Tom Rothamel 3ff2f0cd56 Remove obsolete files, fix filenames, and migrate bzr->git. 2012-06-27 22:22:18 -04:00
Tom Rothamel cb6c4d6953 Fixes to action documentation.
Thanks to SleepKirby for contributing them.
2012-06-27 20:59:38 -04:00
Tom Rothamel acfac50066 Minor update fixes. 2012-06-27 20:51:21 -04:00
Tom Rothamel a90c3e1255 Call Video_AutoInit so we can run on Mac OS X. 2012-06-27 01:05:47 -04:00
Tom Rothamel 91f5f40fd8 Parse the output of an unmodified zsync.
Compliling zsync on windows is proving to be a real PITA - this lets us ship
unmodified binaries.
2012-06-25 00:48:55 -04:00
Tom Rothamel a1616b5e65 Rewrite renpy.sh so it can choose between linux-x86 and linux-x86_64. 2012-06-23 20:09:22 -04:00
SleepKirby 739ea64fa0 A few minor fixes to Screen Action documentation. 2012-06-22 19:32:05 -07:00
Tom Rothamel 010007b0a1 Remove symlink. 2012-06-22 17:45:31 -04:00
Tom Rothamel 13fe854082 Fix a bar rendering glitch.
The break in the bar could be a non-integer number of pixels, causing
both the left and right sides of the bar to be rounded down and the
total bar to lose a pixel of length.
2012-06-19 23:52:33 -04:00
Tom Rothamel 249c98f320 Document save, load, and rollback. 2012-06-19 00:25:04 -04:00
Tom Rothamel 46e84d3661 This release changes the behavior of transforms to make them more correct
and easier to use.

The xzoom and yzoom properties are now applied before, rotation. This means
that the shape of the image will remain consistent as the image is rotated.
Previously, the image to change shape as it was rotated.

The xzoom and yzoom properties may now be negative, with negative zoom
values causing the images to be flipped. The positioning code now takes
this into account, and positions a flipped image properly.
2012-06-18 19:37:30 -04:00
Tom Rothamel 171eb33966 Remove the now-obsolete tools directory.
This gets rid of add_from, but we haven't needed that in a long
time. The archiver is now part of the buld code.
2012-06-18 18:52:31 -04:00
Tom Rothamel 35cdadbcee Allow roll forward to work through a jump out of a call_screen. 2012-06-18 17:54:43 -04:00
Tom Rothamel fd501a7a03 Deleting persistent data. 2012-06-18 09:31:11 -04:00
Tom Rothamel d27ea92fd1 Add lint support to the new launcher. 2012-06-18 09:26:58 -04:00
Tom Rothamel 0a701ed929 Allow the user to change the update channel (URL). 2012-06-18 00:11:00 -04:00
Tom Rothamel b5e6cb97c7 Add the updater to the new launcher. 2012-06-17 23:27:35 -04:00
Tom Rothamel b2671013fd Remove obsolete code, show message + directory when done with build. 2012-06-17 21:46:14 -04:00
Tom Rothamel 3eada61cc7 Include the archiver in the launcher, and automatic archiving as part
of the build process.
2012-06-17 21:20:11 -04:00
Tom Rothamel f693e26ab0 Feed information from the game into the build system, so we can now
use the game script to control building.
2012-06-17 18:26:05 -04:00
Tom Rothamel f575a1f233 Dump build information from the script to the json dump file. 2012-06-17 09:56:07 -04:00
Tom Rothamel 9834b85ced Able to build distributions, using a GUI to show progress. 2012-06-14 01:23:51 -04:00
Tom Rothamel b8d96d86b7 Look tweaks. 2012-06-12 00:15:01 -04:00
Tom Rothamel d58eaaf387 Add file patterns editor. 2012-06-12 00:09:22 -04:00
Tom Rothamel 67adb17ad3 Save project data. 2012-06-11 22:36:28 -04:00
Tom Rothamel 435e919326 Work on the build distributions gui. 2012-06-10 16:54:20 -04:00
Tom Rothamel 37f35e4f34 Add config.rgl_resize.
This was needed for the launcher, and determines if the user can resize
the window.
2012-06-10 01:03:24 -04:00
Tom Rothamel 3c6353f73e Add missing files to distributions. 2012-06-09 23:56:48 -04:00
Tom Rothamel dfc573d307 Integrate updater with Ren'Py.
This includes exposing the updater through Ren'Py functions,
and creating a default user-interface screen.
2012-06-09 23:15:45 -04:00
Tom Rothamel 6758b6acc7 Start turning the updater into a .rpy file. 2012-06-09 21:29:26 -04:00
Tom Rothamel 2c9bfddb4e Add a simulation mode to the updater. 2012-06-07 00:05:44 -04:00
Tom Rothamel 81bf4c2288 Verify signatures in the updater. 2012-06-06 23:50:58 -04:00
Tom Rothamel b38ae1fb13 Add signed update scripts. 2012-06-05 03:30:24 -04:00
Tom Rothamel 7f0ce7a40b Change unlinking to be safe in the face of Windows sharing violations. 2012-06-05 03:29:18 -04:00
Tom Rothamel 0f5da2d89b Add the mac transform to the updater. 2012-06-03 19:56:11 -04:00
Tom Rothamel c80095f511 Make the updater threaded. 2012-06-03 19:27:02 -04:00
Tom Rothamel a9414d4692 The updater is at the point where it can update the_question into the
tutorial game.
2012-06-03 18:46:08 -04:00
Tom Rothamel d2de95afc1 More work on the automatic updater. 2012-06-03 16:58:22 -04:00
Tom Rothamel 718a8fb4f8 Mac transform, include update.json, progress reporting. 2012-06-01 23:37:16 -04:00
Tom Rothamel 7c603578db Basic package building, to the point where we can build a linux
tarball.
2012-06-01 01:02:43 -04:00
Tom Rothamel 86e3c7f12f Change to look of theme changer. 2012-05-23 00:25:32 -04:00
Tom Rothamel 7d8f8b8f12 Add theme chooser. 2012-05-22 00:14:17 -04:00
Tom Rothamel 546a16e23c Add xinitial and yinitial parameters to a viewport. This lets us set the
initial positioning of the viewport.
2012-05-22 00:02:15 -04:00
Tom Rothamel 80571b8fbd Creating new projects.
This is the main part - creating the project - and not the theme-picking
part of it.
2012-05-20 16:42:23 -04:00
Tom Rothamel 7b1a634701 Add projects directory picking. 2012-05-20 15:34:16 -04:00
Tom Rothamel 3e4efa344e Add text input support. 2012-05-19 23:05:10 -04:00
Tom Rothamel 13c76f6cb5 If an input would be empty, display a ZWSP instead.
This ensures the size of the input won't change when text is added to
it.
2012-05-19 23:00:01 -04:00
Tom Rothamel a71e6cf6ec Add a preferences screen and editor selection code to launcher4. 2012-05-17 10:11:07 -04:00
Tom Rothamel b1dbbeeef8 Tweak colors. 2012-05-16 23:55:19 -04:00
Tom Rothamel 1d3216b6c9 Update the navigation data whenever the game is launched, load it whenever it is needed. 2012-05-16 23:46:32 -04:00
Tom Rothamel 11bbe2cff8 Dumps can now take place when the script is launched using any
commmand, so we can auto-refresh when another command is run.

Also, dump even when errors occur.
2012-05-15 00:08:58 -04:00
Tom Rothamel ff83ef5676 Improve navigation screens and look. 2012-05-15 00:08:44 -04:00
Tom Rothamel dcfc3a173e Make launcher into a game. Add directory opening support.
The idea is that we can now use the script navigation to help with developing the new launcher itself.
2012-05-13 12:57:52 -04:00
Tom Rothamel 2f83caea2d Add support of launching all script files in the editor. 2012-05-12 23:35:39 -04:00
Tom Rothamel 17ed25387d l4: Editor support, and hooking the editor up to navigation. 2012-05-12 22:44:27 -04:00
Tom Rothamel 4d8c1031cd l4: Work on navigation screen. 2012-05-12 00:42:01 -04:00
Tom Rothamel 89f4b81b57 Read the dump information into launcher4. 2012-05-11 00:16:34 -04:00
Tom Rothamel ad50aa7602 l4: Information, progress, and error handling functions. 2012-05-09 00:25:38 -04:00
Tom Rothamel 316c64bb48 Various tweaks to the dump format. 2012-05-09 00:25:28 -04:00
Tom Rothamel 19920b37ca Add support for dumping various types of symbols to a file. 2012-05-08 19:52:27 -04:00
Tom Rothamel ef5d6a4b66 Dump additional name types. 2012-05-08 00:03:05 -04:00
Tom Rothamel 2ea0299615 Implement the ability to dump label locations. 2012-05-07 23:41:27 -04:00
Tom Rothamel 4cd605c134 Fix the example colorizer in the demo game.
It was overloading the Python regexp compiler.
2012-05-07 21:00:56 -04:00
Tom Rothamel c2ddd39f2c Better handling of arguments.
Now, we handle subcommands using two-pass parsing, rather than relying
on argparse to do it for us.
2012-05-06 17:26:16 -04:00
Tom Rothamel 47209c9f63 l4: Add the ability to open the documentation, launch the game, and return to a project. 2012-05-03 23:12:04 -04:00
Tom Rothamel bb9c7dfe46 Add the OpenURL function. 2012-05-03 23:11:43 -04:00
Tom Rothamel d95192e018 l4: Work on front screen. 2012-05-03 21:01:04 -04:00
Tom Rothamel 68b76e2306 l4: Work on the new launcher. 2012-04-29 23:24:43 -04:00
Tom Rothamel 6f0c5125ae Merge 4+ months of 6.13 development back into 6.14. 2012-04-23 22:59:11 -04:00
Tom Rothamel 7b6da918a7 Distro fixes for the new host. 2012-04-22 19:25:28 -04:00
Tom Rothamel 0c05990db3 Bump version to 6.13.12. 2012-04-17 22:02:06 -04:00
Tom Rothamel a3581860b3 Clear errors at the start of a texture test.
When ANGLE resets, it can leave a spurious error around, which will
then cause the texture test to fail and Ren'Py to crash.
2012-04-17 20:58:26 -04:00
Tom Rothamel f371ed6f5f Deal with keys that are used in the game, but not defined in config.keymap.
This helps when the creator replaces config.keymap wholesale, and we then
upgrade to a new version of Ren'Py.
2012-04-17 20:55:37 -04:00
Tom Rothamel 17ea9736cd Minor changes to non-written building doc. 2012-04-17 20:55:12 -04:00
Tom Rothamel a1e13e3eab Make the style preferences dirty flag survive a rollback. 2012-04-13 00:35:57 -04:00
Tom Rothamel 1de06e650e Also log to the temp directory if we can't log to the Ren'Py base directory. 2012-04-12 20:44:16 -04:00
Tom Rothamel f92f14f68a Place error handling files in a temp directory if the current
directory isn't writable.
2012-04-12 19:46:45 -04:00
Tom Rothamel a3c5e57616 Allow the screenshot pattern to be configured by the creator. 2012-04-12 18:03:15 -04:00
Tom Rothamel 5840d6c464 Tweak the step size of a FieldValue, and allow it to be configured
by the user.
2012-04-11 23:23:25 -04:00
Tom Rothamel ba751a8a93 Fix run() to recurse into nested lists.
Allow Adjustment to compute a step even if page is 0.
2012-04-11 23:05:04 -04:00
Tom Rothamel 29c7d33c0a Restart the current interaction on a window resize.
This allows the buttons to update their state in response to a resize event.
2012-04-09 17:27:49 -04:00
Tom Rothamel dfb053dbd6 Reset the key modifiers when the game loses or gains focus.
This is a bad solution, but it's better than leaving ALT stuck on,
which makes a bunch of things not work.
2012-04-03 22:17:46 -04:00
Tom Rothamel 5918606f33 Bump version. 2012-03-27 22:37:23 -04:00
Tom Rothamel 794f8955e3 Deal with reuse of an swdraw object. 2012-03-27 22:25:29 -04:00
Tom Rothamel e90754e2dc Fix crashing on windows when minimizing and maximizing in GL mode.
Fix windows icon rendering.
2012-03-27 21:59:42 -04:00
Tom Rothamel 976b4fc2fc Better handling of errors in error handling.
We try to show the original exception, not the error handling one.
2012-03-25 10:37:38 -04:00
Tom Rothamel ddb7bd2167 Do not substitute in a parse error. 2012-03-25 10:20:00 -04:00
Tom Rothamel 74fd442303 Bump version to 6.13.10. 2012-03-24 23:04:38 -04:00
Tom Rothamel 66555facd5 More paranoia in error handling, to prevent errors from being masked. 2012-03-24 23:04:28 -04:00
Tom Rothamel 83b9ca6b96 If the display fails to initialize during error handling, fall back
to the traditional error handling.
2012-03-24 22:57:12 -04:00
Tom Rothamel dddeb56b91 Do not set renpy.display.draw to None when doing a display reset.
We now only do a display reset from inside Ren'Py - we've given up the
ability to change the renderer on the fly.
2012-03-24 22:46:11 -04:00
Tom Rothamel 39a799e995 Ensure that we use integer pixel coordinates when doing is_pixel_opaque
in the software renderer.
2012-03-24 21:55:29 -04:00
Tom Rothamel 88032a1478 Trim the rollback log even if there is no label in it, to prevent it
from growing to an infinite size.
2012-03-24 18:15:30 -04:00
Tom Rothamel 90e547b0a5 Doc fix. 2012-03-24 16:54:47 -04:00
Tom Rothamel cc9ea22354 Various fixes to package loading, to make it work closer to the
way Python does it.
2012-03-23 23:34:13 -04:00
Tom Rothamel ea3d409c19 Fix a regression with tiled frames.
The change to floating-point render widths made a call to range() not
work.
2012-03-11 10:23:41 -04:00
Tom Rothamel 5ef40f8c3e Improve new text editor support to be production quality. 2012-03-10 17:45:52 -05:00
Tom Rothamel 71ccf249f2 Merge 6.14 editor code.
This starts the process or working around windows argument handling,
which would be very difficult to do with the old design.
2012-03-08 16:43:53 -05:00
Tom Rothamel 45d9d640ee Add a check for non-ASCII filenames to lint. 2012-03-08 00:00:36 -05:00
Tom Rothamel 14c38ded81 Use execfile to run the editor file. (Since for some reason, exec didn't
work.)
2012-03-07 23:59:58 -05:00
Tom Rothamel d90d68fd68 Fsencode filenames we hand off to pygame, since it seems to convert at
least some of them if we don't.
2012-03-07 19:48:40 -05:00
Tom Rothamel 9abd26d76c Remove unnecessary module from calls to FsPopen.
(Not just unnecessary, but totally wrong.)
2012-03-07 17:01:08 -05:00
Tom Rothamel 3f0b27ba26 Ensure that all filesystem access occurs using the filesystem
encoding, rather than unicode or utf-8.
2012-03-07 01:33:39 -05:00
Tom Rothamel 70276655c8 Wherever we call sys.getfilesystemencoding(), ensure we use utf-8 if it
returns None.

For whatever reason, we don't know what the filesystem encoding is on
Android.
2012-03-06 22:30:43 -05:00
Tom Rothamel b07b6aa32f Minor fixes to distribute.py to work with my new drive layout. 2012-03-06 21:54:04 -05:00
Tom Rothamel bcce21b0d5 Make save_dump work on Python 2.6. 2012-03-06 12:39:52 -05:00
Tom Rothamel 967e0d6539 Invalidate displayables that are rendered as part of a size_group.
This fixes previous code that used .kill(), which is now a no-op.
2012-03-06 11:36:43 -05:00
Tom Rothamel 383193d478 Bump version to 6.13.9. 2012-03-05 22:45:08 -05:00
Tom Rothamel 6b640a7070 Update changelog. 2012-03-05 22:43:16 -05:00
Tom Rothamel e22a2c16bd Update Android building docs to reflect RAPT. 2012-03-05 22:20:37 -05:00
Tom Rothamel 67f356f1b4 Use doubles instead of ints to represent character widths in texwrap.
This fixes a bug that would cause lines to be too long - the lines
were correct in texwrap, since widths were fine as ints, but expanded
when rendered with the full glyph advances.
2012-03-05 21:18:39 -05:00
Tom Rothamel 2eee3c772b Log menu choices with an index of 0 as choices.
Thanks to Spiky Caterpillar.
2012-03-05 14:03:23 -05:00
Tom Rothamel 7b14755607 Switch all path handling to using unicode.
This prevents us from getting errors when trying to convert encodings
in path names.
2012-03-01 23:24:21 -05:00
Tom Rothamel 8c8940dcbb Change a use of GL_BYTE to GL_UNSIGNED_BYTE.
Since the latter isn't supported on OpenGL ES. Also, one would never
want to use the former. (I have no idea why OpenGL even has it.)
2012-02-29 22:50:09 -05:00
Tom Rothamel 5aadfa5ca4 Add headers for cdef extern functions.
This allows things to compile on Windows. I'm not sure what changed to
make them not compile - probably something in Cython.
2012-02-29 01:05:53 -05:00
Tom Rothamel 46ef0cbf04 Change the type of height and width in Render to float.
This is for compatibility with 6.10 and prior versions of Ren'Py, and
because it makes sense. Zooming an image wants to create an image with
a non-integer width and height. This is especially true when xalign is
non-zero - we need to take the precise width into account when
centering the displayable (at least when using subpixel precision).
2012-02-27 23:43:53 -05:00
Tom Rothamel be6d4fdf77 Add config.save_dump, to allow people to configure save dumping. 2012-02-26 23:04:36 -05:00
Tom Rothamel c663b71114 Discard all displayables when saving a screen.
Previously, we didn't clear the widgets and transforms variables,
which kept almost everything - and made Cradle Song much slower.
2012-02-26 22:33:11 -05:00
Tom Rothamel e9b8a16a80 Code to dump a representation of the contents of the save file
when it's created.

This helps us determine why save-space is leaking.
2012-02-26 19:40:55 -05:00
Tom Rothamel 2750bcf927 Remove blacklist test code. 2012-01-30 17:56:05 -05:00
Tom Rothamel 320dc92092 Improvements to the blacklist.
Some versions of Mesa randomly fail when trying to compile shaders. We catch
those, and fall back to fixed-function mode to prevent the crash.
2012-01-24 23:48:35 -05:00
Tom Rothamel 790bdb03e7 Fix crash in Render.fill.
We were using SolidImage, which has been replaced by Solid.
2012-01-18 21:44:51 -05:00
Tom Rothamel 619addc5f0 Better catch autosave errors. 2012-01-17 22:27:48 -05:00
Tom Rothamel 47fb3f9438 Update copyright to 2012. 2012-01-15 09:50:38 -05:00
Tom Rothamel 7ac22328b2 Quote values displayed in the variable viewer, when they have [ in them.
Bug reported at:  http://lemmasoft.renai.us/forums/viewtopic.php?f=8&t=12726
2012-01-11 22:51:45 -05:00
Tom Rothamel 91989a56e9 Bound outlined blits.
This is in response to http://lemmasoft.renai.us/forums/viewtopic.php?p=177213#p177213
a bug where we were stuck drawing outside the screen.
2012-01-11 22:46:55 -05:00
Tom Rothamel 34070e63e6 Prefer modules from local directory.
Previously, if we had installed the Ren'Py modules, we would use those in
preference to the modules that exist in the current directory.
2012-01-11 22:45:55 -05:00
Tom Rothamel 1a5a7ef82a Fix roll-forward. 2012-01-11 22:27:27 -05:00
Tom Rothamel e2ae6828be Update changelog. 2012-01-07 19:58:10 -05:00
Tom Rothamel 9f02ad9a82 Use glTexParameteri instead of glTexParameterf for the texture test.
This is more consistent with how the normal code does it, and
also compiles on Windows.
2012-01-07 19:32:35 -05:00
Tom Rothamel 0289c770b4 Improvments to SideImage support.
Can track a single tag. Can only show a SideImage for characters
that are not on screen.
2012-01-07 19:12:15 -05:00
Tom Rothamel 6c5ce3198e Make a more useful error report if we can't import pygame.
Users can get this if they have ; or : in the directory, so
we inform them about that before creating a traceback.
2012-01-07 17:53:25 -05:00
Tom Rothamel 7acc54daa3 Protect the call to time.ctime().
It failed once on one user's machine, but since it isn't really
critical path, might as well just continue on in the case of
a failure.
2012-01-07 17:53:01 -05:00
Tom Rothamel 08192c47fc Do not allow a roll_forward when we're not in a context that
allows rollback.

Fixes bug #882807.
2012-01-05 22:44:41 -05:00
Tom Rothamel b94a84b931 Ren'Py now builds with libpng 1.5
Thanks to James Broadhead for the patch.
2012-01-05 21:55:08 -05:00
Tom Rothamel 82576c5ed6 Re-enable old-style interpolation.
This is in response to Bug #909023, and in recognition that there's a
lot of code out there that uses the old syntax.
2012-01-05 20:44:38 -05:00
Tom Rothamel 19333248d9 Ignore attempts to load from a non-existent directory.
This gets KS running.
2012-01-05 20:18:20 -05:00
Tom Rothamel 4774017317 Fix a bug with fonts.
It's possible to have a font's bitmap go above its ascent. When this
happened, we would write outside of memory. This fixes that bug by not
drawing - it might render the font wrong, but it should prevent
crashing.
2012-01-04 22:28:20 -05:00
Tom Rothamel 21a667d645 More accurate wording. 2012-01-01 00:20:06 -05:00
Tom Rothamel 81276aeb26 Added config.python_callbacks.
This is a list of functions that are called at the end of each Python
block. One use of this would be to allow variables to manipulated with
normal mathematical operators, and then have a callback ensure that
they remain within a range.
2012-01-01 00:18:02 -05:00
Tom Rothamel 8e975217f5 Modify the DSE game so that it uses the new-style interpolation syntax. 2011-12-31 23:56:11 -05:00
Tom Rothamel 3d47c7bae3 Quote square brackets in the old launcher. 2011-12-31 23:55:57 -05:00
Tom Rothamel c93a2ed5d5 Fix shebang in renpy.py. 2011-12-31 23:55:43 -05:00
Tom Rothamel eb9b83860b Fix more eclipse warnings.
Figured out how to get eclipse to scan the modules, so we can dispense
with the typeinfo stuff.
2011-12-31 23:03:00 -05:00
Tom Rothamel d9b7c73e8f Round up the width of text before drawing it.
When using negative kerning, we can have a line of text with a
fractional computed width. Rounding down this case lead to the last
pixel being cut off.
2011-12-31 19:14:20 -05:00
Tom Rothamel 0f5b7267fb Test textures before attempting to use them.
The hope is that we never use an overly-large texture.
2011-12-26 23:53:23 -05:00
Tom Rothamel eac1b02212 Remove all PyDev-generated warnings and problems.
(Updated to a new version of PyDev, which generated new warnings.)
2011-12-25 12:17:11 -05:00
Tom Rothamel cc8396a8ab Don't save the child of a screen. 2011-12-18 21:41:22 -05:00
Tom Rothamel 31a8cd2a3c Doc fix. 2011-12-17 23:26:23 -05:00
Tom Rothamel 295e64a02c Merge fixes from mainline. 2011-12-17 23:24:29 -05:00
Tom Rothamel ee566fc6c8 Import minstore into default store.
This ensures that sets created in the default store have the right
(RevertableSet) type.
2011-12-14 22:45:26 -05:00
Tom Rothamel fb60c4acfe New editor code. 2011-12-14 22:35:51 -05:00
Tom Rothamel 8381b5184c Add navigate page. 2011-11-30 21:47:00 -05:00
Tom Rothamel 9e5570b1b4 Only use the transform path for non-identity transforms. 2011-11-27 15:22:11 -05:00
Tom Rothamel 2caaebc1f5 Fix problems w/ rendering.
#1: Operation is not copied during a subsurface operation.

#2: A transformed dissolve (or IMAGEDISSOLVE) isn't rendered properly.
2011-11-27 14:46:17 -05:00
Tom Rothamel abb99e19e2 Start work on the settings screen.
Right now, it has the projects directory choice, and a checkbox to
disable transitions.
2011-11-24 12:29:13 -05:00
Tom Rothamel 63ed2b8632 l3: checkboxes. 2011-11-23 22:56:07 -05:00
Tom Rothamel 07d1391c4a Overlay pages.
We want one layer of overlay pages in the launcher. This lets
us replace the current page with other info, and then easily and
automatically get back to the main page.

Tried a stack, but it's too complex for our needs.
2011-11-22 23:25:56 -05:00
Tom Rothamel b69c0c2007 Refactor launcher, add jsondump command.
The launcher now is based on "pages". The jsondump command will dump
game information to a json file.
2011-11-22 22:42:49 -05:00
Tom Rothamel 6bda5fa459 Implement commands.
Commands are given on the command line after the base
directory. Implemented the lint, quit, and rmpersistent commands.
2011-11-19 22:55:38 -05:00
Tom Rothamel 5e9f4e71c8 Hook up arguments. Remove remote-control support.
Removed the remote control support since it was never documented or used.
2011-11-19 16:23:33 -05:00
Tom Rothamel d2188c860f Create arguments.py, begin switching Ren'Py to use argparse.
Moved the list of arguments to arguments.py.
2011-11-19 00:58:06 -05:00
Tom Rothamel b60ad5f3ec Launcher now launches. Viewport takes a scrollbars parameter. A screen
language block may now contain multiple has statements.
2011-11-13 22:15:40 -05:00
Tom Rothamel 5305670f1c Add launch button 2011-11-11 23:46:23 -05:00
Tom Rothamel bfb9380de0 The :ref:sl-textbutton and :ref:sl-label screen language statements now take
properties prefixed with ``text_``. These properties have the text_
prefix stripped, and are then passed to the internal text displayable.
2011-11-11 22:17:09 -05:00
Tom Rothamel 25c7bc5726 More look improvements. 2011-11-09 22:43:26 -05:00
Tom Rothamel 63acf7eb05 Transitions in the launcher. 2011-11-07 21:14:13 -05:00
Tom Rothamel 2f134f69f1 Improve multiple store support. 2011-11-06 23:37:00 -05:00
Tom Rothamel bf17e281c9 Start work on next-generation launcher. 2011-11-06 23:36:27 -05:00
Tom Rothamel 2b40f1b84d Implement additional store modules. 2011-10-30 19:06:01 -04:00
Tom Rothamel e6617caeef Rewrite store handling. 2011-10-24 23:36:49 -04:00
Tom Rothamel 34eee81a55 StoreDict and StoreModule classes. 2011-10-23 22:04:36 -04:00
Tom Rothamel bec2a832ea Type out text at the full framerate. 2011-10-20 19:26:15 -04:00
Tom Rothamel 6d86238f0a Bump version. 2011-10-18 22:02:59 -04:00
Tom Rothamel 758d5bad17 Disable substitutions in the launcher. 2011-10-18 21:54:17 -04:00
Tom Rothamel 291ff22366 Fix crash in font searching. 2011-10-16 22:37:38 -04:00
Tom Rothamel f4f0b8f8ce On Android, clear out multiple up or down events. 2011-10-15 14:49:45 -04:00
Tom Rothamel b8abc5aa16 Build docs, bump version. 2011-10-13 01:05:20 -04:00
Tom Rothamel 28fd3c9c89 Fix crash when loading in a created style. 2011-10-13 00:20:19 -04:00
Tom Rothamel 2c94cd19f6 Fix problems with QuickSave and QuickLoad. 2011-10-12 22:53:27 -04:00
Tom Rothamel 8add2bca63 Fix the creation of small solid textures on the software renderer. 2011-10-10 23:33:30 -04:00
Tom Rothamel 77041374ea Fix slow text, bump version. 2011-10-09 10:06:19 -04:00
Tom Rothamel 3d54904e89 Sphinx fixes. 2011-10-08 12:18:34 -04:00
Tom Rothamel a9d1f16cd8 shift+G gets people to the graphics menu. 2011-10-08 10:38:46 -04:00
Tom Rothamel 0439b22269 Bump version. 2011-10-06 17:54:46 -04:00
Tom Rothamel 3fe8abf25c Fix jumps from called screens. 2011-10-06 17:54:04 -04:00
Tom Rothamel 04299ac0f5 Fix distributed files, bump version, add build test script. 2011-10-06 08:22:35 -04:00
Tom Rothamel 96397ea768 Bump version. 2011-10-05 18:58:48 -04:00
Tom Rothamel 6580b36e35 Fix bugs in init phase error handling. 2011-10-04 23:33:49 -04:00
Tom Rothamel 4af4384dac Text's __init__ method can't use styles, since they're not built yet. 2011-10-04 23:29:26 -04:00
Tom Rothamel ebaaf0b242 Perform early binding on text substitutions. 2011-10-02 20:58:51 -04:00
Tom Rothamel bea36e2aa2 Doc fix to CDDs. 2011-10-02 15:14:10 -04:00
Tom Rothamel 247ec17be3 Tweaks to DX update phrasing. 2011-10-02 10:30:06 -04:00
Tom Rothamel 577c378517 Doc fixes. 2011-09-30 17:00:20 -04:00
Tom Rothamel 52e631f229 Make scissor box placement more correct, to prevent artifacts on the
sides of Frames.
2011-09-29 23:56:35 -04:00
Tom Rothamel f8307f725e Fix the scissor test to work with non-default projections, like the one
the mouse uses.
2011-09-29 17:20:45 -04:00
Tom Rothamel c13fbcaab2 Set config.auto_save_extra_info. 2011-09-29 00:31:52 -04:00
Tom Rothamel 6c4eff321e But for convenience, do a with None on a JumpException. 2011-09-28 22:38:33 -04:00
Tom Rothamel 54b8b73d45 Call screen only does a with None if it returns. 2011-09-28 22:35:28 -04:00
Tom Rothamel 0e88b7629e Ensure the software renderer calls init. 2011-09-28 18:20:24 -04:00
Tom Rothamel 012f148622 Fix transition per_interact handling. 2011-09-27 21:57:31 -04:00
Tom Rothamel 56a20cc877 Fix timer repeat bug, from http://lemmasoft.renai.us/forums/viewtopic.php?f=8&t=12023 2011-09-27 20:13:30 -04:00
Tom Rothamel b8df922459 Doc fixes. 2011-09-27 20:09:02 -04:00
Tom Rothamel 896232d308 Properly handle newlines in rpt files. 2011-09-27 20:02:31 -04:00
Tom Rothamel 0207327ded Doc fixes, thanks to Koichi Akabe. 2011-09-27 19:07:16 -04:00
Tom Rothamel e6815a3a4f Deal with buggy fonts w/ positive descenders. 2011-09-26 22:38:38 -04:00
Tom Rothamel 179bbaea92 Fixes to text vertical layout. 2011-09-26 22:13:21 -04:00
Tom Rothamel c7889bc7a2 Don't clip the mouse cursor. 2011-09-25 22:00:45 -04:00
Tom Rothamel ce9ecd124a Fix segfault bug. 2011-09-25 21:19:35 -04:00
Tom Rothamel 426a12d50c Use the existence of ANGLE to decide if we should use the fixed function
renderer, or fall back to ANGLE/DX.
2011-09-25 18:38:48 -04:00
Tom Rothamel eefd0ed728 Prioritize gl2 over angle over gl1 over software. 2011-09-24 23:31:41 -04:00
Tom Rothamel 6604043df0 Deactivate attribute arrays when they're not going to be used. 2011-09-20 22:53:24 -04:00
Tom Rothamel a3271bb290 Distribute sound.pyx. 2011-09-18 14:52:12 -04:00
Tom Rothamel aeed3598a1 Bump versions. 2011-09-18 14:00:56 -04:00
Tom Rothamel 4b43986a6c Allow auto-created styles to be loaded. 2011-09-18 13:58:08 -04:00
Tom Rothamel 4f79180a8e Prefer the copy RTT to the FBO one, because FBOs seem to trigger
crashes on a regular basis.
2011-09-18 13:31:42 -04:00
Tom Rothamel a635c4c35c Update changelog. 2011-09-11 12:37:58 -04:00
Tom Rothamel afc42f4ed3 Make error handling more robust. 2011-09-11 12:35:22 -04:00
Tom Rothamel 547accfd44 Allow user-defined statements to take blocks. 2011-09-11 11:34:00 -04:00
Tom Rothamel ccb51c7a26 Fix lint w/ non-English characters in the what part of a say statement. 2011-09-11 09:35:45 -04:00
Tom Rothamel 33190bba34 Update android build; add support for android assets. 2011-09-07 23:35:30 -04:00
Tom Rothamel b3147011d4 Only error out on bad text if config.developer is set. 2011-09-05 09:47:00 -04:00
Tom Rothamel 4c987901b6 Move to avlib. Deal with invalid frame sizes. Include posixpath on windows. 2011-09-05 09:42:37 -04:00
Tom Rothamel ce332b895f When text gets a non-string, non-displayable, trigger the error early. 2011-09-04 14:58:58 -04:00
Tom Rothamel 9b5823109f Guard more prediction. 2011-09-04 14:29:40 -04:00
Tom Rothamel 7a84fb8cdd Renamed from Low-Carb to Eye of the Storm. Thanks, Hurricane Irene. 2011-09-04 13:38:25 -04:00
Tom Rothamel 94c5c525a7 Allow ATL to interpolate None vs a tuple. 2011-09-04 13:19:53 -04:00
Tom Rothamel 0d25e419b4 Fixes. 2011-09-04 11:39:27 -04:00
Tom Rothamel b669f8363c More doc fixes. 2011-09-03 22:06:39 -04:00
Tom Rothamel 8e44aa6f88 More documentation. 2011-09-03 21:35:57 -04:00
Tom Rothamel 3ef70f862e Better format timed output. 2011-09-02 18:20:22 -04:00
Tom Rothamel e4d99edb65 Use RGBA to read pixels, even if we just want the alpha channel. This
is because GL_ALPHA isn't supported on GLES 2.
2011-09-02 08:59:37 -04:00
Tom Rothamel 5f611786dd Tweak compat version. 2011-09-02 07:45:28 -04:00
Tom Rothamel 657711a0a7 Change search style. 2011-09-01 21:01:39 -04:00
Tom Rothamel 0f1e6e7702 Update documentation. 2011-09-01 20:37:57 -04:00
Tom Rothamel e379ffae51 Include line number as part of the bytecode hash data. 2011-09-01 19:56:47 -04:00
Tom Rothamel b10d5e715c Use the advance, not the width, for image-based fonts.
Include .pyo files in an update iff there's no corresponding .py file.
2011-09-01 16:55:37 -04:00
Tom Rothamel 2f54637881 Flush logs after write. 2011-08-31 20:34:32 -04:00
Tom Rothamel eda1e01a71 Ignore more exceptions in displayables. 2011-08-31 17:07:42 -04:00
Tom Rothamel 8fdc4b8f58 Include utf_16_be, since it's used by the python compiler. 2011-08-31 15:28:15 -04:00
Tom Rothamel 3048825824 Only run iconified/restored code if we change states. 2011-08-30 22:04:50 -04:00
Tom Rothamel 704685c11a Bug fixing. 2011-08-30 19:30:33 -04:00
Tom Rothamel 7fba3a04da Try to fix reported encoding problem. 2011-08-30 17:35:59 -04:00
Tom Rothamel bfc57ecfc6 Fix off-by-one error in the blit outlining code. 2011-08-30 16:43:16 -04:00
Tom Rothamel c0dba7f121 Add a break point before a displayable. 2011-08-30 16:19:40 -04:00
Tom Rothamel ce3e63f3a5 Add latin encoding.
Fix windows build.
2011-08-27 23:47:19 -04:00
Tom Rothamel 0105503855 Quote urls properly. 2011-08-27 22:44:33 -04:00
Tom Rothamel 0d8525f1b1 Fix an exception in text.py, and one in logging. 2011-08-27 21:01:50 -04:00
Tom Rothamel bfd4a1e846 Reset the display when restoring on windows.
This fixes a bug where DirectX would leave a restored window blank, for
some reason.
2011-08-27 20:22:50 -04:00
Tom Rothamel c74343d2dd Use #-of-texture specific vertex shaders. 2011-08-27 16:11:43 -04:00
Tom Rothamel 6f7f545cd8 Document new text tags. 2011-08-26 21:43:48 -04:00
Tom Rothamel 303885776e Use RENPY_CYTHON to get the path to cython. 2011-08-26 21:17:03 -04:00
Tom Rothamel cabcf5b73c Fix compatibility. 2011-08-26 14:05:37 -04:00
Tom Rothamel a8a1972418 Don't update the file page when it's None. 2011-08-25 22:33:35 -04:00
Tom Rothamel 347778d8aa Revert {w} handling to be more similar to the way it was in 6.12, so
as to work better with NVL-mode.
2011-08-25 00:02:39 -04:00
Tom Rothamel 9646c951bb ANGLE should render to RGBA textures. 2011-08-24 12:45:23 -04:00
Tom Rothamel 7b4128f6b2 Don't transition off of a null that's been created without the ATL
script ever running.
2011-08-23 23:47:40 -04:00
Tom Rothamel 7ac623fc99 Fix problem with drawing an empty texture. Other fixes required to
build things.
2011-08-23 22:07:55 -04:00
Tom Rothamel e9328255b7 Pick a name: Low-Carb 2011-08-22 21:37:25 -04:00
Tom Rothamel 11ce47287b Make label take a scope. 2011-08-22 20:32:38 -04:00
Tom Rothamel a1ab25955d Make the tutorial game use new-style substitutions. 2011-08-22 20:08:40 -04:00
Tom Rothamel 3f59b82c2a Don't package bad filenames. 2011-08-22 19:30:17 -04:00
Tom Rothamel 0e6cded6cd Tweak what we distribute. 2011-08-22 19:28:34 -04:00
Tom Rothamel e18f73b317 Fix problem with empty lines in Text. 2011-08-22 19:15:00 -04:00
Tom Rothamel e65146503c Update license and changelog. 2011-08-20 21:53:42 -04:00
Tom Rothamel a6a5c65067 Make Ren'Py compile w/ ffmpeg-0.8.2. 2011-08-20 21:45:37 -04:00
Tom Rothamel afb58fa423 Offer the user the ability to install DirectX. 2011-08-20 17:08:07 -04:00
Tom Rothamel 8762636374 Document text overflow debugging. 2011-08-19 23:04:44 -04:00
Tom Rothamel d1b53fb56c Tweak wording. 2011-08-19 22:49:53 -04:00
Tom Rothamel c7b028b8cf Add missing files. 2011-08-19 22:42:07 -04:00
Tom Rothamel d0ee364a81 Document style preferences and image fonts. 2011-08-19 22:41:15 -04:00
Tom Rothamel a48fdc0d2c Remove minigame; fix uses of renpy.display.text; fix auto-unicode. 2011-08-18 12:05:58 -04:00
Tom Rothamel a464034fd0 More documentation. 2011-08-17 22:10:51 -04:00
Tom Rothamel 51955cae76 Add more indexes, start writing text documentation. 2011-08-17 21:42:35 -04:00
Tom Rothamel f2633d528e Translation update support. 2011-08-16 21:21:11 -04:00
Tom Rothamel 33090e1aa4 Document new text styles. 2011-08-16 20:36:24 -04:00
Tom Rothamel ffc801eaca Write changelog. 2011-08-16 19:16:52 -04:00
Tom Rothamel 49e77a1fa1 Add time_warp parameter to Dissolve and ImageDissolve. 2011-08-15 21:42:36 -04:00
Tom Rothamel 13c5ddc5fa Change the meaning of the auto-forward adjustment when default_afm_enable is
not None.
2011-08-15 21:25:44 -04:00
Tom Rothamel 1ee54eecbd Restore 6.11's xfill/yfill behavior. 2011-08-15 21:01:31 -04:00
Tom Rothamel b7ac285aeb Theme updates and color schemes from Aleema. 2011-08-15 13:57:06 -04:00
Tom Rothamel b6b50f1842 New themes, courtesy of Aleema. 2011-08-15 13:49:09 -04:00
Tom Rothamel d283792193 Add the quick menu to input and nvl-mode screens. 2011-08-14 09:46:45 -04:00
Tom Rothamel 0c5ccd267c Add quick menu to tutorial game. 2011-08-14 09:31:53 -04:00
Tom Rothamel 81108e2d26 Add image gallery. 2011-08-13 22:05:18 -04:00
Tom Rothamel 3c3590bafe Basic translation framework (no tool support). 2011-08-11 23:50:44 -04:00
Tom Rothamel b9e1120f69 New actions - SelectedIf, SetMixer, Rollback, and RollForward. 2011-08-11 20:18:41 -04:00
Tom Rothamel 9f943337bb Update the look of the documentation. 2011-08-11 17:48:49 -04:00
Tom Rothamel ab8964be1d Fix renpy.free_memory. 2011-08-11 15:41:17 -04:00
Tom Rothamel 37c1ba3926 Implement the caret style property. 2011-08-11 15:21:00 -04:00
Tom Rothamel 364d077c8a Allow frame borders to be assymetric. 2011-08-10 00:04:15 -04:00
Tom Rothamel 626f86b500 Fix an encoding problem. 2011-08-08 21:57:42 -04:00
Tom Rothamel d6488e4e7d Export renpy.easy.displayable as renpy.displayable. 2011-08-08 21:57:05 -04:00
Tom Rothamel 846abef17f Include platform in url. 2011-08-08 21:56:51 -04:00
Tom Rothamel 60e65a4d01 Automatically set the focus name of screens. 2011-08-08 20:47:39 -04:00
Tom Rothamel 4057365ff1 Allow newtext to react to style prefix changes. 2011-08-08 13:44:28 -04:00
Tom Rothamel f7d95e2791 Ensure that a transform always has a child after it has been copied,
since the copying code assumes the presence of a child when it updates
the state.

Other Cradle Song-inspired fixes.
2011-08-08 08:21:15 -04:00
Tom Rothamel db812e7f7b Implement style preferences. 2011-08-07 23:09:37 -04:00
Tom Rothamel 66e51bab0d Remove iliad support. 2011-08-07 20:46:29 -04:00
Tom Rothamel d0d82a5e22 Ren'Py always uses RGBA, with the software renderer translating that to the
screen format at texture load time.
2011-08-07 16:46:35 -04:00
Tom Rothamel 2d99e76007 Remove old-style scaling, in favor of a simple render-and-scale approach. 2011-08-07 14:30:04 -04:00
Tom Rothamel 102ff2145f Made setup.py report unnecessary files in gen. 2011-08-06 23:28:50 -04:00
Tom Rothamel 0e00282758 Merge Angle/DirectX support. 2011-08-06 23:22:43 -04:00
Tom Rothamel 337d12e490 Factor the performance test out into its own function, so creators can
call it whenever they want.
2011-08-06 23:19:05 -04:00
Tom Rothamel 916e125f4b Tweak language. 2011-08-06 22:59:31 -04:00
Tom Rothamel 752ef70000 Use framebuffer RTT by default when available. 2011-08-06 22:36:39 -04:00
Tom Rothamel b67c70dbe3 Add performance test.
Change how Ren'Py stores the renderer to use.

Add renpy.windows, renpy.macintosh, renpy.linux, and renpy.android
platform variables.
2011-08-06 22:31:05 -04:00
Tom Rothamel 8277ba6b5b Set the swap interval, although ANGLE doesn't seem to respect it. 2011-08-06 14:57:05 -04:00
Tom Rothamel 2db2a4a94d Fix windows build. 2011-08-06 14:20:02 -04:00
Tom Rothamel a477b862dd Eliminate the glenviron module. 2011-08-06 12:42:17 -04:00
Tom Rothamel 0a5cf3bcee Remove glshader now that everything from it has been moved into glenviron_shader. 2011-08-05 08:41:59 -04:00
Tom Rothamel 2d6e2bcd61 Accept dense packing from OpenGL when taking a screenshot - this allows us to take
screenshots from OpenGL ES.
2011-08-05 08:37:53 -04:00
Tom Rothamel 8d8b52dead Minor tweaks so things run on angle. 2011-08-05 07:13:03 -04:00
Tom Rothamel 3409759271 Refactor the way clipping occurs to be environ-specific. Use the shader to clip when
it's available.
2011-08-04 22:41:43 -04:00
Tom Rothamel 3109dad59b Angle now works on windows, even when the window changes. 2011-08-03 21:12:57 -04:00
Tom Rothamel 16c35e21f4 Transpose projection matrix, since OpenGL ES won't accept the option that
tells it to transpose for us.
2011-08-03 07:34:39 -04:00
Tom Rothamel 509b33477a Checkpoint progress - can open window, list version & extensions. 2011-08-02 23:08:23 -04:00
Tom Rothamel 4fcfdd24d1 Changes to allow things to build w/ ANGLE. 2011-08-02 12:39:20 -04:00
Tom Rothamel 473e8ea861 Redo glcompat.h so that it can handle GLES2. 2011-08-02 07:41:30 -04:00
Tom Rothamel 0bbbde3fb6 Fix RTT. 2011-08-01 23:58:33 -04:00
Tom Rothamel 0576bb71de Now mostly working (w/ transition problems). 2011-08-01 23:41:30 -04:00
Tom Rothamel e91d35abda Buggy as hell gles2-style shader. 2011-08-01 22:11:50 -04:00
Tom Rothamel da638df367 Generate angle code from gl code; tweak build system so they coexist. 2011-07-31 14:07:49 -04:00
Tom Rothamel bf8467aaa0 Move gl modules into their own package. 2011-07-30 22:09:27 -04:00
Tom Rothamel 3a8eea3223 Tweak bzrignore. 2011-07-30 21:32:02 -04:00
Tom Rothamel 566ed9bae6 Merge in changes from 6.12 branch. 2011-07-29 20:44:59 -04:00
Tom Rothamel 132341c9b5 Add versioning documentation. 2011-07-29 20:37:28 -04:00
Tom Rothamel 3f2a18a387 Add 6.12.2 information. 2011-07-29 19:48:06 -04:00
Tom Rothamel 296f940437 Update the docs. 2011-07-28 22:04:14 -04:00
Tom Rothamel dc7833e0fe End skipping on a game restart. 2011-07-28 21:59:26 -04:00
Tom Rothamel 7f38694341 Show mouse when quit_action runs. 2011-07-28 19:52:27 -04:00
Tom Rothamel 0a25f4e488 Fix lockup when a transition terminates early. 2011-07-28 19:13:29 -04:00
Tom Rothamel 88d5b6ea16 Make RENPY_SCALE_FAST work. 2011-07-27 22:23:00 -04:00
Tom Rothamel b775916a8d Fix doc bugs. 2011-07-27 16:06:55 -04:00
Tom Rothamel c1e4d3d598 Prospective patch for compiling w/ new ffmpeg 2011-07-27 15:58:52 -04:00
Tom Rothamel 2435b50e6d Have multipletransition handle timeevent. 2011-07-26 21:38:49 -04:00
Tom Rothamel 466c40f501 bump version. 2011-07-25 21:48:25 -04:00
Tom Rothamel e76f4205cb Try a different approach to how we deal with childless transforms. 2011-07-24 17:40:44 -04:00
Tom Rothamel 1961d467d9 Merge in newtext branch, which includes a rewrite of Text and also improvments
to the module build system.
2011-07-23 20:00:34 -04:00
Tom Rothamel 3cb9b3637d Fix quoting of text tags. 2011-07-23 19:43:53 -04:00
Tom Rothamel cf0232d24a Clean up code. 2011-07-23 18:58:51 -04:00
Tom Rothamel d1c786aa4a Remove oldtext. 2011-07-23 18:39:48 -04:00
Tom Rothamel 209b2b2099 Backwards compatibility and test cases. 2011-07-23 18:37:36 -04:00
Tom Rothamel efd378e71c Change defaults, bump version. 2011-07-22 13:33:05 -04:00
Tom Rothamel 50edf2ad83 Add backwards compatibility. 2011-07-22 13:27:28 -04:00
Tom Rothamel 27aae8a8f0 Hook newtext up to the screen language. 2011-07-21 21:13:27 -04:00
Tom Rothamel b07cae5959 Update Input to work with newtext. 2011-07-21 16:10:11 -04:00
Tom Rothamel f786704d9a Eliminate most uses of renpy.display.text. 2011-07-21 15:40:46 -04:00
Tom Rothamel 9f46f7a824 Text overflow detection. 2011-07-21 13:32:10 -04:00
Tom Rothamel 9b98a0f442 Make substitutions occur in Character. 2011-07-21 13:10:07 -04:00
Tom Rothamel 165c6886c1 Finish font TODOs. 2011-07-21 12:08:44 -04:00
Tom Rothamel c79f9f585b Displaying image fonts (with TODOs, still.) 2011-07-20 23:05:38 -04:00
Tom Rothamel 486ea3dc70 Start work on the new font module. 2011-07-20 22:29:14 -04:00
Tom Rothamel 765566acb0 Implement newline indent. 2011-07-20 06:47:28 -04:00
Tom Rothamel 06e06c3504 Continue integration/testing work. Can now begin to run the tutorial. 2011-07-18 22:36:29 -04:00
Tom Rothamel a16cf65808 Start hooking up newtext. 2011-07-17 21:22:59 -04:00
Tom Rothamel b65a5e6452 Redo build system to be simpler, and to automatically track dependencies. 2011-07-17 14:39:10 -04:00
Tom Rothamel ec88378641 Put newtext into its own package. 2011-07-17 12:15:09 -04:00
Tom Rothamel e22cc152d8 Finish substitutions and add to newtext. 2011-07-16 21:21:39 -04:00
Tom Rothamel db8adea231 Remove all symlinks from tree. 2011-07-16 10:55:00 -04:00
Tom Rothamel 7c7c92fe91 Add support for {_end} tag. 2011-07-15 22:29:23 -04:00
Tom Rothamel 7a8dec6afa State-machine-based formatter object. 2011-07-15 21:44:30 -04:00
Tom Rothamel 49637c2dbd Add a "nobreak" layout mode. 2011-07-14 21:54:25 -04:00
Tom Rothamel 51372d281a Finish implementing TeX linebreaking. 2011-07-14 21:37:13 -04:00
Tom Rothamel 3a4973ba20 Add support for RTL languages. 2011-07-14 21:12:30 -04:00
Tom Rothamel e447c6170b merge mainline 2011-07-14 11:28:51 -04:00
Tom Rothamel 90b25d3ea4 Remove symlink. 2011-07-13 00:49:14 -04:00
Tom Rothamel 951afa8799 screens: Only show joystick if a joystick exists (or we fake it). 2011-07-12 23:49:19 -04:00
Tom Rothamel 644243db31 Timer now can take a list of actions, rather than just a callable. Fixes lp:808546. 2011-07-10 21:41:44 -04:00
Tom Rothamel 212a1f0682 Document music_room. 2011-07-02 21:53:29 -04:00
Tom Rothamel d700cd9a97 Add music room. 2011-07-02 20:34:55 -04:00
Tom Rothamel 59d4ff87b8 Merge in fixes from the 6.12.1 branch. 2011-06-23 22:09:28 -04:00
Tom Rothamel 08641efd0c Force ATL transforms to be executed before they can be copied. This
prevents no child errors when the child is the first thing in the ATL.
2011-06-22 23:23:14 -04:00
Tom Rothamel 7c81554b39 Comment out parameterize for now. 2011-06-22 22:24:21 -04:00
Tom Rothamel 6fc1792436 Fix CTC-related problems. 2011-06-22 17:52:31 -04:00
Tom Rothamel c2855f7871 Use the correct definition for RENPY_THIRD_TEXTURE. 2011-06-22 16:13:17 -04:00
Tom Rothamel 5988076d56 Update documentation. 2011-06-22 13:54:50 -04:00
Tom Rothamel 4a0164fc7f Fix xfill/yfill fix. 2011-06-22 00:23:15 -04:00
Tom Rothamel 9bad334102 Ren'Py no longer captures gamepad input when not focused. 2011-06-21 23:19:27 -04:00
Tom Rothamel 4dfca9e6c1 Handle quit-during-error-handling by quitting. 2011-06-21 22:53:47 -04:00
Tom Rothamel 8b1dee04cd Fixes for the software renderer. 2011-06-20 22:32:33 -04:00
Tom Rothamel d856bd13be Pick a better window size on netbooks that use the software renderer. 2011-06-20 00:17:51 -04:00
Tom Rothamel e9d198109c ATL splines should deal with unknown properties, just like linear interpolation does. 2011-06-19 23:25:33 -04:00
Tom Rothamel aed19f9492 Add a NoRollback class, and make Particle inherit from it, to preserve
previous semantics.
2011-06-19 22:55:21 -04:00
Tom Rothamel 126c520d14 Fix bug with side images. 2011-06-19 14:45:29 -04:00
Tom Rothamel 6d23374f01 Use tablet/phone variants before None variant; also before touch variant. Add pc variant. 2011-06-19 13:56:40 -04:00
Tom Rothamel 6f0c5873c2 Call slow_done even if slow is set to False. This fixes a problem with CTC not showing up after a reload. 2011-06-19 12:32:36 -04:00
Tom Rothamel b8fb05f30f Give a more informative diagnostic for a menu caption followed by a block. 2011-06-19 08:45:05 -04:00
Tom Rothamel 925b53db58 Restore the behavior of xfill on vboxes and yfill on hboxes. 2011-06-19 08:35:37 -04:00
Tom Rothamel 99c1268051 Merge in fixes for gltexture. 2011-06-18 22:48:13 -04:00
Tom Rothamel 6be247e07d Make texwrap ignore RUBY_TOP glyphs. 2011-06-18 09:50:26 -04:00
Tom Rothamel dfa423b62d More performance and correctness fixes. 2011-06-16 22:58:28 -04:00
Tom Rothamel 49b95e1a8a Fix bugs in texture performance, including an ~5ms performance loss on texture loading. 2011-06-16 21:53:11 -04:00
Tom Rothamel 03eedca87c Much faster texwrap. (But is it fast enough for asian text?) 2011-06-16 16:04:59 -04:00
Tom Rothamel 4602f8b43a More optimizations. 2011-06-16 08:52:35 -04:00
Tom Rothamel 9b77f044ab Speed up the tex layout algorithm. (But it's still slow.) 2011-06-16 01:36:47 -04:00
Tom Rothamel 7200908ea9 newtext: tex wrapping algorith,. 2011-06-15 23:52:21 -04:00
Tom Rothamel b87827f53b newtext: Use unicode line breaking algorithm. 2011-06-15 12:57:14 -04:00
Tom Rothamel 173370b905 Generate linebreak data. 2011-06-15 09:51:31 -04:00
Tom Rothamel 628703aab3 newtext: Add asian annotation support. 2011-06-14 23:30:50 -04:00
Tom Rothamel 6bd014b9a6 Implement _start, cps text tags. 2011-06-13 10:14:11 -04:00
Tom Rothamel 7feff9e690 Add more test cases; fix code so they pass. 2011-06-12 22:16:33 -04:00
Tom Rothamel af300d118a newtext: Fix antialiasing and justification. 2011-06-11 23:54:22 -04:00
Tom Rothamel 25e74c5f79 Test case for newtext properties. 2011-06-11 15:24:14 -04:00
Tom Rothamel c63d860d1f Add support for alignment and justification. 2011-06-11 12:17:23 -04:00
Tom Rothamel 32db1082c0 newtext: Implement ruby, leading, and spacing. 2011-06-11 00:44:43 -04:00
Tom Rothamel 06193b4285 newtext: Less updates. 2011-06-10 20:26:00 -04:00
Tom Rothamel 1192c546a1 newtext: Add displayable support.
newtext: Add layout_cache.
2011-06-10 07:28:21 -04:00
Tom Rothamel ec3881d5c4 newtext: Add {space} and {vspace} tags. 2011-06-09 00:44:08 -04:00
Tom Rothamel 473ae87547 newtext: Add hyperlinks, underline, and strikethrough. 2011-06-08 15:58:01 -04:00
Tom Rothamel 6112741a6b newtext: Drawing/updating hyperlinks. 2011-06-08 11:24:50 -04:00
Tom Rothamel b68e23551a newtext: Figure out hyperlink areas. 2011-06-08 00:22:02 -04:00
Tom Rothamel 817bc804a6 newtext: separate initial and later layout steps.
newtext: fix multiple fonts from face.
2011-06-07 23:55:04 -04:00
Tom Rothamel 93976e043f Add support for bold. 2011-06-07 11:34:52 -04:00
Tom Rothamel 07b48bd353 newtext: Implement italics. 2011-06-07 01:19:55 -04:00
Tom Rothamel 6923507e74 newtext: get outlines working. 2011-06-06 15:30:27 -04:00
Tom Rothamel 5e1a260546 newtext: Compute the time the next character should be shown. 2011-06-06 13:10:50 -04:00
Tom Rothamel 63e2cc802c newtext: some fixes, calling it a night. 2011-06-06 01:13:10 -04:00
Tom Rothamel c4bdd4a800 newtext: First go at typing out text. 2011-06-05 23:55:16 -04:00
Tom Rothamel 0fdca7c146 newtext: cache font glyphs. 2011-06-01 14:00:39 -04:00
Tom Rothamel 0d35f3709b newtext: Fix line breaking, display text on screen, add profiling code. 2011-06-01 13:59:39 -04:00
Tom Rothamel b1e366a31f newtext: Working with outlines, and other bug fixes. 2011-06-01 00:43:14 -04:00
Tom Rothamel 922e5c0fbb newtext: Make ftfont use the over operation. 2011-05-31 01:37:27 -04:00
Tom Rothamel 11bc000a85 newtext: checkpoint @ writing text to a file. 2011-05-30 12:33:13 -04:00
Tom Rothamel 8ab9bb0e01 newtext: western-style character annotation and line-breaking. 2011-05-29 16:49:58 -04:00
Tom Rothamel ea83307012 Create the lists of glyphs. 2011-05-28 11:14:32 -04:00
Tom Rothamel df35b3f955 newtext: working tokenizer and segmenter. 2011-05-28 00:24:43 -04:00
Tom Rothamel b9b460e549 Rearrange code in preparation for newtext. 2011-05-28 00:22:52 -04:00
Tom Rothamel 91f78bee55 ftfont: rendering text to a surface. 2011-05-22 14:34:44 -04:00
Tom Rothamel a0833f0dd7 ftfont: Set unicode encoding. 2011-05-22 00:26:48 -04:00
Tom Rothamel b9a2c8d50c ftfont: init library
ftfont: open a face from a python file-like object.
2011-05-21 22:04:24 -04:00
Tom Rothamel dafd79d55b Merge fix for GLES devices. 2011-05-16 22:57:25 -04:00
Tom Rothamel 18808fffec Fix problems on GLES devices with only two textures, or that don't
have texture crossbar support.
2011-05-16 21:23:02 -04:00
Tom Rothamel 29ea80260f Don't error out if we has_screen an empty screen. 2011-05-15 16:28:16 -04:00
Tom Rothamel a61dd71833 Don't error out if we has_screen an empty screen. 2011-05-11 14:29:44 -04:00
Tom Rothamel e1b740eeff Allow shift+R when errorhandling. 2011-05-04 21:56:31 -04:00
Tom Rothamel c99e94e24d Properly initialize and deinitialize the environ and rtt objects. 2011-05-04 18:46:21 -04:00
Tom Rothamel 7141ae8478 Properly initialize and deinitialize the environ and rtt objects,
preventing a bug that caused a white screen to show up.
2011-05-04 17:36:18 -04:00
Tom Rothamel b10df22048 Init the GL environment in set_mode, so we can detect if we can't load shaders. 2011-05-03 13:07:15 -04:00
Tom Rothamel 986a5822bc Bump versions for 6.12.2. 2011-05-02 21:14:38 -04:00
Tom Rothamel 5f0057d3f8 Use the back buffer for screenshots. (Fixes a bug on Intel GPUs - hopefully.) 2011-05-01 12:06:58 -04:00
Tom Rothamel 8b64077881 Wave dead chickens over all-black screenshots. 2011-04-30 18:15:04 -04:00
Tom Rothamel 61c7e90f86 Clarify auto-population of config.archives. 2011-04-30 12:17:00 -04:00
Tom Rothamel 9ec2752883 By default, archives are searched in reverse asciiabetical order. 2011-04-29 00:06:37 -04:00
Tom Rothamel 192fe79839 Make viewport contents visible in style inspector. 2011-04-28 21:19:02 -04:00
Tom Rothamel 51e548d481 Properly display exceptions in init code. 2011-04-26 18:53:31 -04:00
Tom Rothamel 045077e983 Update doc version automatically. 2011-04-24 19:31:27 -04:00
Tom Rothamel 334195cc8f Implement config.say_attribute_transition. 2011-04-24 18:58:05 -04:00
Tom Rothamel 1d5696e10d Fix problems with invoking old-school yes/no prompts. 2011-04-24 18:27:27 -04:00
Tom Rothamel d4139d026a Clean out the say attributes at the end of an interaction. 2011-04-24 18:17:28 -04:00
Tom Rothamel 13520a7e23 Clear the screen on errors, to prevent erroneous displayables from
causing problems.
2011-04-24 16:57:59 -04:00
Tom Rothamel 49890f230a Reset image attributes on a failed say prediction. 2011-04-24 16:48:03 -04:00
Tom Rothamel 0bb8c545f0 Update changelog. 2011-04-24 09:53:07 -04:00
Tom Rothamel f7d799ea78 Remove legacy error handling. 2011-04-24 01:21:34 -04:00
Tom Rothamel c7cadc4097 Display parse errors in Ren'Py. 2011-04-24 01:16:34 -04:00
Tom Rothamel 583b4d79af Stop distributing CHANGELOG.txt, which is obsolete. 2011-04-23 17:52:43 -04:00
Tom Rothamel d58bea4f19 Document changes to say statement. 2011-04-23 17:51:39 -04:00
Tom Rothamel bacab075d8 Document android. 2011-04-23 17:29:46 -04:00
Tom Rothamel 46b4ca65eb Document transforms and transitions in python. 2011-04-23 17:03:33 -04:00
Tom Rothamel 783fdc120a Document transitions. 2011-04-23 12:52:29 -04:00
Tom Rothamel 4cce7d9523 Document transitions. 2011-04-23 00:31:25 -04:00
Tom Rothamel 065a1736f6 Document with statement. 2011-04-22 01:06:48 -04:00
Tom Rothamel 8f5119bb10 Be conservative on get_filename_line. 2011-04-22 00:18:30 -04:00
Tom Rothamel f5a9eb90ac glReadBuffer isn't in OpenGL ES. 2011-04-18 22:21:12 -04:00
Tom Rothamel 24f553dfec Take screenshots from the front buffer, since it's what the user is
seeing. Fixes a bug where screenshots could turn up black.
2011-04-18 22:14:29 -04:00
Tom Rothamel 47be57973e Fix bug with upgrading save games containing image references. 2011-04-18 20:58:34 -04:00
Tom Rothamel 23240e634a Documentation work. 2011-04-18 20:57:50 -04:00
Tom Rothamel c13438cee9 Add displaying images page to documentation. 2011-04-18 00:38:41 -04:00
Tom Rothamel 3e3cd634a0 Ren'Py no longer attempts to adjust the system level mixer controls, which
means that it's no longer possible to raise the volume from within Ren'Py.
Controlling the system volume exhibited bugs on all three platforms, including
hard-to-predict volume changes that affect other applications.
2011-04-17 15:06:42 -04:00
Tom Rothamel 72c5974efe Credit for bug. 2011-04-17 00:20:42 -04:00
Tom Rothamel 5832498bfe Do not merge TIMEEVENT with other events. (It rarely happens, and
it can lead to problems if the other event is ignored.)
2011-04-16 23:53:51 -04:00
Tom Rothamel 965418255d Make timers participate in rollback. Opens the gates for other displayables
to have rollback state, as well.
2011-04-16 23:47:36 -04:00
Tom Rothamel 317f981657 Fix bug with automatic images. 2011-04-16 17:53:57 -04:00
Tom Rothamel 8706c55260 Use the transform size property as the initial size of a render (fixes a
regression).
2011-04-16 17:43:14 -04:00
Tom Rothamel d29326065e Eliminate spurious PyDev warnings. 2011-04-16 17:38:44 -04:00
Tom Rothamel e5cdb1346d Future-proof ast.py. 2011-04-16 16:38:10 -04:00
Tom Rothamel 9b2ff06341 Add FullRestartException to the list of control exceptions. 2011-04-16 15:38:48 -04:00
Tom Rothamel 725382a378 Implement screen variants. Suppress more warnings. 2011-04-14 23:13:54 -04:00
Tom Rothamel 61c4cac28e Update Ren'Py to work w/ Honeycomb and tablets. 2011-04-14 21:31:22 -04:00
Tom Rothamel 05a0273995 Pre-release. 2011-04-08 22:40:11 -04:00
Tom Rothamel 5c30ed7ebe Minor changes for pre-release. 2011-04-08 22:31:21 -04:00
Tom Rothamel 32f7790b1f Update the changelog. 2011-04-07 21:54:15 -04:00
Tom Rothamel 0926618ed0 Allow Preference("display", 2.0) to set the screen size. 2011-04-07 21:44:06 -04:00
Tom Rothamel e4b8b3e726 Persist window size. 2011-04-07 12:20:07 -04:00
Tom Rothamel 0615b8432e Add tooltips.
Fix docs.
2011-04-05 23:10:20 -04:00
Tom Rothamel 88ad3fc1dd Censor tracebacks a bit better. 2011-04-05 22:13:22 -04:00
Tom Rothamel 4187cdafd4 Quote filenames in the image location picker. 2011-04-05 21:47:06 -04:00
Tom Rothamel 62d4323c95 Update style inspector. 2011-04-05 00:32:55 -04:00
Tom Rothamel 57f1fb6505 Make the renderer selection use the amie style. 2011-04-04 22:16:52 -04:00
Tom Rothamel c953a71e36 Added support for debugging text overflows. 2011-04-04 00:15:51 -04:00
Tom Rothamel db7075753d Improve logging. 2011-04-03 12:06:49 -04:00
Tom Rothamel f9709a429e Redo logging. 2011-04-03 11:32:39 -04:00
Tom Rothamel 3bc64e4af3 Ignore eclipse files. 2011-04-02 23:38:15 -04:00
Tom Rothamel 49cf9af762 Fix potential uninitialized variable bug. 2011-04-02 16:13:15 -04:00
Tom Rothamel ed14a0576a Fix bug in renpy.showing. 2011-04-02 10:55:44 -04:00
Tom Rothamel ec3a4ddb5a Debounce the VIDEORESIZE event - fixes duplicate mouse problem when
maximized on Linux.
2011-04-01 22:26:20 -04:00
Tom Rothamel 097479d0b0 Actions now can have an :method:Action.unhovered method. This method is
called when an action supplied as a `hovered` parameter loses focus.

Error handling now uses tooltips.
2011-03-31 11:54:33 -04:00
Tom Rothamel a995e3f542 Allow the user to ignore exceptions. 2011-03-31 00:56:38 -04:00
Tom Rothamel a0cfb8779d Change the AST nodes to call the new next_node function as early as
possible, so error recovery becomes plausible.
2011-03-31 00:25:29 -04:00
Tom Rothamel 3b137c3e54 Error handling at init time.
game.init_phase has been replaced with renpy.context().init_phase.
2011-03-30 21:46:05 -04:00
Tom Rothamel 50cc54840f Tweak look / spelling. 2011-03-30 00:42:03 -04:00
Tom Rothamel d9799ac5bb Good-looking error handling. 2011-03-29 23:55:02 -04:00
Tom Rothamel 64bf3f1b9c Add the box_wrap style property.
Fix many (bogus) errors reported by Eclipse, and a few minor real ones.
2011-03-29 00:07:09 -04:00
Tom Rothamel b791945564 Ren'Py now attempts to elide personal information from filenames. Where
possible, filenames are reported relative to the base or Ren'Py base
directories,  rather than the root of the filesystem.
2011-03-28 00:59:11 -04:00
Tom Rothamel a8cc7abfff Normalize error reporting.
Congratulations Deb and Mike!
2011-03-26 10:20:11 -04:00
Tom Rothamel fa15618437 Added the :func:SetScreenVariable and :func:ToggleScreenVariable actions.
These allow screen-local variables to be changed.
2011-03-26 09:40:36 -04:00
Tom Rothamel 844f7ac4d2 Indentation errors are now reported on the indented line, and not the line
preceding the erroneous indentation.
2011-03-26 00:21:50 -04:00
Tom Rothamel a43426bf64 Move the hyperlink functions into a style property. 2011-03-26 00:06:44 -04:00
Tom Rothamel 7015216392 merged 2011-03-25 16:00:16 -04:00
Tom Rothamel 5cc0dbbf08 Factor error handling out into its own file, which is loaded before anything else. 2011-03-25 11:03:25 -04:00
Tom Rothamel 98acd5b0f3 Insert basic exception interception. 2011-03-25 09:41:05 -04:00
Tom Rothamel 14f24424ea Restore merges. 2011-03-31 18:47:17 -04:00
Tom Rothamel 9483a7daa5 Back out changes. Release 6.12.0f. 2011-03-31 18:46:01 -04:00
Tom Rothamel 89d93544a7 Fix bug in new prediction. 2011-03-31 17:52:10 -04:00
Tom Rothamel af3a579122 merged 2011-03-24 22:32:39 -04:00
Tom Rothamel ae769272a6 merge changes 2011-03-24 22:31:55 -04:00
Tom Rothamel 5f08daa85a Fix problems w/ newer cython caused by no-longer-necessary forward
declaration.
2011-03-24 22:27:26 -04:00
Tom Rothamel 8fdec02557 Add the new internal (amie2) style. 2011-03-22 00:59:30 -04:00
Tom Rothamel f8cef3d339 Add the new internal (amie2) style. 2011-03-22 00:59:30 -04:00
Tom Rothamel d891dd290c Merge smartshow branch. 2011-03-21 00:11:56 -04:00
Tom Rothamel 0b366f6850 Document side_image. 2011-03-21 00:07:28 -04:00
Tom Rothamel 899bf47d34 Fix lint to work with screens. 2011-03-20 23:52:59 -04:00
Tom Rothamel 888c485186 Implement the new side image code. 2011-03-20 20:31:37 -04:00
Tom Rothamel dbbabbb2dc More eclipse annotations. 2011-03-20 14:17:39 -04:00
Tom Rothamel 7a38331f8c Fix/Annotate errors and warnings produced by PyDev. 2011-03-20 12:25:56 -04:00
Tom Rothamel 0dbcb352c9 Implement say with image attributes. 2011-03-19 21:29:38 -04:00
Tom Rothamel 1ab0b43202 Refactor images; Add image attributes. 2011-03-15 00:48:14 -04:00
Tom Rothamel 106d95e795 Implement keep_running_transform. 2011-03-06 15:18:55 -05:00
Tom Rothamel cf9005e457 Early work on keep_running_transform. 2011-03-05 11:32:57 -05:00
Tom Rothamel be7fd4fa13 Refactor image-like code out of image.py. 2011-03-01 23:23:00 -05:00
Tom Rothamel b0f848b089 Add xcenter and ycenter style and transform properties. 2011-02-23 23:42:33 -05:00
Tom Rothamel 07077e89b1 Add renpy.vibrate. 2011-02-21 23:26:14 -05:00
Tom Rothamel bc2a0451db Finish bumps to 6.12.1. 2011-02-15 22:19:46 -05:00
Tom Rothamel 4e38257900 Distribute bumps the vc_version file, which is read by __init__.py to
compute the advertised version.
2011-02-15 22:13:58 -05:00
Tom Rothamel f934838a59 Tree cleanup. 2011-02-15 21:43:19 -05:00
Tom Rothamel ee0fb68d60 Licenxe fixes. Better behavior for Frames with overly-big corners. 2011-02-08 20:32:39 -05:00
Tom Rothamel 37e8fd19cd Set _last_say_window at the start of a say statement. 2011-02-07 09:54:54 -05:00
Tom Rothamel f600e6a24b Remove texture unit check. 2011-02-06 17:38:30 -05:00
Tom Rothamel ca9009f5fe Fix problems with menu prediction. Doc/screen fixes. 2011-02-06 16:09:40 -05:00
Tom Rothamel 9a299a9b38 Make chosen work. 2011-02-06 10:51:20 -05:00
Tom Rothamel 845ae6e7ba Add FileSlotName. 2011-02-06 09:48:03 -05:00
Tom Rothamel 8f706107ac 6.12.0d 2011-02-05 21:28:37 -05:00
Tom Rothamel d489199e00 Screen tweaks, doc fixes. 2011-02-05 21:06:39 -05:00
Tom Rothamel bf023dc2e3 Only select FileSave if confirm=True. 2011-02-05 20:17:00 -05:00
Tom Rothamel ac6b04b5e3 Add FilePageName. 2011-02-05 16:53:14 -05:00
Tom Rothamel a34de5d601 Predict main_menu while in splashscreen.
Better logging on image cache misses.

Minor bug/doc fixes.
2011-02-05 13:58:15 -05:00
Tom Rothamel b9900776a8 Fix choice example 2011-02-03 23:53:57 -05:00
Tom Rothamel 12a444c11f Bump version. 2011-02-03 22:14:29 -05:00
Tom Rothamel 433473e53e No predict when a movie is playing; image cache debugging; gl debugging. 2011-02-03 21:39:57 -05:00
Tom Rothamel d5f889767a Multiple changes.
* Change how chosen choices are reported to screens.
* Don't use raw pygame to report an error.
* Check in the documentation includes.
2011-02-03 00:20:03 -05:00
Tom Rothamel 9873dd487c Don't go fullscreen on Android. 2011-02-02 00:30:44 -05:00
Tom Rothamel ec8bed61f1 Add xminimum property. Rewrite compute_subrect as compute_subline, which
winds up with clearer code.
2011-02-02 00:24:48 -05:00
Tom Rothamel d76971385d Fix typos. (Thanks backansi.) 2011-01-30 21:50:36 -05:00
Tom Rothamel b87fed5541 Remove unnecessary change. 2011-01-30 20:46:41 -05:00
Tom Rothamel bd8d3dbc38 Use the 6.11.2 (hacky) frame code when using the software renderer, to
prevent visual artifacts.
2011-01-30 20:38:14 -05:00
Tom Rothamel 6022e3fa2b Fixes. 2011-01-30 19:47:49 -05:00
Tom Rothamel c5c8a6e20e Allow unicode in ATL. 2011-01-30 09:19:21 -05:00
Tom Rothamel 3306bc848a Start work on b. 2011-01-30 09:03:36 -05:00
Tom Rothamel 2911ef54e5 Fix UTF-8 code. 2011-01-30 08:35:54 -05:00
Tom Rothamel cc54d1970b Windows & Distribution fixes. 2011-01-29 18:26:49 -05:00
Tom Rothamel e6915fffd3 Ensure that we can load Matrix2Ds. 2011-01-29 12:16:36 -05:00
Tom Rothamel 964d746f6d Move yesno_prompt back to 6.11 location. 2011-01-29 10:44:33 -05:00
Tom Rothamel de6af43d74 Bump copyright year. 2011-01-29 09:27:48 -05:00
Tom Rothamel 0dc1a6e46c Android docs. 2011-01-29 00:23:53 -05:00
Tom Rothamel 4098830804 Prevent get_screenshot from returning None. 2011-01-28 00:29:48 -05:00
Tom Rothamel 304ab15b8f Doc and tutorial additions/fixes. 2011-01-28 00:26:24 -05:00
Tom Rothamel 16fa9410db Pixel opacity can't be determined in GLES mode - so don't bother trying. 2011-01-28 00:10:38 -05:00
Tom Rothamel 9ff69de20c Kill a possible INVALID_ENUM error. 2011-01-27 21:51:14 -05:00
Tom Rothamel cd50f1ee86 Document snowblossom. 2011-01-27 19:07:19 -05:00
Tom Rothamel 195f3d6130 Documentation; Particle fix; Sprite demo. 2011-01-27 18:36:10 -05:00
Tom Rothamel 89d8622f6f Typo fix in tutorial. Change how we setup modulefinder. 2011-01-27 01:58:18 -05:00
Tom Rothamel d71e054eb4 Changes to import so that we can build packages. 2011-01-27 01:17:27 -05:00
Tom Rothamel 48a648eecd A far more minimial solution. 2011-01-27 00:07:16 -05:00
Tom Rothamel 63268d079e Remove the clipper from the software renderer, as it was causing problems
with transformed scaled images.
2011-01-26 23:24:54 -05:00
Tom Rothamel 743d5ca81a Add starfield effect. 2011-01-26 16:30:44 -05:00
Tom Rothamel dffb33c8e0 Fix the demo. 2011-01-25 21:36:11 -05:00
Tom Rothamel a6ea0931dd Fix Philippines flag orientation.
Never trust mugenjohncel.
2011-01-24 23:33:36 -05:00
Tom Rothamel 17016c0eb2 Fix bugs, tweak memory usage. 2011-01-24 23:33:31 -05:00
Tom Rothamel 67c703d934 Use big textures for RTT. 2011-01-24 22:28:58 -05:00
Tom Rothamel c163d1c936 Add focus_mask to screen language. 2011-01-24 21:12:33 -05:00
Tom Rothamel e3c15a2c58 Automatically size the window on initial load. 2011-01-24 19:28:43 -05:00
Tom Rothamel dfc149f292 Use glrtt fbo to render to textures.
Fix problem w/ rtt format.
2011-01-23 23:57:49 -05:00
Tom Rothamel 627ba65b9a Partially fix distribute, fixes for android. 2011-01-22 21:02:57 -05:00
Tom Rothamel a92170d88a Various fixes required to fix the Ren'Py tutorial. 2011-01-22 13:35:26 -05:00
Tom Rothamel 503653cb5e Fix sound problem. 2011-01-22 10:55:47 -05:00
Tom Rothamel 68c277ff9a Cleanup after merging. 2011-01-21 23:13:22 -05:00
Tom Rothamel 7b171b4f9b Spacing. 2011-01-21 22:42:34 -05:00
Tom Rothamel 30956e4c58 Rewrite the code that writes bytecode.rpyb, so that it uses md5 hashes
so that we don't have to recompile the code every time Ren'Py is
upgraded. (This matters on android.)
2011-01-21 22:36:40 -05:00
Tom Rothamel 6a956aacab Ren'Py now treats filenames as if they were case-insensitive. This
means that filename mismatches on Linux should no longer be a problem.
2011-01-21 00:20:33 -05:00
Tom Rothamel 681c845e2d Fix ordering problem the meant a parent's per_interact could be called
before its children's.

Fix lp:680266.
2011-01-19 23:45:07 -05:00
Tom Rothamel 11594ef5e8 Fix problems with SnowBlossom/Particles. 2011-01-19 00:19:21 -05:00
Tom Rothamel 28f06291db sl: add spacing 2011-01-18 23:04:14 -05:00
Tom Rothamel c6937698ed Fix screen prediction, especially for menus.
Rewrote tutorial to use an imagemap-screen.
2011-01-18 21:01:21 -05:00
Tom Rothamel 15f85c8b80 Merge with mainline. 2011-01-17 23:04:27 -05:00
Tom Rothamel 7fd5695f83 More build tweaks. 2011-01-17 23:03:18 -05:00
Tom Rothamel 952880287b Change how we version the module. 2011-01-17 22:01:44 -05:00
Tom Rothamel f76c7cf25a Lower the double-click to quit time to .75 seconds, to prevent confusion. 2011-01-16 14:03:17 -05:00
Tom Rothamel 7c14b4d381 Fix bug that prevented canvas from working in GL mode. 2011-01-16 13:59:42 -05:00
Tom Rothamel c67389f0a3 Fix dbz in audio code. 2011-01-16 11:13:35 -05:00
Tom Rothamel 219994ced2 Fix problems switching from sw -> gl, in 00gltest. 2011-01-15 23:21:28 -05:00
Tom Rothamel 274f08807e Allow Ren'Py to run on ancient OpenGL implementations. 2011-01-15 21:35:03 -05:00
Tom Rothamel 7601b4d3da Ensure Ren'Py can start even when OpenGL is missing. 2011-01-15 20:13:56 -05:00
Tom Rothamel 05d14b4bfd Fix im.matrix.colorize. 2011-01-15 19:24:24 -05:00
Tom Rothamel c5b63fd1c5 Fix get_screenshot regression. 2011-01-15 19:05:58 -05:00
Tom Rothamel 0bb6a926b2 Add config.screenshot_callback. 2011-01-15 18:54:38 -05:00
Tom Rothamel 0124eacb15 Add hovered and unhovered to Bar.
Remove spritemanager sl statement.
2011-01-15 18:19:04 -05:00
Tom Rothamel 7ac06761d6 Add MouseArea/mousearea. Add spritemanager to screen language. 2011-01-15 16:59:47 -05:00
Tom Rothamel c8c6226045 Add screen prediction to say, menu, and call screen statements, and
to several Actions.
2011-01-15 13:53:58 -05:00
Tom Rothamel 507d9610c7 Implement screen variants. 2011-01-15 00:10:53 -05:00
Tom Rothamel 5f4075fc35 Add NVL screen. 2011-01-14 09:39:07 -05:00
Tom Rothamel 514571cc80 Fix problems with options and shift+R reloading. 2011-01-13 01:09:51 -05:00
Tom Rothamel 6ff34b71cf Round stencil box coordinates more accurately. 2011-01-13 01:06:09 -05:00
Tom Rothamel 37416daa53 Fixes for menu screens. 2011-01-13 00:20:23 -05:00
Tom Rothamel 6bd5401633 Make the tutorial game use screens; improve screen support as necessary. 2011-01-12 23:59:25 -05:00
Tom Rothamel ea6b9571b5 Fixed software rendering / transform for now. This required ensuring that
there is always a 2-pixel band around the border of each image, up from
the previous 1-pixel border.
2011-01-10 02:06:00 -05:00
Tom Rothamel bd7c403986 Rewrite Solid and Frame so that they use the GPU to do scaling. Frame
no longer requires its argument to be an image manipulator.
2011-01-09 22:44:14 -05:00
Tom Rothamel 99417726ce Prediction of screens. 2011-01-09 18:14:52 -05:00
Tom Rothamel 4319e542f7 Add accessor for prefixed style properties.
Add prediction for images used in windows, buttons, and bars.
2011-01-09 00:25:44 -05:00
Tom Rothamel 61d8445949 Rewrote image prediction code. 2011-01-08 23:42:13 -05:00
Tom Rothamel 743095064d Update logging. 2011-01-08 01:41:29 -05:00
Tom Rothamel efa12ab5a6 Add logging infrastructure. 2011-01-08 01:15:39 -05:00
Tom Rothamel b49b1b392c Action prediction code. 2011-01-08 00:16:16 -05:00
Tom Rothamel 09e54e9915 Doc fix. 2011-01-07 23:39:14 -05:00
Tom Rothamel 373d175f2d Make imagemap caching configurable on a per-screen basis. 2011-01-04 01:57:10 -05:00
Tom Rothamel 5f3955a04a Cache imagemap hotspots to disk. 2011-01-04 01:37:33 -05:00
Tom Rothamel 98c0e51527 Document images and image manipulators. 2011-01-01 01:03:43 -05:00
Tom Rothamel 8b3a6e8fc6 Checkin to merge docs from wrong place. 2011-01-01 00:47:13 -05:00
Tom Rothamel b2d2e8ba7e Brillantly documented im.py in the wrong place. Checking in for a merge. 2011-01-01 00:46:29 -05:00
Tom Rothamel f1efced19c merge from trunk 2010-12-29 23:54:46 -05:00
Tom Rothamel 5b09dfc80c merge from trunk 2010-12-29 23:54:22 -05:00
Tom Rothamel 39f91a4368 Doc work 2010-12-29 23:52:37 -05:00
Tom Rothamel 3b6c9bde63 Fix sprites and add documentation. 2010-12-29 00:57:54 -05:00
Tom Rothamel 1df05ea53e fix bug when computing determinant. 2010-12-29 00:34:33 -05:00
Tom Rothamel 3e9aee1c6f Documentation. 2010-12-28 00:09:13 -05:00
Tom Rothamel 5231a460da Document Drag and Drop. 2010-12-26 21:10:31 -05:00
Tom Rothamel e6b3b36df9 Tweak sphinx building to handle methods; add (some) docs to dragdrop. 2010-12-25 10:13:22 -05:00
Tom Rothamel 060d510658 Random tweaks to work better with cardgame. 2010-12-25 02:34:23 -05:00
Tom Rothamel 3b21a4aa97 Redo joining support to be a better design; add clicked, hovered, and
unhovered to drag and drop.
2010-12-24 16:19:26 -05:00
Tom Rothamel 4824b44950 Added joins to achieve reasonably working drag and drop. 2010-12-24 01:25:31 -05:00
Tom Rothamel 988a92d4a5 Drag and drop uses style prefixes. 2010-12-23 11:21:53 -05:00
Tom Rothamel 378e2e61bd Implement drag & drop callbacks. 2010-12-23 01:29:23 -05:00
Tom Rothamel eb94a7d9bb Implement drag groups. 2010-12-23 00:40:25 -05:00
Tom Rothamel fe2ba07a57 Remember drag position. 2010-12-22 01:12:57 -05:00
Tom Rothamel 2788b12eb2 Add drag to SL and UI, restrict positions to the screen. 2010-12-21 00:01:59 -05:00
Tom Rothamel 265b553b4e Initial working drag and drop code. 2010-12-20 22:39:55 -05:00
Tom Rothamel 5f800681aa Make field presentable, preventing a memory leak. 2010-12-16 21:56:50 -05:00
Tom Rothamel 890c9cf591 Delete the correct file on restart. 2010-12-16 11:29:23 -05:00
Tom Rothamel 2c356b80ed Reset clear color to black. 2010-12-15 23:20:00 -05:00
Tom Rothamel cc097ba7da Use glScissor for clipping. 2010-12-15 23:12:08 -05:00
Tom Rothamel 78401f1c4a implement config.linear_saves_page_size 2010-12-14 21:43:48 -05:00
Tom Rothamel 8802363544 implement config.linear_saves_page_size 2010-12-14 21:39:51 -05:00
Tom Rothamel 05388c3733 Setup android keymap. 2010-12-14 11:51:54 -05:00
Tom Rothamel 8f84301b39 Android fixes. 2010-12-12 16:26:05 -05:00
Tom Rothamel 774ba5d990 Merge changes from lp:renpy. 2010-12-05 16:46:21 -05:00
Tom Rothamel 6bf0cd93d1 Merge bug fixes. 2010-12-05 16:43:56 -05:00
Tom Rothamel 7f63c26348 Since OpenGL ES doesn't support ClipPlanes, don't use them. 2010-12-05 13:04:22 -05:00
Tom Rothamel bce3e6ede1 More android fixes. 2010-12-05 00:17:48 -05:00
Tom Rothamel 4f642041f9 Change how reloading a game works.
Other minor android-related fixes.
2010-12-04 00:49:02 -05:00
Tom Rothamel b990b2768c Implement fast dissolve, config.simulate_android. 2010-11-29 22:28:42 -05:00
Tom Rothamel 53b8d37d8c Android fixes. 2010-11-28 16:29:47 -05:00
Tom Rothamel db9f63c2d9 Sound on Android Ren'Py. 2010-11-23 12:00:47 -05:00
Tom Rothamel 87df4ff487 Add power management support. 2010-11-16 23:08:49 -05:00
Tom Rothamel f0fe459460 GLES Video Working. 2010-11-14 23:02:07 -05:00
Tom Rothamel f71a35751a Fix problem with texture signedness. 2010-11-08 19:39:32 -05:00
Tom Rothamel 2458d9cbb3 Starting to display using GLES. 2010-11-07 22:15:15 -05:00
Tom Rothamel 81c6d33005 Limited environment. 2010-11-06 23:54:56 -04:00
Tom Rothamel dba5c20e34 Use RGBA instead of BGRA. 2010-11-05 22:34:38 -04:00
Tom Rothamel c2eddb21e5 Android work. 2010-11-04 00:06:55 -04:00
Tom Rothamel de1d289670 Better fix. 2010-11-01 08:01:12 -04:00
Tom Rothamel 623201fd75 fix crash bugs 2010-10-31 23:18:29 -04:00
Tom Rothamel 2f900b6bc7 Bump minimum GL version to 1.3. Rewrite drawing to use array-based functions that are supported by OpenGL ES. 2010-10-31 23:10:48 -04:00
Tom Rothamel 375af0cccd 6.11.2b 2010-10-26 22:12:50 -04:00
Tom Rothamel 8ae8e887f5 Fix a bug in Frame that can cause an image to be drawn more than once
a border size is 0.
2010-10-24 18:06:36 -04:00
Tom Rothamel 201b6432c4 6.11.2a 2010-10-24 14:59:33 -04:00
Tom Rothamel fc10bbf6b6 Update themes code to support Aleema's new themes. 2010-10-23 14:14:27 -04:00
Tom Rothamel 1c82c71aea Defensively code adding an event to the queue. 2010-10-23 00:13:53 -04:00
Tom Rothamel a59abd3135 Rewrote MoveTransition to deal with changes in order more gracefully. 2010-10-22 01:15:41 -04:00
Tom Rothamel a51633b511 Fixed :lpbug:647324, where ImageDissolves are rendered as if
specified with alpha=True whether or not alpha=True was set.
2010-10-21 23:26:41 -04:00
Tom Rothamel 2b40d265f9 Search for environment.txt in the directory containing the mac .app file. 2010-10-21 22:56:54 -04:00
Tom Rothamel 734b5b02f8 Buttons now only pass key events to their children when they are
focused. This allows a screen language key statement to be used as the
child of a button, and only activate when the button is focused.
2010-10-21 22:34:44 -04:00
Tom Rothamel 4120434e5a Add four themes contributed by Aleema. 2010-10-21 20:15:49 -04:00
Tom Rothamel 6d9c4dc6d9 Preserve statement names over more changes. 2010-10-21 19:47:21 -04:00
Tom Rothamel ce94a1360a Fixed a problem that prevented AnimatedValue from functioning properly
when delay was not 1.0. Thanks to Scout for the fix.
2010-10-20 01:09:56 -04:00
Tom Rothamel 27a61f4faf Proofreading by Doomfest. 2010-10-20 00:57:07 -04:00
Tom Rothamel 36f50a482b Deallocate movie surface when a movie is not playing, to prevent the last frame of the previous movie. 2010-10-20 00:47:10 -04:00
Tom Rothamel 28d681b29b Change movie drawing so that we use swscale to convert to RGB, rather
than the SDL stuff. The SDL was broken when video resize was used.
2010-10-20 00:38:32 -04:00
Tom Rothamel ddb53bfce1 Fixed :lpbug:661983, which caused insensitive hotspots to default to
the idle, rather than ground, image when no insensitive image was
supplied.
2010-10-17 02:02:33 -04:00
Tom Rothamel 81414254f9 The maximum default physical size of the Ren'Py window is now 102
pixels smaller than the height of the screen.
2010-10-16 23:33:14 -04:00
Tom Rothamel 4af4481a17 Fixed launchpad bug 647686, a regression that prevented sounds from looping properly.
Added lpbug documentation reference.
2010-10-16 19:06:28 -04:00
Tom Rothamel 1e6e0f0800 Fix spritemanager when st=0, add destroy_all method. 2010-10-11 18:20:48 -04:00
Tom Rothamel f1cff045e1 Better handle the overloading of Return(). 2010-10-09 18:13:11 -04:00
Tom Rothamel b3b3c55473 Factor environments and RTTs out into their own files, so we don't have
to compile them for Android.
2010-10-09 13:50:34 -04:00
Tom Rothamel 7f2c6fd977 Fix software rendering. 2010-10-09 13:22:10 -04:00
Tom Rothamel 59338d3ae3 Eliminate the use of the tegl and pysdlgl modules. 2010-10-09 12:41:55 -04:00
Tom Rothamel 98a5647f97 Convert glenviron and glshader to use GL directly. 2010-10-09 11:26:41 -04:00
Tom Rothamel 5d11642776 Convert gldraw and gltexture to use GL directly. 2010-10-09 10:52:11 -04:00
Tom Rothamel 297277451f Use the TEGL infrastructure to auto-generate gl.pxd. (The result is
checked in for convenience's sake.)
2010-10-09 02:37:12 -04:00
Tom Rothamel d5ec269811 Rewrite Particles in terms of SpriteManager. 2010-10-09 00:25:58 -04:00
Tom Rothamel 02bbe29ccb Finished sprite manager.
Expose python objects in store.
2010-10-08 18:48:39 -04:00
Tom Rothamel 3844ace955 New SpriteManager. 2010-10-08 01:04:20 -04:00
Tom Rothamel 3715a03598 Checkpoint. 2010-10-06 00:25:07 -04:00
Tom Rothamel 82c695a199 make buildable 2010-10-05 23:09:11 -04:00
Tom Rothamel 09ff58a1a6 Add a gc-based to checking for memory leakes in Renders. 2010-10-05 22:58:53 -04:00
Tom Rothamel 0fbe522235 More speedup of transform_render. 2010-10-03 23:57:21 -04:00
Tom Rothamel cc38b5e5c3 Add missing files. 2010-10-03 23:09:32 -04:00
Tom Rothamel c6101f5565 More improvements. 2010-10-03 23:09:18 -04:00
Tom Rothamel f4e50ae4d8 Add config.imagereference_respects_position. When set to False, ImageReference
ignores positions in its styles - much faster.
2010-10-03 18:21:37 -04:00
Tom Rothamel 3f42edbb08 Add some types to draw_render_textures. 2010-10-03 18:04:18 -04:00
Tom Rothamel c63ff665b2 Checkpointing work. 2010-10-03 17:06:23 -04:00
Tom Rothamel 230ef6d4ca Add pxds. 2010-10-02 20:52:43 -04:00
Tom Rothamel 9d1783f4d6 Checkpoint progress. 2010-10-02 20:52:23 -04:00
Tom Rothamel 99d14d9521 Improve the speed of the render function. 2010-10-02 15:30:24 -04:00
Tom Rothamel 57ed7e692e Annotate render fields, implement mark-sweep render gc. 2010-10-02 14:40:43 -04:00
Tom Rothamel 6aaf974049 Make sure everything can build with the latest cython, and remove
cython-generated code from the tree.
2010-09-27 23:03:17 -04:00
Tom Rothamel 1fce0f5557 Add infrastructure for automatically building and loading cython
Ren'Py modules, when they change.
2010-09-27 22:38:12 -04:00
Tom Rothamel f75f0ccb14 Allow the default property to be set in the screen language. 2010-09-16 08:31:39 -04:00
Tom Rothamel 01f82aaf4c Bump version. 2010-09-15 23:37:44 -04:00
Tom Rothamel 8b294e05ad Fix problem where if you hit quit, no at the main menu, the game starts. 2010-09-15 23:34:14 -04:00
Tom Rothamel 5b2fcb85e5 Fixed character not respecting the interact argument. 2010-09-15 22:34:29 -04:00
Tom Rothamel fb1d38dc3a Enter the with mode on with None. 2010-09-14 23:18:08 -04:00
Tom Rothamel 5cc6a8d75a Ensure that empty strings render with 0 width. 2010-09-13 23:22:58 -04:00
Tom Rothamel fbe2a03933 Normalize file line endings during updates. 2010-09-13 21:04:48 -04:00
Tom Rothamel 915bccf099 Fixed problem with modes (reported with patch by Spiky Catapillar.) 2010-09-12 23:52:08 -04:00
Tom Rothamel 0943e368e7 Fix mode to work with nvl and extend. 2010-09-12 23:48:39 -04:00
Tom Rothamel d35c6e190c Fix docs. 2010-09-09 11:37:34 -04:00
Tom Rothamel 1025ad5a6a Reduce size of updates. 2010-09-09 11:23:42 -04:00
Tom Rothamel fd74541318 Check that sayer is valid. 2010-09-09 11:23:24 -04:00
Tom Rothamel 821db477ae Update default enter/leave factories to work with offsets. 2010-09-09 10:06:40 -04:00
Tom Rothamel ed66034930 Fix bug that caused atl revolution not to work. 2010-09-09 09:58:30 -04:00
Tom Rothamel a9c91378fd Another version bump. 2010-09-08 22:17:48 -04:00
Tom Rothamel 1dc58f2ed1 Add AlphaDissolve to the tutorial. 2010-09-08 09:36:56 -04:00
Tom Rothamel ae916e2a59 More updater work. 2010-09-07 22:17:31 -04:00
Tom Rothamel f3af72e67e Properly notify on update events. 2010-09-07 21:52:45 -04:00
Tom Rothamel 939c2121b7 Fixes to updater. 2010-09-07 21:41:02 -04:00
Tom Rothamel 46699bfc1e Update copyright, and bump versions. 2010-09-07 21:19:54 -04:00
Tom Rothamel 63d381d5a6 FieldValues with max_is_zero set to True now work properly. Thanks to
SleepKirby for the fix.
2010-09-07 08:13:30 -04:00
Tom Rothamel c608d18684 Update distribution building to reflect new Windows layout. 2010-09-07 00:05:11 -04:00
Tom Rothamel c31f61e7b6 Integrate updater support w/ launcher. 2010-09-06 23:45:41 -04:00
Tom Rothamel 9912c15c04 Don't consider hidden screens when assigning default focus. 2010-09-06 14:19:07 -04:00
Tom Rothamel 651653593c Make MoveTransition respect offsets. 2010-09-06 12:52:29 -04:00
Tom Rothamel 85858974b8 Add urllib to dependencies. 2010-09-05 23:48:52 -04:00
Tom Rothamel a265fbb797 Fix problem with screen language lines numbers being in error. 2010-09-05 23:26:24 -04:00
Tom Rothamel e353ea2d56 Don't crash when compiling shaders. 2010-09-05 22:54:00 -04:00
Tom Rothamel 6f91db067a Fix a bug with hotbars not working.
Fix a bug caused by an incorrect texture unit check.
2010-09-05 18:32:49 -04:00
Tom Rothamel 8ed51cc810 Add renpy.notify and Notify. 2010-09-04 17:25:59 -04:00
Tom Rothamel f256f174f9 The new :func:HideInterface action allows the interface to
temporarily be hidden, as a screen language action.
2010-09-04 15:59:30 -04:00
Tom Rothamel 49d3796378 Added the :ref:renpy.focus_coordinates function, which returns the
coordinates of the currently focused displayable, when possible.
2010-09-04 15:46:30 -04:00
Tom Rothamel bfb6a18527 The new :ref:modes system allows one to invoke callbacks when
switching from one type of interaction to another. This can be used,
for example, to automatically hide the window before transitions.
2010-09-04 12:30:21 -04:00
Tom Rothamel 2960220a74 Improvements to updater. 2010-09-03 22:52:10 -04:00
Tom Rothamel c6605f1742 Add experimental update code. 2010-09-03 18:17:48 -04:00
Tom Rothamel cebffcfee1 Imagemaps created using the screen language now only have a size equal
to that of their ground image. (Previously, they took up the entire
screen.) This change makes it easier to position an imagemap at a
different location on screen, such as the bottom.

Imagemaps now take an alpha argument. If true (the default), hotspots
are only focused if the mouse is over a non-transparent part of the
idle or hover image. If set to false, the hotspot is focused whenever
the mouse is within its boundaries.
2010-09-03 17:42:46 -04:00
Tom Rothamel 006cdb8c3b The developer menu now includes a command that will list all the files
in the game directory.
2010-09-02 01:08:18 -04:00
Tom Rothamel 374e0697bf Fix documentation generation from curried functions. 2010-09-02 00:48:57 -04:00
Tom Rothamel f988878424 Transforms no longer cause a divide by zero exception when the zoom,
xzoom, or yzoom properties are 0.
2010-09-02 00:02:46 -04:00
Tom Rothamel e59b252dce Fix problems with scaling (and especially, switching back and forth
between GL and scaled SW modes.)
2010-08-31 16:36:00 -04:00
Tom Rothamel b2747914d8 Fix hotspot so that it properly handles insensitive and selected images. 2010-08-28 18:47:15 -04:00
Tom Rothamel 41aeb625f3 Try to fix backwards compatibility problem. 2010-08-24 21:55:20 -04:00
Tom Rothamel 4cfa8aa06c Document AlphaDissolve. 2010-08-24 21:51:42 -04:00
Tom Rothamel 8cb4a4e3b9 Merge alphadissolve. 2010-08-24 21:46:58 -04:00
Tom Rothamel 9a84c9715f Use 256 as the parameter - allows alphablend to use the full 8 bits of alpha
range.
2010-08-24 21:17:52 -04:00
Tom Rothamel 38538f1d9a Add AlphaBlend. 2010-08-24 02:33:29 -04:00
Tom Rothamel 6a42b2a107 Initial implementation of AlphaDissolve transition. 2010-08-24 02:20:38 -04:00
Tom Rothamel 486790b810 merge w/ renpy 2010-08-22 16:11:15 -04:00
Tom Rothamel 0e538e2261 Remove obsolete files.
Remove symlinks in documentation.
2010-08-22 16:08:03 -04:00
Tom Rothamel 9042fcca55 Redo the windows build process, so that no symlinks are involved, and so
that dlls are no longer bundled inside renpy.code.
2010-08-22 15:53:55 -04:00
Tom Rothamel 040035adbc Allow keymap to take a list of actions. 2010-08-21 11:58:32 -04:00
Tom Rothamel d72097de18 add comment 2010-08-19 13:23:27 -04:00
Tom Rothamel d9771bdade Draw mouse cursor in right place. 2010-08-19 13:01:20 -04:00
Tom Rothamel 07ca905373 Fix the parameters for define_screen. 2010-08-19 08:48:58 -04:00
Tom Rothamel ccd0d45a67 A sub-render should inherit alpha from the parent render. 2010-08-18 19:54:59 -04:00
Tom Rothamel 15a15870e7 Start of new updater code. 2010-08-18 18:11:09 -04:00
Tom Rothamel 28108c7796 Remove launcher1. 2010-08-18 12:30:05 -04:00
Tom Rothamel 171f388120 6.11.0k 2010-08-17 21:19:01 -04:00
Tom Rothamel bc50f171db Add transition parameters to Show and Hide. 2010-08-17 01:08:10 -04:00
Tom Rothamel ea4c955f1f Modal and zorder are now expressions. Note that this changes the signature to define_screen. 2010-08-16 02:22:54 -04:00
Tom Rothamel 27524457d0 Copy a screen when keeping it around after a hide, rather than modifying the original screen. 2010-08-16 01:53:51 -04:00
Tom Rothamel 01fe67cfa9 Fix problems with screens caused by renpy.transition being given None as an argument, by making it handle that case properly, rather than simply delegating to with_none. 2010-08-15 21:46:21 -04:00
Tom Rothamel f4d493465d Fix problem with iterating over a list that's changing. 2010-08-15 19:15:32 -04:00
Tom Rothamel 33cbe44390 Only call _hide on direct children of the screen. 2010-08-15 02:53:41 -04:00
Tom Rothamel 5214f08d1a Assign ids to displayables correctly.
Remove non-transitions from screens at hide-time.x
2010-08-15 01:50:46 -04:00
Tom Rothamel 608fc986c4 Now can hide screens by name and tag. 2010-08-15 00:39:01 -04:00
Tom Rothamel 779a96f97f Things in a screen without an on hide method go away once hidden. 2010-08-15 00:32:53 -04:00
Tom Rothamel faf48246d7 Don't let a hiding displayable pass along focus. 2010-08-14 20:10:10 -04:00
Tom Rothamel 81ec2a6c35 fix modal when hiding. 2010-08-14 19:12:56 -04:00
Tom Rothamel 803423f12b Was over-aggressive in combining screen and old_transfers - split them. 2010-08-14 17:17:11 -04:00
Tom Rothamel b384ee0381 Make the gl-test strings translatable. Bump version. 2010-08-14 13:29:41 -04:00
Tom Rothamel b8862d6b24 Add support for a "Graphics Acceleration" menu, which allows the user
to choose between software and opengl rendering.
2010-08-13 00:50:48 -04:00
Tom Rothamel dbfa4ed46d Fix problem where displayables on a screen of one name could inherit transforms and state from displayables on a screen of a different name. 2010-08-13 00:38:43 -04:00
Tom Rothamel d9eb999775 Report when a grid is overfull. 2010-08-11 16:30:43 -04:00
Tom Rothamel b4a9ca3f87 Tweaks to gltest.
FilePageNext grows a max argument.

Report screen errors better.
2010-08-11 16:25:31 -04:00
Tom Rothamel d087c86d1a Set correct variable when setting default afm time. 2010-08-10 22:08:14 -04:00
Tom Rothamel 0cfc7b25a6 Remove imagemap rectangle from the image picker. 2010-08-10 00:35:50 -04:00
Tom Rothamel 8f3c9bd2ba Cycle through OpenGL logfile. 2010-08-09 23:19:55 -04:00
Tom Rothamel 91c79cdac9 sl: add default statement. 2010-08-09 21:42:49 -04:00
Tom Rothamel 20e4e110ce Add a check for calling ui.interact inside itself. 2010-08-09 18:57:12 -04:00
Tom Rothamel 870d7ffe2c Try the opengl test twice. 2010-08-09 16:29:10 -04:00
Tom Rothamel 6ff88c914d Fix use of modal in docs. 2010-08-08 22:46:59 -04:00
Tom Rothamel 2a2078517f Only don't transition when failing to go to the game menu from the main
menu.
2010-08-08 22:33:27 -04:00
Tom Rothamel c09f697293 6.11.0i 2010-08-08 20:20:20 -04:00
Tom Rothamel a9e273a13d Document modal more precisely. 2010-08-07 14:53:50 -04:00
Tom Rothamel 592665aa9a Various fixes to cause modal displayables to work better. 2010-08-07 14:43:13 -04:00
Tom Rothamel 3745788f06 Store the OpenGL-giveup value on startup, and use it on a restart. 2010-08-07 10:59:18 -04:00
Tom Rothamel 52b09d8f4c Fix problems with y aspect ratio. 2010-08-07 10:47:22 -04:00
Tom Rothamel 32f25cdcec Fix problem with lint_play_sound. 2010-08-07 09:06:41 -04:00
Tom Rothamel 6f022a9b6a 6.11.0h 2010-08-07 08:52:31 -04:00
Tom Rothamel eea6970929 (doc) Clarify that the hide event isn't called on scene or context exit. 2010-08-07 07:59:41 -04:00
Tom Rothamel 35ecfd279f Tweak when we run the hide event. 2010-08-07 07:52:49 -04:00
Tom Rothamel 1f5c610843 Better logic before picking between adv and nvl windows. 2010-08-07 00:30:52 -04:00
Tom Rothamel 05f4c52c33 Always render to an alpha texture, for dissolve/imagedissolve in sw mode. 2010-08-06 12:27:54 -04:00
Tom Rothamel 326f773e75 Constrain drawing area using glViewport. 2010-08-06 02:08:03 -04:00
Tom Rothamel 2079b518a2 F11 now toggles fullscreen. 2010-08-04 01:15:20 -04:00
Tom Rothamel 70ed15e5ac Add If function. 2010-08-04 00:59:09 -04:00
Tom Rothamel f1d7fe0c73 Rename group -> style_group. 2010-08-03 22:59:53 -04:00
Tom Rothamel 08e4b9bafc Minor optimizations in GL code. 2010-08-03 22:22:01 -04:00
Tom Rothamel 56a0212316 Fix problem with mouse, when going fullscreen. 2010-08-03 22:17:09 -04:00
Tom Rothamel 5df6506191 Take file_prefix and file_suffix into account for lint. 2010-08-02 23:36:10 -04:00
Tom Rothamel 39779be980 Fix problems with lint and call. Humanize lint output. 2010-08-02 18:22:13 -04:00
Tom Rothamel bdacdddf14 Fix crash with shift+Y and generated styles. 2010-08-02 17:59:40 -04:00
Tom Rothamel 4b32337ef3 Command the mouse to be displayed once a second. 2010-08-02 17:58:01 -04:00
Tom Rothamel 4897d5b7a9 Ensure Ren'Py starts when the GL modules can't be loaded. 2010-08-02 12:29:58 -04:00
Tom Rothamel 6daa64facd Store and restore the windows size on a shift+R reload. 2010-08-02 12:19:31 -04:00
Tom Rothamel 07651e414d Ensure we always check for yesno_prompt. 2010-08-01 21:33:29 -04:00
Tom Rothamel 7e1e76f0d8 When loading textures, load the borders with adjacent pixels, rather than
transparency. This means we no longer have to distort textures when
upscaling, which improves quality.
2010-08-01 13:47:05 -04:00
Tom Rothamel b91a5d1a16 Check in keywords file. 2010-07-31 23:19:39 -04:00
Tom Rothamel 39b0646f24 Change around some things involving clip planes to try to fix a
problem with them on the mac.

6.11.0g
2010-07-31 21:08:58 -04:00
Tom Rothamel ea6406f144 When upscaling, adjust texture coordinates so that we never go outside
the loaded texture.
2010-07-31 13:30:23 -04:00
Tom Rothamel 7ed3f3fbad Add the quickstart to the manual. 2010-07-30 13:16:50 -04:00
Tom Rothamel cacb4ac40e Allow {fast} to work in menus and all-at-once mode. 2010-07-28 23:27:52 -04:00
Tom Rothamel 9503744631 Unbranding error messages. 2010-07-28 22:45:00 -04:00
Tom Rothamel 58dfd5dbfa Document focus, and use it to ensure that menus do not have any choice highlighted by default. 2010-07-28 22:40:48 -04:00
Tom Rothamel 60d5507184 Only call unhovered when a non-default unhover occurs. 2010-07-28 22:34:39 -04:00
Tom Rothamel 5641cec146 Give a proper error when someone tries to use an empty string as a displayable. 2010-07-28 22:32:51 -04:00
Tom Rothamel dd455e3d14 Fix problems with window hide / window show and NVL-mode. 2010-07-28 21:55:16 -04:00
Tom Rothamel 6876697f74 Fixed proble with default focus and subsurface. 2010-07-25 23:15:40 -04:00
Tom Rothamel 4373cab8cf 6.11.0f 2010-07-25 20:10:01 -04:00
Tom Rothamel eeccb5833b Doc fixes, remove AutoForward as an independent action. 2010-07-25 20:07:22 -04:00
Tom Rothamel 790dad0330 Fix / document screens. 2010-07-25 19:58:48 -04:00
Tom Rothamel 078a38af5d Pass transform events through to children of Transforms. 2010-07-25 13:55:44 -04:00
Tom Rothamel 8c186d2eb1 Remove extraneous print. 2010-07-25 13:40:04 -04:00
Tom Rothamel 81b94b27e0 Display problems documentation.
Limit display to screen size.
2010-07-25 01:15:20 -04:00
Tom Rothamel 17e8616e8c Do not buffer playback of movies.
Change get_playing to return audio that's queued up to play, as well as audio that's currently playing.
2010-07-24 16:44:39 -04:00
Tom Rothamel 50b0dc3c5e Add the ability to blacklist mugen's video card. 2010-07-24 13:24:49 -04:00
Tom Rothamel 9e217e722f Introduce StoreProxy object. 2010-07-24 11:41:22 -04:00
Tom Rothamel f466b44b66 Fix problem with negative line_spacing. 2010-07-23 02:32:31 -04:00
Tom Rothamel 34e0fc7cba Always take screenshots from the main thread. 2010-07-23 01:53:39 -04:00
Tom Rothamel bb88a7bb95 Remove letterboxing when taking a screenshot. 2010-07-23 01:14:06 -04:00
Tom Rothamel 71ba444e62 6.11.0e. 2010-07-18 10:39:09 -04:00
Tom Rothamel 3e0baee463 Update documentation. 2010-07-17 22:44:53 -04:00
Tom Rothamel a0064f5511 Disable OpenGL in launcher. 2010-07-17 22:37:01 -04:00
Tom Rothamel e7ce23f377 Fix potential video race. 2010-07-17 22:35:11 -04:00
Tom Rothamel 9c6d93968c Stop defining default in terms of other transforms, to allow those
transforms to be re-defined.
2010-07-17 22:00:21 -04:00
Tom Rothamel e4b29d58f4 Include indentation in text size. 2010-07-17 17:38:44 -04:00
Tom Rothamel a48b87a0d6 Fixed a bug that could cause ATL transforms to over-compute changes,
this leading to problems when used in parallel
2010-07-17 16:17:26 -04:00
Tom Rothamel 763515a937 Add GL Performance test. 2010-07-17 14:02:00 -04:00
Tom Rothamel 46a8242e51 Make sure that lexer revert also reverts the line. 2010-07-17 12:59:18 -04:00
Tom Rothamel efa8d66d3d Make placement of developer menu more friendly. 2010-07-15 23:28:37 -04:00
Tom Rothamel b7c71bb3b8 Work better with broken fonts. 2010-07-15 22:36:05 -04:00
Tom Rothamel aca5438b5a Use shift to disable OpenGL. Add deinit to swdraw. 2010-07-15 17:15:54 -04:00
Tom Rothamel e7eb23ab5e Create layout.yesno_screen function.
Doc update.

Bump to 6.11.0d.
2010-07-14 21:47:46 -04:00
Tom Rothamel 05dd8bfcc7 Use "screen" as the screen type and mouse for screens. 2010-07-14 20:39:30 -04:00
Tom Rothamel 2c299ab079 Share code between fullscreen and displayable versions of video playback. 2010-07-14 19:00:33 -04:00
Tom Rothamel 62acff5c75 CTRL on startup aborts OpenGL mode. 2010-07-14 01:22:40 -04:00
Tom Rothamel 316d146893 Make imagedissolve use the correct texture units. 2010-07-13 22:28:41 -04:00
Tom Rothamel e69fee2108 Auto-vivification of styles.
New styles.
2010-07-13 01:09:14 -04:00
Tom Rothamel 8fe6e1cf20 Add group argument to ui functions. 2010-07-13 00:27:48 -04:00
Tom Rothamel 6fcf7dbbba Blacklist Mesa Indirect GLX renderer. 2010-07-12 21:13:32 -04:00
Tom Rothamel f55c5f0ce5 Make screen language automatically prefix unicode-containing strings with u"" - like we do for other strings. 2010-07-12 20:42:32 -04:00
Tom Rothamel aaf8369421 Deallocate textures on shutdown. 2010-07-12 20:40:41 -04:00
Tom Rothamel 8e26c7730c Finish has rename.
Fix bugs with screens.
2010-07-11 22:46:19 -04:00
Tom Rothamel 556ca0611a Add has statement. 2010-07-11 17:25:46 -04:00
Tom Rothamel e2e78c175b Tweak the parser so that it recognizes \$ as a word unto itself. 2010-07-11 15:14:44 -04:00
Tom Rothamel 7b8033e6b2 A reference loop was preventing the weakref-based way of dealing with
PyCode from working. So instead, manually control when PyCodes are
recorded.
2010-07-11 13:04:44 -04:00
Tom Rothamel d602645fee Use button_text rather than default as the default button text style. 2010-07-11 11:57:06 -04:00
Tom Rothamel f8ac9c9e83 Bump version to 6.11.0c. 2010-07-10 16:06:22 -04:00
Tom Rothamel 98c90f8ab3 Shutdown trace.
Restrict minimum window size to 256x256.

Ensure window caption and icon are set when reiniting pygame.
2010-07-10 16:03:54 -04:00
Tom Rothamel 16bb21ee62 Always have an auto-forward length of 1. 2010-07-10 13:44:00 -04:00
Tom Rothamel 46bfec93d4 Set the window caption and icon whenenver we reinit the display. 2010-07-10 13:42:38 -04:00
Tom Rothamel 00e1ecf37d Fix DBZ protection. 2010-07-10 11:45:41 -04:00
Tom Rothamel a3e7b290fb Make references to PyCode weak, so that they are not compiled if they
do not live into the final game script.
2010-07-09 01:35:40 -04:00
Tom Rothamel 27ce59963f Document ui.detached, and make it work in an init block. 2010-07-09 01:02:10 -04:00
Tom Rothamel 54e3a97447 Play test sounds on the "sound" channel. 2010-07-09 00:36:41 -04:00
Tom Rothamel f886f710b7 Make video transient.
Fix most problems with ui.textbutton.
2010-07-09 00:06:30 -04:00
Tom Rothamel a895e1dc6c Always use copy RTT.
Deinitialize pygame on shutdown, and log that deinit, so we can notice where a crash there occurs.
2010-07-08 23:22:27 -04:00
Tom Rothamel 6f24d8eebd 6.11.0b 2010-07-07 19:40:03 -04:00
Tom Rothamel 000174c2c4 Implement renpy.get_renderer_info.
Change RENPY_DRAW -> RENPY_RENDERER.
2010-07-07 14:19:53 -04:00
Tom Rothamel 192aaea186 Make a click while AFM is enabled disable AFM. 2010-07-07 14:01:20 -04:00
Tom Rothamel eb0d6b696e Adds label and ui.label. 2010-07-07 02:42:40 -04:00
Tom Rothamel 94e1b0eb56 Update gl-screen when soft mouse moves. 2010-07-07 02:05:48 -04:00
Tom Rothamel 694a1cd6d5 Ensure we always project the mouse location into virtual coordinates. 2010-07-07 01:26:40 -04:00
Tom Rothamel 0600897a26 Check the number of texture units, and give up on OpenGL if less than 4. 2010-07-06 22:32:14 -04:00
Tom Rothamel e8c52f9417 Disable texture units w/o a texture bound to them. 2010-07-06 22:19:49 -04:00
Tom Rothamel 6d86963b1d Restart the video system when switching from GL to SW rendering. 2010-07-06 21:35:40 -04:00
Tom Rothamel 01e621067a Fix spelling error. 2010-07-06 12:11:03 -04:00
Tom Rothamel cd379ef1a3 Fix aspect ratio problem. 2010-07-06 11:07:20 -04:00
Tom Rothamel 41a4fbfb4d Rewrite icon changing to use the standard PEfile library.
Fix other bugs found through testing.
2010-07-05 22:25:48 -04:00
Tom Rothamel 04db2112c3 Rewrote Character and Text so that text is only parsed once. 2010-07-04 23:40:38 -04:00
Tom Rothamel d20bfb18bc Handle syntax errors in screen language code. 2010-07-04 16:44:20 -04:00
Tom Rothamel d02d83f896 Try to ensure that runtime errors in screen language code are
reported at the right location.
2010-07-04 02:25:31 -04:00
Tom Rothamel 6b45c92a58 Rewrite screenlang.py so that it generates and compiles python code
directly.
2010-07-03 13:58:25 -04:00
Tom Rothamel 871ad8c07f Ensure the screen reflects the end of a pause before the pause finishes.
Actually limit gl framerate.
2010-06-30 01:14:13 -04:00
Tom Rothamel 997290cd28 Work on improving screen speed. 2010-06-30 00:30:20 -04:00
Tom Rothamel fcfab5ada6 spelling fix 2010-06-29 02:23:13 -04:00
Tom Rothamel 005f45bad3 Stop Popen.__del__ from throwing errors on shutdown. 2010-06-28 23:48:46 -04:00
Tom Rothamel ef64872af5 Set the projects directory to None if it no longer exists. 2010-06-27 23:15:58 -04:00
Tom Rothamel 2cd5528df9 Take the condition parameter to Characters into account when scrying to
determine if the statement interacts.
2010-06-27 22:44:45 -04:00
Tom Rothamel 0a73e6f905 Stop sounds and movies on a rollback event. 2010-06-27 22:04:46 -04:00
Tom Rothamel b9f468e3f4 Update the license.
Fix a bar regression.

Ensure that slow_done always triggers, and the ctc indicator is always shown. (Fixes lp:520276)
2010-06-27 21:01:47 -04:00
Tom Rothamel ad5631ffc1 Fix bug 595532 - wrong text in tutorial game. 2010-06-27 18:40:25 -04:00
Tom Rothamel 50767c211a Sphinx style and indexing tweaks. 2010-06-27 18:11:44 -04:00
Tom Rothamel 8223545b72 Add sphinx ATL documentation. 2010-06-27 16:55:28 -04:00
Tom Rothamel 9925fa78e7 More documentation work. 2010-06-27 12:38:48 -04:00
Tom Rothamel 7834365803 Adding various changelogs. 2010-06-27 11:16:45 -04:00
Tom Rothamel 5bfeea6e30 Finish style documentation (for now at least). 2010-06-27 10:28:09 -04:00
Tom Rothamel 1877fcfe65 Link style lists from screens. 2010-06-27 02:23:36 -04:00
Tom Rothamel 98437bc207 Adding styles documentation. 2010-06-27 02:04:56 -04:00
Tom Rothamel 49e9560e91 Rename docs a bit more.
Add dlls to distribute.py files.
2010-06-25 01:56:09 -04:00
Tom Rothamel 9c5084ef14 Move doc directory.
Add automatic keyword generation support to examples.rpy.
2010-06-25 00:32:50 -04:00
Tom Rothamel 401c503c91 Mark the newest save file as selected.
Fix a problem with buttons showing up as insensitive during a transition.
2010-06-24 23:31:36 -04:00
Tom Rothamel 73d4515f9e Fix SaveMenu. 2010-06-24 22:09:13 -04:00
Tom Rothamel 9faadbd077 Fix tutorial game ATL.
Add renpy.list_files.
2010-06-24 21:05:32 -04:00
Tom Rothamel c886f16308 Change tutorial to deal with new Transform semantics.
Change DynamicDisplayable to be sure we can always get_position.
2010-06-24 11:01:10 -04:00
Tom Rothamel 6b4b410708 Ensure that we don't fail to set a transform's pos and anchor because
we're setting it to the old default value.
2010-06-24 08:46:51 -04:00
Tom Rothamel d6e50d840f pos and anchor are now considered part of the execution state of a
transform.
2010-06-24 01:26:59 -04:00
Tom Rothamel c1848159a9 The new LiveTile displayable tiles its child, without consuming a
large amount of memory to do so.
2010-06-23 23:49:36 -04:00
Tom Rothamel 46f503ec3c Wait until the adjustment is done being created before setting the
focusable property on a bar.
2010-06-23 22:05:05 -04:00
Tom Rothamel 71f40a33f7 Add the language basics document. 2010-06-23 21:05:33 -04:00
Tom Rothamel 94e789efde More windows distribution fixes. 2010-06-23 19:02:36 -04:00
Tom Rothamel d738da4272 Update build_exe and pefile to support python 2.6. 2010-06-23 18:52:38 -04:00
Tom Rothamel 8bbf9cb618 Update modules to build on Windows.
Read the surface masks out of a surface.
2010-06-23 15:49:35 -04:00
Tom Rothamel c5276e5073 Use a screen for the tutorial game tutorials menu.
Document viewport, add XScrollValue and YScrollValue.
2010-06-21 20:34:13 -04:00
Tom Rothamel 9b0a739872 Make bar actually respect a supplied style. 2010-06-20 22:55:54 -04:00
Tom Rothamel b3e817e1d4 Make subsurfaces depend on a surface. Fixes render leak bug. 2010-06-20 21:19:25 -04:00
Tom Rothamel 96a73712eb Try fixing a bug with masks on Linux. 2010-06-20 20:51:35 -04:00
Tom Rothamel dc91721ca2 Add config to doc. 2010-06-20 20:47:10 -04:00
Tom Rothamel 7175bb664c Tweak doc look. 2010-06-20 01:00:28 -04:00
Tom Rothamel 2a49120ac2 Add special screens. 2010-06-18 00:49:57 -04:00
Tom Rothamel 4ef546649b Document python mode. 2010-06-17 22:44:28 -04:00
Tom Rothamel f1a77bd2b0 Fix bug with old load/saves and invalid files.
Fix bug with screens and rollback.
2010-06-17 14:13:05 -04:00
Tom Rothamel aa8b6d364b Moved button and bar specialness into the displayables, rather than
the ui functions.

Changed the _replaces method to be a replaces constructor parameter.

Make the periodic method take st.

Add a periodic method to BarValue.

Implement AnimatedValue.
2010-06-17 12:56:04 -04:00
Tom Rothamel 1245c6120e Wrote a lot of screen documentation. 2010-06-15 23:32:03 -04:00
Tom Rothamel 2995118cae Re-implement subsurface clipping, to improve performance in some cases.
Make call scene (and renpy.call_scene) participate in rollback, roll
forward, and set _return as appropriate.
2010-06-15 13:40:37 -04:00
Tom Rothamel a201418d1a Implement is_pixel_opaque. 2010-06-15 11:54:36 -04:00
Tom Rothamel 1b46904897 Modify yesno_prompt so it uses actions, rather than interacting.
Add FileTakeScreenshot.
2010-06-15 00:42:10 -04:00
Tom Rothamel 1cf6764a08 Allow an input screen. 2010-06-15 00:09:47 -04:00
Tom Rothamel 6527b4e198 Implement screens for NVL-mode. 2010-06-14 23:48:45 -04:00
Tom Rothamel fd4d01374f Implement the show screen, hide screen, and call screen user-statements. 2010-06-14 11:08:31 -04:00
Tom Rothamel c77a11382d Rewrite parsing in terms of a trie, for flexibility and speed reasons. 2010-06-14 09:47:37 -04:00
Tom Rothamel 1239153a1c The distribution code has been moved into launcher/distribute.py. This
file can be run from the command line to build distributions in shell
scripts and other automated processes.

Plug games.renpy.org when building distributions.

Change xoffset and yoffset in transforms so that they stack with that
of the child.
2010-06-13 22:46:28 -04:00
Tom Rothamel ae7152a5fc The renpy.music.register_channel method now has two additional
parameters, file_prefix and file_suffix. These are prepended and
appended to filenames provided to the registered channel,
respectively.
2010-06-13 21:24:02 -04:00
Tom Rothamel eec4eb73b5 Added the rotate_pad transform property, which controls how Transform
pads rotated displayables. When set to False, _not_ the default, it's
now possible to rotate a (100, 50) displayable by 90 degrees, and have
the result be (50, 100) in size.
2010-06-13 19:51:02 -04:00
Tom Rothamel 0ab3521005 The screen language (and ui) now allows you to write action rather
than clicked.
2010-06-13 17:44:13 -04:00
Tom Rothamel 660ef587c9 Add mute preferences, and SetDict/ToggleDict to support them.
Add InvertSelected.
2010-06-13 16:47:13 -04:00
Tom Rothamel 541dd7b3c3 Implement _replaced on various displayables (Text, Input, Timer, and Viewport).
Implement _ctc screen.
2010-06-13 15:19:53 -04:00
Tom Rothamel ca53e2f696 Implement the basic framework for _replaces, which is called when
one widget replaces another as part of a screen.
2010-06-13 11:54:10 -04:00
Tom Rothamel 80764e130f Make opengl logging flush the file on each write.
Make opengl fullscreen quit and reinit the video system, so that we
can properly read out the size of the desktop.
2010-06-11 22:46:55 -04:00
Tom Rothamel 6afd0120c1 Add the screenshot action. 2010-06-10 22:21:23 -04:00
Tom Rothamel 953be074f2 The config.screenshot_crop configuration variable controls the area of
the screen that it stored when the user presses the screenshot key.
2010-06-10 22:16:19 -04:00
Tom Rothamel 03781d24d6 Ensure that actions only run when they are sensitive.
Ensure we can have more than one yesno_prompt up at a time.

Add CallInNewContext.

Make the inspector show things on the screens layer.
2010-06-10 22:01:41 -04:00
Tom Rothamel 55d87064a8 config.game_menu_action allows one to specify an action that is run
when entering the game menu.
2010-06-10 20:54:35 -04:00
Tom Rothamel 512478b945 Allow the user to specify an action that is run when someone hits the
quit button. (The one in the upper-right corner of the screen.)
2010-06-10 20:45:18 -04:00
Tom Rothamel 1c19ca8062 Add yes/no prompting. 2010-06-10 09:22:47 -04:00
Tom Rothamel fc764b464d ui.add can now take transform properties as keyword arguments. If at least
one transform property is present, ui.add will create a transform that
wraps the displayable it's adding to the screen.
2010-06-09 08:56:54 -04:00
Tom Rothamel 945b4fc1cd Add python statement (short and long forms) to screen language.
Change include statement to use statement.
2010-06-09 08:32:22 -04:00
Tom Rothamel 902b17462e Implement loading and saving using Actions, and various improvements
to screens, screen language, and ui to make sure we can pull off a
sensible implementation.
2010-06-09 00:27:54 -04:00
Tom Rothamel 8b0b39829a Use renpy.context()._main_menu rather than main_menu; ensure the former is always set. 2010-06-08 01:35:04 -04:00
Tom Rothamel 356ca9cd1e Implement the Play, Queue, and Stop actions, which control music/sound/etc.
Add a periodic method to actions, which is called on a periodic basis
while a button has that action.
2010-06-08 01:04:05 -04:00
Tom Rothamel 634da84442 Implement yesno_prompt for Quit and MainMenu, make ShowMenu-shown
screens transient, and clear out the screens when we enter a new
context.
2010-06-08 00:20:17 -04:00
Tom Rothamel 1d109ddaee Implement the Preference action/value constructor. 2010-06-07 23:37:01 -04:00
Tom Rothamel c1f996da07 Various fixes required to allow a working SL preferences screen. 2010-06-07 02:08:18 -04:00
Tom Rothamel b14c9f8954 Change ShowMenu so that it takes a short screen name, without the
"_screen" suffix.
2010-06-07 00:55:19 -04:00
Tom Rothamel 126050b4f3 Able to display an operational imagemap screen based main menu.
Rewrote screens so they are now use single word names, with an
optional explicit tag parameter.
2010-06-07 00:09:54 -04:00
Tom Rothamel 313e417f28 The choice screen allows in-game menus to be defined using screens. 2010-06-05 23:32:54 -04:00
Tom Rothamel e98ef1025c Implement more Actions and BarValues.
Ensure the say screen still works.
2010-06-05 23:02:46 -04:00
Tom Rothamel 3729e4bc3a sl: Ensure execution errors are reported in a relevant location. 2010-06-05 16:16:13 -04:00
Tom Rothamel ac071777ad Implement BarValue. 2010-06-05 01:15:59 -04:00
Tom Rothamel 445972756d sl: add on statement. 2010-06-04 01:22:32 -04:00
Tom Rothamel 91732e7def sl: Implement the for statement. 2010-06-03 01:25:38 -04:00
Tom Rothamel 5b7e4af26c Add key, timer, and transform statements to ATL. 2010-05-29 23:24:55 -04:00
Tom Rothamel 2bb459cda5 screen: Implement support for transient screens. 2010-05-28 23:03:16 -04:00
Tom Rothamel d410c73074 screen: refactor screens into Screen and ScreenDisplayable classes. 2010-05-28 08:59:08 -04:00
Tom Rothamel da70f197fe screen, sl: add zorder parameter. 2010-05-27 23:03:33 -04:00
Tom Rothamel c18ffb28d0 Pass transform events to the children of a screen. Allow the screen to
respond to a hide event.
2010-05-27 21:56:02 -04:00
Tom Rothamel d5f17ef9f1 Events propagate to all children. 2010-05-25 23:42:54 -04:00
Tom Rothamel 79c3f426e5 sl: Add xmaximum and ymaximum to the list of properties we support. 2010-05-25 23:02:29 -04:00
Tom Rothamel b004dd138f Add code for customizing the say screen. 2010-05-25 22:47:58 -04:00
Tom Rothamel 45b479e324 sl: implement if statement.
screen: trigger a redraw on each interaction.
2010-05-23 22:50:22 -04:00
Tom Rothamel b07cbd4193 sl: add include statement. 2010-05-23 21:58:00 -04:00
Tom Rothamel ae2739f32d Hooked up the screen language to the screen system. 2010-05-23 20:43:37 -04:00
Tom Rothamel dd51fcb1fd Fix ui.at, get things going with visit. 2010-05-22 22:07:58 -04:00
Tom Rothamel edc26fe0a4 First working screens. 2010-05-22 19:16:08 -04:00
Tom Rothamel c9215b3b71 Add renpy.ui.remove_above, for use by screens. (Not sure I'll bother
publically documenting this.)

Improve documentation of Scene Lists.
2010-05-16 01:06:13 -04:00
Tom Rothamel 115338bdeb Basic initial implementation of screens.
Rewrote the scene lists. This added support for "replaced" images, but
more importantly, cleaned up the code quite a bit, by making it be in
terms of objects rather than tuples.
2010-05-15 20:24:28 -04:00
Tom Rothamel b0b10ac7d3 Add all existing ui functions to the screen language parser. 2010-05-11 23:42:51 -04:00
Tom Rothamel 5a6013aac9 Update changelog.
Tweak config.default_transform behavior so that it only applies to
non-transforms, so we better match the old behavior.

fix renpy.ui.Many to work with with.
2010-05-04 01:58:10 -04:00
Tom Rothamel f3aa299aa0 Remove obsolete files from the gl-renpy branch. 2010-05-04 01:30:19 -04:00
Tom Rothamel 8e44536133 Merge in changes from old mainline. 2010-05-04 01:27:59 -04:00
Tom Rothamel 0cb937298e Add checkmark background when the screen is left empty, with no background.
Fix backwards compatibility bugs.
2010-05-04 01:26:01 -04:00
Tom Rothamel 6ed0491520 Add hotbars. 2010-05-02 00:27:58 -04:00
Tom Rothamel af7748920c Add hotspots. 2010-05-01 22:55:51 -04:00
Tom Rothamel 3c1c0310d8 Merge in screen language changes. 2010-04-30 01:29:57 -04:00
Tom Rothamel 91a67304dd Rewrite the ui module in terms of wrapper code. 2010-04-30 01:28:37 -04:00
Tom Rothamel 04d0e46c3e Rewrite how things are added in renpy.ui. 2010-04-29 01:08:10 -04:00
Tom Rothamel ed27eac80b Added support for composite style properties, that allow several style
properties to be set using a single parameter. The new composite style
properties are:

* pos - takes a pair, and uses it to set xpos and ypos.
* anchor - takes a pair, and uses it to set xanchor and yanchor.
* align - takes a pair, and uses it to set xalign and yalign. (And
  hence xpos, ypos, xanchor, and yanchor.)
* area - take (x, y, height, width) pair, and tries to set properties
  such that the displayable will be placed inside the rectangle. This 
  sets the xpos, ypos, xanchor, yanchor, xfill, yfill, xminimum, yminimum,
  xmaximum, and ymaximum properties.
2010-04-28 01:19:45 -04:00
Tom Rothamel 1f3e02bbdc More SL parsing. 2010-04-28 00:31:02 -04:00
Tom Rothamel 275e938602 Snapshot of work on screen system. 2010-04-27 00:24:33 -04:00
Tom Rothamel 3f80320d37 The python compiler has been rewritten to use the python ast module.
This should both improve performance, and improve error handling for
python syntax.
2010-04-23 23:12:11 -04:00
Tom Rothamel 0e44ce7636 Update docs. 2010-04-23 22:06:24 -04:00
Tom Rothamel 8fe727a8a1 Start on sphinx documentation for build system. 2010-04-18 01:51:17 -04:00
Tom Rothamel b82f7a5548 Use default_transform as the main way of positioning images on the screen. 2010-04-17 12:15:27 -04:00
Tom Rothamel fe15242479 Allow the position properties to be specified independently when transforms are composed. 2010-04-17 00:44:06 -04:00
Tom Rothamel 677a9b0dab Transform (and ui.transform) have been changed so that their arguments
can now be prefixed with a style prefix. One can write
ui.transform(idle_rotate=30, hover_rotate=90) and have it work. [doc]
2010-04-13 23:57:37 -04:00
Tom Rothamel 309001e2fe Pick mask based on platform. Fixes a bug in ubuntu 10.4 beta. 2010-03-30 02:06:25 -04:00
Tom Rothamel 90e782c9c6 Actually put textures on the free-lists, so we can reuse them. 2010-03-23 00:03:15 -04:00
Tom Rothamel f95d9cacb5 Sleep to prevent swdraw from speeding up the CPU. 2010-03-17 11:34:44 -04:00
Tom Rothamel 308d1e6b00 Choose directory for opengl.txt. 2010-03-17 11:16:23 -04:00
Tom Rothamel c57b3004a0 Reset display after renpygame. 2010-03-17 11:12:11 -04:00
Tom Rothamel 00bd5c96e9 Shift-reload now works in GL mode. 2010-03-16 22:08:45 -04:00
Tom Rothamel 371b11370a Allow Ren'Py to keep working even if GL can't be loaded. 2010-03-16 10:13:49 -04:00
Tom Rothamel b9338a7446 Video support. 2010-03-16 01:54:05 -04:00
Tom Rothamel e39ae375f4 Refactor things so texture caching takes place in the draw modules, using
weak references.
2010-03-15 13:24:48 -04:00
Tom Rothamel 975907aebf Fixed spelling, thanks to ZeikJT. 2010-03-15 00:45:51 -04:00
Tom Rothamel ccfbdf6f3a Software mouse works in GL Ren'Py. 2010-03-15 00:42:55 -04:00
Tom Rothamel 7934d40b7c Refactor mouse code. 2010-03-15 00:21:45 -04:00
Tom Rothamel 3b569a10bd Implement screenshots. 2010-03-14 16:49:11 -04:00
Tom Rothamel 941d959ee5 Reinitialize OpenGL (except for various detection) each time the window
is resized. This allows us to work on Mac OS X, which can't share any 
OpenGL state through a window resize. (At least with SDL+Pygame.)
2010-03-13 21:20:13 -05:00
Tom Rothamel d5a51c8139 Implement pixellate in gl-mode. 2010-03-13 19:01:46 -05:00
Tom Rothamel fc79078d51 Implement RENPY_GL_VSYNC, which control OpenGL vertical sync. 2010-03-13 12:42:43 -05:00
Tom Rothamel d6615410dd Allow the user to resize the GL window by dragging (or hitting the maximize
button).
2010-03-13 12:34:30 -05:00
Tom Rothamel adee372b4b Always add a left border to images. 2010-03-13 02:06:25 -05:00
Tom Rothamel 9c7542a357 Track total texture size. 2010-03-12 01:17:21 -05:00
Tom Rothamel bc18285a61 Allow renpy_draw to pick between software and hardware rendering. 2010-03-12 00:46:53 -05:00
Tom Rothamel 7b6c3f52e0 Implement imageblend. 2010-03-12 00:30:15 -05:00
Tom Rothamel f95c6e479d Add an extra row and column of pixels to textures that aren't full, to
ensure we don't interpolate in junk during subpixel rendering.
2010-03-11 21:47:27 -05:00
Tom Rothamel e4e224348f Merge premultiplied textures. 2010-03-11 01:50:59 -05:00
Tom Rothamel 7e914da261 Initial writing of premultiplied textures. 2010-03-11 01:49:33 -05:00
Tom Rothamel ae3eb40a0e Code to read from FB to surface.
Fix shaders to handle alpha blending.
2010-03-10 22:19:48 -05:00
Tom Rothamel 2f8cd81870 Dissolve works (with copy RTT). FBO rtt is buggy. 2010-03-09 23:50:55 -05:00
Tom Rothamel a1e7b60dab Implement basic render-to-texture.
Implement non-aligned clipping.
2010-03-09 17:02:12 -05:00
Tom Rothamel 92515fca49 Implement aligned clipping. 2010-03-09 02:27:41 -05:00
Tom Rothamel 6a8abf2a79 Basic support for clipping using glClipPlane. 2010-03-09 01:24:52 -05:00
Tom Rothamel 9a47b02840 Allocate texture numbers in the GL thread. 2010-03-08 18:49:19 -05:00
Tom Rothamel 488c1c34cd Use the right direction for the transform. 2010-03-08 02:03:42 -05:00
Tom Rothamel 52bd7de14f First drawing via GL to the screen. 2010-03-08 01:36:36 -05:00
Tom Rothamel deb0f813ca Making progress towards getting gl-drawing working. 2010-03-07 18:46:00 -05:00
Tom Rothamel 5030513375 Rewrite the text handling to create textures. 2010-03-06 20:16:55 -05:00
Tom Rothamel 53deb04137 Rewrite im to use textures instead of surfaces directly.
Add support for textures (really just surfaces) to swdraw.

Move rle cache code into swdraw.
2010-02-28 23:01:58 -05:00
Tom Rothamel 2c60f5251f Rewrite RotoZoom in terms of Transform. 2010-02-26 14:47:33 -05:00
Tom Rothamel 64ac5a9317 Rewrote Zoom, FactorZoom, and SizeZoom in terms of Renders. 2010-02-26 01:33:10 -05:00
Tom Rothamel 607113b31c Move pixellate into swdraw. 2010-02-24 21:47:32 -05:00
Tom Rothamel 5a472ef44b Finished factoring out dissolve and imagedissolve. 2010-02-24 01:28:27 -05:00
Tom Rothamel c67ba9b4e4 Restructured dissolve and imagedissolve. 2010-02-24 01:04:11 -05:00
Tom Rothamel 3f36d3a881 get_parameterized -> _get_parameterized 2010-02-24 01:03:10 -05:00
Tom Rothamel d188618785 Sync with main branch. 2010-02-23 16:31:25 -05:00
Tom Rothamel e6827bdff8 * lp:526297 - im.Rotozoom()s crash when Ren'Py is scaled down. (Thanks to Spiky Caterpillar for the bug report and fix.)
Renamed the internal show and hide methods of Displayable, so those
names can once again be used by user-defined displayables.
2010-02-23 15:12:44 -05:00
Tom Rothamel 85ac26fb1e Move the drawing code from render.py to swdraw.py. Now, none of the
code in render.py should be software-renderer specific.
2010-02-23 01:52:33 -05:00
Tom Rothamel abea49df8e Massive restructuring of the display system. The methods in Display
were split between the new SWDraw class and Interface. The idea is to
separate the software renderer out from the common code.
2010-02-23 01:13:02 -05:00
Tom Rothamel bfc7de0d16 glcore -> gldraw 2010-02-22 22:05:35 -05:00
Tom Rothamel aa8c3ecec9 Move gl stuff into the display directory. 2010-02-22 22:02:11 -05:00
Tom Rothamel 7ab984972e Started work on glcore.py. 2010-02-22 21:55:57 -05:00
Tom Rothamel da09c4d04f Implement the subsurface operation. 2010-02-21 20:02:31 -05:00
Tom Rothamel c42457446f Implemented a shader-based GL environment. 2010-02-21 02:35:30 -05:00
Tom Rothamel 40bb6ca557 Can compile shaders. 2010-02-20 23:25:58 -05:00
Tom Rothamel f2cc5d25e8 Implement render-to-texture using EXT_framebuffer_object, with
acceptable performance on both Nvidia and 950.
2010-02-20 13:50:49 -05:00
Tom Rothamel 04a5460e8b Init rtt and environ in a function, so we don't have to wait for them. 2010-02-20 11:04:20 -05:00
Tom Rothamel 12ef8ee199 Refactor render-to-texture code into a class, so we can have an
alternative implementation of it.
2010-02-20 02:41:26 -05:00
Tom Rothamel 9c2d2f3a06 Implement render to texture.
Implement (GL 1.1) blank texture loading.

Add EXT_framebuffer_object to tegl.
2010-02-19 19:56:11 -05:00
Tom Rothamel 94bcfe5c58 Change to using BGRA textures for speed on Nvida chips.
Make work on the mac.
2010-02-18 10:41:22 -05:00
Tom Rothamel fecd13c733 Allow textures of various sizes, from 512 to 64 pixels. 2010-02-17 22:54:43 -05:00
Tom Rothamel a9a6595d43 Implemented fixed-function imageblend. Also, tweaked normal blend so
textures are taken in the right order.
2010-02-16 00:20:02 -05:00
Tom Rothamel e4e9ea4e87 Working blend operation. 2010-02-14 21:14:29 -05:00
Tom Rothamel 588682f0d2 Change the representation of texgrids to include a tile index, rather
than implying the tile index.

Work on environments continues.
2010-02-14 19:17:32 -05:00
Tom Rothamel 0b502d5530 C-accelerated the rectangle drawing code. 2010-02-13 23:53:27 -05:00
Tom Rothamel 86a2b5d4e5 Move the GL setup code into a module. 2010-02-13 20:05:12 -05:00
Tom Rothamel 312a657e78 Rename surface.py to gltexture.py 2010-02-11 20:00:32 -05:00
Tom Rothamel 6197597ec9 Can now draw a TextureGrid to the screen. 2010-02-11 19:35:19 -05:00
Tom Rothamel c3ee29a9b0 Work on loading textures. 2010-02-11 09:01:42 -05:00
Tom Rothamel d5b26aa973 Work on loading textures. 2010-02-11 08:58:36 -05:00
Tom Rothamel 5d926ad49b Build modules in module directory. 2010-02-10 00:38:44 -05:00
Tom Rothamel b5f133ce17 Have working direct transfer of SDL surface -> texture. 2010-02-09 00:32:01 -05:00
Tom Rothamel 6ee4474e5e Prevent completing a rollback from triggering an exception if
other code is updating objects that it uses.
2010-02-07 13:06:58 -05:00
Tom Rothamel d515d07110 Customized TEGL for our purposes. 2010-02-04 20:58:57 -05:00
Tom Rothamel 3d2e5124d4 Add a clean tegl. 2010-02-04 20:50:51 -05:00
Tom Rothamel 48a826a13d Fix bug that could cause last element of a MultipleTransition to show twice. 2010-02-04 16:53:57 -05:00
Tom Rothamel 64e82c2c62 Rewrote MultipleTransition (which is used by Fade) to fix some
problems it was exhibiting.
2010-02-04 15:43:21 -05:00
Tom Rothamel 9c5d4d7ad5 Do not query volume if a mixer is disabled, in the imagemap
preferences screen.
2010-01-26 20:42:17 -05:00
Tom Rothamel 5f006c8f4c Bump version. 2010-01-22 11:00:07 -05:00
Tom Rothamel 3d8b6cbecb Remove default_transform test code that got stuck in a release. 2010-01-22 10:56:36 -05:00
Tom Rothamel 7e2e123af7 Bump version, update changelog. 2010-01-21 18:53:32 -05:00
Tom Rothamel 14aa4c4e3d Do not display ctc when interact=False. 2010-01-21 18:04:22 -05:00
Tom Rothamel 2c15237b8a Implement renpy.config.default_transform, but don't make it the default yet. 2010-01-21 16:54:10 -05:00
Tom Rothamel b4845252c1 Bump version. 2010-01-20 13:03:58 -05:00
Tom Rothamel 2f513235b3 The launcher now accepts a RENPY_DEFAULT_PROJECTS_DIRECTORY, which sets
the default for the projects directory, if it has not already been set 
by the user. It also will report an error when creating a project fails,
rather than producing a traceback.
2010-01-20 11:16:55 -05:00
Tom Rothamel c68b3bae89 The new voice_replay function replays the voice played on the current
interaction. The new voice_can_replay function returns True if a voice
can be replayed.
2010-01-20 01:01:24 -05:00
Tom Rothamel 3825e88883 Properly purge images from the image cache. 2010-01-20 00:10:20 -05:00
Tom Rothamel bbe0fdb98f It's now possible to assign style properties to individual imagemap
buttons, by indexing style.imagemap_button. (So for example, one could 
assign to style.imagemap_button["Start Game"].hover_sound .)
2010-01-18 22:46:56 -05:00
Tom Rothamel 009969dab5 Can't pop from a tuple. 2010-01-18 03:04:02 -05:00
Tom Rothamel 376ac7ad81 Add a link to the Ren'Py Games List to the launcher. 2010-01-17 17:07:38 -05:00
Tom Rothamel de8257f459 Ren'Py now builds zip files in distributions 64k at a time. 2010-01-14 22:03:14 -05:00
Tom Rothamel 3b0fbcc55f Previously, it was impossible to pass an arguments list to a call
expression. Now, we allow the pass keyword to be used to distinguish 
the two, using code like:

call expression foo pass (bar, baz)
2010-01-14 12:48:54 -05:00
Tom Rothamel e33abc05fb Prevent infinite looping when iterating over an object with
__getitem__ defined.
2010-01-14 11:37:59 -05:00
Tom Rothamel 430ee03d45 Bump version to 6.10.2b. 2010-01-14 00:12:46 -05:00
Tom Rothamel 03477d1c75 Fix lp:506322 - MoveTransition wouldn't work on the overlay layer, even if explicitly specified. 2010-01-13 23:20:15 -05:00
Tom Rothamel ef9ee657f7 Add cache_unpin 2010-01-12 23:48:57 -05:00
1090 changed files with 169340 additions and 53337 deletions
-60
View File
@@ -1,60 +0,0 @@
build
dist
dists
renpy.app
**/*.rpyc
**/*.rpyb
**/*.rpymc
jedit
lint.txt
renpy.code
traceback.txt
doc/common.css
doc/images
doc/index.html
doc/monobook.css
doc/monobook2.css
doc/reference
doc/shared.css
doc/tutorials
doc/www.renpy.org
testing
translations.rpy
launchertrans.rpy
jcc
scite/scite.zip
screenshot*
.ropeproject
release_cardgame.sh
cardgame
dse.split
empty
empty-linux-x86.tar.bz2
empty-mac.zip
empty.zip
errors.txt
icons
iliad-icon.png
iliad-work
kuroi
lsprofcalltree.py
manifest.xml
mediatest
musicroom
nobmtest
renpy-iliad.sh
renpy.kcg
renpy.stats
renpygame-1.2.zip
speedtest
styles.txt
renpygame-demo/game/saves
./lib
Lucy Sprites.zip
translate
close_bugs.py
.logplayer
scite-6.10.zip
scite-renpy-20090803.zip
module/cython.sh
old_demo
+54
View File
@@ -0,0 +1,54 @@
*.rpyc
*.rpyb
*.rpymc
*.pyc
*.pyo
*~
*.bak
saves
tmp
cache
log.txt
/errors.txt
/traceback.txt
styles.txt
/android
/build
/dist
/dists
/renpy.app
/jedit
/lint.txt
/renpy.code
/*testing*
/screenshot*
/renpy.exe
/lib
/lib.old
/doc
/.pydevproject
/.pydevproject.bak
/.project
/.settings
/LICENSE.txt
/templates/english/README.html
/the_question/README.html
/tutorial/README.html
/renpy/angle/*.pyx
/renpy/angle/*.pxd
/renpy-ppc.zip
/module/build
/module/gen
/editra
/launcher/game/theme
/launcher/game/script_version.rpy
dl
renpy/vc_version.py
.externalToolBuilders
rapt
-4757
View File
File diff suppressed because it is too large Load Diff
-761
View File
@@ -1,761 +0,0 @@
Ren'Py itself is covered by the terms of the following (MIT) license:
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation files
(the "Software"), to deal in the Software without restriction,
including without limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of the Software,
and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Please see each individual source file for a list of copyright
holders. The artwork in the demo is released by various copyright
holders, under the same terms.
The Ren'Py module, the Ren'Py windows binaries, and the various Ren'Py
launchers may contain code taken from the following projects:
* Python (Python License)
* Pygame (LGPL)
* SDL (LGPL)
* SDL_image (LGPL)
* SDL_ttf (LGPL)
* SDL_mixer (LGPL)
* Freetype (LGPL)
* FFmpeg (LGPL)
* Fribidi (LGPL)
* jpeg (JPEG License)
* libpng (PNG license)
* zlib (Zlib License)
* bzip2 (Bzip2 License)
* pyobjc (MIT License)
The Linux build may also include code from:
* directfb (LGPL)
* svgalib (LGPL)
For the purpose of LGPL compliance, the source code to all LGPL
software we depend on is either in the Ren'Py package (available from
http://www.renpy.org/), or in the renpy-deps package
(http://www.renpy.org/dl/lgpl/). We believe compliance can be achieved
by including a copy of this license with every copy of Ren'Py you
distribute, and referring to it in your project's README file.
The default Ren'Py build distributes Ren'Py alongside jEdit, which is
licensed under the GNU GPL. The source code to jEdit is distributed as
part of the renpy-deps package (http://www.renpy.org/dl/lgpl/).
GNU Lesser General Public License
=================================
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
[This is the first released version of the Lesser GPL. It also counts
as the successor of the GNU Library Public License, version 2, hence
the version number 2.1.]
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
This license, the Lesser General Public License, applies to some
specially designated software packages--typically libraries--of the
Free Software Foundation and other authors who decide to use it. You
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations
below.
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
you have the freedom to distribute copies of free software (and charge
for this service if you wish); that you receive source code or can get
it if you want it; that you can change the software and use pieces of
it in new free programs; and that you are informed that you can do
these things.
To protect your rights, we need to make restrictions that forbid
distributors to deny you these rights or to ask you to surrender these
rights. These restrictions translate to certain responsibilities for
you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
code. If you link other code with the library, you must provide
complete object files to the recipients, so that they can relink them
with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
We protect your rights with a two-step method: (1) we copyright the
library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
To protect each distributor, we want to make it very clear that
there is no warranty for the free library. Also, if the library is
modified by someone else and passed on, the recipients should know
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
effectively restrict the users of a free program by obtaining a
restrictive license from a patent holder. Therefore, we insist that
any patent license obtained for a version of the library must be
consistent with the full freedom of use specified in this license.
Most GNU software, including some libraries, is covered by the
ordinary GNU General Public License. This license, the GNU Lesser
General Public License, applies to certain designated libraries, and
is quite different from the ordinary General Public License. We use
this license for certain libraries in order to permit linking those
libraries into non-free programs.
When a program is linked with a library, whether statically or using
a shared library, the combination of the two is legally speaking a
combined work, a derivative of the original library. The ordinary
General Public License therefore permits such linking only if the
entire combination fits its criteria of freedom. The Lesser General
Public License permits more lax criteria for linking other code with
the library.
We call this license the "Lesser" General Public License because it
does Less to protect the user's freedom than the ordinary General
Public License. It also provides other free software developers Less
of an advantage over competing non-free programs. These disadvantages
are the reason we use the ordinary General Public License for many
libraries. However, the Lesser license provides advantages in certain
special circumstances.
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it
becomes a de-facto standard. To achieve this, non-free programs must
be allowed to use the library. A more frequent case is that a free
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
In other cases, permission to use a particular library in non-free
programs enables a greater number of people to use a large body of
free software. For example, permission to use the GNU C Library in
non-free programs enables many more people to use the whole GNU
operating system, as well as its variant, the GNU/Linux operating
system.
Although the Lesser General Public License is Less protective of the
users' freedom, it does ensure that the user of a program that is
linked with the Library has the freedom and the wherewithal to run
that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library or other
program which contains a notice placed by the copyright holder or
other authorized party saying it may be distributed under the terms of
this Lesser General Public License (also called "this License").
Each licensee is addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
(which use some of those functions and data) to form executables.
The "Library", below, refers to any such software library or work
which has been distributed under these terms. A "work based on the
Library" means either the Library or any derivative work under
copyright law: that is to say, a work containing the Library or a
portion of it, either verbatim or with modifications and/or translated
straightforwardly into another language. (Hereinafter, translation is
included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control
compilation and installation of the library.
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running a program using the Library is not restricted, and output from
such a program is covered only if its contents constitute a work based
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
appropriate copyright notice and disclaimer of warranty; keep intact
all the notices that refer to this License and to the absence of any
warranty; and distribute a copy of this License along with the
Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) The modified work must itself be a software library.
b) You must cause the files modified to carry prominent notices
stating that you changed the files and the date of any change.
c) You must cause the whole of the work to be licensed at no
charge to all third parties under the terms of this License.
d) If a facility in the modified Library refers to a function or a
table of data to be supplied by an application program that uses
the facility, other than as an argument passed when the facility
is invoked, then you must make a good faith effort to ensure that,
in the event an application does not supply such function or
table, the facility still operates, and performs whatever part of
its purpose remains meaningful.
(For example, a function in a library to compute square roots has
a purpose that is entirely well-defined independent of the
application. Therefore, Subsection 2d requires that any
application-supplied function or table used by this function must
be optional: if the application does not supply it, the square
root function must still compute square roots.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Library,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Library, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote
it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Library.
In addition, mere aggregation of another work not based on the Library
with the Library (or with a work based on the Library) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do
this, you must alter all the notices that refer to this License, so
that they refer to the ordinary GNU General Public License, version 2,
instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
This option is useful when you wish to copy part of the code of
the Library into a program that is not a library.
4. You may copy and distribute the Library (or a portion or
derivative of it, under Section 2) in object code or executable form
under the terms of Sections 1 and 2 above provided that you accompany
it with the complete corresponding machine-readable source code, which
must be distributed under the terms of Sections 1 and 2 above on a
medium customarily used for software interchange.
If distribution of object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the
source code from the same place satisfies the requirement to
distribute the source code, even though third parties are not
compelled to copy the source along with the object code.
5. A program that contains no derivative of any portion of the
Library, but is designed to work with the Library by being compiled or
linked with it, is called a "work that uses the Library". Such a
work, in isolation, is not a derivative work of the Library, and
therefore falls outside the scope of this License.
However, linking a "work that uses the Library" with the Library
creates an executable that is a derivative of the Library (because it
contains portions of the Library), rather than a "work that uses the
library". The executable is therefore covered by this License.
Section 6 states terms for distribution of such executables.
When a "work that uses the Library" uses material from a header file
that is part of the Library, the object code for the work may be a
derivative work of the Library even though the source code is not.
Whether this is true is especially significant if the work can be
linked without the Library, or if the work is itself a library. The
threshold for this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data
structure layouts and accessors, and small macros and small inline
functions (ten lines or less in length), then the use of the object
file is unrestricted, regardless of whether it is legally a derivative
work. (Executables containing this object code plus portions of the
Library will still fall under Section 6.)
Otherwise, if the work is a derivative of the Library, you may
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
modification of the work for the customer's own use and reverse
engineering for debugging such modifications.
You must give prominent notice with each copy of the work that the
Library is used in it and that the Library and its use are covered by
this License. You must supply a copy of this License. If the work
during execution displays copyright notices, you must include the
copyright notice for the Library among them, as well as a reference
directing the user to the copy of this License. Also, you must do one
of these things:
a) Accompany the work with the complete corresponding
machine-readable source code for the Library including whatever
changes were used in the work (which must be distributed under
Sections 1 and 2 above); and, if the work is an executable linked
with the Library, with the complete machine-readable "work that
uses the Library", as object code and/or source code, so that the
user can modify the Library and then relink to produce a modified
executable containing the modified Library. (It is understood
that the user who changes the contents of definitions files in the
Library will not necessarily be able to recompile the application
to use the modified definitions.)
b) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (1) uses at run time a
copy of the library already present on the user's computer system,
rather than copying library functions into the executable, and (2)
will operate properly with a modified version of the library, if
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
c) Accompany the work with a written offer, valid for at least
three years, to give the same user the materials specified in
Subsection 6a, above, for a charge no more than the cost of
performing this distribution.
d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
e) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
the materials to be distributed need not include anything that is
normally distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
It may happen that this requirement contradicts the license
restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
library, provided that the separate distribution of the work based on
the Library and of the other library facilities is otherwise
permitted, and provided that you do these two things:
a) Accompany the combined library with a copy of the same work
based on the Library, uncombined with any other library
facilities. This must be distributed under the terms of the
Sections above.
b) Give prominent notice with the combined library of the fact
that part of it is a work based on the Library, and explaining
where to find the accompanying uncombined form of the same work.
8. You may not copy, modify, sublicense, link with, or distribute
the Library except as expressly provided under this License. Any
attempt otherwise to copy, modify, sublicense, link with, or
distribute the Library is void, and will automatically terminate your
rights under this License. However, parties who have received copies,
or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance.
9. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Library or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Library (or any work based on the
Library), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Library or works based on it.
10. Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties with
this License.
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Library at all. For example, if a patent
license would not permit royalty-free redistribution of the Library by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply, and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License
may add an explicit geographical distribution limitation excluding those
countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and
"any later version", you have the option of following the terms and
conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
copyrighted by the Free Software Foundation, write to the Free
Software Foundation; we sometimes make exceptions for this. Our
decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
possible use to the public, we recommend making it free software that
everyone can redistribute and change. You can do so by permitting
redistribution under these terms (or, alternatively, under the terms
of the ordinary General Public License).
To apply these terms, attach the following notices to the library.
It is safest to attach them to the start of each source file to most
effectively convey the exclusion of warranty; and each file should
have at least the "copyright" line and a pointer to where the full
notice is found.
<one line to give the library's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Also add information on how to contact you by electronic and paper mail.
You should also get your employer (if you work as a programmer) or
your school, if any, to sign a "copyright disclaimer" for the library,
if necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
library `Frob' (a library for tweaking knobs) written by James
Random Hacker.
<signature of Ty Coon>, 1 April 1990
Ty Coon, President of Vice
That's all there is to it!
Python License
==============
1. This LICENSE AGREEMENT is between the Python Software Foundation
("PSF"), and the Individual or Organization ("Licensee") accessing and
otherwise using Python 2.3 software in source or binary form and its
associated documentation.
2. Subject to the terms and conditions of this License Agreement, PSF
hereby grants Licensee a nonexclusive, royalty-free, world-wide
license to reproduce, analyze, test, perform and/or display publicly,
prepare derivative works, distribute, and otherwise use Python 2.3
alone or in any derivative version, provided, however, that PSF's
License Agreement and PSF's notice of copyright, i.e., "Copyright (c)
2001, 2002 Python Software Foundation; All Rights Reserved" are
retained in Python 2.3 alone or in any derivative version prepared by
Licensee.
3. In the event Licensee prepares a derivative work that is based on
or incorporates Python 2.3 or any part thereof, and wants to make
the derivative work available to others as provided herein, then
Licensee hereby agrees to include in any such work a brief summary of
the changes made to Python 2.3.
4. PSF is making Python 2.3 available to Licensee on an "AS IS"
basis. PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR
IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND
DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS
FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON 2.3 WILL NOT
INFRINGE ANY THIRD PARTY RIGHTS.
5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON
2.3 FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS
A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON 2.3,
OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF.
6. This License Agreement will automatically terminate upon a material
breach of its terms and conditions.
7. Nothing in this License Agreement shall be deemed to create any
relationship of agency, partnership, or joint venture between PSF and
Licensee. This License Agreement does not grant permission to use PSF
trademarks or trade name in a trademark sense to endorse or promote
products or services of Licensee, or any third party.
8. By copying, installing or otherwise using Python 2.3, Licensee
agrees to be bound by the terms and conditions of this License
Agreement.
Jpeg License
============
In plain English:
1. We don't promise that this software works. (But if you find any bugs,
please let us know!)
2. You can use this software for whatever you want. You don't have to pay us.
3. You may not pretend that you wrote this software. If you use it in a
program, you must acknowledge somewhere in your documentation that
you've used the IJG code.
In legalese:
The authors make NO WARRANTY or representation, either express or implied,
with respect to this software, its quality, accuracy, merchantability, or
fitness for a particular purpose. This software is provided "AS IS", and you,
its user, assume the entire risk as to its quality and accuracy.
This software is copyright (C) 1991-1998, Thomas G. Lane.
All Rights Reserved except as specified below.
Permission is hereby granted to use, copy, modify, and distribute this
software (or portions thereof) for any purpose, without fee, subject to these
conditions:
(1) If any part of the source code for this software is distributed, then this
README file must be included, with this copyright and no-warranty notice
unaltered; and any additions, deletions, or changes to the original files
must be clearly indicated in accompanying documentation.
(2) If only executable code is distributed, then the accompanying
documentation must state that "this software is based in part on the work of
the Independent JPEG Group".
(3) Permission for use of this software is granted only if the user accepts
full responsibility for any undesirable consequences; the authors accept
NO LIABILITY for damages of any kind.
These conditions apply to any software derived from or based on the IJG code,
not just to the unmodified library. If you use our work, you ought to
acknowledge us.
Permission is NOT granted for the use of any IJG author's name or company name
in advertising or publicity relating to this software or products derived from
it. This software may be referred to only as "the Independent JPEG Group's
software".
We specifically permit and encourage the use of this software as the basis of
commercial products, provided that all warranty or liability claims are
assumed by the product vendor.
PNG License
===========
The PNG Reference Library is supplied "AS IS". The Contributing Authors
and Group 42, Inc. disclaim all warranties, expressed or implied,
including, without limitation, the warranties of merchantability and of
fitness for any purpose. The Contributing Authors and Group 42, Inc.
assume no liability for direct, indirect, incidental, special, exemplary,
or consequential damages, which may result from the use of the PNG
Reference Library, even if advised of the possibility of such damage.
Permission is hereby granted to use, copy, modify, and distribute this
source code, or portions hereof, for any purpose, without fee, subject
to the following restrictions:
1. The origin of this source code must not be misrepresented.
2. Altered versions must be plainly marked as such and must not
be misrepresented as being the original source.
3. This Copyright notice may not be removed or altered from any
source or altered source distribution.
The Contributing Authors and Group 42, Inc. specifically permit, without
fee, and encourage the use of this source code as a component to
supporting the PNG file format in commercial products. If you use this
source code in a product, acknowledgment is not required but would be
appreciated.
Zlib License
============
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
arising from the use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it
freely, subject to the following restrictions:
1. The origin of this software must not be misrepresented; you must not
claim that you wrote the original software. If you use this software
in a product, an acknowledgment in the product documentation would be
appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not be
misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
Bzip2 License
=============
This program, "bzip2", the associated library "libbzip2", and all
documentation, are copyright (C) 1996-2005 Julian R Seward. All
rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. The origin of this software must not be misrepresented; you must
not claim that you wrote the original software. If you use this
software in a product, an acknowledgment in the product
documentation would be appreciated but is not required.
3. Altered source versions must be plainly marked as such, and must
not be misrepresented as being the original software.
4. The name of the author may not be used to endorse or promote
products derived from this software without specific prior written
permission.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+150
View File
@@ -0,0 +1,150 @@
==============================
The Ren'Py Visual Novel Engine
==============================
http://www.renpy.org
Ren'Py development takes place on the ``master`` branch, and occasionally
on feature branches.
Getting Started
===============
Ren'Py depends on a number of python modules written in Cython and C. For
changes to Ren'Py that only involve python modules, you can use the modules
found in the latest nightly build. Otherwise, you'll have to compile the
modules yourself.
The development scripts assume a POSIX-like platform. The scripts should run
on Linux or Mac OS X, and can be made to run on Windows using an environment
like Msys.
Nightly Build
-------------
Nightly builds can be downloaded from:
http://nightly.renpy.org
Note that the latest nightly build is at the bottom of the list. Once you've
unpacked the nightly, change into this repository, and run::
./after_checkout.sh <path-to-nightly>
Once this script completes, you should be able to run Ren'Py using renpy.sh,
renpy.app, or renpy.exe, as appropriate for your platform.
If the current nightly build doesn't work, please wait 24 hours for a new
build to occur. If that build still doesn't work, contact Tom (`pytom at bishoujo.us`,
or @renpytom on twitter) to find out what's wrong.
The ``doc`` symlink will dangle until documentation is built, as described
below.
Compiling the Modules
----------------------
Building the modules requires you have the many dependencies installed on
your system. On Ubuntu and Debian, these dependencies can be installed with
the command::
apt-get install python-dev python-pygame libavcodec-dev libavformat-dev \
libavresample-dev libfreetype6-dev libglew1.6-dev libsdl1.2-dev \
libsdl-image1.2-dev libfribidi-dev libswscale-dev libesd0-dev libpulse-dev
Other platforms may have an equivalent command. Otherwise, you'll need to
build `renpy-deps <https://github.com/renpy/renpy-deps>`_.
We strongly suggest installing the Ren'Py modules into a Python
virtualenv. `This page <http://dabapps.com/blog/introduction-to-pip-and-virtualenv-python/>`_
describes how to install pip and the virtualenv tool, and set up a new virtualenv.
After activating the virtualenv, install cython::
pip install -U cython
Next, set RENPY_DEPS_INSTALL To a \::-separated list of paths containing the
dependencies, and RENPY_CYTHON to the name of the cython command::
export RENPY_DEPS_INSTALL=/usr::/usr/lib/x86_64-linux-gnu/
export RENPY_CYTHON=cython
Finally, change into the `modules` directory, and run::
python setup.py install
Ren'Py will be installed into the activated virtualenv. It can then be run
using the command::
python -O renpy.py
Documentation
=============
Building
--------
Building the documentation requires Ren'Py to work. You'll either need to
link in a nightly build, or compile the modules as described above. You'll
also need the `Sphinx <http://sphinx-doc.org/>`_ documentation generator.
If you have pip working, install Sphinx using::
pip install -U sphinx
Once Sphinx is installed, change into the ``sphinx`` directory inside the
Ren'Py checkout and run::
./build.sh
Format
------
Ren'Py's documentation consists of reStructuredText files found in sphinx/source, and
generated documentation found in function docstrings scattered throughout the code. Do
not edit the files in sphinx/source/inc directly, as they will be overwritten.
Docstrings may include tags on the first few lines:
\:doc: `section` `kind`
Indicates that this functions should be documented. `section` gives
the name of the include file the function will be documented in, while
`kind` indicates the kind of object to be documented (one of ``function``,
``method`` or ``class``. If omitted, `kind` will be auto-detected.
\:name: `name`
The name of the function to be documented. Function names are usually
detected, so this is only necessary when a function has multiple aliases.
\:args: `args`
This overrides the detected argument list. It can be used if some arguments
to the function are deprecated.
For example::
def warp_speed(factor, transwarp=False):
"""
:doc: warp
:name: renpy.warp_speed
:args: (factor)
Exceeds the speed of light.
"""
renpy.engine.warp_drive.engage(factor)
Translating
===========
For best practices when it comes to translating the launcher and template
game, please read:
http://lemmasoft.renai.us/forums/viewtopic.php?p=321603#p321603
Contributing
============
For bug fixes, documentation improvements, and simple changes, just
make a pull request. For more complex changes, it might make sense
to file an issue first so we can discuss the design.
Executable
+68
View File
@@ -0,0 +1,68 @@
#!/usr/bin/env python
import argparse
import os
import subprocess
import sys
from renpy import version_tuple #@UnresolvedImport
version = ".".join(str(i) for i in version_tuple)
short_version = ".".join(str(i) for i in version_tuple[:3])
print "Version", version
ap = argparse.ArgumentParser()
ap.add_argument("--release", action="store_true")
ap.add_argument("--prerelease", action="store_true")
ap.add_argument("--experimental", action="store_true")
ap.add_argument("--no-tag", "-n", action="store_true")
args = ap.parse_args()
if args.release:
links = [ "release", "prerelease", "experimental" ]
tag = True
elif args.prerelease:
links = [ "prerelease", "experimental" ]
tag = True
elif args.experimental:
links = [ "experimental" ]
tag = False
else:
links = [ ]
tag = False
def check_dirty():
if args.no_tag:
return
if subprocess.check_call([ "git", "diff", "--quiet", "HEAD" ]):
print "Directory not checked in: {}".format(os.getcwd())
sys.exit(1)
os.chdir("/home/tom/ab/renpy")
check_dirty()
os.chdir("/home/tom/ab/renpy/android")
check_dirty()
if not args.no_tag:
subprocess.check_call([ "git", "tag", "-a", "rapt-" + version, "-m", "Tagging RAPT release." ])
os.chdir("/home/tom/ab/renpy/dl")
for i in links:
if os.path.exists(i):
os.unlink(i)
os.symlink(short_version, i)
os.chdir("/home/tom/ab/renpy")
if tag and not args.no_tag:
cmd = [ "git", "tag", "-a", version, "-m", "Ren'Py " + version ]
subprocess.check_call(cmd)
os.chdir("/home/tom/ab/website")
subprocess.check_call("./upload.sh")
-13
View File
@@ -1,13 +0,0 @@
#!/bin/sh
if [ "x$1" = "x" ]; then
echo need version
exit
fi
mkdir ~/ab/website/renpy/dl/$1
cp dists/renpy-$1-* ~/ab/website/renpy/dl/$1
cp CHANGELOG.txt ~/ab/website/renpy/dl/$1
cd ~/ab/website
./upload.sh
+15
View File
@@ -0,0 +1,15 @@
#!/bin/bash
ROOT="$(dirname $(python -c "import os;print(os.path.realpath('$0'))"))"
ln -s "$ROOT/help.html" "$ROOT/tutorial/README.html"
ln -s "$ROOT/help.html" "$ROOT/the_question/README.html"
ln -s "$ROOT/help.html" "$ROOT/templates/english/README.html"
ln -s "$ROOT/sphinx/source/license.rst" "$ROOT/LICENSE.txt"
if [ "$1" != "" ]; then
ln -s "$1/lib" "$ROOT/lib"
ln -s "$1/renpy.app" "$ROOT"
ln -s "$1/renpy.exe" "$ROOT"
fi
+10
View File
@@ -0,0 +1,10 @@
# This file sets up the normal python modules. It's used to help eclipse
# do type detection, by providing an importable version of the cython code.
from distutils.core import setup
setup(
packages=['renpy', 'renpy.gl', 'renpy.angle', 'renpy.display', 'renpy.audio', 'renpy.text', 'pysdlsound'],
package_dir={ 'pysdlsound' : 'module' },
)
-80
View File
@@ -1,80 +0,0 @@
#!/usr/bin/env python
from distutils.core import setup
import py2exe
import sys
import zipfile
import traceback
# The pythonpath on my system.
sys.path.insert(0, 'c:\\msys\\1.0\\newbuild25\\install\\bin')
sys.path.insert(0, 'c:\\msys\\1.0\\newbuild25\\install\\python')
def main():
sys.argv[1:] = [ 'py2exe', '--bundle', '2', '-a', '--dll-excludes', 'w9xpopen.exe', ]
# sys.argv[1:] = [ 'py2exe', '-a', '--dll-excludes', 'w9xpopen.exe', ]
setup(name="RenPy",
windows=[ dict(script="renpy.py",
dest_base="renpy",
icon_resources=[ (1, "newicon.ico") ],
),
],
console=[ dict(script="renpy.py", dest_base="console") ],
zipfile='renpy.code',
options={ 'py2exe' : { 'excludes' : [ 'doctest',
'pygame.macosx',
'pygame.surfarray',
'pygame.mixer',
'pygame.mixer_music',
'pygame.font',
'_ssl',
'_hashlib',
'win32con',
'win32api',
'Numeric',
'locale',
'gettext',
'os2emxpath',
'macpath',
'posixpath',
],
'optimize' : 2,
} },
)
zfold = zipfile.ZipFile("dist/renpy.code")
zfnew = zipfile.ZipFile("renpy.code", "w", zipfile.ZIP_STORED)
seen = { }
for fn in zfold.namelist():
if fn.startswith("renpy/"):
continue
if fn in seen:
continue
if fn == "SDL_mixer.dll":
continue
seen[fn] = True
zfnew.writestr(fn, zfold.read(fn))
zfold.close()
zfnew.close()
try:
main()
except:
traceback.print_exc()
print
print "Press return to quit."
raw_input()
-84
View File
@@ -1,84 +0,0 @@
1#!/usr/bin/env python
import collections
import glob
import re
import sys
import time
# A map from string to filename, line number where the string is found.
strings = collections.defaultdict(list)
def process(fn):
lineno = 0
for data in file(fn, "r"):
lineno += 1
matches = [ ]
matches += re.finditer(r'\bu\"(\\"|[^"])+\"', data)
matches += re.finditer(r"\bu\'(\\'|[^'])+\'", data)
for m in matches:
s = m.group(0)[2:-1]
if "\\u" in s:
continue
if len(s) == 1:
continue
strings[s].append("%s:%d" % (fn, lineno))
if __name__ == "__main__":
files = [ ]
files += glob.glob("launcher2/*.rpy")
files += glob.glob("common/*.rpy")
files += glob.glob("common/_layout/*.rpym")
files += glob.glob("common/_compat/*.rpym")
for fn in files:
process(fn)
converse = [ ]
for k, v in strings.iteritems():
v = " ".join(sorted(v))
converse.append((v, k))
converse.sort()
print """\
# Ren'Py Visual Novel Engine
# Copyright (C) 2009 PyTom <pytom@bishoujo.us>
# This file is distributed under the same license as the Ren'Py package.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: mainline\\n"
"Report-Msgid-Bugs-To: PyTom <pytom@bishoujo.us>\\n"
"POT-Creation-Date: %s\\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\\n"
"Language-Team: LANGUAGE <LL@li.org>\\n"
"MIME-Version: 1.0\\n"
"Content-Type: text/plain; charset=UTF-8\\n"
"Content-Transfer-Encoding: 8bit\\n"
""" % time.strftime("%Y-%m-%d %H:%M%z")
for v, k in converse:
print
print "#:", v
print "#, python-format"
print "msgid \"%s\"" % k
print "msgstr \"\""
-81
View File
@@ -1,81 +0,0 @@
#!/usr/bin/env python
import collections
import glob
import re
import sys
import time
import os
# A map from string to filename, line number where the string is found.
strings = collections.defaultdict(list)
def process(fn):
lineno = 0
for data in file(fn, "r"):
lineno += 1
matches = [ ]
matches += re.finditer(r'\bu\"(\\"|[^"])+\"', data)
matches += re.finditer(r"\bu\'(\\'|[^'])+\'", data)
for m in matches:
s = m.group(0)[2:-1]
if "\\u" in s:
continue
if len(s) == 1:
continue
strings[s].append("%s:%d" % (fn, lineno))
if __name__ == "__main__":
files = [ ]
files += glob.glob("launcher/*.rpy")
files += glob.glob("common/*.rpy")
files += glob.glob("common/*.rpym")
files += glob.glob("common/_layout/*.rpym")
files += glob.glob("common/_compat/*.rpym")
if "launcher/strings.rpy" in files:
files.remove("launcher/strings.rpy")
for fn in files:
process(fn)
converse = [ ]
for k, v in strings.iteritems():
v = " ".join(sorted(v))
converse.append((v, k))
converse.sort()
f = file("launcher/strings.rpy", "w")
files = set(i for i in os.listdir("launcher") if i.endswith(".rpy"))
print >>f, """\
init python:
LAUNCHER_RPYS = %r
TRANSLATION_STRINGS = [
""" % files
for v, k in converse:
# print
# print "#:", v
# print "#, python-format"
print >>f, " u\"%s\"," % unicode(k)
print >>f, """\
]
"""
-35
View File
@@ -1,35 +0,0 @@
# Copyright 2004-2010 PyTom <pytom@bishoujo.us>
# See LICENSE.txt for license details.
# This file contains warpers that are used by ATL. They need to be defined
# early, so Ren'Py knows about them when parsing other files.
python early hide:
# pause is defined internally, but would look like:
#
# @renpy.atl_warper
# def pause(t):
# if t >= 1.0:
# return 1.0
# else:
# return 0.0
@renpy.atl_warper
def linear(t):
return t
@renpy.atl_warper
def easeout(x):
import math
return 1.0 - math.cos(x * math.pi / 2.0)
@renpy.atl_warper
def easein(x):
import math
return math.cos((1.0 - x) * math.pi / 2.0)
@renpy.atl_warper
def ease(x):
import math
return .5 - math.cos(math.pi * x) / 2.0
-85
View File
@@ -1,85 +0,0 @@
# Copyright 2004-2010 PyTom <pytom@bishoujo.us>
# See LICENSE.txt for license details.
init -1210 python:
# This is called when script_version is set, to immediately
# run code in response to a script_version change.
def _set_script_version(version):
if version is None:
return
if version <= (5, 6, 0):
config.check_properties = False
if version <= (6, 5, 0):
layout.compat()
if version <= (6, 9, 1):
store.library = store.config
if version <= (6, 9, 3):
# Before 6.10, these were positions, rather than transforms.
store.left = Position(xalign=0.0)
store.center = Position(xalign=0.5)
store.truecenter = Position(xalign=0.5, yalign=0.5)
store.right = Position(xalign=1.0)
store.offscreenleft = Position(xpos=0.0, xanchor=1.0)
store.offscreenright = Position(xpos=1.0, xanchor=0.0)
init 1210 python hide::
# This returns true if the script_version is <= the
# script_version supplied. Give it the last script version
# where an old version was used.
def compat(x, y, z):
return config.script_version and config.script_version <= (x, y, z)
# Compat for changes to with-callback.
if compat(5, 4, 5):
if config.with_callback:
def compat_with_function(trans, paired, old=config.with_callback):
old(trans)
return trans
config.with_callback = compat_with_function
if not config.sound:
config.has_sound = False
config.has_music = False
config.has_voice = False
# Compat for SFont recoloring.
if compat(5, 1, 1):
config.recolor_sfonts = False
if compat(5, 5, 4):
config.implicit_with_none = False
# Compat for changes to button look.
if compat(5, 5, 4):
style.button.setdefault(xpos=0.5, xanchor=0.5)
style.menu_button.clear()
style.menu_button_text.clear()
if compat(5, 6, 6):
config.reject_midi = False
if compat(6, 2, 0):
config.reject_backslash = False
if compat(6, 9, 0):
style.motion.clear()
if "Fullscreen" in config.translations:
fs = _("Fullscreen")
config.translations.setdefault("Fullscreen 4:3", fs + " 4:3")
config.translations.setdefault("Fullscreen 16:9", fs + " 16:9")
config.translations.setdefault("Fullscreen 16:10", fs + " 16:10")
for i in layout.compat_funcs:
i()
-181
View File
@@ -1,181 +0,0 @@
# Copyright 2004-2010 PyTom <pytom@bishoujo.us>
# See LICENSE.txt for license details.
# This file contains a number of definitions of standard
# locations and transitions. We've moved them into the common
# directory so that it's easy for an updated version of all of these
# definitions.
init -1110:
# These are positions that can be used inside at clauses. We set
# them up here so that they can be used throughout the program.
transform left:
xpos 0.0 xanchor 0.0 ypos 1.0 yanchor 1.0
transform right:
xpos 1.0 xanchor 1.0 ypos 1.0 yanchor 1.0
transform center:
xpos 0.5 xanchor 0.5 ypos 1.0 yanchor 1.0
transform truecenter:
xpos 0.5 xanchor 0.5 ypos 0.5 yanchor 0.5
# Offscreen positions for use with the move transition. Images at
# these positions are still shown (and consume
# resources)... remember to hide the image after the transition.
transform offscreenleft:
xpos 0.0 xanchor 1.0 ypos 1.0 yanchor 1.0
transform offscreenright:
xpos 1.0 xanchor 0.0 ypos 1.0 yanchor 1.0
init -1110 python:
_define = define = object()
# Positions ##############################################################
# Transitions ############################################################
# Simple transitions.
fade = Fade(.5, 0, .5) # Fade to black and back.
dissolve = Dissolve(0.5)
pixellate = Pixellate(1.0, 5)
# Various uses of CropMove.
wiperight = CropMove(1.0, "wiperight")
wipeleft = CropMove(1.0, "wipeleft")
wipeup = CropMove(1.0, "wipeup")
wipedown = CropMove(1.0, "wipedown")
slideright = CropMove(1.0, "slideright")
slideleft = CropMove(1.0, "slideleft")
slideup = CropMove(1.0, "slideup")
slidedown = CropMove(1.0, "slidedown")
slideawayright = CropMove(1.0, "slideawayright")
slideawayleft = CropMove(1.0, "slideawayleft")
slideawayup = CropMove(1.0, "slideawayup")
slideawaydown = CropMove(1.0, "slideawaydown")
irisout = CropMove(1.0, "irisout")
irisin = CropMove(1.0, "irisin")
# Ease images around. These are basically cosine-warped moves.
def _ease_out_time_warp(x):
import math
return 1.0 - math.cos(x * math.pi / 2.0)
def _ease_in_time_warp(x):
import math
return math.cos((1.0 - x) * math.pi / 2.0)
def _ease_time_warp(x):
import math
return .5 - math.cos(math.pi * x) / 2.0
# This defines a family of move transitions.
def move_transitions(prefix, delay, time_warp=None, in_time_warp=None, out_time_warp=None, old=False, layers=[ 'master' ], **kwargs):
moves = {
"" : MoveTransition(
delay,
old=old,
layers=layers,
factory=MoveFactory(time_warp=time_warp, **kwargs)),
"inright" : MoveTransition(
delay,
old=old,
layers=layers,
factory=MoveFactory(time_warp=time_warp, **kwargs),
enter_factory=MoveIn((1.0, None, 0.0, None), time_warp=in_time_warp, **kwargs)),
"inleft" : MoveTransition(
delay,
old=old,
layers=layers,
factory=MoveFactory(time_warp=time_warp, **kwargs),
enter_factory=MoveIn((0.0, None, 1.0, None), time_warp=in_time_warp, **kwargs)),
"intop" : MoveTransition(
delay,
old=old,
layers=layers,
factory=MoveFactory(time_warp=time_warp, **kwargs),
enter_factory=MoveIn((None, 0.0, None, 1.0), time_warp=in_time_warp, **kwargs)),
"inbottom" : MoveTransition(
delay,
old=old,
layers=layers,
factory=MoveFactory(time_warp=time_warp, **kwargs),
enter_factory=MoveIn((None, 1.0, None, 0.0), time_warp=in_time_warp, **kwargs)),
"outright" : MoveTransition(
delay,
old=old,
layers=layers,
factory=MoveFactory(time_warp=time_warp, **kwargs),
leave_factory=MoveOut((1.0, None, 0.0, None), time_warp=out_time_warp, **kwargs)),
"outleft" : MoveTransition(
delay,
old=old,
layers=layers,
factory=MoveFactory(time_warp=time_warp, **kwargs),
leave_factory=MoveOut((0.0, None, 1.0, None), time_warp=out_time_warp, **kwargs)),
"outtop" : MoveTransition(
delay,
old=old,
layers=layers,
factory=MoveFactory(time_warp=time_warp, **kwargs),
leave_factory=MoveOut((None, 0.0, None, 1.0), time_warp=out_time_warp, **kwargs)),
"outbottom" : MoveTransition(
delay,
old=old,
layers=layers,
factory=MoveFactory(time_warp=time_warp, **kwargs),
leave_factory=MoveOut((None, 1.0, None, 0.0), time_warp=time_warp, **kwargs)),
}
for k, v in moves.iteritems():
setattr(store, prefix + k, v)
define.move_transitions = move_transitions
del move_transitions
define.move_transitions("move", 0.5)
define.move_transitions("ease", 0.5, _ease_time_warp, _ease_in_time_warp, _ease_out_time_warp)
# Zoom-based transitions.
zoomin = MoveTransition(0.5, enter_factory=ZoomInOut(0.01, 1.0))
zoomout = MoveTransition(0.5, leave_factory=ZoomInOut(1.0, 0.01))
zoominout = MoveTransition(0.5, enter_factory=ZoomInOut(0.01, 1.0), leave_factory=ZoomInOut(1.0, 0.01))
# These shake the screen up and down for a quarter second.
# The delay needs to be an integer multiple of the period.
vpunch = Move((0, 10), (0, -10), .10, bounce=True, repeat=True, delay=.275)
hpunch = Move((15, 0), (-15, 0), .10, bounce=True, repeat=True, delay=.275)
# These use the ImageDissolve to do some nifty effects.
blinds = ImageDissolve(im.Tile("blindstile.png"), 1.0, 8)
squares = ImageDissolve(im.Tile("squarestile.png"), 1.0, 256)
init -1110:
image black = Solid("#000")
init 1110 python:
if not hasattr(store, 'narrator'):
narrator = Character(None, kind=adv, what_style='say_thought')
if not hasattr(store, 'name_only'):
name_only = adv
if not hasattr(store, 'centered'):
centered = Character(None, what_style="centered_text", window_style="centered_window")
-832
View File
@@ -1,832 +0,0 @@
# Copyright 2004-2010 PyTom <pytom@bishoujo.us>
# See LICENSE.txt for license details.
# This file consists of renpy functions that aren't expected to be
# touched by the user too much. We reserve the _ prefix for names
# defined in the library.
init -1180 python:
# These are settings that the user can tweak to control the
# look of the main menu and the load/save/escape screens.
# basics: The version of Ren'Py this script is intended for, or
# None if it's intended for the current version.
config.script_version = None
# The minimum version of the module we work with. Don't change
# this unless you know what you're doing.
config.module_version = 6007001
# Should we warn the user if the module is missing or has a bad
# version?
config.module_warning = False
# basics: A map from a string that's displayed by the interface to
# a translated value of that string.
config.translations = { }
# Used internally to maintain compatiblity with old
# translations of strings.
config.old_names = { }
# basics: True if the skip indicator should be shown.
config.skip_indicator = True
# basics: The width of a thumbnail.
config.thumbnail_width = 66
# basics: The height of a thumbnail.
config.thumbnail_height = 50
# basics: If not None, the default value of the fullscreen
# preference when the game is first run.
config.default_fullscreen = None
# basics: If not None, the default value of the text_cps
# preference when the game is first run.
config.default_text_cps = None
# Should we automatically define images?
config.automatic_images = None
# Prefixes to strip from automatic images.
config.automatic_images_strip = [ ]
# A save to automatically load, if it exists.
config.auto_load = None
# Layers to clear when entering the menus.
config.menu_clear_layers = [ ]
# This is updated to give the user an idea of where a save is
# taking place.
save_name = ''
# Should the window be shown during transitions?
_window_during_transitions = False
def _default_with_callback(trans, paired=None):
if (_window_during_transitions and not
renpy.context_nesting_level() and
not renpy.count_displayables_in_layer('transient')):
# narrator("", interact=False)
ui.window(style=style.say_window["empty"])
ui.null()
return trans
config.with_callback = _default_with_callback
def _default_empty_window():
store.narrator("", interact=False)
config.empty_window = _default_empty_window
style.skip_indicator = Style(style.default, heavy=True, help='The skip indicator.')
style.skip_indicator.xpos = 10
style.skip_indicator.ypos = 10
# This is used to jump to a label with a transition.
def _intra_jumps_core(label, transition):
renpy.transition(getattr(config, transition))
renpy.jump(label)
_intra_jumps = renpy.curry(_intra_jumps_core)
# The function that's used to translate strings in the game menu.
def _(s):
"""
Translates s into another language or something.
"""
if s in config.translations:
return config.translations[s]
if s in config.old_names and config.old_names[s] in config.translations:
return config.translations[config.old_names[s]]
return s
# Are the windows currently hidden?
_windows_hidden = False
init -1180 python:
def toggle_skipping():
if not config.skipping:
config.skipping = "slow"
else:
config.skipping = None
if renpy.context()._menu:
renpy.jump("_noisy_return")
else:
renpy.restart_interaction()
config.help = None
def _help():
if not config.help:
return
if renpy.has_label(config.help):
renpy.call_in_new_context(config.help)
return
_preferences.fullscreen = False
try:
import webbrowser
webbrowser.open_new("file:///" + config.basedir + "/" + config.help)
except:
pass
init -1180 python hide:
# Called to make a screenshot happen.
def screenshot():
import os.path
import os
import __main__
pattern = os.environ.get("RENPY_SCREENSHOT_PATTERN", "screenshot%04d.png")
# Pick the directory to save into.
dest = config.renpy_base.rstrip("/")
# Guess if we're an OSX App.
if dest.endswith("/Contents/Resources/autorun"):
# Go up 4 directories.
dest = os.path.dirname(dest)
dest = os.path.dirname(dest)
dest = os.path.dirname(dest)
dest = os.path.dirname(dest)
# Try to pick a filename.
i = 1
while True:
fn = dest + "/" + pattern % i
if not os.path.exists(fn):
break
i += 1
try:
renpy.screenshot(fn)
except:
import traceback
traceback.print_exc()
def dump_styles():
if config.developer:
renpy.style.write_text("styles.txt")
def invoke_game_menu():
if renpy.context()._menu:
renpy.jump("_noisy_return")
else:
renpy.call_in_new_context('_game_menu')
def keymap_toggle_skipping():
if renpy.context()._menu:
return
toggle_skipping()
def fast_skip():
if config.fast_skipping or config.developer:
config.skipping = "fast"
if renpy.context()._menu:
renpy.jump("_noisy_return")
def reload_game():
if not config.developer:
return
renpy.call_in_new_context("_save_reload_game")
def launch_editor():
if not config.developer:
return
filename, line = renpy.get_filename_line()
renpy.launch_editor([ filename ], line)
# The default keymap. We might also want to put some of this into
# the launcher.
km = renpy.Keymap(
rollback = renpy.rollback,
screenshot = screenshot,
toggle_fullscreen = renpy.toggle_fullscreen,
toggle_music = renpy.toggle_music,
toggle_skip = keymap_toggle_skipping,
fast_skip = fast_skip,
game_menu = invoke_game_menu,
hide_windows = renpy.curried_call_in_new_context("_hide_windows"),
launch_editor = launch_editor,
dump_styles = dump_styles,
reload_game = reload_game,
developer = renpy.curried_call_in_new_context("_developer"),
quit = renpy.quit_event,
iconify = renpy.iconify,
help = _help,
)
config.underlay = [ km ]
def skip_indicator():
### skip_indicator default
# (text) The style and placement of the skip indicator.
if config.skip_indicator is True:
if config.skipping == "slow" and config.skip_indicator:
ui.text(_(u"Skip Mode"), style='skip_indicator')
if config.skipping == "fast" and config.skip_indicator:
ui.text(_(u"Fast Skip Mode"), style='skip_indicator')
return
if not config.skip_indicator:
return
if not config.skipping:
return
ui.add(renpy.easy.displayable(config.skip_indicator))
config.overlay_functions.append(skip_indicator)
def hyperlink_styler(target):
return style.hyperlink_text
def hyperlink_function(target):
if target.startswith("http:"):
try:
import webbrowser
webbrowser.open(target)
except:
pass
else:
renpy.call_in_new_context(target)
config.hyperlink_styler = hyperlink_styler
config.hyperlink_callback = hyperlink_function
config.extend_interjection = "{fast}"
init -1180 python:
def extend(what, interact=True):
who = _last_say_who
if who is not None:
who = eval(who)
if who is None:
who = narrator
if isinstance(who, basestring):
who = unknown.copy(who)
# This ensures extend works even with NVL mode.
who.do_extend()
what = _last_say_what + config.extend_interjection + what
renpy.exports.say(who, what, interact=interact)
store._last_say_what = what
extend.record_say = False
label _hide_windows:
if renpy.context()._menu:
return
if _windows_hidden:
return
python:
_windows_hidden = True
ui.saybehavior(dismiss=['dismiss', 'hide_windows'])
ui.interact(suppress_overlay=True, suppress_window=True)
_windows_hidden = False
return
# This code here handles check for the correct version of the Ren'Py module.
label _save_reload_game:
python hide:
renpy.take_screenshot((config.thumbnail_width, config.thumbnail_height))
ui.add(Solid((0, 0, 0, 255)))
ui.text("Saving game...",
size=32, xalign=0.5, yalign=0.5, color=(255, 255, 255, 255))
renpy.pause(0)
renpy.save("reload", "reload save game")
renpy.music.stop()
persistent._reload_save = "reload"
ui.add(Solid((0, 0, 0, 255)))
ui.text("Reloading script...",
size=32, xalign=0.5, yalign=0.5, color=(255, 255, 255, 255))
renpy.pause(0)
renpy.utter_restart()
label _load_reload_game:
if not persistent._reload_save:
return
python hide:
save = persistent._reload_save
persistent._reload_save = 0
ui.add(Solid((0, 0, 0, 255)))
ui.text("Reloading game...",
size=32, xalign=0.5, yalign=0.5, color=(255, 255, 255, 255))
ui.pausebehavior(0)
ui.interact(suppress_underlay=True, suppress_overlay=True)
renpy.load(save)
return
init -1001:
image text = renpy.ParameterizedText(style="centered_text")
# Lock the library object.
$ config.locked = True
# Implement config.default_fullscreen and config.default_text_cps.
init 1180 python:
if not persistent._set_preferences:
persistent._set_preferences = True
if config.default_fullscreen is not None:
_preferences.fullscreen = config.default_fullscreen
if config.default_text_cps is not None:
_preferences.text_cps = config.default_text_cps
if config.developer:
def _inspector(l):
ui.add("#000")
ui.window(xmargin=20, ymargin=20, style='default')
ui.vbox()
ui.text("Style Inspector")
ui.text("")
if not l:
ui.text("Nothing to inspect.")
for depth, width, height, d in l:
s = d.style
while s:
if s.name:
break
if s.parent:
s = style.get(s.parent)
else:
break
name = s.name[0] + "".join([ "[%r]" % i for i in s.name[1:] ])
ui.text(" " * depth + u" \u2022 " + d.__class__.__name__ + " : " + name + " (%dx%d)" % (width, height))
ui.text("")
ui.text("(click to continue)")
ui.close()
ui.saybehavior()
ui.interact(suppress_overlay=True, suppress_underlay=True)
return
config.inspector = _inspector
##############################################################################
# Code that originated in 00gamemenu.rpy
init -1180 python:
######################################################################
# First up, we define a bunch of configuration variable, which the
# user can change.
# menus: Music to play when entering the game menu.
config.game_menu_music = None
# menus: Sound played when entering the library without clicking a
# button.
config.enter_sound = None
# menus: Sound played when leaving the library without clicking a
# button.
config.exit_sound = None
# menus: Transition that occurs when entering the game menu.
config.enter_transition = None
# menus: Transition that occurs when leaving the game menu.
config.exit_transition = None
# menus: Transition that's used when going from one screen to another.
config.intra_transition = None
# menus: Transition that's used when going from the main to the game
# menu.
config.main_game_transition = None
# menus: Transition that's used when going from the game to the main
# menu.
config.game_main_transition = None
# menus: Transition that's used at the end of the game, when returning
# to the main menu.
config.end_game_transition = None
# menus: Transition that's used at the end of the splash screen, when
# it is shown.
config.end_splash_transition = None
# Transition that's used after the game is loaded.
config.after_load_transition = None
# basics: True if autosave should be used.
config.has_autosave = True
# basics: True if quicksave has been enabled.
config.has_quicksave = False
# A list of layers to clear when entering the main and game menus.
config.clear_layers = [ ]
# The _window_subtitle used inside menus.
config.menu_window_subtitle = ''
# The screen that we go to when entering the game menu.
_game_menu_screen = None
style.error_root = Style(style.default)
style.error_title = Style(style.default)
style.error_body = Style(style.default)
def _show_exception(title, message):
ui.window(style='error_root')
ui.vbox()
ui.text(title, style='error_title')
ui.text("")
ui.text(message, style='error_body')
ui.text("")
ui.text(_(u"Please click to continue."), style='error_body')
ui.close()
ui.saybehavior()
ui.interact()
# Run at the end of init, to set up autosaving based on the user's
# choices.
init 1180 python:
if config.has_autosave:
config.autosave_slots = 10
else:
config.autosave_frequency = None
label _enter_menu:
python hide:
renpy.movie_stop(only_fullscreen=True)
renpy.take_screenshot((config.thumbnail_width, config.thumbnail_height))
for i in config.menu_clear_layers:
renpy.scene(layer=i)
renpy.context()._menu = True
# This may be changed, if we are already in the main menu.
renpy.context().main_menu = False
renpy.context_dynamic("main_menu")
renpy.context_dynamic("_window_subtitle")
renpy.context_dynamic("_window")
store.main_menu = False
store._window_subtitle = config.menu_window_subtitle
store._window = False
store.mouse_visible = True
store.suppress_overlay = True
ui.clear()
for i in config.clear_layers:
renpy.scene(layer=i)
return
# Factored this all into one place, to make our lives a bit easier.
label _enter_game_menu:
call _enter_menu from _call__enter_menu_2
$ renpy.transition(config.enter_transition)
if renpy.has_label("enter_game_menu"):
call expression "enter_game_menu" from _call_enter_game_menu_1
if config.game_menu_music:
$ renpy.music.play(config.game_menu_music, if_changed=True)
return
# Entry points from the game into menu-space.
label _game_menu(_game_menu_screen=_game_menu_screen):
if not _game_menu_screen:
return
$ renpy.play(config.enter_sound)
call _enter_game_menu from _call__enter_game_menu_0
if renpy.has_label("game_menu"):
jump expression "game_menu"
jump expression _game_menu_screen
label _game_menu_save:
call _enter_game_menu from _call__enter_game_menu_1
if renpy.has_label("_save_screen"):
jump expression "_save_screen"
else:
jump expression "save_screen"
label _game_menu_load:
call _enter_game_menu from _call__enter_game_menu_2
if renpy.has_label("_load_screen"):
jump expression "_load_screen"
else:
jump expression "load_screen"
label _game_menu_preferences:
call _enter_game_menu from _call__enter_game_menu_3
if renpy.has_label("_prefs_screen"):
jump expression "_prefs_screen"
else:
jump expression "preferences_screen"
label _quit:
$ renpy.quit()
label _return_skipping:
$ config.skipping = "slow"
jump _return
# Make some noise, then return.
label _noisy_return:
$ renpy.play(config.exit_sound)
# Return to the game.
label _return:
if renpy.context().main_menu:
$ renpy.transition(config.game_main_transition)
jump _main_menu_screen
$ renpy.transition(config.exit_transition)
return
label _confirm_quit:
call _enter_menu from _call__enter_menu_3
if renpy.has_label("confirm_quit"):
jump expression "confirm_quit"
elif renpy.has_label("_compat_confirm_quit"):
jump expression "_compat_confirm_quit"
else:
jump expression "_quit_prompt"
##############################################################################
# Code that originated in 00mainmenu.rpy
init -1180 python hide:
# menus: Music to play at the main menu.
config.main_menu_music = None
# advanced: Callbacks to run at start.
config.start_callbacks = [ ]
# This fixes up the context, if necessary, then calls the real
# after_load.
label _after_load:
$ renpy.context()._menu = False
if config.after_load_transition:
$ renpy.transition(config.after_load_transition, force=True)
if renpy.has_label("after_load"):
jump expression "after_load"
else:
return
# This is the true starting point of the program. Sssh... Don't
# tell anyone.
label _start:
python hide:
renpy.context()._menu = False
for i in config.start_callbacks:
i()
call _load_reload_game from _call__load_reload_game_1
if not _restart and config.auto_load and renpy.can_load(config.auto_load):
$ renpy.load(config.auto_load)
scene black
if not _restart:
$ ui.pausebehavior(0)
$ ui.interact(suppress_underlay=True, suppress_overlay=True)
$ renpy.block_rollback()
$ _old_game_menu_screen = _game_menu_screen
$ _game_menu_screen = None
if renpy.has_label("splashscreen") and not _restart:
call expression "splashscreen" from _call_splashscreen_1
$ _game_menu_screen = _old_game_menu_screen
$ del _old_game_menu_screen
$ renpy.block_rollback()
if config.main_menu_music:
$ renpy.music.play(config.main_menu_music, if_changed=True)
else:
$ renpy.music.stop()
# Clean out any residual scene from the splashscreen.
scene black
# This has to be python, to deal with a case where _restart may
# change across a shift-reload.
python:
if _restart is None:
renpy.transition(config.end_splash_transition)
else:
renpy.transition(_restart[0])
renpy.jump(_restart[1])
label _invoke_main_menu:
# Again, this has to be python.
python:
if _restart:
renpy.call_in_new_context(_restart[2])
else:
renpy.call_in_new_context("_main_menu")
# If the main menu returns, then start the game.
jump start
# At this point, we've been switched into a new context. So we
# initialize it.
label _main_menu(_main_menu_screen="_main_menu_screen"):
call _enter_menu from _call__enter_menu_1
python:
renpy.dynamic("_load_prompt")
_load_prompt = False
renpy.context().main_menu = True
store.main_menu = True
jump expression _main_menu_screen
# This is called to show the main menu to the user.
label _main_menu_screen:
# Let the user completely override the main menu. (But please note
# it still lives in the menu context, rather than the game context.)
if renpy.has_label("main_menu"):
jump expression "main_menu"
# New name.
if renpy.has_label("main_menu_screen"):
jump expression "main_menu_screen"
# Compatibility name.
if renpy.has_label("_library_main_menu"):
jump expression "_library_main_menu"
return
init 1180 python hide:
def create_automatic_images():
seps = config.automatic_images
if seps is True:
seps = [ ' ', '/', '_' ]
for dir, fn in renpy.loader.listdirfiles():
if fn.startswith("_"):
continue
# Only .png and .jpg
if not fn.lower().endswith(".png") and not fn.lower().endswith(".jpg"):
continue
# Strip the extension, replace slashes.
shortfn = fn[:-4].replace("\\", "/")
# Determine the name.
name = ( shortfn, )
for sep in seps:
name = tuple(j for i in name for j in i.split(sep))
# Strip name components.
while name:
for i in config.automatic_images_strip:
if name[0] == i:
name.pop(0)
break
else:
break
# Only names of 2 components or more.
if len(name) < 2:
continue
# Reject if it already exists.
if name in renpy.exports.images:
continue
renpy.image(name, fn)
if config.automatic_images:
create_automatic_images()
# Load the developer screen, if necessary.
init 1180 python hide:
if config.developer:
renpy.load_module("_developer")
# Entry point for the developer screen. The rest of it is loaded from
# _developer.rpym
label _developer:
if not config.developer:
return
call _enter_menu from _call__enter_menu_4
jump expression "_developer_screen"
-44
View File
@@ -1,44 +0,0 @@
# Copyright 2004-2010 PyTom <pytom@bishoujo.us>
# See LICENSE.txt for license details.
# Common stuff that's used by the various Ren'Py menus. This includes
# the default definitions of config.main_menu and config.game_menu, as
# well as the default definitions of the various preferences (and the objects
# holding those preferences)
init -1150 python:
config.main_menu = [
(u"Start Game", "start", "True"),
(u"Load Game", _intra_jumps("load_screen", "main_game_transition"), "True"),
(u"Preferences", _intra_jumps("preferences_screen", "main_game_transition"), "True"),
(u"Help", _help, "True", "config.help"),
(u"Quit", ui.jumps("_quit"), "True"),
]
config.game_menu = [
( None, u"Return", ui.jumps("_return"), 'True'),
( "preferences", u"Preferences", _intra_jumps("preferences_screen", "intra_transition"), 'True' ),
( "save", u"Save Game", _intra_jumps("save_screen", "intra_transition"), 'not main_menu' ),
( "load", u"Load Game", _intra_jumps("load_screen", "intra_transition"), 'True'),
( None, u"Main Menu", ui.callsinnewcontext("_main_menu_prompt"), 'not main_menu' ),
( "help", u"Help", _help, "True", "config.help"),
( None, u"Quit", ui.callsinnewcontext("_quit_prompt"), 'True' ),
]
label _quit_prompt:
$ renpy.loadsave.force_autosave()
if layout.yesno_prompt(None, layout.QUIT):
jump _quit
else:
return
label _main_menu_prompt:
if layout.yesno_prompt(None, layout.MAIN_MENU):
$ renpy.full_restart(transition=config.game_main_transition)
else:
return
-311
View File
@@ -1,311 +0,0 @@
# Copyright 2004-2010 PyTom <pytom@bishoujo.us>
# See LICENSE.txt for license details.
# This file is responsible for creating and defining the default styles
# used by the system.
# This file should be considered part of the Ren'Py library, and not
# something that needs to be modified by the user. Instead, just update
# the appropriate style property in an init: block in your script.
#
# For example, to change the default window backgrounds to a
# transparent dark red, add:
#
# init:
# $ style.window.background = "#8008"
#
# to your script. No need to mess around here, it will just make your
# life harder when a new version of Ren'Py is released.
init -1200 python hide:
# Style Declarations #################################################
style.default = Style(None, help='root of style hierarchy')
style.hbox = Style(style.default, help='horizontal boxes')
style.vbox = Style(style.default, help='vertical boxes')
style.window = Style(style.default, help='windows created with ui.window')
style.image_placement = Style(style.default, help='default placement of images on the screen')
style.image = Style(style.default, help="default style of images")
style.motion = Style(style.default, help="default style of motions and zooms.")
style.animation = Style(style.default, help="default style of animations.")
style.say_label = Style(style.default, help='the name of the character speaking dialogue.')
style.say_dialogue = Style(style.default, help='used for dialogue text')
style.say_thought = Style(style.default, help='used by the default narrator')
style.say_window = Style(style.window, help='windows containing dialogue and thoughts')
style.say_who_window = Style(style.window, help='window containing the label in two-window-say mode')
style.say_two_window_vbox = Style(style.vbox, help='vbox containing the two windows in two-window-say mode')
style.say_vbox = Style(style.vbox, help='contains the label (if present) and the body of dialogue')
style.menu = Style(style.default, help='the vbox containing an in-game menu')
style.menu_caption = Style(style.default, help='in-game menu caption text')
style.menu_choice = Style(style.default, help='text of an in-game menu choice')
style.menu_choice_button = Style(style.default, help='buttons containing in-game menu choices')
style.menu_choice_chosen = Style(style.menu_choice, help='text of an in-game menu choice that has been chosen')
style.menu_choice_chosen_button = Style(style.menu_choice_button, help='buttons containing chosen in-game menu choices')
style.menu_window = Style(style.window, help='a window containing a menu')
style.input_text = Style(style.default, help='text of an input box')
style.input_prompt = Style(style.default, help='prompt of an input box')
style.input_window = Style(style.window, help='window of an input box')
style.centered_window = Style(style.default, help='window containing centered text')
style.centered_text = Style(style.default, help='centered text')
style.imagemap = Style(style.image_placement, help='default style of imagemaps')
style.imagemap_button = Style(style.default, help='default style of buttons inside imagemaps')
style.image_button = Style(style.default, help='default style of image buttons')
style.image_button_image = Style(style.default, help='default style of images inside image buttons')
style.hyperlink = Style(style.default, help=None) # ignored
style.hyperlink_text = Style(style.default, help='hyperlinked text')
style.viewport = Style(style.default, help='default style of viewports')
style.transform = Style(style.motion, help='default style of transforms')
style.list = Style(style.default)
style.list_box = Style(style.vbox)
style.list_row = Style(style.default)
style.list_row_box = Style(style.hbox)
style.list_spacer = Style(style.default)
style.list_text = Style(style.default)
# The base styles that can be customized by themes.
style.frame = Style(style.default, help='base style for frames.')
style.menu_frame = Style(style.frame, help='base style for frames used in the game and main menus.')
style.button = Style(style.default, help='base style for buttons.')
style.button_text = Style(style.default, help='base style for button text')
style.small_button = Style(style.button, help="base style for small buttons")
style.small_button_text = Style(style.button_text, help="base style for small button text")
style.radio_button = Style(style.button, help="base style for radio buttons")
style.radio_button_text = Style(style.button_text, help="base style for radio button text")
style.check_button = Style(style.button, help="base style for check buttons")
style.check_button_text = Style(style.button_text, help="base style for check button text")
style.large_button = Style(style.default, help="base style for large buttons")
style.large_button_text = Style(style.default, help="base style for large button text")
style.label = Style(style.default, help="base style for windows surrounding labels")
style.label_text = Style(style.default, help="base style for label text")
style.prompt = Style(style.default, help="base style for windows surrounding prompts")
style.prompt_text = Style(style.default, help="base style for prompt text")
style.bar = Style(style.default, help='base style for horizontal bars')
style.vbar = Style(style.default, help='base style for vertical bars')
style.slider = Style(style.default, help='base style for horizontal sliders')
style.vslider = Style(style.default, help='base style for vertical sliders')
style.scrollbar = Style(style.default, help='base style for horizontal scrollbars')
style.vscrollbar = Style(style.default, help='base style for vertical scollbars')
style.mm_root = Style(style.default, help="main menu root window")
style.gm_root = Style(style.default, help="game menu root window")
init -1090 python:
# Colors #############################################################
# The Default Style ###################################################
# Text properties.
style.default.font = "DejaVuSans.ttf"
style.default.language = "western"
style.default.antialias = True
style.default.size = 22
style.default.color = (255, 255, 255, 255)
style.default.black_color = (0, 0, 0, 255)
style.default.bold = False
style.default.italic = False
style.default.underline = False
style.default.strikethrough = False
style.default.drop_shadow = None
style.default.drop_shadow_color = (0, 0, 0, 255)
style.default.outlines = [ ]
style.default.minwidth = 0
style.default.text_align = 0
style.default.justify = False
style.default.text_y_fudge = 0
style.default.first_indent = 0
style.default.rest_indent = 0
style.default.line_spacing = 0
style.default.layout = "greedy"
style.default.subtitle_width = 0.9
style.default.slow_cps = None
style.default.slow_cps_multiplier = 1.0
style.default.slow_abortable = False
# Window properties.
style.default.background = None
style.default.xpadding = 0
style.default.ypadding = 0
style.default.xmargin = 0
style.default.ymargin = 0
style.default.xfill = False
style.default.yfill = False
style.default.xminimum = 0 # Includes margins and padding.
style.default.yminimum = 0 # Includes margins and padding.
# Placement properties.
style.default.xpos = None # 0
style.default.ypos = None # 0
style.default.xanchor = None # 0
style.default.yanchor = None # 0
style.default.xmaximum = None
style.default.ymaximum = None
style.default.xoffset = 0
style.default.yoffset = 0
style.default.subpixel = False
# Sound properties.
style.default.sound = None
# Box properties.
style.default.spacing = 0
style.default.first_spacing = None
style.default.box_layout = None
# Focus properties.
style.default.focus_mask = None
style.default.focus_rect = None
# Bar properties.
style.default.fore_bar = Null()
style.default.aft_bar = Null()
style.default.thumb = None
style.default.thumb_shadow = None
style.default.left_gutter = 0
style.default.right_gutter = 0
style.default.thumb_offset = 0
style.default.unscrollable = None
# Misc.
style.default.activate_sound = None
style.default.clipping = False
# Boxes.
style.hbox.box_layout = 'horizontal'
style.vbox.box_layout = 'vertical'
# Motions, zooms, rotozooms, and transforms.
style.motion.xanchor = 0
style.motion.yanchor = 0
style.motion.xpos = 0
style.motion.ypos = 0
# Windows.
style.window.background = Solid((0, 0, 0, 192))
style.window.xpadding = 6
style.window.ypadding = 6
style.window.xmargin = 0
style.window.ymargin = 0
style.window.xfill = True
style.window.yfill = False
style.window.yminimum = 150 # Includes margins and padding.
style.window.xalign = 0.5
style.window.yalign = 1.0
# Image placement.
style.image_placement.xpos = 0.5
style.image_placement.ypos = 1.0
style.image_placement.xanchor = 0.5
style.image_placement.yanchor = 1.0
# Dialogue
style.say_label.bold = True
style.say_vbox.spacing = 8
# Two window styles.
style.say_who_window.xminimum = 200
style.say_who_window.yminimum = 34
style.say_who_window.xfill = False
style.say_who_window.xalign = 0
style.say_two_window_vbox.yalign = 1.0
# Menus.
style.menu_choice.idle_color = "#0ff"
style.menu_choice.hover_color = "#ff0"
style.input_text.color = "#ff0"
# Styles used by centered.
style.centered_window.xalign = 0.5
style.centered_window.xfill = False
style.centered_window.yalign = 0.5
style.centered_window.yfill = False
style.centered_window.xpadding = 10
style.centered_text.textalign = 0.5
style.centered_text.xalign = 0.5
style.centered_text.yalign = 0.5
style.centered_text.layout = "subtitle"
# Hyperlinks.
style.hyperlink_text.underline = True
style.hyperlink_text.hover_color = "#0ff"
style.hyperlink_text.idle_color = "#08f"
# Bars.
style.default.bar_invert = False
style.default.bar_resizing = False
style.default.bar_vertical = False
style.vbar.bar_vertical = True
style.vslider.bar_vertical = True
style.vscrollbar.bar_vertical = True
style.vscrollbar.bar_invert = True
# Viewport
style.viewport.clipping = True
# Transform
style.transform.subpixel = True
# Menu windows.
style.mm_root.background = "#000"
style.mm_root.xfill = True
style.mm_root.yfill = True
style.gm_root.background = "#000"
style.gm_root.xfill = True
style.gm_root.yfill = True
# Lists.
style.list_row.xfill = True
style.list_row.ymargin = 0
style.list_row.background = "#eee"
style.list_row[1].background = "#ddd"
style.list_row.hover_background = "#fff"
style.list_row[1].hover_background = "#fff"
style.list_row.selected_background = "#cce"
style.list_row[1].selected_background = "#cce"
style.list_text.color = "#000"
style.list_text.size = 14
style.list_spacer.xminimum = 15
######################################################################
# Error messages.
style.error_root.background = Solid((220, 220, 255, 255))
style.error_root.xfill = True
style.error_root.yfill = True
style.error_root.xpadding = 20
style.error_root.ypadding = 20
style.error_title.color = (255, 128, 128, 255)
style.error_body.color = (128, 128, 255, 255)
-710
View File
@@ -1,710 +0,0 @@
# Copyright 2004-2010 PyTom <pytom@bishoujo.us>
# See LICENSE.txt for license details.
init -1110 python:
class _Theme(object):
# Using theme as a decorator is what we do to create a new theme.
def __call__(self, func):
setattr(self, func.func_name, func)
return func
_theme = theme = _Theme()
del _Theme
# Public only for compatiblity purposes.
def RoundRect(color, small=False):
if small:
size = 6
else:
if config.screen_width <= 640:
size = 6
else:
size = 12
return Frame(theme.OneOrTwoColor("_roundrect/rr%dg.png" % size, color), size, size)
init -1110 python hide:
@theme
def clear_frames():
style.frame.clear()
@theme
def clear_buttons():
style.button.clear()
style.button_text.clear()
style.radio_button.clear()
style.radio_button_text.clear()
style.check_button.clear()
style.check_button_text.clear()
style.small_button.clear()
style.small_button_text.clear()
@theme
def clear_large_buttons():
style.large_button.clear()
style.large_button_text.clear()
@theme
def clear_labels():
style.label.clear()
style.label_text.clear()
@theme
def clear_prompts():
style.prompt.clear()
style.prompt_text.clear()
@theme
def clear_bars():
style.bar.clear()
style.vbar.clear()
style.scrollbar.clear()
style.vscrollbar.clear()
style.slider.clear()
style.vslider.clear()
style.vbar.bar_vertical = True
style.vslider.bar_vertical = True
style.vscrollbar.bar_vertical = True
style.vscrollbar.bar_invert = True
# This recolors the given image using one or two colors.
@theme
def OneOrTwoColor(image, color):
if len(color) == 2:
return im.Twocolor(image, color[0], color[1])
else:
return im.Twocolor(image, color, color)
@theme
def roundrect_frames(
less_rounded,
frame):
theme.clear_frames()
style.frame.background = RoundRect(frame, less_rounded)
style.frame.xpadding = 6
style.frame.ypadding = 6
@theme
def roundrect_buttons(text_size,
less_rounded,
widget,
widget_hover,
widget_text,
widget_selected,
disabled,
disabled_text):
theme.clear_buttons()
style.button.background = RoundRect(widget, less_rounded)
style.button.hover_background = RoundRect(widget_hover, less_rounded)
style.button.insensitive_background = RoundRect(disabled, less_rounded)
style.button_text.size = text_size
style.button_text.color = widget_text
style.button_text.selected_color = widget_selected
style.button_text.insensitive_color = disabled_text
if less_rounded:
style.button.xpadding = 6
else:
style.button.xpadding = 12
style.button.ypadding = 1
style.button.xmargin = 1
style.button.ymargin = 1
style.button_text.xalign = 0.5
style.button_text.yalign = 0.5
style.button_text.text_align = 0.5
@theme
def roundrect_large_buttons(
text_size,
less_rounded,
widget,
widget_hover,
widget_text,
widget_selected,
disabled,
disabled_text):
theme.clear_large_buttons()
if less_rounded:
style.large_button.xpadding = 6
else:
style.large_button.xpadding = 12
style.large_button.ypadding = 1
style.large_button.xmargin = 1
style.large_button.ymargin = 1
style.large_button.background = RoundRect(widget, less_rounded)
style.large_button.hover_background = RoundRect(widget_hover, less_rounded)
style.large_button.insensitive_background = RoundRect(disabled, less_rounded)
style.large_button_text.size = text_size
style.large_button_text.color = widget_text
style.large_button_text.selected_color = widget_selected
style.large_button_text.insensitive_color = disabled_text
style.large_button_text.xalign = 0
style.large_button_text.yalign = 0
@theme
def roundrect_labels(
text_size,
label):
theme.clear_labels()
style.label_text.size = text_size
style.label_text.color = label
@theme
def roundrect_prompts(
text_size,
label):
theme.clear_prompts()
style.prompt_text.size = text_size
style.prompt_text.color = label
style.prompt.xalign = 0.5
style.prompt_text.text_align = 0.5
style.prompt_text.layout = "subtitle"
@theme
def roundrect_bars(
widget,
widget_hover):
theme.clear_bars()
def img(name, color, x, y):
rv = theme.OneOrTwoColor("_roundrect/" + name + ".png", color)
if x is not None:
rv = Frame(rv, x, y)
return rv
# Bars.
style.bar.ymaximum = 24
style.bar.left_gutter = 6
style.bar.right_gutter = 6
style.bar.thumb_offset = 6
style.bar.left_bar = img("rrslider_full", widget, 12, 0)
style.bar.right_bar = img("rrslider_empty", widget, 12, 0)
style.bar.thumb = img("rrslider_thumb", widget, None, None)
style.bar.hover_left_bar = img("rrslider_full", widget_hover, 12, 0)
style.bar.hover_right_bar = img("rrslider_empty", widget_hover, 12, 0)
style.bar.hover_thumb = img("rrslider_thumb", widget_hover, None, None)
style.vbar.xmaximum = 24
style.vbar.top_gutter = 6
style.vbar.bottom_gutter = 6
style.vbar.thumb_offset = 6
style.vbar.bottom_bar = img("rrvslider_full", widget, 0, 12)
style.vbar.top_bar = img("rrvslider_empty", widget, 0, 12)
style.vbar.thumb = img("rrvslider_thumb", widget, None, None)
style.vbar.hover_bottom_bar = img("rrvslider_full", widget_hover, 0, 12)
style.vbar.hover_top_bar = img("rrvslider_empty", widget_hover, 0, 12)
style.vbar.hover_thumb = img("rrvslider_thumb", widget_hover, None, None)
# Sliders.
style.slider.ymaximum = 24
style.slider.left_gutter = 6
style.slider.right_gutter = 6
style.slider.thumb_offset = 6
style.slider.left_bar = img("rrslider_full", widget, 12, 0)
style.slider.right_bar = img("rrslider_empty", widget, 12, 0)
style.slider.thumb = img("rrslider_thumb", widget, None, None)
style.slider.hover_left_bar = img("rrslider_full", widget_hover, 12, 0)
style.slider.hover_right_bar = img("rrslider_empty", widget_hover, 12, 0)
style.slider.hover_thumb = img("rrslider_thumb", widget_hover, None, None)
style.vslider.xmaximum = 24
style.vslider.top_gutter = 6
style.vslider.bottom_gutter = 6
style.vslider.thumb_offset = 6
style.vslider.bottom_bar = img("rrvslider_full", widget, 0, 12)
style.vslider.top_bar = img("rrvslider_empty", widget, 0, 12)
style.vslider.thumb = img("rrvslider_thumb", widget, None, None)
style.vslider.hover_bottom_bar = img("rrvslider_full", widget_hover, 0, 12)
style.vslider.hover_top_bar = img("rrvslider_empty", widget_hover, 0, 12)
style.vslider.hover_thumb = img("rrvslider_thumb", widget_hover, None, None)
# Scrollbars.
style.scrollbar.left_gutter = 6
style.scrollbar.right_gutter = 6
style.scrollbar.thumb_offset = 6
style.scrollbar.ymaximum = 12
style.scrollbar.left_bar = img("rrscrollbar", widget, 12, 0)
style.scrollbar.right_bar = img("rrscrollbar", widget, 12, 0)
style.scrollbar.thumb = img("rrscrollbar_thumb", widget, None, None)
style.scrollbar.hover_left_bar = img("rrscrollbar", widget_hover, 12, 0)
style.scrollbar.hover_right_bar = img("rrscrollbar", widget_hover, 12, 0)
style.scrollbar.hover_thumb = img("rrscrollbar_thumb", widget_hover, None, None)
style.vscrollbar.top_gutter = 6
style.vscrollbar.bottom_gutter = 6
style.vscrollbar.thumb_offset = 6
style.vscrollbar.xmaximum = 12
style.vscrollbar.left_bar = img("rrvscrollbar", widget, 0, 12)
style.vscrollbar.right_bar = img("rrvscrollbar", widget, 0, 12)
style.vscrollbar.thumb = img("rrvscrollbar_thumb", widget, None, None)
style.vscrollbar.hover_left_bar = img("rrvscrollbar", widget_hover, 0, 12)
style.vscrollbar.hover_right_bar = img("rrvscrollbar", widget_hover, 0, 12)
style.vscrollbar.hover_thumb = img("rrvscrollbar_thumb", widget_hover, None, None)
@theme
def roundrect(
widget = (0, 60, 120, 255),
widget_hover = (0, 80, 160, 255),
widget_text = (200, 225, 255, 255),
widget_selected = (255, 255, 200, 255),
disabled = (64, 64, 64, 255),
disabled_text = (200, 200, 200, 255),
label = (255, 255, 255, 255),
frame = (100, 150, 200, 255),
window = (0, 0, 0, 192),
mm_root = Solid((220, 235, 255, 255)),
gm_root = Solid((220, 235, 255, 255)),
text_size=None,
small_text_size=None,
less_rounded = False,
# Compat for the old roundrect theme.
window = None,
button_menu = None,
rounded_window = True,
outline_bars = False,
mm_root = None,
gm_root = None):
if button_menu is None:
if (config.script_version is not None) and (config.script_version < (6, 9, 0)):
button_menu = True
else:
button_menu = False
layout.defaults()
if config.screen_width <= 640:
text_size = text_size or 18
small_text_size = small_text_size or 12
less_rounded = True
else:
text_size = text_size or 22
small_text_size = small_text_size or 16
radius = 12
theme.roundrect_frames(
less_rounded,
frame)
theme.roundrect_buttons(
text_size,
less_rounded,
widget,
widget_hover,
widget_text,
widget_selected,
disabled,
disabled_text)
theme.roundrect_large_buttons(
small_text_size,
less_rounded,
widget,
widget_hover,
widget_text,
widget_selected,
disabled,
disabled_text)
theme.roundrect_labels(
text_size,
label)
theme.roundrect_prompts(
text_size,
label)
theme.roundrect_bars(
widget,
widget_hover)
if mm_root is not None:
style.mm_root.background = mm_root
if gm_root is not None:
style.gm_root.background = gm_root
if window is not None:
if rounded_window:
style.window.background = RoundRect(window, less_rounded)
style.window.xpadding = 6
style.window.xmargin = 6
style.window.ypadding = 6
style.window.ymargin = 6
else:
style.window.background = Solid(window)
style.window.xpadding = 6
style.window.xmargin = 0
style.window.ypadding = 6
style.window.ymargin = 0
if button_menu:
layout.button_menu()
@theme
def ancient():
layout.defaults()
style.frame.background = Solid((0, 0, 128, 128))
style.frame.xpadding = 10
style.frame.ypadding = 10
style.frame.xmargin = 10
style.frame.ymargin = 5
style.menu_frame.set_parent(style.default)
dark_cyan = (0, 192, 255, 255)
bright_cyan = (0, 255, 255, 255)
dark_red = (255, 128, 128, 255)
bright_red = (255, 64, 64, 255)
green = (0, 128, 0, 255)
style.button_text.color = dark_cyan
style.button_text.hover_color = bright_cyan
style.button_text.insensitive_color = (192, 192, 192, 255)
style.button_text.size = 24
style.button_text.drop_shadow = (2, 2)
style.button_text.drop_shadow_color = "#000"
style.button_text.selected_color = dark_red
style.button_text.selected_hover_color = bright_red
style.button_text.xalign = 0.5
style.button_text.text_align = 0.5
style.bar.ymaximum = 22
style.bar.left_bar = Solid(bright_cyan)
style.bar.right_bar = Solid((0, 0, 0, 128))
style.bar.thumb = None
style.bar.thumb_offset = 0
style.bar.thumb_shadow = None
style.vbar.xmaximum = 22
style.vbar.bottom_bar = Solid(bright_cyan)
style.vbar.top_bar = Solid((0, 0, 0, 128))
style.vbar.thumb = None
style.vbar.thumb_offset = 0
style.vbar.thumb_shadow = None
style.slider.ymaximum = 22
style.slider.left_bar = Solid(bright_cyan)
style.slider.right_bar = Solid((0, 0, 0, 128))
style.slider.thumb = None
style.slider.thumb_offset = 0
style.slider.thumb_shadow = None
style.vslider.xmaximum = 22
style.vslider.bottom_bar = Solid(bright_cyan)
style.vslider.top_bar = Solid((0, 0, 0, 128))
style.vslider.thumb = None
style.vslider.thumb_offset = 0
style.vslider.thumb_shadow = None
style.scrollbar.ymaximum = 22
style.scrollbar.left_bar = Solid("#0008")
style.scrollbar.right_bar = Solid("#0008")
style.scrollbar.thumb = Solid(bright_cyan)
style.scrollbar.thumb_offset = 0
style.scrollbar.thumb_shadow = None
style.vscrollbar.xmaximum = 22
style.vscrollbar.top_bar = Solid("#0008")
style.vscrollbar.bottom_bar = Solid("#0008")
style.vscrollbar.thumb = Solid(bright_cyan)
style.vscrollbar.thumb_offset = 0
style.vscrollbar.thumb_shadow = None
style.large_button.xpadding = 5
style.large_button.ypadding = 2
style.large_button.xmargin = 5
style.large_button.ymargin = 2
style.large_button.background = "#fff"
style.large_button.hover_background = "#ffc"
style.large_button_text.size = 16
style.large_button_text.drop_shadow = (1, 1)
style.large_button_text.xalign = 0
style.large_button_text.text_align = 0
style.label_text.size = 24
style.label_text.color = green
style.label_text.drop_shadow = (1, 1)
style.label_text.drop_shadow_color = "#000"
style.prompt_text.size = 24
style.prompt_text.color = green
style.prompt_text.layout = "subtitle"
style.prompt_text.text_align = 0.5
style.prompt_text.drop_shadow = (1, 1)
style.prompt_text.drop_shadow_color = "#000"
style.mm_root.background = "#e9d8bc"
style.gm_root.background = "#e9d8bc"
@theme
def outline_frames():
theme.clear_frames()
@theme
def outline_buttons(
inside,
idle,
hover,
selected,
insensitive,
text_size):
theme.clear_buttons()
style.button.xmargin = 4
style.button_text.size = text_size
style.button_text.color = inside
style.button_text.outlines = [ (2, idle) ]
style.button_text.hover_outlines = [ (2, hover) ]
style.button_text.selected_outlines = [ (2, selected) ]
style.button_text.selected_hover_outlines = [ (2, hover) ]
style.button_text.insensitive_outlines = [ (2, insensitive) ]
@theme
def outline_large_buttons(
inside,
idle,
hover,
selected,
insensitive,
text_size,
large_button):
theme.clear_large_buttons()
style.large_button.xmargin = 4
style.large_button.ymargin = 2
style.large_button.background = large_button
style.large_button_text.size = text_size
style.large_button_text.color = inside
style.large_button_text.outlines = [ (2, idle) ]
style.large_button_text.hover_outlines = [ (2, hover) ]
style.large_button_text.selected_outlines = [ (2, selected) ]
style.large_button_text.selected_hover_outlines = [ (2, hover) ]
style.large_button_text.insensitive_outlines = [ (2, insensitive) ]
@theme
def outline_prompts(
inside,
prompt,
text_size):
theme.clear_prompts()
style.prompt_text.color = inside
style.prompt_text.outlines = [ (2, prompt) ]
style.prompt_text.size = text_size
@theme
def outline_labels(
inside,
label,
text_size):
theme.clear_labels()
style.label_text.color = inside
style.label_text.outlines = [ (2, label) ]
style.label_text.size = text_size
@theme
def outline_bars(
inside,
idle,
hover):
theme.clear_bars()
def color(fn, c):
return im.Twocolor("_outline/" + fn + ".png", inside, c)
style.bar.ymaximum = 16
style.bar.left_bar = Frame(color("circle", idle), 7, 0)
style.bar.right_bar = Frame(color("bar", idle), 0, 0)
style.bar.left_gutter = 16
style.bar.bar_resizing = True
style.slider.ymaximum = 16
style.slider.left_bar = Frame(color("bar", idle), 0, 0)
style.slider.right_bar = Frame(color("bar", idle), 0, 0)
style.slider.thumb = color("circle", idle)
style.slider.hover_left_bar = Frame(color("bar", hover), 0, 0)
style.slider.hover_right_bar = Frame(color("bar", hover), 0, 0)
style.slider.hover_thumb = color("circle", hover)
style.scrollbar.ymaximum = 16
style.scrollbar.left_bar = Frame(color("bar", idle), 0, 0)
style.scrollbar.right_bar = Frame(color("bar", idle), 0, 0)
style.scrollbar.thumb = Frame(color("circle", idle), 7, 0)
style.scrollbar.hover_left_bar = Frame(color("bar", hover), 0, 0)
style.scrollbar.hover_right_bar = Frame(color("bar", hover), 0, 0)
style.scrollbar.hover_thumb = Frame(color("circle", hover), 7, 0)
style.vbar.xmaximum = 16
style.vbar.bottom_bar = Frame(color("circle", idle), 0, 7)
style.vbar.top_bar = Frame(color("vbar", idle), 0, 0)
style.vbar.bottom_gutter = 16
style.vbar.bar_resizing = True
style.vslider.xmaximum = 16
style.vslider.top_bar = Frame(color("vbar", idle), 0, 0)
style.vslider.bottom_bar = Frame(color("vbar", idle), 0, 0)
style.vslider.thumb = color("circle", idle)
style.vslider.hover_top_bar = Frame(color("vbar", hover), 0, 0)
style.vslider.hover_bottom_bar = Frame(color("vbar", hover), 0, 0)
style.vslider.hover_thumb = color("circle", hover)
style.vscrollbar.xmaximum = 16
style.vscrollbar.top_bar = Frame(color("vbar", idle), 0, 0)
style.vscrollbar.bottom_bar = Frame(color("vbar", idle), 0, 0)
style.vscrollbar.thumb = Frame(color("circle", idle), 0, 7)
style.vscrollbar.hover_top_bar = Frame(color("vbar", hover), 0, 0)
style.vscrollbar.hover_bottom_bar = Frame(color("vbar", hover), 0, 0)
style.vscrollbar.hover_thumb = Frame(color("circle", hover), 0, 7)
@theme
def outline(
inside="#fff",
idle="#e66",
hover="#48f",
selected="#84f",
insensitive="#ccc",
label="#484",
prompt="#484",
background="#fee",
large_button="#fff8f8",
text_size=22,
small_text_size=16,
):
layout.defaults()
theme.outline_frames()
theme.outline_buttons(
inside,
idle,
hover,
selected,
insensitive,
text_size)
theme.outline_large_buttons(
inside,
idle,
hover,
selected,
insensitive,
small_text_size,
large_button)
theme.outline_prompts(
inside,
prompt,
text_size)
theme.outline_labels(
inside,
label,
text_size)
theme.outline_bars(
inside,
idle,
hover)
style.mm_root.background = background
style.gm_root.background = background
@theme
def image_buttons(d):
for k, (idle, hover, selected_idle, selected_hover, insensitive) in d.iteritems():
s = style.button[k]
s.xpadding = 0
s.ypadding = 0
s.background = None
s.foreground = None
s.idle_child = idle
s.hover_child = hover
s.selected_idle_child = selected_idle
s.selected_hover_child = selected_hover
s.insensitive_child = insensitive
s.focus_mask = True
@theme
def image_labels(d):
for k, l in d.iteritems():
s = style.label[k]
s.xpadding = 0
s.ypadding = 0
s.background = None
s.foreground = None
s.child = k
config.image_buttons = { }
config.image_labels = { }
init 1110 python:
if not "compat" in _layout.provided:
theme.image_buttons(config.image_buttons)
theme.image_labels(config.image_labels)
-119
View File
@@ -1,119 +0,0 @@
# Copyright 2004-2010 PyTom <pytom@bishoujo.us>
# See LICENSE.txt for license details.
# This extra contains a basic implementation of voice support. Right
# now, voice is given its own toggle, and can either be turned on or
# turned off. In the future, we'll probably provide some way of
# toggling it on or off for individual characters.
#
# To use it, place a voice "<sndfile>" line before each voiced line of
# dialogue.
#
# voice "e_1001.ogg"
# e "Voice support lets you add the spoken word to your games."
#
# Normally, a voice is cancelled at the start of the next
# interaction. If you want a voice to span interactions, call
# voice_sustain.
#
# voice "e_1002.ogg"
# e "Voice sustain is a technique that allows the same voice file.."
#
# $ voice_sustain()
# e "...to play for two lines of dialogue."
init -1120:
python:
_voice = object()
_voice.play = None
_voice.sustain = False
_voice.seen_in_lint = False
# Call this to specify the voice file that will be played for
# the user.
def voice(file, **kwargs):
if not config.has_voice:
return
_voice.play = file
# Call this to specify that the currently playing voice file
# should be sustained through the current interaction.
def voice_sustain(ignored="", **kwargs):
if not config.has_voice:
return
_voice.sustain = True
python hide:
# basics: True if the game will have voice.
config.has_voice = True
# This is called on each interaction, to ensure that the
# appropriate voice file is played for the user.
def voice_interact():
if not config.has_voice:
return
if _voice.play and not config.skipping:
renpy.sound.play(_voice.play, channel=2)
elif not _voice.sustain:
renpy.sound.stop(channel=2)
_voice.play = None
_voice.sustain = False
config.start_interact_callbacks.append(voice_interact)
config.say_sustain_callbacks.append(voice_sustain)
def voice_afm_callback():
return not renpy.sound.is_playing(channel=2)
config.afm_callback = voice_afm_callback
python early hide:
def parse_voice(l):
fn = l.simple_expression()
if fn is None:
renpy.error('expected simple expression (string)')
if not l.eol():
renpy.error('expected end of line')
return fn
def execute_voice(fn):
fn = eval(fn)
voice(fn)
def lint_voice(fn):
_voice.seen_in_lint = True
fn = _try_eval(fn, 'voice filename')
if isinstance(fn, basestring) and not renpy.loadable(fn):
renpy.error('voice file %r is not loadable' % fn)
renpy.statements.register('voice',
parse=parse_voice,
execute=execute_voice,
lint=lint_voice)
def parse_voice_sustain(l):
if not l.eol():
renpy.error('expected end of line')
return None
def execute_voice_sustain(parsed):
voice_sustain()
renpy.statements.register('voice sustain',
parse=parse_voice_sustain,
execute=execute_voice_sustain)
+2
View File
@@ -0,0 +1,2 @@
lib\windows-i686\python.exe -OO renpy.py
pause
-1
View File
@@ -1 +0,0 @@
dist/console.exe
Regular → Executable
+205 -206
View File
@@ -1,238 +1,237 @@
#!/home/tom/bin/renpython -O
# Builds a distributions of Ren'Py.
# Builds a distribution of Ren'Py.
import sys
import os
import zipfile
import tarfile
import time
import zlib
import compileall
import shutil
import subprocess
import argparse
import glob
zlib.Z_DEFAULT_COMPRESSION = 9
ROOT = os.path.dirname(os.path.abspath(__file__))
# Gets the data for the given file.
def data(fn):
def copy_tutorial_file(src, dest):
"""
Copies a file from src to dst. Lines between "# tutorial-only" and
"# end-tutorial-only" comments are omitted from the copy.
"""
rv = file(fn, "rb").read()
sf = open(src, "rb")
df = open(dest, "wb")
if fn.startswith("renpy.app"):
return rv
# True if we want to copy the line.
copy = True
if fn.endswith(".rpy") or fn.endswith(".py") or fn.endswith(".txt"):
rv = rv.replace("\n", "\r\n")
rv = rv.replace("\r\r\n", "\r\n")
for l in sf:
if "# tutorial-only" in l:
copy = False
elif "# end-tutorial-only" in l:
copy = True
else:
if copy:
df.write(l)
return rv
sf.close()
df.close()
def tarup(filename, prefix, files):
tf = tarfile.open(filename, "w:bz2")
tf.dereference = True
sys.stdout.write(filename)
sys.stdout.flush()
for fn in files:
sys.stdout.write(".")
sys.stdout.flush()
tf.add(fn, prefix + "/" + fn, False)
sys.stdout.write("\n")
tf.close()
# Creates a zip file.
def zipup(filename, prefix, files):
zf = zipfile.ZipFile(filename, "w")
sys.stdout.write(filename)
sys.stdout.flush()
for fn in files:
sys.stdout.write(".")
sys.stdout.flush()
zi = zipfile.ZipInfo(prefix + "/" + fn)
st = os.stat(fn)
zi.date_time = time.gmtime(st.st_mtime)[:6]
zi.compress_type = zipfile.ZIP_DEFLATED
zi.create_system = 3
zi.external_attr = long(st.st_mode) << 16
zf.writestr(zi, data(fn))
zf.close()
sys.stdout.write("\n")
sys.stdout.flush()
def tree(root):
rv = [ ]
for dirname, dirs, filenames in os.walk(root):
if "saves" in dirs:
dirs.remove("saves")
if ".svn" in dirs:
dirs.remove(".svn")
for f in filenames:
if f[-1] == '~' or f[0] == '.':
continue
if f.endswith(".bak") or f.endswith(".pyc"):
continue
if f == "semantic.cache":
continue
if "libSDL_mixer" in f or "mixer_music" in f:
continue
rv.append(dirname + "/" + f)
return rv
def main():
if len(sys.argv) != 2:
print "Usage: %s <prefix>" % sys.argv[0]
return
if not sys.flags.optimize:
raise Exception("Not running with python optimization.")
prefix = sys.argv[1]
ap = argparse.ArgumentParser()
ap.add_argument("version")
ap.add_argument("--fast", action="store_true")
compileall.compile_dir("renpy/", ddir=prefix + "/renpy/", force=1)
args = ap.parse_args()
os.environ['RENPY_PATH_ELIDE'] = '/home/tom/ab/renpy:' + prefix
# Revision updating is done early, so we can do it even if the rest
# of the program fails.
# Chmod the mac app.
os.chmod("./renpy.app/Contents/MacOS/Ren'Py Launcher", 0755)
# Compile the various games
for i in [ 'tutorial/game', 'launcher', 'template/game', 'the_question/game' ]:
os.system("./renpy.sh --compile --game " + i)
# Determine the version. We grab the current revision, and if any
# file has changed, bump it by 1.
import renpy
files = [ ]
more_files = [ ]
match_version = ".".join(str(i) for i in renpy.version_tuple[:2]) #@UndefinedVariable
zip_version = ".".join(str(i) for i in renpy.version_tuple[:3]) #@UndefinedVariable
files.append("CHANGELOG.txt")
files.append("LICENSE.txt")
files.extend(tree("common"))
more_files.append("console.exe")
files.extend(tree("launcher"))
files.extend(tree("tutorial"))
# files.extend(tree("dse"))
files.extend(tree("the_question"))
s = subprocess.check_output([ "git", "describe", "--tags", "--dirty", "--match", match_version ])
parts = s.strip().split("-")
# editor = tree("editor")
# editor.remove("editor/scite.exe")
# files.append("editor/scite.exe")
# more_files.extend(editor)
if len(parts) <= 2:
vc_version = 0
else:
vc_version = int(parts[1])
more_files.extend(tree("jedit"))
# files.extend(tree("extras"))
more_files.extend(tree("lib"))
more_files.extend(tree("lib/linux-x86"))
if parts[-1] == "dirty":
vc_version += 1
module_files = [
"lib/pysdlsound/linmixer.py",
"lib/pysdlsound/__init__.py",
"core.c",
"ffdecode.c",
"IMG_savepng.c",
"IMG_savepng.h",
"mmx.h",
"pss.c",
"pss.h",
"README.txt",
"_renpy.c",
"renpy_font.c",
"renpy.h",
"_renpy.pyx",
"renpy_ttf.c",
"renpy_ttf.h",
"rwobject.c",
"setup.py",
"sound.c",
"sound.pyx",
"subpixel.c",
"winmixer.c",
"winmixer.pyx",
"_renpybidi.c",
"renpybidicore.c",
"_renpybidi.pyx",
]
for i in module_files:
files.append('module/' + i)
more_files.append('python25.dll')
more_files.append('msvcr71.dll')
files.extend(tree('renpy'))
more_files.extend(tree('renpy.app'))
more_files.append('renpy.code')
more_files.append('renpy.exe')
files.append('renpy.py')
more_files.append('renpy.sh')
files.extend(tree('template'))
# files.extend(tree('tools'))
files.append('doc/index.html')
files.append('doc/common.css')
files.append('doc/docs.css')
files.append('doc/monobook.css')
files.append('doc/monobook2.css')
files.append('doc/shared.css')
files.extend(tree('doc/reference'))
files.extend(tree('doc/tutorials'))
files.extend(tree('doc/images'))
files.sort()
more_files.sort()
# zipup("dists/" + prefix + "-win32.zip", prefix, files)
# print "----"
zipup("dists/" + prefix + "-sdk.zip", prefix, files + more_files)
print "----"
tarup("dists/" + prefix + "-sdk.tar.bz2", prefix, files + more_files)
tarup("dists/" + prefix + "-source.tar.bz2", prefix, files)
# Make the 7zip.
os.chdir("dists")
os.system("unzip " + prefix + "-sdk.zip")
with open("renpy/vc_version.py", "w") as f:
f.write("vc_version = {}".format(vc_version))
try:
os.unlink(prefix + "-sdk.7z")
reload(sys.modules['renpy.vc_version']) #@UndefinedVariable
except:
pass
import renpy.vc_version # @UnusedImport
reload(sys.modules['renpy'])
# Check that the versions match.
full_version = ".".join(str(i) for i in renpy.version_tuple) #@UndefinedVariable
if args.version != "renpy-experimental" \
and not args.version.startswith("renpy-nightly-") \
and not full_version.startswith(args.version):
raise Exception("The command-line and Ren'Py versions do not match.")
# The destination directory.
destination = os.path.join("dl", args.version)
print "Version {} ({})".format(args.version, full_version)
# Perhaps autobuild.
if "RENPY_BUILD_ALL" in os.environ:
print("Autobuild...")
subprocess.check_call(["scripts/autobuild.sh"])
# Copy over the screens, to keep them up to date.
copy_tutorial_file("tutorial/game/screens.rpy", "templates/english/game/screens.rpy")
# Compile all the python files.
compileall.compile_dir("renpy/", ddir="renpy/", force=1, quiet=1)
# Generate launcher/game/script_version.rpy
with open("launcher/game/script_version.rpy", "w") as f:
f.write("init -999 python:\n")
f.write(" config.script_version = {!r}\n".format(renpy.version_tuple[:3])) # @UndefinedVariable
# Compile the various games.
if not args.fast:
for i in [ 'tutorial', 'launcher', 'the_question' ] + glob.glob("templates/*"):
print "Compiling", i
subprocess.check_call(["./renpy.sh", i, "quit" ])
# Kick off the rapt build.
if not args.fast:
out = open("/tmp/rapt_build.txt", "wb")
print("Building RAPT.")
android = os.path.abspath("android")
rapt_build = subprocess.Popen([
os.path.join(android, "build_renpy.sh"),
"renpy",
ROOT,
],
cwd = android,
stdout=out,
stderr=out)
code = rapt_build.wait()
if code:
print "RAPT build failed. The output is in /tmp/rapt_build.txt."
sys.exit(1)
else:
print "RAPT build succeeded."
if not os.path.exists(destination):
os.makedirs(destination)
if args.fast:
cmd = [
"./renpy.sh",
"launcher",
"distribute",
"launcher",
"--package",
"sdk",
"--destination",
destination,
"--no-update",
]
else:
cmd = [
"./renpy.sh",
"launcher",
"distribute",
"launcher",
"--destination",
destination,
]
os.system("7z a " + prefix + "-sdk.7z " + prefix)
os.system("cat ../7z.sfx " + prefix + "-sdk.7z > " + prefix + "-sdk.7z.exe""")
shutil.rmtree(prefix)
os.unlink(prefix + "-sdk.7z")
print
print "Did you remember to rebuild the exe after the last change?"
print "Did you run me with renpython -OO?"
print "Was ming using the right crt?"
print "Did you update renpy.py and launcher/script_version.rpy?"
print "Did you run with a RENPY_SCALE_FACTOR?"
subprocess.check_call(cmd)
# Sign the update.
if not args.fast:
subprocess.check_call([
"scripts/sign_update.py",
"/home/tom/ab/keys/renpy_private.pem",
os.path.join(destination, "updates.json"),
])
# Write 7z.exe.
sdk = "renpy-{}-sdk".format(zip_version)
if args.version.startswith("renpy-nightly-"):
sdk = args.version + "-sdk"
if not args.fast:
# shutil.copy("renpy-ppc.zip", os.path.join(destination, "renpy-ppc.zip"))
with open("7z.sfx", "rb") as f:
sfx = f.read()
os.chdir(destination)
if os.path.exists(sdk):
shutil.rmtree(sdk)
subprocess.check_call([ "unzip", "-q", sdk + ".zip" ])
if os.path.exists(sdk + ".7z"):
os.unlink(sdk + ".7z")
sys.stdout.write("Creating -sdk.7z")
p = subprocess.Popen([ "7z", "a", sdk +".7z", sdk], stdout=subprocess.PIPE)
for i, _l in enumerate(p.stdout):
if i % 10 != 0:
continue
sys.stdout.write(".")
sys.stdout.flush()
if p.wait() != 0:
raise Exception("7z failed")
with open(sdk + ".7z", "rb") as f:
data = f.read()
with open(sdk + ".7z.exe", "wb") as f:
f.write(sfx)
f.write(data)
os.unlink(sdk + ".7z")
shutil.rmtree(sdk)
else:
os.chdir(destination)
if os.path.exists(sdk + ".7z.exe"):
os.unlink(sdk + ".7z.exe")
print
if __name__ == "__main__":
main()
-16
View File
@@ -1,16 +0,0 @@
#bodyContent {
font-size: medium;
background: #fff;
margin-left: 20%;
margin-right: 20%;
padding: 1.5em;
}
.editsection {
display: none;
}
#bodyContent a.external {
background: none;
padding-right: 0px;
}
-19
View File
@@ -1,19 +0,0 @@
#!/bin/sh
wget http://www.renpy.org/w/skins/common/shared.css -O shared.css
wget http://www.renpy.org/w/skins/monobook/main.css -O monobook.css
wget 'http://www.renpy.org/w/index.php?title=MediaWiki:Common.css&usemsgcache=yes&action=raw&ctype=text/css&smaxage=18000' -O common.css
wget 'http://www.renpy.org/w/index.php?title=MediaWiki:Monobook.css&usemsgcache=yes&action=raw&ctype=text/css&smaxage=18000' -O monobook2.css
rm -Rf www.renpy.org
wget -e robots=off -m -I /wiki/renpy/doc/reference/,/wiki/renpy/doc/tutorials/,/w/images -m http://www.renpy.org/wiki/renpy/doc/index
rm -Rf images
mkdir -p images
cp `find www.renpy.org -name \*.png -type f` images
No jpgs yet.
cp `find www.renpy.org -name \*.jpg -type f` images
rm -Rf reference tutorials
python2.5 process.py
-164
View File
@@ -1,164 +0,0 @@
#!/usr/bin/python2.4
import sys
import os.path
# import xml.etree.ElementTree as elementtree
# sys.modules['elementtree'] = elementtree
# from elementtree.ElementTree import ElementTree, Element, SubElement, tostring, fromstring
# from elementtidy import TidyHTMLTreeBuilder
from xml.etree.ElementTree import ElementTree, Element, SubElement, tostring, fromstring
from elementtidy import TidyHTMLTreeBuilder
# Removes everyhing we don't care about from the wikipages.
def remove_crap(n):
classes = n.attrib.get("class", "").split()
if "editsection" in classes:
return None
if "printfooter" in classes:
return None
if "magnify" in classes:
return None
id = n.attrib.get("id", None)
if "catlinks" == id:
return None
newchildren = [ ]
for i in n:
i = remove_crap(i)
if i is not None:
newchildren.append(i)
n[:] = newchildren
if n.tag == "a" and not n.text:
n.text = "SPACE REMOVE ME PLEASE"
return n
def process(src, dst, nav):
if nav:
nav = fromstring(nav)
base = "../" * (len(dst.split('/')) - 1)
if dst.startswith("./"):
base = ""
# tree = TidyHTMLTreeBuilder.parse(src)
code = file(src).read()
code = code.replace("&nbsp;", u"\u00a0".encode("utf-8"))
tree = fromstring(code)
XHTML = "{http://www.w3.org/1999/xhtml}"
for elem in tree.getiterator():
if elem.tag.startswith(XHTML):
elem.tag = elem.tag[len(XHTML):]
by_id = dict()
for n in tree.getiterator():
if "id" in n.attrib:
by_id[n.attrib["id"]] = n
html = Element("html")
head = SubElement(html, "head")
title = SubElement(head, "title")
title.text = tree.findtext(".//title")
head = SubElement(head, "link", rel="stylesheet", href=base + "shared.css")
head = SubElement(head, "link", rel="stylesheet", href=base + "monobook.css")
head = SubElement(head, "link", rel="stylesheet", href=base + "common.css")
head = SubElement(head, "link", rel="stylesheet", href=base + "monobook2.css")
head = SubElement(head, "link", rel="stylesheet", href=base + "docs.css")
body = SubElement(html, "body")
# gw = SubElement(body, "div", id="globalWrapper")
# cc = SubElement(gw, "div", id="column-content")
# content = SubElement(cc, "div", id="content")
bc = by_id['bodyContent']
body.append(bc)
bc.remove(by_id['siteSub'])
bc.remove(by_id['contentSub'])
bc.remove(by_id['jump-to-nav'])
for n in bc.findall(".//a"):
if "href" in n.attrib:
href = n.attrib['href']
if href.startswith("/wiki/Image:") or href.startswith("/w/"):
n.attrib['href'] = 'http://www.renpy.org' + href
continue
if href.startswith("#"):
continue
if href.startswith("http:"):
continue
href = href.replace("/wiki/renpy/doc/", base)
if "#" in href:
href.replace("#", ".html#")
else:
href += ".html"
n.attrib['href'] = href
for n in bc.findall(".//img"):
src = n.attrib["src"]
src = base + "images" + src[src.rfind("/"):]
n.attrib["src"] = src
if nav:
hr = Element("hr")
bc[:] = [ nav ] + list(bc) + [ hr, nav ]
html = remove_crap(html)
doc = tostring(html)
doc = doc.replace("SPACE REMOVE ME PLEASE", "")
file(dst, "w").write(doc)
def process_dir(src, dst, nav):
try:
os.makedirs(dst)
except:
pass
for fn in os.listdir(src):
if os.path.isdir(src + "/" + fn):
continue
if fn.endswith(".1"):
continue
print src + "/" + fn
process(src + "/" + fn, dst + "/" + fn + ".html", nav)
nav = '<p class="docnav"><a href="../index.html">documentation index</a></p>'
process_dir("www.renpy.org/wiki/renpy/doc/tutorials", "tutorials", nav)
nav = '<p class="docnav"><a href="../index.html">documentation index</a> &#x25e6; <a href="Reference_Manual.html">reference manual</a> &#x25e6; <a href="Function_Index.html">function index</a></p>'
process_dir("www.renpy.org/wiki/renpy/doc/reference", "reference", nav)
nav = '<p class="docnav"><a href="../../index.html">documentation index</a> &#x25e6; <a href="../Reference_Manual.html">reference manual</a> &#x25e6; <a href="../Function_Index.html">function index</a></p>'
process_dir("www.renpy.org/wiki/renpy/doc/reference/functions", "reference/functions", nav)
nav = ''
process_dir("www.renpy.org/wiki/renpy/doc/", ".", nav)
-137
View File
@@ -1,137 +0,0 @@
# This contains code for the new day planner. You probably
# don't want to change this file, but it might make sense to
# change many of the variables or styles defined here from
# other files.
init -100 python:
# The frame containing the day planner.
style.dp_frame = Style(style.frame)
style.dp_vbox = Style(style.vbox)
style.dp_hbox = Style(style.hbox)
# The frame and vbox containing a single choice.
style.dp_choices = Style(style.default)
style.dp_choices_vbox = Style(style.vbox)
style.dp_choices.xalign = 0.5
# Buttons.
style.dp_choice_button = Style(style.button)
style.dp_choice_button_text = Style(style.button_text)
style.dp_done_button = Style(style.button)
style.dp_done_button_text = Style(style.button_text)
# Labels.
style.dp_label = Style(style.label)
style.dp_label_text = Style(style.label_text)
# The title of the done button.
dp_done_title = "Done Planning"
# A map from period name to the information we know about that
# period.
__periods = { }
# The period we're updating.
__period = None
class __Period(object):
def __init__(self, name, var):
self.name = name
self.var = var
self.acts = [ ]
def dp_period(name, var):
__periods[name] = store.__period = __Period(name, var)
__None = object()
def dp_choice(name, value=__None, enable="True", show="True"):
if not __period:
raise Exception("Choices must be part of a defined period.")
if value is __None:
value = name
__period.acts.append((name, value, enable, show))
def __set_noncurried(var, value):
setattr(store, var, value)
return True
__set = renpy.curry(__set_noncurried)
label day_planner(periods):
python hide:
renpy.choice_for_skipping()
label day_planner_repeat:
if renpy.has_label("dp_callback"):
call dp_callback
python hide:
ui.window(style=style.dp_frame)
ui.vbox(style=style.dp_vbox)
ui.hbox(style=style.dp_hbox)
can_continue = True
for p in periods:
if p not in __periods:
raise Exception("Period %r was never defined." % p)
ui.window(style=style.dp_choices)
ui.vbox(style=style.dp_choices_vbox)
p = __periods[p]
v = getattr(store, p.var)
layout.label(p.name, "dp")
valid_choice = False
for name, value, enable, show in p.acts:
show = eval(show)
enable = eval(enable)
selected = (v == value)
if show:
layout.button(
name,
"dp_choice",
clicked=__set(p.var, value),
selected=selected,
enabled=enable,
)
if show and enable and selected:
valid_choice = True
if not valid_choice:
can_continue = False
ui.close()
ui.close() # hbox.
layout.button(
dp_done_title,
"dp_done",
clicked=ui.returns(False),
enabled=can_continue)
ui.close() # vbox
if ui.interact():
jump day_planner_repeat
else:
return
-328
View File
@@ -1,328 +0,0 @@
# The Ren'Py/DSE event dispatcher. This file contains the code that
# actually supports the running of events. Specifically, it contains
# code that determines which events are available, which events can
# run, and to actually run the events that should be run during a
# given period.
# This isn't really intended to be user-changable.
init -100 python:
# A list of all of the events that the system knowns about,
# it's filtered to determine which events should run when.
all_events = [ ]
# The base class for events. When constructed, an event
# automatically adds itself to all_events.
#
# The first parameter for this is a unique name for the event,
# which is also used as the label that is called when the
# event executes.
#
# All other parameters are expressions. These expressions can
# be either strings, or objects having an eval method. Many
# interesting objects are given below.
#
# Keyword arguments are also kept on the object. Currently,
# there is one useful keyword argument, priority. This
# controls the order in which events are in the event list.
# (Events with lower priority number are evaluated first. If a
# priority is not specified, it's 100.)
class event(object):
def __repr__(self):
return '<event ' + self.name + '>'
def __init__(self, name, *args, **kwargs):
self.name = name
exprs = [ ]
for i in args:
if isinstance(i, basestring):
exprs.append(event.evaluate(i))
else:
exprs.append(i)
self.exprs = exprs
self.priority = kwargs.get('priority', 100)
all_events.append(self)
# Checks to see if this event is valid. It's called with
# a list of events that have already checked out to be
# True, and returns True if this event checks out.
def check(self, valid):
for i in self.exprs:
if not i.eval(self.name, valid):
return False
return True
def properties(self):
rv = { }
for i in self.exprs:
rv.update(i.properties())
return rv
# The base class for all of the event checks given below.
class event_check(object):
def properties(self):
return { }
def __invert__(self):
return event.false(self)
def __and__(self, other):
return event.and_op(self, other)
def __or__(self, other):
return event.or_op(self, other)
# This evaluates the expression given as an argument, and the
# returns true if it evaluates to true.
class evaluate(event_check):
def __init__(self, expr):
self.expr = expr
def eval(self, name, valid):
return eval(self.expr)
# If present as a condition to an event, an object of this
# type ensures that the event will only execute once.
class once(event_check):
def eval(self, name, valid):
return name not in events_executed
# Returns True if no event of higher priority can execute,
# and false otherwise. In general, solo events should be
# the lowest priority, and are run if nothing else is.
class solo(event_check):
def eval(self, name, valid):
# True if valid is empty.
return not valid
# Returns True if no event of higher priority can execute.
# This also prevents other events from executing.
class only(solo):
def properties(self):
return dict(only=True)
# Returns True if the given events have happend already,
# at any time in the game. False if at least one hasn't
# happened yet.
class happened(event_check):
def __init__(self, *events):
self.events = events
def eval(self, name, valid):
for i in self.events:
if i not in events_executed:
return False
return True
# Returns True probability of the time, where probability
# is a number between 0 and 1.
class random(event_check):
def __init__(self, probability):
self.probability = probability
def eval(self, name, valid):
return renpy.random.random() <= self.probability
# Chooses only one from the group.
class choose_one(event_check):
def __init__(self, group, group_count=1):
self.group = group
self.group_count = group_count
def eval(self, name, valid):
return True
def properties(self):
return dict(group=self.group,
group_count=self.group_count)
# Evaluates its argument, and returns true if it is false
# and vice-versa.
class false(event_check):
def __init__(self, cond):
self.cond = cond
def eval(self, name, valid):
return not self.cond.eval(name, valid)
# Handles the and operator.
class and_op(event_check):
def __init__(self, *args):
self.args = args
def eval(self, name, valid):
for i in self.args:
if not i.eval(name, valid):
return False
return True
# Handles the or operator.
class or_op(event_check):
def __init__(self, *args):
self.args = args
def eval(self, name, valid):
for i in self.args:
if i.eval(name, valid):
return True
return False
# Returns True if all of the events given as arguments have
# happened yesterday or earlier, or False otherwise.
class depends(event_check):
def __init__(self, *events):
self.events = events
def eval(self, name, valid):
for i in self.events:
if i not in events_executed_yesterday:
return False
return True
# The number of periods to skip.
skip_periods = 0
# This returns True if the current period should be skipped,
# or False if the current period should execute. If it returns
# True, it decrements skip_periods.
def check_skip_period():
global skip_periods
if skip_periods:
skip_periods -= 1
return True
else:
return False
def __events_init():
store.events_executed = { }
store.events_executed_yesterday = { }
config.start_callbacks.append(__events_init)
# This should called at the end of a (game) day, to let things
# like depends_yesterday to work.
label events_end_day:
$ skip_periods = 0
python hide:
# We can't skip between days.
skip_periods = 0
for k in events_executed:
events_executed_yesterday[k] = True
return
# This is called once per period, to determine, and then execute, the
# events that should be run for that period.
label events_run_period:
$ events = [ ]
python hide:
eobjs = [ ]
egroups = { }
eingroup = { }
for i in all_events:
if not i.check(eobjs):
continue
eobjs.append(i)
props = i.properties()
if 'group' in props:
group = props['group']
count = props['group_count']
egroups.setdefault(group, [ ]).extend([ i ] * count)
eingroup[i] = group
if 'only' in props:
break
echosen = { }
for k in egroups:
echosen[k] = renpy.random.choice(egroups[k])
for i in eobjs:
if i in eingroup and echosen[eingroup[i]] is not i:
continue
events.append(i.name)
while not check_skip_period() and events:
$ _event = events.pop(0)
$ events_executed[_event] = True
call expression _event from call_expression_event_1
return
# If this is jumped to, it will end the current period immediately,
# and return control to the main program.
label events_end_period:
$ skip_period = 1
return
# If this is jumped to, it will end the current period and skip
# the next period. Use this if, say, the user goes on a date that
# takes up two time slots.
label events_skip_period:
$ skip_period = 2
return
init 100:
python hide:
# Sort all events on priority.
all_events.sort(key=lambda i : i.priority)
python hide:
for i in all_events:
if not renpy.has_label(i.name):
raise Exception("'%s' is defined as an event somewhere in the game, but no label named '%s' was defined anywhere." % (i.name, i.name))
-767
View File
@@ -1,767 +0,0 @@
# This file contains the events that will be part of the game. It's
# expected that the user will add and remove events as appropriate
# for this game.
# Some characters that are used in events in the game.
init:
$ t = Character('Teacher')
$ gg = Character('Glasses Girl', color=(192, 255, 192, 255))
$ sg = Character('Sporty Girl', color=(255, 255, 192, 255))
$ bg = Character('Both Girls')
$ narrator = Character(' ')
# First up, we define some simple events for the various actions, that
# are run only if no higher-priority event is about to occur.
init:
$ event("class", "act == 'class'", event.only(), priority=200)
$ event("class_bad", "act == 'class'", priority=210)
$ event("cut1", "act == 'cut'", event.choose_one('cut'), priority=200)
$ event("cut2", "act == 'cut'", event.choose_one('cut'), priority=200)
$ event("study", "act == 'study'", event.solo(), priority=200)
$ event("hang", "act == 'hang'", event.solo(), priority=200)
$ event("exercise", "act == 'exercise'", event.solo(), priority=200)
$ event("play", "act == 'play'", event.solo(), priority=200)
label class:
"I make it to class just in time, and proceed to listen to the
teacher droning on about a wide range of topics, none of which
are remotely interesting."
return
# For test purposes only.
label class_bad:
"You shouldn't be seeing this."
"This is because class was declared with event.only(), which
should suspend processing of further events."
"This is really for testing purposes only."
return
label cut1:
"I cut class, and spend the morning goofing off instead."
$ intelligence -= 10
return
label cut2:
"I cut class, and spend the morning playing computer games."
return
label study:
"I head on down to the library, and start reading about the topics
I should have been reading about in class."
$ intelligence += 10
return
label hang:
"I spend the afternoon hanging out with my friends, killing
some time."
return
label exercise:
"I decide to go out for a run through the town, to keep myself in
shape."
$ strength += 10
return
label play:
"I pop a DVD into my video game console, and spend the evening
rolling small cities up into balls."
$ strength -= 10
return
# Below here are special events that are triggered when certain
# conditions are true.
# This is an introduction event, that runs once when we first go
# to class.
init:
$ event("introduction", "act == 'class'", event.once(), event.only())
label introduction:
"I run to school, and make it to my seat just as the bell
signalling the start of class rings."
t "Before we start, I have an announcement to make."
t "We will have two new students joining us. Girls, come on in."
"Two girls walk in, and stand in front of the class."
"They're twins."
"Identical twins."
"Identical black hair, and the same pretty face."
"Despite that, it's still fairly easy to tell them apart."
"The one on the left is wearing glasses."
"Not too thick, but enough to let me know she probably reads alot
of books."
"If I look a little closely, I can find another difference."
"The one on the right probably exercises a bit more."
"I can tell by the muscle tone in her legs."
"I realize that I'm staring at her legs, and quickly look up."
"Suddenly, I realize that she's been talking for all this town."
sg "... to this town. And we hope to be friends with all of you."
sg "Well, that's about it. Sis, do you have anything to say?"
"The girl with glasses pauses for a second, and then quickly says:"
gg "{size=-4}It's good to meet you all.{/size}"
"She stops, and goes back to not saying anything."
t "Well, if that's all, you can take your seats and we can start
the class."
"They do, and our teacher begins his lecture."
"I don't think anyone pays much attention to it, however."
return
# These are the events with glasses girl.
init:
# The glasses girl is studying in the library, but we do not
# talk to her.
#
#
$ event("gg_studying",
# This takes place when the action is 'study'.
"act == 'study'",
# This will only take place if no higher-priority
# event will occur.
event.solo(),
# This takes place at least one day after seeing the
# introduction event.
event.depends("introduction"),
# This takes priority over the study event.
priority=190)
# She asks to borrow our pen.
$ event("borrow_pen",
# This takes place when we go to study, and we have an int
# >= 50.
"act == 'study' and intelligence >= 50",
# It runs only once.
event.once(),
# It requires the introduction event to have run at least
# one day before.
event.depends("introduction"))
# After the pen, she smiles when she sees us.
$ event("gg_smiling", "act == 'study'",
event.solo(), event.depends("borrow_pen"),
priority = 180)
# The bookslide.
$ event("bookslide", "act == 'study' and intelligence == 100",
event.once(), event.depends("borrow_pen"))
# She makes us cookies.
$ event("cookies", "act == 'study'",
event.once(), event.depends("bookslide"))
# Her solo ending.
$ event("gg_confess", "act == 'class'",
event.once(), event.depends("cookies"))
label gg_studying:
"I head to the library, to get some studying done."
"The glasses girl is there, but she's busy reading a book, taking
notes as she does so."
"I decide not to disturb her, and instead start reading my own
book."
$ intelligence += 10
return
label borrow_pen:
"I head to the library, to get some studying done."
"The glasses girl is there, but she's busy reading a book."
"I decide not to disturb her, and instead start reading my own
book."
"Suddenly, I feel a tap on my shoulder."
"I look up, and see the glasses girl standing right next to me."
gg "Excuse me, but can I borrow your pen?"
gg "Mine ran out of ink."
"I dig through my bag, to find the pen I had stashed there."
"While I'm looking, I point out that she seems to come to the
library alot."
gg "Hm... I guess you're right."
gg "There's so much stuff here, and I want to know about it all."
gg "Surely, you must feel the same way, as you're here almost as
much as I am."
"I don't have the heart to tell her that I'm only here to study so
that I don't fail out."
"My hand brushes the pen, and I quickly pull it out and give it to
her."
gg "Thank you."
"She says, and she goes back to studying."
return
label gg_smiling:
"I head to the library, to get some studying done."
"The glasses girl is there, and smiles at me for a second before
turning back to her book."
"I decide not to disturb her, and instead start reading my own
book."
$ intelligence += 10
return
label bookslide:
"I head to the library, to get some studying done."
"The glasses girl is standing right by the entrance, putting a
book back into a bookcase containing science books."
"It looks quite old, and quite weak, as if it could break at any
time."
"Suddenly, I hear a loud crack come from the bookcase."
"Without thinking, I throw myself between the girl and the
bookcase, pushing her out of the way in the process."
"As the shelves fail one by one, I'm hit with large textbooks on
topics ranging from Astronomy to Zoology."
"She's safe, but I'm knocked off my feet by the falling books."
"Before the dust even settled, the girl with glasses realized what
happened and asked:"
gg "Are you alright?"
"I tell her that I am, all the while rubbing a bruise left by a
particularly large Physics book."
gg "You saved me."
"She points out. I shrug... I guess I did, but it's not like I'm a
hero or anything."
"She extends out her hand, I take it, and she helps me to get up."
gg "Wow... Um..."
"She doesn't know what to say."
"I suggest that we help clean up the mess, mostly to take her off
the spot."
"She agrees, and together we begin piling the books up into neat
piles."
return
label cookies:
"I head to the library, to get some studying done."
"The glasses girl is there, apparently waiting for me."
"She's holding a package in her hands."
gg "Here."
"She says, and she hands me the package."
"I take it from her, and open it."
"It contains fresh homemade cookies. Ginger snaps, I think."
gg "It's to thank you."
"She points out... She's probably not used to this. Especially
with guys."
"I take one of them, and stick it in my mouth."
"The taste is exquisite."
"It's perhaps one of the best cookies I've ever tasted."
"Of course it is. It's the only cookie I'd ever tasted that was
made for me by a beutiful girl."
"I tell her this... that it's delicious, not the girl part."
"But I do let slip that if I could eat these every day, I'd be the
happiest guy in the world."
"At this, she can only blush."
return
label gg_confess:
"I once again barely make it to class on time."
"I sit down, at my desk, and put some of my books into it."
"My hand brushes a folded sheet of paper, one I didn't remember
putting in there."
"It's a girl's handwriting... \"Meet me on the roof at lunch.\""
"That's all it says... no signature or anything."
"Lunch is a few hours away, but the time passes like a blur."
"It's all I can do to avoid racing up to the roof... but I give it
some time anyway."
"It wouldn't make sense for me to get there first."
"I let two minutes elapse before leaving the classroom, and then
slowly walk the flights of stairs up to the roof."
"Standing there, I find the glasses girl."
"She's holding what looks like a homemade lunch... big enough for
two."
"I look at it, then her, then remember what I had said after she
made me the cookies."
"Finally, I ask her... \"Does this mean?\""
"She nods. It's all the confirmation I need."
"I sit down next to my new girlfriend... and together we start
eating her lunch."
"I'm probably the happiest guy in the world."
"But I still have to find out her name."
".:. Ending 1."
$ renpy.full_restart()
init:
$ event("catchme", "act == 'exercise'",
event.depends('introduction'), event.once())
$ event("cantcatchme", "act == 'exercise'",
event.depends('catchme'), event.solo(), priority=190)
$ event("caughtme", "act == 'exercise' and strength >= 50",
event.depends('catchme'), event.once())
$ event("together", "act == 'exercise' and strength >= 50",
event.depends('caughtme'), event.solo(), priority=180)
$ event("apart", "act == 'exercise' and strength < 50",
event.depends('caughtme'), event.solo(), priority=180)
$ event("pothole", "act == 'exercise' and strength >= 100",
event.depends('caughtme'), event.once())
$ event("dontsee", "act == 'exercise'",
event.depends('pothole'), event.solo(), priority=170)
$ event("sg_confess", "act == 'class'",
event.depends('dontsee'), event.once())
label catchme:
"I decide to go out for a run, to keep myself in shape."
"As I'm running through the town, I see a girl."
"She's one of the twins who transferred into my class."
"She waves, and comes over to me."
sg "I didn't know you were a runner."
"I point out that I'm not really a runner... I just run a little
bit at a time."
"I ask her if she wants to run with me for a while."
sg "As if! You couldn't keep up with me."
"I point out that I probably can."
sg "Well, let's see."
"We set off running, but she quickly pulls past me."
sg "See? Well, maybe we can try it again when you're a bit
faster."
sg "Until then, later."
"Even though I'm jogging, she pulls away as if it is nothing."
return
label cantcatchme:
"I'm out running again, when the sporty girl catches up to me."
sg "Still at it?"
sg "Well, keep up the good work. One day you'll be as fast as me!"
sg "Well, maybe."
"She pulls out past me, and disappears into the distance. One day
I'll catch up to her."
$ strength += 10
return
label caughtme:
"I'm out running again, when the sporty girl catches up to me."
sg "Still at it?"
sg "Well, keep up the good work. One day you'll be as fast as me!"
sg "Well, maybe."
"Today, however, I'm not about to let this stand unchallenged."
"I break out into a run, and for the first time ever, I keep up
with her."
"We both run, neck and neck, me keeping up with her."
"Finally, she starts slowing down, and we come to a stop
together."
sg "Not bad."
"She pauses to catch her breath."
sg "You've been practicing, and it really shows."
sg "You've finally become fast enough to run with me."
"I nod, accepting her praise."
sg "We should do this more often... it's better to run with
someone else, to keep the challenge up."
"I nod again."
sg "Well, shall we go?"
"I nod a third time, and we take off, running side by side."
$ strength += 10
return
label together:
"I start running, and meet up with the sporty girl as she passes
the street in front of my house."
"She's still better than me... she's been running for over a mile
before reaching this point."
"Still, I can keep up with her for the rest of the run. And that's
not bad."
$ strength += 10
return
label apart:
"I start running, and meet up with the sporty girl as she passes
the street in front of my house."
"I try to keep up with her, but she pulls away from me."
"When she's a block away, she slows down and lets me catch up."
sg "It's your own fault... this is what you get for not
practicing."
"She's right, of course, and I redouble my efforts to try to keep
up with her."
$ strength += 10
return
label pothole:
"I start running, and meet up with the sporty girl as she passes
the street in front of my house."
"We run together for several miles."
"I think about how much I've improved in our time together."
"And, although she probably won't admit it, I think she's improved
as well."
"I guess a little friendly competition is usually for the best."
"A small yelp pulls me out of my thought."
sg "Ow!"
"The sporty girl sits down, grabbing her ankle."
"I ask her what happened."
sg "I... hit a... pothole. Twisted my... ankle."
"I wince in sympathy."
"We wait a bit. I'm not sure what to do."
"Finally, I ask her if she can walk on it."
"She tries for a bit, but then winces in pain."
sg "No, I don't think so."
"I realize that we can't stay here."
"And so, I crouch down and motion for her to climb up onto my
back."
sg "What are you doing?"
"I explain that she can't stay out in the middle of the street
forever, and she won't get any help until I can get her home."
"And the only way to do that is for me to carry her."
"She accepts this, and climbs up onto my back."
"She wraps her arms around my neck, and I place my hands
underneath her to make a seat."
"I stand up, and start carrying her home."
return
label dontsee:
"I go running again."
"But this time, I don't see the sporty girl."
"I finish the course that we usually take, but it's not the same
without her."
return
label sg_confess:
"I once again barely make it to class on time."
"I sit down, at my desk, and put some of my books into it."
"My hand brushes a folded sheet of paper, one I didn't remember
putting in there."
"It's a girl's handwriting... \"Meet me on the roof at lunch.\""
"That's all it says... no signature or anything."
"Lunch is a few hours away, but the time passes like a blur."
"It's all I can do to avoid racing up to the roof... but I give it
some time anyway."
"It wouldn't make sense for me to get there first."
"I let two minutes elapse before leaving the classroom, and then
slowly walk the flights of stairs up to the roof."
"Standing there, I find the sporty girl."
"She's leaning on a crutch."
"I look at it for a second, and she notices that."
sg "I went to the doctor, and he gave me this."
sg "Looks like we won't be running together for a while."
"I nod."
sg "And that's why I asked you here."
sg "I couldn't stand the though of not seeing you for a few
weeks."
"I search my feelings, and realize I feel the same way."
sg "So I thought..."
"She doesn't say it... she doesn't need to."
"We both know how we feel about each other."
"And with that, we went from being running partners to partners in
a deeper sense."
"Now if I only knew her name..."
".:. Ending 2."
$ renpy.full_restart()
init:
# This needs to be higher-priority than either girl's ending.
$ event('both_confess', 'act == "class"',
event.depends("dontsee"), event.depends("cookies"),
event.once(), priority = 50)
label both_confess:
"I once again barely make it to class on time."
"I sit down, at my desk, and put some of my books into it."
"My hand brushes a folded sheet of paper, then another."
"I take the first one out, and read it."
"It's a girl's handwriting... \"Meet me on the roof at lunch.\""
"That's all it says... no signature or anything."
"I take a look at the second one, and it says the same thing."
"Sure, the handwriting is a little different, but..."
"Lunch is a few hours away, but the time passes like a blur."
"It's all I can do to avoid racing up to the roof... but I give it
some time anyway."
"I let two minutes elapse before leaving the classroom, and then
slowly walk the flights of stairs up to the roof."
"Standing there are the twins."
"Both of them."
"As in, the two notes came from the two twins."
"I ask them what they are doing there, feigning ignorance."
sg "Well, I invited you up here to confess to you..."
sg "... and then I found out that my sister here was about to do
the same thing."
gg "{size=-4}...I was...{/size}"
sg "When we found out, we were quite shocked, but after comparing
notes, we decide what we're going to do..."
"I quickly run through the possibilities in my head."
"The best cases involve them never talking to me again."
"The worst cases involve me being thrown off the roof."
bg "We're going to share you!"
"Eh?"
"That wasn't something I considered."
"Each of the girls grabs onto one of my arms."
"I don't know what the future holds for us..."
"... and I don't know if this will work out."
"But I do know that one day I will work up the courage to find out
their names."
".:. Ending 3."
$ renpy.full_restart()
-163
View File
@@ -1,163 +0,0 @@
# This is the main program. This can be changed quite a bit to
# customize it for your program... But remember what you do, so you
# can integrate with a new version of DSE when it comes out.
# Set up a default theme.
init python:
register_stat("Strength", "strength", 10, 100)
register_stat("Intelligence", "intelligence", 10, 100)
dp_period("Morning", "morning_act")
dp_choice("Attend Class", "class")
dp_choice("Cut Class", "cut")
dp_period("Afternoon", "afternoon_act")
dp_choice("Study", "study")
dp_choice("Hang Out", "hang")
dp_period("Evening", "evening_act")
dp_choice("Exercise", "exercise")
dp_choice("Play Games", "play")
# This is the entry point into the game.
label start:
# Initialize the default values of some of the variables used in
# the game.
$ day = 0
# Show a default background.
scene black
# The script here is run before any event.
"In case you're just tuning in, here's the story of my life to
date."
"I'm a guy in the second year of high school."
"I'm not good at sports or school or even something as simple as
remembering peoples names."
"In short, I am your usual random loser guy."
"And this is my story..."
# We jump to day to start the first day.
jump day
# This is the label that is jumped to at the start of a day.
label day:
# Increment the day it is.
$ day += 1
# We may also want to compute the name for the day here, but
# right now we don't bother.
"It's day %(day)d."
# Here, we want to set up some of the default values for the
# day planner. In a more complicated game, we would probably
# want to add and remove choices from the dp_ variables
# (especially dp_period_acts) to reflect the choices the
# user has available to him.
$ morning_act = None
$ afternoon_act = None
$ evening_act = None
# Now, we call the day planner, which may set the act variables
# to new values. We call it with a list of periods that we want
# to compute the values for.
call day_planner(["Morning", "Afternoon", "Evening"])
# We process each of the three periods of the day, in turn.
label morning:
# Tell the user what period it is.
centered "Morning"
# Set these variables to appropriate values, so they can be
# picked up by the expression in the various events defined below.
$ period = "morning"
$ act = morning_act
# Ensure that the stats are in the proper range.
$ normalize_stats()
# Execute the events for the morning.
call events_run_period
# That's it for the morning, so we fall through to the
# afternoon.
label afternoon:
# It's possible that we will be skipping the afternoon, if one
# of the events in the morning jumped to skip_next_period. If
# so, we should skip the afternoon.
if check_skip_period():
jump evening
# The rest of this is the same as for the morning.
centered "Afternoon"
$ period = "afternoon"
$ act = afternoon_act
$ normalize_stats()
call events_run_period
label evening:
# The evening is the same as the afternoon.
if check_skip_period():
jump night
centered "Evening"
$ period = "evening"
$ act = evening_act
$ normalize_stats()
call events_run_period
label night:
# This is now the end of the day, and not a period in which
# events can be run. We put some boilerplate end-of-day text
# in here.
centered "Night"
"It's getting late, so I decide to go to sleep."
# We call events_end_day to let it know that the day is done.
call events_end_day
# And we jump back to day to start the next day. This goes
# on forever, until an event ends the game.
jump day
# This is a callback that is called by the day planner. One of the
# uses of this is to show the statistics to the user.
label dp_callback:
# Add in a line of dialogue asking the question that's on
# everybody's mind.
$ narrator("What should I do today?", interact=False)
$ display_stats()
return
-88
View File
@@ -1,88 +0,0 @@
init -100 python:
style.stats_frame = Style(style.frame)
style.stats_vbox = Style(style.vbox)
style.stats_label = Style(style.label)
style.stats_label_text = Style(style.label_text)
style.stat_side = Style(style.default)
style.stat_label = Style(style.label)
style.stat_label_text = Style(style.label_text)
style.stat_bar = Style(style.bar)
style.stat_value_label = Style(style.label)
style.stat_value_label_text = Style(style.label_text)
__dse_stats = [ ]
class __Stat(object):
def __init__(self, name, var, default, max):
self.name = name
self.var = var
self.default = default
self.max = max
def __init_stats():
for s in __dse_stats:
setattr(store, s.var, s.default)
config.start_callbacks.append(__init_stats)
def register_stat(name, var, default, max):
__dse_stats.append(__Stat(name, var, default, max))
def normalize_stats():
for s in __dse_stats:
v = getattr(store, s.var)
if v > s.max:
v = s.max
if v < 0:
v = 0
setattr(store, s.var, v)
def display_stats(name=True, bar=True, value=True, max=True):
normalize_stats()
ui.window(style=style.stats_frame)
ui.vbox(style=style.stats_vbox)
layout.label("Statistics", "stats")
for s in __dse_stats:
v = getattr(store, s.var)
ui.side(['l', 'r', 'c'], style=style.stat_side)
if name:
layout.label(s.name, "stat")
else:
ui.null()
if value and max:
layout.label("%d/%d" % (v, s.max), "stat_value")
elif value:
layout.label("%d" % (v,), "stat_value")
elif max:
layout.label("%d" % (max,), "stat_value")
else:
ui.null()
if bar:
ui.bar(s.max, v, style=style.stat_bar)
else:
ui.null()
ui.close()
ui.close()
-49
View File
@@ -1,49 +0,0 @@
# This file contains styles for the day planner.
init python:
# Place the day planner.
style.dp_frame.ypos = 120
style.dp_frame.yanchor = 0.0
style.dp_frame.xalign = 0.5
# Spacing betweeen the choices and the done button.
style.dp_vbox.box_spacing = 20
# Spacing between the choice columns.
style.dp_hbox.box_spacing = 20
# Center the choices.
style.dp_choices.xalign = 0.5
# Center the label of each choice.
style.dp_label.xalign = 0.5
style.dp_label_text.text_align = 0.5
# Make each choice button the same size, and centered.
style.dp_choice_button.size_group = "dp_choice"
style.dp_choice_button.xalign = 0.5
# Center the done button.
style.dp_done_button.xalign = 0.5
# Put a margin on the stats frame.
style.stats_frame.xmargin = 10
style.stats_frame.ymargin = 5
# Space between the label and the stats.
style.stats_vbox.box_first_spacing = 10
# Put blank space around each stat name, and right-justify.
style.stat_label.xminimum = 140
style.stat_label_text.xalign = 1.0
style.stat_label.xmargin = 5
# Put blank space around each stat value, and right-justify.
style.stat_value_label.xminimum = 100
style.stat_value_label_text.xalign = 1.0
# Center the stat bar vertically.
style.stat_bar.yalign = 0.5
-2
View File
@@ -1,2 +0,0 @@
description = "A game that demonstrates the use of the dating-sim engine. A non-graphical proof of concept."
ro = True
+83 -79
View File
@@ -42,86 +42,90 @@ display: none;
<p><a name="Basic_Help" id="Basic_Help"></a></p>
<h2><span class="editsection">[<a href="/w/index.php?title=renpy/Help&amp;action=edit&amp;section=1" title="Edit section: Basic Help">edit</a>]</span> <span class="mw-headline">Basic Help</span></h2>
<p>To advance through the game, <tt>left-click</tt> or press the <tt>space</tt> or <tt>enter</tt> keys. When at a menu, <tt>left-click</tt> to make a choice, or use the arrow keys to select a choice and <tt>enter</tt> to activate it.</p>
<p><a name="Game_Menu" id="Game_Menu"></a></p>
<h3><span class="editsection">[<a href="/w/index.php?title=renpy/Help&amp;action=edit&amp;section=2" title="Edit section: Game Menu">edit</a>]</span> <span class="mw-headline">Game Menu</span></h3>
<p>When playing a game, <tt>right-click</tt> or press the <tt>escape</tt> key to enter the game menu. The game menu gives the following choices:</p>
<dl>
<dt>Return</dt>
<dd>Returns to the game.</dd>
<dt>Save Game</dt>
<dd>Allows you to save a game by clicking on a save slot.</dd>
<dt>Load Game</dt>
<dd>Allows you to load a game by clicking on a save slot. Clicking on "Auto" accesses the automatic save slots.</dd>
<dt>Preferences</dt>
<p><a name="Basic_Help" id="Basic_Help"></a></p>
<h2><span class="editsection">[<a href="/w/index.php?title=renpy/Help&amp;action=edit&amp;section=1" title="Edit section: Basic Help">edit</a>]</span> <span class="mw-headline">Basic Help</span></h2>
<p>To advance through the game, <tt>left-click</tt> or press the <tt>space</tt> or <tt>enter</tt> keys. When at a menu, <tt>left-click</tt> to make a choice, or use the arrow keys to select a choice and <tt>enter</tt> to activate it.</p>
<p><a name="Game_Menu" id="Game_Menu"></a></p>
<h3><span class="editsection">[<a href="/w/index.php?title=renpy/Help&amp;action=edit&amp;section=2" title="Edit section: Game Menu">edit</a>]</span> <span class="mw-headline">Game Menu</span></h3>
<p>When playing a game, <tt>right-click</tt> or press the <tt>escape</tt> key to enter the game menu. The game menu gives the following choices:</p>
<dl>
<dt>Return</dt>
<dd>Returns to the game.</dd>
<dt>Save Game</dt>
<dd>Allows you to save a game by clicking on a save slot.</dd>
<dt>Load Game</dt>
<dd>Allows you to load a game by clicking on a save slot. Clicking on "Auto" accesses the automatic save slots.</dd>
<dt>Preferences</dt>
<dd>Changes the game preferences (options/configuration):
<dl>
<dt>Display</dt>
<dd>Switches between fullscreen and windowed mode.</dd>
<dt>Transitions</dt>
<dd>Controls the display of transitions between game screens.</dd>
<dt>Text Speed</dt>
<dd>Controls the rate at which text displays. The further to the right this slider is, the faster the text will display. All the way to the right causes text to be shown instantly.</dd>
<dt>Joystick</dt>
<dd>Lets you control the game using a joystick.</dd>
<dt>Skip</dt>
<dd>Chooses between skipping messages that have been already seen (in any play through the game), and skipping all messages.</dd>
<dt>Begin Skipping</dt>
<dd>Returns to the game, while skipping.</dd>
<dt>After Choices</dt>
<dd>Controls if skipping stops upon reaching a menu.</dd>
<dt>Auto-Forward Time</dt>
<dd>Controls automatic advance. The further to the left this slider is, the shorter the amount of time before the game advances. All the way to the right means text will never auto-forward.</dd>
<dt>Music, Sound, and Voice Volume</dt>
<dd>Controls the volume of the Music, Sound effect, and Voice channels, respectively. The further to the right these are, the louder the volume.</dd>
</dl>
</dd>
</dl>
<dl>
<dt>Main Menu</dt>
<dd>Returns to the main menu, ending the current game.</dd>
<dt>Help</dt>
<dd>Shows this help screen.</dd>
<dt>Quit</dt>
<dd>Exits the game; the game will be closed and ended.</dd>
</dl>
<p><a name="Key_and_Mouse_Bindings" id="Key_and_Mouse_Bindings"></a></p>
<h3><span class="editsection">[<a href="/w/index.php?title=renpy/Help&amp;action=edit&amp;section=3" title="Edit section: Key and Mouse Bindings">edit</a>]</span> <span class="mw-headline">Key and Mouse Bindings</span></h3>
<dl>
<dt>Left-click, Enter</dt>
<dd>Advances through the game, activates menu choices, buttons, and sliders.</dd>
<dt>Space</dt>
<dd>Advances through the game, but does not activate choices.</dd>
<dt>Arrow Keys</dt>
<dd>Selects menu choices, buttons, and sliders.</dd>
<dt>Ctrl</dt>
<dd>Causes skipping to occur while the ctrl key is held down.</dd>
<dt>Tab</dt>
<dd>Toggles skipping, causing it to occur until tab is pressed again.</dd>
<dt>Mousewheel-Up, PageUp</dt>
<dd>Causes rollback to occur. Rollback reverses the game back in time, showing prior text and even allowing menu choices to be changed.</dd>
<dt>Mousewheel-Down, PageDown</dt>
<dd>Causes rollforward to occur, cancelling out a previous rollback.</dd>
<dt>Right-click, Escape</dt>
<dd>Enters the game menu. When in the game menu, returns to the game.</dd>
<dt>Middle-click, H</dt>
<dd>Hides the text window and other transient displays.</dd>
<dt>F</dt>
<dd>Toggles fullscreen mode</dd>
<dt>S</dt>
<dd>Takes a screenshot, saving it in a file named screenshotxxxx.png, where xxxx is a serial number.</dd>
<dt>Alt-H, Command-H</dt>
<dd>Hides (iconifies) the window.</dd>
<dt>Alt-F4, Command-Q</dt>
<dd>Quits the game.</dd>
<dt>Delete</dt>
<dd>When a save slot is selected, deletes that save slot.</dd>
</dl>
<p><a name="Legal_Notice" id="Legal_Notice"></a></p>
<h2><span class="editsection">[<a href="/w/index.php?title=renpy/Help&amp;action=edit&amp;section=4" title="Edit section: Legal Notice">edit</a>]</span> <span class="mw-headline">Legal Notice</span></h2>
<p>This game uses source code from a number of open source projects. For a list, and a location where the source code can be downloaded from, please view the LICENSE.txt file in the renpy directory, or visit <a href="http://www.renpy.org/wiki/renpy/License" class="external free" title="http://www.renpy.org/wiki/renpy/License" rel="nofollow">http://www.renpy.org/wiki/renpy/License</a> .</p>
<dl>
<dt>Display</dt>
<dd>Switches between fullscreen and windowed mode.</dd>
<dt>Transitions</dt>
<dd>Controls the display of transitions between game screens.</dd>
<dt>Text Speed</dt>
<dd>Controls the rate at which text displays. The further to the right this slider is, the faster the text will display. All the way to the right causes text to be shown instantly.</dd>
<dt>Joystick</dt>
<dd>Lets you control the game using a joystick.</dd>
<dt>Skip</dt>
<dd>Chooses between skipping messages that have been already seen (in any play through the game), and skipping all messages.</dd>
<dt>Begin Skipping</dt>
<dd>Returns to the game, while skipping.</dd>
<dt>After Choices</dt>
<dd>Controls if skipping stops upon reaching a menu.</dd>
<dt>Auto-Forward Time</dt>
<dd>Controls automatic advance. The further to the left this slider is, the shorter the amount of time before the game advances. All the way to the right means text will never auto-forward.</dd>
<dt>Music, Sound, and Voice Volume</dt>
<dd>Controls the volume of the Music, Sound effect, and Voice channels, respectively. The further to the right these are, the louder the volume.</dd>
</dl>
</dd>
</dl>
<dl>
<dt>Main Menu</dt>
<dd>Returns to the main menu, ending the current game.</dd>
<dt>Help</dt>
<dd>Shows this help screen.</dd>
<dt>Quit</dt>
<dd>Exits the game; the game will be closed and ended.</dd>
</dl>
<p><a name="Key_and_Mouse_Bindings" id="Key_and_Mouse_Bindings"></a></p>
<h3><span class="editsection">[<a href="/w/index.php?title=renpy/Help&amp;action=edit&amp;section=3" title="Edit section: Key and Mouse Bindings">edit</a>]</span> <span class="mw-headline">Key and Mouse Bindings</span></h3>
<dl>
<dt>Left-click, Enter</dt>
<dd>Advances through the game, activates menu choices, buttons, and sliders.</dd>
<dt>Space</dt>
<dd>Advances through the game, but does not activate choices.</dd>
<dt>Arrow Keys</dt>
<dd>Selects menu choices, buttons, and sliders.</dd>
<dt>Ctrl</dt>
<dd>Causes skipping to occur while the ctrl key is held down.</dd>
<dt>Tab</dt>
<dd>Toggles skipping, causing it to occur until tab is pressed again.</dd>
<dt>Mousewheel-Up, PageUp</dt>
<dd>Causes rollback to occur. Rollback reverses the game back in time, showing prior text and even allowing menu choices to be changed.</dd>
<dt>Mousewheel-Down, PageDown</dt>
<dd>Causes rollforward to occur, cancelling out a previous rollback.</dd>
<dt>Right-click, Escape</dt>
<dd>Enters the game menu. When in the game menu, returns to the game.</dd>
<dt>Middle-click, H</dt>
<dd>Hides the text window and other transient displays.</dd>
<dt>F</dt>
<dd>Toggles fullscreen mode</dd>
<dt>S</dt>
<dd>Takes a screenshot, saving it in a file named screenshotxxxx.png, where xxxx is a serial number.</dd>
<dt>Alt-M, Command-H</dt>
<dd>Hides (iconifies) the window.</dd>
<dt>Alt-F4, Command-Q</dt>
<dd>Quits the game.</dd>
<dt>Delete</dt>
<dd>When a save slot is selected, deletes that save slot.</dd>
<dt>v</dt>
<dd>Toggles self-voicing mode, which reads text to the user using an os-supplied
speech synthesizer. For more information, please read the <a href="http://www.renpy.org/dev-doc/html/self_voicing.html">self-voicing</a>
documentation.</dd>
</dl>
<p><a name="Legal_Notice" id="Legal_Notice"></a></p>
<h2><span class="editsection">[<a href="/w/index.php?title=renpy/Help&amp;action=edit&amp;section=4" title="Edit section: Legal Notice">edit</a>]</span> <span class="mw-headline">Legal Notice</span></h2>
<p>This game uses source code from a number of open source projects. For a list, and a location where the source code can be downloaded from, please view the LICENSE.txt file in the renpy directory, or visit <a href="http://www.renpy.org/wiki/renpy/License" class="external free" title="http://www.renpy.org/wiki/renpy/License" rel="nofollow">http://www.renpy.org/wiki/renpy/License</a> .</p>
</body>
Binary file not shown.
+4
View File
@@ -0,0 +1,4 @@
import renpy
# Do nothing when the editor is invoked.
Editor = renpy.editor.Editor
-6
View File
@@ -1,6 +0,0 @@
# Name: None
# Version: 1
# Description: Disables the automatic launching of an editor.
config.editor = None
config.editor_transient = None
+4
View File
@@ -0,0 +1,4 @@
import renpy
# Pass the file off to the system editor (as determined by file associations).
Editor = renpy.editor.SystemEditor
-177
View File
@@ -1,177 +0,0 @@
init python:
import renpy.tools.archiver as archiver
import os
import os.path
import fnmatch
label archiver:
python hide:
# Get the options
name = project.info.get('archive_name', "data")
include = project.info.get('archive_include', "*.png *.gif *.jpg")
exclude = project.info.get('archive_exclude', "presplash.png")
# Allow the user to set the options.
while True:
set_tooltip("")
screen()
ui.vbox()
title(_(u"Archiver"))
text(_(u"The archiver allows you to obfuscate your game by including files in an archive file."))
ui.null(height=15)
text_variable(_(u"Archive Name:"), name, "name",
_(u"The name of the archive to create."))
text_variable(_(u"Include Patterns:"), include, "include",
_(u"Files matching these patterns are included in the archive."))
text_variable(_(u"Exclude Patterns:"), exclude, "exclude",
_(u"Files matching these patterns are excluded from the archive."))
ui.null(height=15)
button(_(u"Archive"), ui.returns("archive"), _(u"Build the archive."))
button(_(u"Cancel"), ui.jumps("top"), "")
ui.close()
act = interact()
if act == "name":
name = input(
_(u"Archive Name"),
_(u"The name of the archive file to create, without the .rpa extension.\n\nThe \"data\" archive is loaded automatically. Other archives must be added to config.archives."),
name)
elif act == "include":
include = input(
_(u"Include Patterns"),
_(u"This is a space-separated list of file patterns. Files matching these patterns are added to the archive.\n\nAsterisks (*) can be used as a wildcard."),
include)
elif act == "exclude":
exclude = input(
_(u"Include Patterns"),
_(u"This is a space-separated list of file patterns. Files matching these patterns are excluded from the archive. If a file is matched by both an exclude and include pattern, the exclude takes precedence.\n\nAsterisks (*) can be used as a wildcard."),
exclude)
elif act == "archive":
break
# Store the options.
project.info["archive_name"] = name
project.info["archive_include"] = include
project.info["archive_exclude"] = exclude
project.save()
# Break up the extension lists.
include = [ i.strip() for i in include.split() ]
exclude = [ i.strip() for i in exclude.split() ]
# Get the gamedir and the archived dir.
gamedir = os.path.join(project.path, "game")
archived = os.path.join(project.path, "archived")
# The prefix of the archive file.
prefix = os.path.join(gamedir, name)
archived_files = set()
files = [ ]
# Choose files to archive.
set_tooltip("")
info(
_(u"Scanning Files..."),
"")
for bdir in (gamedir, archived):
for dirname, dirs, filenames in os.walk(bdir):
dirs[:] = [ i for i in dirs if not i[0] == '.' ]
for fn in filenames:
fullfn = dirname + "/" + fn
shortfn = fullfn[len(bdir)+1:]
if fn[0] == ".":
continue
if shortfn in archived_files:
continue
should_archive = False
for i in include:
if fnmatch.fnmatch(fn, i):
should_archive = True
for i in exclude:
if fnmatch.fnmatch(fn, i):
should_archive = False
if not should_archive:
continue
files.append((fullfn, shortfn))
archived_files.add(shortfn)
if not files:
error(_(u"The patterns did not match any files, so no archive was created."))
# Actually archiving files.
info(_(u"Archiving Files..."), "")
archiver.archive(prefix, files)
# Move files out of the way.
for fullfn, shortfn in files:
afn = archived + "/" + shortfn
if fullfn == afn:
continue
try:
os.makedirs(os.path.dirname(afn))
except:
pass
try:
os.rename(fullfn, afn)
except:
os.rename(afn, afn + ".old")
os.rename(fullfn, afn)
os.unlink(afn + ".old")
# Report success.
screen()
ui.vbox()
title(_(u"Success"))
text(_(u"The files have been added to the archive, and moved into the \"archived\" directory. Future runs of the archiver will archive files in both the \"game\" and \"archived\" directories."))
ui.null(height=20)
button(_(u"Return"), ui.jumps("top"), None)
ui.close()
interact()
-326
View File
@@ -1,326 +0,0 @@
init python:
import codecs
import re
import sys
##########################################################################
# Code to update options.rpy
def list_logical_lines(filename):
"""
This reads in filename, and turns it into a list of logical
lines.
"""
f = codecs.open(filename, "rb", "utf-8")
data = f.read()
f.close()
# The result.
rv = []
# The current position we're looking at in the buffer.
pos = 0
# Looping over the lines in the file.
while pos < len(data):
# The line that we're building up.
line = ""
# The number of open parenthesis there are right now.
parendepth = 0
# Looping over the characters in a single logical line.
while pos < len(data):
c = data[pos]
if c == '\n' and not parendepth:
rv.append(line)
pos += 1
# This helps out error checking.
line = ""
break
# Backslash/newline.
if c == "\\" and data[pos+1] == "\n":
pos += 2
line += "\\\n"
continue
# Parenthesis.
if c in ('(', '[', '{'):
parendepth += 1
if c in ('}', ']', ')') and parendepth:
parendepth -= 1
# Comments.
if c == '#':
while data[pos] != '\n':
line += data[pos]
pos += 1
continue
# Strings.
if c in ('"', "'", "`"):
delim = c
line += c
pos += 1
escape = False
while pos < len(data):
c = data[pos]
if escape:
escape = False
pos += 1
line += c
continue
if c == delim:
pos += 1
line += c
break
if c == '\\':
escape = True
line += c
pos += 1
continue
continue
line += c
pos += 1
if line:
rv.append(line)
return rv
def switch_theme(name):
"""
Switches the theme of the current project to the named theme.
"""
theme_functions = set(i[1] for i in themes)
td = theme_data[name].copy()
td["name"] = name
# Did we change the file at all?
changed = False
filename = os.path.join(project.gamedir, "options.rpy")
out = codecs.open(filename + ".new", "wb", "utf-8")
for l in list_logical_lines(filename):
m = re.match(r' theme.(\w+)\(', l)
if m:
if m.group(1) in theme_functions:
l = theme_templates[td["theme"]] % td
changed = True
out.write(l + "\n")
out.close()
if changed:
try:
os.unlink(filename + ".bak")
except:
pass
os.rename(filename, filename + ".bak")
os.rename(filename + ".new", filename)
else:
os.unlink(filename + ".new")
error(_(u"Could not modify options.rpy. Perhaps it was changed too much."))
set_tooltip(_(u"Theme changed to %s.") % name)
renpy.jump("top")
curried_switch_theme = renpy.curry(switch_theme)
##########################################################################
# Code that handles display.
current_theme = None
def show_theme(name, target):
"""
Changes from the current theme to the roundrect theme named
`name`.
"""
if current_theme == name:
return
store.current_theme = name
td = theme_data[name].copy()
kind = td["theme"]
del td["theme"]
if kind == "roundrect":
td["rounded_window"] = False
renpy.style.restore(style_backup)
getattr(theme, kind)(**td)
customize_styles()
renpy.style.rebuild()
renpy.jump(target)
curried_show_theme = renpy.curry(show_theme)
def theme_demo():
# The sample area, that shows what the theme looks like.
ui.window(style='default', background="#444", xpadding=1, ypadding=1)
ui.window(style='gm_root', xpadding=5, ypadding=5)
ui.vbox(5)
# Display Preference.
ui.window(style=style.prefs_pref_frame)
ui.vbox(style=style.prefs_pref_box)
ui.hbox(style=style.prefs_pref_choicebox)
layout.label(_(u"Display"), "prefs")
layout.button(_(u"Window"), "prefs", clicked=does_nothing, selected=True)
layout.button(_(u"Fullscreen"), "prefs", clicked=does_nothing, selected=False)
layout.button(_(u"Planetarium"), "prefs", clicked=None, selected=False)
ui.close()
ui.close()
# Volume Preference
ui.window(style=style.prefs_pref_frame)
ui.vbox(style=style.prefs_pref_box)
layout.label(_(u"Music Volume"), "prefs")
ui.vbox(style=style.prefs_volume_box)
ui.bar(128,
92,
changed=does_nothing,
style=style.prefs_volume_slider)
layout.button(_(u"Test"), "soundtest", clicked=does_nothing)
ui.close()
ui.close()
ui.close() # vbox
# Used to have buttons not do anything.
def does_nothing(*args):
return
label choose_theme:
python:
if not os.path.exists(os.path.join(project.gamedir, "options.rpy")):
error(_(u"The options.rpy file does not exist in the game directory, so this launcher cannot change the theme."))
current_theme = None
theme_adjustment = ui.adjustment()
label repeat_choose_theme:
python hide:
tip = _(u"Themes control the basic look of interface elements. You'll be able to pick a color scheme next.")
screen()
ui.vbox()
title(_(u"Choose Theme"))
ui.grid(2, 1, padding=10, xfill=True)
# The scroll area, that lets the user pick a theme.
scrolled('top', theme_adjustment)
ui.vbox()
for name, function, exemplar in themes:
button(name,
ui.returns(function),
"",
hovered=curried_show_theme(exemplar, "repeat_choose_theme"),
unhovered=does_nothing)
ui.close() # vbox
ui.close() # scrolled
theme_demo()
ui.close() # grid
ui.close() # vbox
set_tooltip(tip)
store.theme_function = interact()
label choose_color_scheme:
python:
current_theme = None
theme_adjustment = ui.adjustment()
label repeat_choose_color_scheme:
python hide:
tip = _(u"Please choose a color scheme for your project.")
themes = [ k for k,v in theme_data.iteritems() if v["theme"] == theme_function ]
themes.sort()
screen()
ui.vbox()
title(_(u"Choose Color Scheme"))
ui.grid(2, 1, padding=10, xfill=True)
# The scroll area, that lets the user pick a theme.
scrolled('choose_theme', theme_adjustment)
ui.vbox()
for i in themes:
button(i,
curried_switch_theme(i),
"",
hovered=curried_show_theme(i, "repeat_choose_color_scheme"),
unhovered=does_nothing)
ui.close() # vbox
ui.close() # scrolled
theme_demo()
ui.close() # grid
ui.close() # vbox
set_tooltip(tip)
interact()
-554
View File
@@ -1,554 +0,0 @@
# This file contains the code needed to build a Ren'Py distribution.
init python:
import os
import os.path
import zipfile
import tarfile
import time
import sys
import zlib
zlib.Z_DEFAULT_COMPRESSION = 9
import pefile
# These are files that are ignored wherever they are found in a
# distribution.
ignored_files = (
"thumbs.db",
"traceback.txt",
"errors.txt",
"saves"
)
# These are files (and directories) that are ignored when found in
# the root directory of the distribution.
root_ignored_files = (
"common",
"renpy",
"renpy.code",
"python23.dll",
"python24.dll",
"python25.dll",
"msvcr71.dll",
"lib",
"iliad-icon.png",
"manifest.xml",
"icon.ico",
"icon.icns",
"launcherinfo.py",
"archived",
)
# Extensions that should be made executable.
executable_extensions = (
"MacOS",
"so",
"dylib",
".sh",
"python",
"python.real",
)
def tree(
src,
dest,
exclude_suffix=[ ".pyc", "~", ".bak" ],
exclude_prefix=[ "#", "." ],
exclude_files = set(ignored_files),
root_exclude_prefix = [ ],
root_exclude_suffix = [ ".py", ".sh", ".app" ],
root_exclude_files = set(root_ignored_files),
root=False):
"""
Returns a list of source-filename, destination-filename pairs.
"""
if dest[0] != "/":
raise Exception("Destination must begin with /: %r" % dest)
src = src.rstrip('/')
dest = dest.rstrip('/')
def include(fn, is_root):
"""
Returns True if the file should be included in the list of
files we are copying.
"""
for i in exclude_suffix:
if fn.endswith(i):
return False
for i in exclude_prefix:
if fn.startswith(i):
return False
if fn in exclude_files:
return False
if not root or not is_root:
return True
for i in root_exclude_suffix:
if fn.endswith(i):
return False
for i in root_exclude_prefix:
if fn.startswith(i):
return False
if fn in root_exclude_files:
return False
return True
rv = [ ]
# Walk the tree, including what is necessary.
for srcdir, dirs, files in os.walk(src):
is_root = (srcdir == src)
srcdir += "/"
destdir = dest + srcdir[len(src):]
destdir.replace("\\", "/")
rv.append((srcdir, destdir))
for fn in files:
if not include(fn, is_root):
continue
sfn = srcdir + fn
dfn = destdir + fn
rv.append((sfn, dfn))
dirs[:] = [ i for i in dirs if include(i, is_root) ]
rv = [ (a.replace("\\", "/"), b.replace("\\", "/")) for a, b in rv ]
return rv
def make_zip(t, filename, files, file_data):
"""
This creates `filename`.zip, containing `files`, placed in the
`filename` directory. `file_data` is a map from source file to
replacement data.
"""
files.sort(key=lambda a : a[1])
progress_len = len(files)
fn = os.path.join(os.path.dirname(project.path), filename)
zf = zipfile.ZipFile(fn + ".zip", "w", zipfile.ZIP_DEFLATED)
for i, (fn, an) in enumerate(files):
progress(t, progress_len, i)
if os.path.isdir(fn):
continue
zi = zipfile.ZipInfo(filename + an)
s = os.stat(fn)
zi.date_time = time.gmtime(s.st_mtime)[:6]
zi.compress_type = zipfile.ZIP_DEFLATED
zi.create_system = 3
for i in executable_extensions:
if os.path.dirname(fn).endswith(i) or fn.endswith(i):
zi.external_attr = long(0100777) << 16
break
else:
zi.external_attr = long(0100666) << 16
if fn in file_data:
data = file_data[fn]
else:
data = file(fn, "rb").read()
zf.writestr(zi, data)
zf.close()
def make_tar(t, filename, files):
"""
Makes a tarfile, as above.
"""
files.sort(key=lambda a : a[1])
progress_len = len(files)
fn = os.path.join(os.path.dirname(project.path), filename)
tf = tarfile.open(fn + ".tar.bz2", "w:bz2")
tf.dereference = True
for j, (fn, an) in enumerate(files):
progress(t, progress_len, j)
info = tf.gettarinfo(fn, filename + an)
perms = 0666
if info.isdir():
perms = 0777
for i in executable_extensions:
if fn.endswith(i):
perms = 0777
info.mode = perms
info.uid = 1000
info.gid = 1000
info.uname = "renpy"
info.gname = "renpy"
if info.isreg():
tf.addfile(info, file(fn, "rb"))
else:
tf.addfile(info)
tf.close()
def dist_exists(fn):
"""
Returns true if the given file exists in the renpy directory.
"""
return os.path.exists(os.path.join(config.renpy_base, fn))
label distribute:
call lint
if not yesno(_(u"Building Distributions"),
_(u"I've just performed a lint on your project. If it contains errors, you should say no and fix them.\nPlease also check {a=http://www.renpy.org/wiki/renpy/Download_Ren'Py}www.renpy.org{/a} to see if updates or fixes are available.\n\nDo you want to continue?")):
jump top
python hide:
# Do we have the files?
has_windows = dist_exists("renpy.exe")
has_linux = dist_exists("lib/linux-x86")
has_mac = dist_exists("renpy.app")
has_all = has_windows and has_mac and has_linux
# Should we build these distributions?
build_windows = has_windows and project.info.get("build_windows", has_windows)
build_linux = has_linux and project.info.get("build_linux", has_linux)
build_mac = has_mac and project.info.get("build_mac", has_mac)
build_all = has_all and project.info.get("build_all", False)
# The base name of the distribution.
base_name = project.info.get("distribution_base", project.name)
# The executable name.
executable_name = project.info.get("executable_name", project.name)
# Extensions to exclude.
ignore_extensions = project.info.get("ignore_extensions", "~ .bak")
# Documentation extensions.
documentation_extensions = project.info.get("documentation_extensions", "txt html")
# Prompt the user for all of the above.
while True:
set_tooltip("")
screen()
ui.vbox()
title(_(u"Building Distributions"))
text_variable(_(u"Base Name:"), base_name, "base_name",
_(u"Used to generate the names of directories and archive files."))
text_variable(_(u"Executable Name:"), executable_name, "executable_name",
_(u"Used to generate the names of executables and runnable programs."))
text_variable(_(u"Ignore Extensions:"), ignore_extensions, "ignore_extensions",
_(u"Files with these extensions will not be included in the distributions."))
text_variable(_(u"Documentation Extensions:"), documentation_extensions, "documentation_extensions",
_(u"Files with these extensions will be treated as documentation, when building the Macintosh application."))
text(_(u"Distributions to Build:"))
if has_windows:
toggle_button(_(u"Windows x86"), build_windows, ui.returns("build_windows"),
_(u"Zip distribution for the 32-bit Windows platform."))
if has_linux:
toggle_button(_(u"Linux x86"), build_linux, ui.returns("build_linux"),
_(u"Tar.Bz2 distribution for the Linux x86 platform."))
if has_mac:
toggle_button(_(u"Macintosh Universal"), build_mac, ui.returns("build_mac"),
_(u"Single application distribution for the Macintosh x86 and ppc platforms."))
if has_all:
toggle_button(_(u"Windows/Linux/Mac Combined"), build_all, ui.returns("build_all"),
_(u"Zip distribution for the Windows x86, Linux x86, Macintosh x86 and Macintosh ppc platforms."))
ui.null(height=15)
button(_(u"Build"), ui.returns("build"), _(u"Start building the distributions."))
button(_(u"Cancel"), ui.jumps("top"), "")
ui.close()
act = interact()
if act == "build_windows":
build_windows = not build_windows
elif act == "build_linux":
build_linux = not build_linux
elif act == "build_mac":
build_mac = not build_mac
elif act == "build_all":
build_all = not build_all
elif act == "base_name":
base_name = input(
_(u"Base Name"),
_(u"Please enter in the base name for your distribution. This name is used to generate the names of directories and archive files. Usually, this is the name of your game, plus a version number, like \"moonlight-1.0\"."),
base_name)
elif act == "executable_name":
executable_name = input(
_(u"Executable Name"),
_(u"Please enter a name for the executables in your distribution. This should not include an extension, as that will be added automatically."),
executable_name)
elif act == "ignore_extensions":
ignore_extensions = input(
_(u"Ignore Extensions"),
_(u"Please enter a space-separated list of file extensions. Files with these extensions will not be included in the built distributions."),
ignore_extensions)
elif act == "documentation_extensions":
documentation_extensions = input(
_(u"Documentation Extensions"),
_(u"Please enter a space separated list of documentation extensions. Files in the base directory with these extensions will have a second copy stored outside of the Macintosh application."),
documentation_extensions)
elif act == "build":
break
# Store the user-selected options in info, and save info.
project.info["distribution_base"] = base_name
project.info["executable_name"] = executable_name
project.info["ignore_extensions"] = ignore_extensions
project.info["documentation_extensions"] = documentation_extensions
project.info["build_windows"] = build_windows
project.info["build_linux"] = build_linux
project.info["build_mac"] = build_mac
project.info["build_all"] = build_all
project.save()
base_name = base_name.encode("utf-8")
executable_name = executable_name.encode("utf-8")
ignore_extensions = ignore_extensions.encode("utf-8")
documentation_extensions = documentation_extensions.encode("utf-8")
# Convert some of these to more useful formats.
ignore_extensions = [ i.strip() for i in ignore_extensions.split() ]
documentation_extensions = [ i.strip() for i in documentation_extensions.split() ]
# Scan for the files we want to include in the various distributions.
info(_(u"Scanning..."), "")
# Files included in the various distributions.
multi_files = [ ]
win_files = [ ]
linux_files = [ ]
mac_files = [ ]
# A map from source file name to replacement data to be placed in
# that file.
file_data = { }
######################################################################
# Multi files.
rb = config.renpy_base.replace("\\", "/") + "/"
# Project files.
multi_files.extend(tree(project.path, "/", root=True, exclude_suffix=ignore_extensions))
multi_files.append((rb + "renpy.py", "/" + executable_name + ".py"))
# Renpy files.
multi_files.extend(tree(rb + "common", "/common"))
multi_files.extend(tree(rb + "renpy", "/renpy"))
multi_files.append((rb + "LICENSE.txt", "/renpy/LICENSE.txt"))
def add_script_version(fn, ignore_extensions=ignore_extensions, multi_files=multi_files, rb=rb):
"""
Add a script_version file if it does not already exist, and if the
extension is allowed by the game.
"""
for a, b in multi_files:
if b == "/game/" + fn:
return
for i in ignore_extensions:
if fn.endswith(i):
return
multi_files.append((rb + "launcher/" + fn, "/game/" + fn))
add_script_version("script_version.rpy")
add_script_version("script_version.rpyc")
######################################################################
# Windows files.
if build_windows or build_all:
win_files.append((rb + "renpy.exe", "/" + executable_name + ".exe"))
win_files.append((rb + "renpy.code", "/renpy.code"))
win_files.append((rb + "python25.dll", "/python25.dll"))
win_files.append((rb + "msvcr71.dll", "/msvcr71.dll"))
if os.path.exists(project.path + "/icon.ico"):
file_data[rb + "renpy.exe"] = pefile.change_icons(
rb + "renpy.exe",
project.path + "/icon.ico",
)
######################################################################
# Linux files.
if build_linux or build_all:
linux_files.append((rb + "renpy.sh", "/" + executable_name + ".sh"))
linux_files.append((rb + "lib", "/lib"))
linux_files.append((rb + "lib/python", "/lib/python"))
linux_files.extend(tree(rb + "lib/linux-x86", "/lib/linux-x86"))
# Warning: The tar.bz2 builder doesn't support file_data.
######################################################################
# Mac (non-app) files.
if build_mac or build_all:
mac_files = tree(rb + "renpy.app",
"/" + executable_name + ".app")
# Rename executable.
mac_files = [ (fn, an.replace("Ren'Py Launcher", executable_name)) for (fn, an) in mac_files ]
# Plist file.
quoted_name = executable_name.replace("&", "&amp;").replace("<", "&lt;")
info_plist = file(rb + "renpy.app/Contents/Info.plist", "rb").read().replace("Ren'Py Launcher", quoted_name)
file_data[rb + "renpy.app/Contents/Info.plist"] = info_plist
# Launcher script.
quoted_name = executable_name.replace("\"", "\\\"")
launcher_py = file(rb + "renpy.app/Contents/Resources/launcher.py", "rb").read().replace("Ren'Py Launcher", quoted_name)
file_data[rb + "renpy.app/Contents/Resources/launcher.py"] = launcher_py
# Icon file.
if os.path.exists(project.path + "/icon.icns"):
icon_data = file(project.path + "/icon.icns", "rb").read()
file_data[rb + "renpy.app/Contents/Resources/launcher.icns"] = icon_data
######################################################################
# Now, build the various distributions.
if build_windows:
make_zip(
_(u"Building Windows..."),
base_name + "-win32",
multi_files + win_files,
file_data)
if build_linux:
make_tar(
_(u"Building Linux..."),
base_name + "-linux-x86",
multi_files + linux_files)
if build_mac:
# Reorganize the files so all the non application files live inside
# the application. If there's documentation involved, then it
# lives in both places.
macapp_files = [ ]
for fn, an in multi_files + mac_files:
if not an.startswith("/" + executable_name + ".app"):
new_an = "/" + executable_name + ".app/Contents/Resources/autorun" + an
macapp_files.append((fn, new_an))
if an.rindex('/') == 0:
for i in documentation_extensions:
if fn.endswith(i):
macapp_files.append((fn, an))
break
else:
macapp_files.append((fn, an))
make_zip(
_(u"Building Macintosh..."),
base_name + "-mac",
macapp_files,
file_data)
if build_all:
make_zip(
_(u"Building Combined..."),
base_name + "-all",
multi_files + win_files + linux_files + mac_files,
file_data)
# Report success to the user.
set_tooltip(_(u"Thank you for choosing Ren'Py."))
screen()
ui.vbox()
title(_(u"Success"))
text(_(u"The distributions have been built. Be sure to test them before release.\n\nNote that unpacking and repacking the Macintosh, Linux, or Combined distributions on Windows is not supported.\n\nPlease announce your release at the {a=http://lemmasoft.renai.us/forums/}Lemma Soft Forums{/a}, so we can add it to the Ren'Py web site."))
ui.null(height=20)
button(_(u"Return"), ui.jumps("top"), None)
ui.close()
interact()
-162
View File
@@ -1,162 +0,0 @@
# This file contains logic for selecting an editor.
init python:
import glob
import re
import traceback
import os
import os.path
# The default name for the editor.
if persistent.editor is None:
persistent.editor = "jEdit"
# A map from editor name to the file containing information about
# that editor.
editors = { }
# A map from editor to the version of that editor.
editor_versions = { }
# A map from editor to a description of that editor.
editor_descriptions = { }
# Should we set up the editor? How about the transient editor?
set_editor = "RENPY_EDITOR" not in os.environ
set_editor_transient = "RENPY_EDITOR_TRANSIENT" not in os.environ
if set_editor and not set_editor_transient:
config.editor_transient = config.editor
os.environ['RENPY_EDITOR_TRANSIENT'] = config.editor
set_editor_transient = False
def scan_editor(ef):
"""
Scans a single editor file to get the meta-information. If it
checks out, adds it to editors. Uses editor_versions as a cache
so we only add the newest version of each editor.
"""
info = { }
f = file(ef, "r")
for l in f:
m = re.match("#\s*(\w+):\s*(.*?)\s*$", l)
if not m:
break
info[m.group(1)] = m.group(2)
f.close()
try:
name = info["Name"]
version = int(info["Version"])
description = info.get("Description", "")
except:
traceback.print_exc()
print >>sys.stderr, ef
if version > editor_versions.get(name, -1):
editors[name] = ef
editor_versions[name] = version
editor_descriptions[name] = description
def scan_editors():
"""
Finds all *.editor.py files, and uses them to populate the list
of editors.
"""
editors.clear()
editor_versions.clear()
editor_descriptions.clear()
for d in [ config.renpy_base, persistent.projects_directory ]:
if d is None:
continue
for ef in glob.glob(d + "/*/*.editor.py"):
scan_editor(ef)
def setup_editor():
"""
Sets the system up to respect the value containined in
persistent.editor.
"""
if not set_editor:
return
ef = None
for i in [ persistent.editor, "jEdit", "None" ]:
if i in editors:
ef = editors[i]
break
else:
return
ctx = {
"renpy" : renpy,
"config" : config,
"persistent" : persistent,
"base" : os.path.dirname(ef),
}
execfile(ef, ctx, ctx)
if set_editor:
if config.editor:
os.environ['RENPY_EDITOR'] = config.editor
else:
if 'RENPY_EDITOR' in os.environ:
del os.environ['RENPY_EDITOR']
if set_editor_transient:
if config.editor_transient:
os.environ['RENPY_EDITOR_TRANSIENT'] = config.editor_transient
else:
if 'RENPY_EDITOR_TRANSIENT' in os.environ:
del os.environ['RENPY_EDITOR_TRANSIENT']
label editor:
python hide:
if not set_editor:
error(_(u"The editor has been set from the RENPY_EDITOR environment variable, and cannot be changed."), "options")
set_tooltip("")
screen()
ui.vbox()
title(_(u"Choose Editor"))
text(_(u"Please choose the editor that will be use to edit scripts and display errors. More editors can be downloaded from {a=http://www.renpy.org/wiki/renpy/Editors}the Ren'Py website{/a}."))
ui.null(height=15)
scrolled("options")
ui.vbox()
for i in sorted(editors, key=lambda a : a.lower()):
button(i,
ui.returns(i),
editor_descriptions[i])
ui.close() # Vbox
ui.close() # Scrolled
ui.close() # Vbox
persistent.editor = interact()
setup_editor()
jump options
Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.7 KiB

@@ -1,3 +1,4 @@
#@PydevCodeAnalysisIgnore
"""Easy to use dialogs.
Message(msg) -- display a message and an OK button.
Binary file not shown.
Binary file not shown.
+23 -10
View File
@@ -1,4 +1,4 @@
# Copyright 2007 PyTom <pytom@bishoujo.us>
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
@@ -19,14 +19,27 @@
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
import renpy
import pygame
import renpygame
# Checks for various abilities that might be taken away from us by
# redistributors.
from pygame.time import *
init 1 python in ability:
from store import config
import store
import store.updater as updater
import os
EXECUTABLES = [ "renpy.exe", "renpy.app", "renpy.sh" ]
# can_distribute - True if we can distribute
for i in EXECUTABLES:
if not os.path.exists(os.path.join(config.renpy_base, i)):
can_distribute = False
else:
can_distribute = True
# can_update - True if we can update.
can_update = updater.can_update() or (store.UPDATE_SIMULATE is not None)
# This doesn't work right if the wait is too long. Well, probably other
# things will break as well, so no biggie.
def wait(time):
renpygame.event.periodic()
pygame.time.wait(time)
+23 -19
View File
@@ -1,4 +1,4 @@
# Copyright 2007 PyTom <pytom@bishoujo.us>
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
@@ -19,27 +19,31 @@
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
import renpy
import pygame
screen about:
try:
import _renpy_font
pygame.font = _renpy_font
except:
pass
$ version = renpy.version()
def Font(filename, size):
"""
RPG: Extended to load fonts from the game directory.
"""
frame:
style_group "l"
style "l_root"
if filename is None:
filename = renpy.store.style.default.font
window:
xfill True
return pygame.font.Font(renpy.loader.transfn(filename), size)
has vbox xfill True
def init():
"""
RPG: Does nothing.
"""
add "images/logo.png" xalign 0.5 yoffset -5
null height 15
text _("[version!q]") xalign 0.5 bold True
null height 20
textbutton _("View license") action interface.OpenLicense() xalign 0.5
textbutton _("Back") action Jump("front_page") style "l_left_button"
label about:
call screen about
+57
View File
@@ -0,0 +1,57 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
label add_file:
python hide:
import os
import codecs
filename = interface.input(_("FILENAME"), _("Enter the name of the script file to create."), filename="withslash", cancel=Jump("navigation"))
if "." in filename and not filename.endswith(".rpy"):
interface.error(_("The filename must have the .rpy extension."), label="navigation")
elif "." not in filename:
filename += ".rpy"
path = os.path.join(project.current.gamedir, filename)
dir = os.path.dirname(path)
if os.path.exists(path):
interface.error(_("The file already exists."), label="navigation")
contents = u"\uFEFF"
contents += _("# Ren'Py automatically loads all script files ending with .rpy. To use this\n# file, define a label and jump to it from another file.\n")
contents += "\n"
try:
os.makedirs(dir)
except:
pass
contents = u"\uFEFF"
contents += _("# Ren'Py automatically loads all script files ending with .rpy. To use this\n# file, define a label and jump to it from another file.\n")
with open(path, "wb") as f:
f.write(contents.encode("utf-8"))
jump navigation_refresh
+674
View File
@@ -0,0 +1,674 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python:
ANDROID_NO_RAPT = 0
ANDROID_NO_JDK = 1
ANDROID_NO_SDK = 2
ANDROID_NO_KEY = 3
ANDROID_NO_CONFIG = 4
ANDROID_OK = 5
NO_RAPT_TEXT = _("To build Android packages, please download RAPT, unzip it, and place it into the Ren'Py directory. Then restart the Ren'Py launcher.")
NO_JDK_TEXT = _("A 32-bit Java Development Kit is required to build Android packages on Windows. The JDK is different from the JRE, so it's possible you have Java without having the JDK.\n\nPlease {a=http://www.oracle.com/technetwork/java/javase/downloads/index.html}download and install the JDK{/a}, then restart the Ren'Py launcher.")
NO_SDK_TEXT = _("RAPT has been installed, but you'll need to install the Android SDK before you can build Android packages. Choose Install SDK to do this.")
NO_KEY_TEXT = _("RAPT has been installed, but a key hasn't been configured. Please create a new key, or restore android.keystore.")
NO_CONFIG_TEXT = _("The current project has not been configured. Use \"Configure\" to configure it before building.")
OK_TEXT = _("Choose \"Build\" to build the current project, or attach an Android device and choose \"Build & Install\" to build and install it on the device.")
PHONE_TEXT = _("Attempts to emulate an Android phone.\n\nTouch input is emulated through the mouse, but only when the button is held down. Escape is mapped to the menu button, and PageUp is mapped to the back button.")
TABLET_TEXT = _("Attempts to emulate an Android tablet.\n\nTouch input is emulated through the mouse, but only when the button is held down. Escape is mapped to the menu button, and PageUp is mapped to the back button.")
OUYA_TEXT = _("Attempts to emulate a televison-based Android console, like the OUYA or Fire TV.\n\nController input is mapped to the arrow keys, Enter is mapped to the select button, Escape is mapped to the menu button, and PageUp is mapped to the back button.")
INSTALL_SDK_TEXT = _("Downloads and installs the Android SDK and supporting packages. Optionally, generates the keys required to sign the package.")
CONFIGURE_TEXT = _("Configures the package name, version, and other information about this project.")
PLAY_KEYS_TEXT = _("Opens the file containing the Google Play keys in the editor.\n\nThis is only needed if the application is using an expansion APK. Read the documentation for more details.")
BUILD_TEXT = _("Builds the Android package.")
BUILD_AND_INSTALL_TEXT = _("Builds the Android package, and installs it on an Android device connected to your computer.")
CONNECT_TEXT = _("Connects to an Android device running ADB in TCP/IP mode.")
DISCONNECT_TEXT = _("Disconnects from an Android device running ADB in TCP/IP mode.")
import subprocess
import re
import os
import json
def find_rapt():
global RAPT_PATH
candidates = [ ]
RAPT_PATH = os.path.join(config.renpy_base, "rapt")
if os.path.isdir(RAPT_PATH):
import sys
sys.path.insert(0, os.path.join(RAPT_PATH, "buildlib"))
else:
RAPT_PATH = None
RAPT_PATH is None
find_rapt()
import threading
if RAPT_PATH:
import rapt
import rapt.build
import rapt.configure
import rapt.install_sdk
import rapt.plat
import rapt.interface
else:
rapt = None
def AndroidState():
"""
Determines the state of the android install, and returns it.
"""
if RAPT_PATH is None:
return ANDROID_NO_RAPT
if renpy.windows and not "JAVA_HOME" in os.environ:
return ANDROID_NO_JDK
if not os.path.exists(rapt.plat.path("android-sdk/extras/google/play_licensing")):
return ANDROID_NO_SDK
if not os.path.exists(rapt.plat.path("android.keystore")):
return ANDROID_NO_KEY
if not os.path.exists(rapt.plat.path("local.properties")):
return ANDROID_NO_KEY
if not os.path.exists(os.path.join(project.current.path, ".android.json")):
return ANDROID_NO_CONFIG
return ANDROID_OK
def AndroidStateText(state):
"""
Returns text corresponding to the state.
"""
if state == ANDROID_NO_RAPT:
return NO_RAPT_TEXT
if state == ANDROID_NO_JDK:
return NO_JDK_TEXT
if state == ANDROID_NO_SDK:
return NO_SDK_TEXT
if state == ANDROID_NO_KEY:
return NO_KEY_TEXT
if state == ANDROID_NO_CONFIG:
return NO_CONFIG_TEXT
if state == ANDROID_OK:
return OK_TEXT
def AndroidIfState(state, needed, action):
"""
If `state` is `needed` or better, `action` is returned. Otherwise,
returns None, disabling the button.
"""
if state >= needed:
return action
else:
return None
class AndroidInterface(object):
def __init__(self):
self.process = None
self.filename = project.current.temp_filename("android.txt")
self.info_msg = ""
with open(self.filename, "w"):
pass
def log(self, msg):
with open(self.filename, "a") as f:
f.write("\n")
f.write(msg)
f.write("\n")
def info(self, prompt):
self.info_msg = prompt
interface.processing(prompt, pause=False)
self.log(prompt)
def yesno(self, prompt, submessage=None):
return interface.yesno(prompt, submessage=submessage)
def yesno_choice(self, prompt, default=None):
choices = [ (True, "Yes"), (False, "No") ]
return interface.choice(prompt, choices, default)
def terms(self, url, prompt):
submessage = _("{a=%s}%s{/a}") % (url, url)
if not interface.yesno(prompt, submessage=submessage):
self.fail("You must accept the terms and conditions to proceed.", edit=False)
def input(self, prompt, empty=None):
if empty is None:
empty = ''
while True:
rv = interface.input(_("QUESTION"), prompt, default=empty, cancel=Jump("android"))
rv = rv.strip()
if rv:
return rv
def choice(self, prompt, choices, default):
return interface.choice(prompt, choices, default, cancel=Jump("android"))
def fail(self, prompt, edit=True):
self.log(prompt)
prompt = re.sub(r'(http://\S+)', r'{a=\1}\1{/a}', prompt)
# Open android.txt in the editor.
if edit:
editor.EditAbsolute(self.filename)()
interface.error(prompt, label="android")
def success(self, prompt):
self.log(prompt)
interface.info(prompt, pause=False)
def final_success(self, prompt):
self.log(prompt)
interface.info(prompt, label="android")
def run_yes_thread(self):
import time
try:
while self.run_yes:
self.process.stdin.write('y\n')
self.process.stdin.flush()
time.sleep(.2)
except:
import traceback
traceback.print_exc()
def call(self, cmd, cancel=False, use_path=False, yes=False):
print
print " ".join(cmd)
self.cmd = cmd
f = open(self.filename, "a")
f.write("\n\n\n")
if cancel:
cancel_action = self.cancel
else:
cancel_action = None
startupinfo = None
if renpy.windows:
startupinfo = subprocess.STARTUPINFO()
startupinfo.dwFlags |= subprocess.STARTF_USESHOWWINDOW
self.yes_thread = None
try:
interface.processing(self.info_msg, show_screen=True, cancel=cancel_action)
kwargs = { }
if yes:
kwargs["stdin"] = subprocess.PIPE
try:
self.process = subprocess.Popen(cmd, cwd=RAPT_PATH, stdout=f, stderr=f, startupinfo=startupinfo, **kwargs)
except:
import traceback
traceback.print_exc(file=f)
raise
if yes:
import threading
self.run_yes = True
self.yes_thread = threading.Thread(target=self.run_yes_thread)
self.yes_thread.daemon = True
self.yes_thread.start()
renpy.call_screen("android_process", interface=self)
finally:
f.close()
interface.hide_screen()
if yes and self.yes_thread:
self.run_yes = False
self.yes_thread.join()
self.process = None
self.yes_thread = None
def check_process(self):
rv = self.process.poll()
if rv is not None:
if rv:
raise subprocess.CalledProcessError(rv, self.cmd)
else:
return True
def download(self, url, dest):
try:
d = Downloader(url, dest)
cancel_action = [ d.cancel, Jump("android") ]
interface.processing(self.info_msg, show_screen=True, cancel=cancel_action, bar_value=DownloaderValue(d))
ui.timer(.1, action=d.check, repeat=True)
ui.interact()
finally:
interface.hide_screen()
def background(self, f):
try:
t = threading.Thread(target=f)
t.start()
interface.processing(self.info_msg, show_screen=True)
while t.is_alive():
renpy.pause(0)
t.join(0.25)
finally:
interface.hide_screen()
def cancel(self):
if self.process:
self.process.terminate()
renpy.jump("android")
class AndroidBuild(Action):
"""
Activates an Android build process.
"""
def __init__(self, label):
self.label = label
def __call__(self):
renpy.jump(self.label)
class LaunchEmulator(Action):
def __init__(self, emulator, variants):
self.emulator = emulator
self.variants = variants
def __call__(self):
env = {
"RENPY_EMULATOR" : self.emulator,
"RENPY_VARIANT" : self.variants,
}
p = project.current
p.launch(env=env)
def update_android_json(p, gui):
"""
Updates .android.json to include the google play information.
`p`
The project to update json for.
"""
p.update_dump(True, gui=gui)
build = p.dump["build"]
filename = os.path.join(p.path, ".android.json")
with open(filename, "r") as f:
android_json = json.load(f)
if "google_play_key" in build:
android_json["google_play_key"] = build["google_play_key"]
else:
android_json.pop("google_play_key", None)
if "google_play_salt" in build:
if len(build["google_play_salt"]) != 20:
raise Exception("build.google_play_salt must be exactly 20 bytes long.")
android_json["google_play_salt"] = ", ".join(str(i) for i in build["google_play_salt"])
else:
android_json.pop("google_play_salt", None)
with open(filename, "w") as f:
json.dump(android_json, f)
def android_build(command, p=None, gui=True):
"""
This actually builds the package.
"""
if p is None:
p = project.current
update_android_json(p, gui)
dist = p.temp_filename("android.dist")
if os.path.exists(dist):
shutil.rmtree(dist)
if gui:
reporter = distribute.GuiReporter()
rapt_interface = AndroidInterface()
else:
reporter = distribute.TextReporter()
rapt_interface = rapt.interface.Interface()
distribute.Distributor(p,
reporter=reporter,
packages=[ 'android' ],
build_update=False,
noarchive=True,
packagedest=dist,
report_success=False,
)
with interface.nolinks():
rapt.build.build(rapt_interface, dist, command)
# The android support can stick unicode into os.environ. Fix that.
init 100 python:
for k, v in list(os.environ.items()):
if not isinstance(v, str):
os.environ[k] = renpy.fsencode(v)
screen android_process(interface):
zorder 100
default ft = FileTail(interface.filename)
text "[ft.text!q]":
size 14
color TEXT
font "Roboto-Light.ttf"
xpos 75
ypos 350
timer .1 action interface.check_process repeat True
timer .2 action ft.update repeat True
screen android:
default tt = Tooltip(None)
$ state = AndroidState()
frame:
style_group "l"
style "l_root"
window:
has vbox
label _("Android: [project.current.name!q]")
add HALF_SPACER
hbox:
# Left side.
frame:
style "l_indent"
xmaximum ONEHALF
xfill True
has vbox
add SEPARATOR2
frame:
style "l_indent"
has vbox
text _("Emulation:")
add HALF_SPACER
frame style "l_indent":
has vbox
textbutton _("Phone"):
action LaunchEmulator("touch", "small phone touch android")
hovered tt.Action(PHONE_TEXT)
textbutton _("Tablet"):
action LaunchEmulator("touch", "medium tablet touch android")
hovered tt.Action(TABLET_TEXT)
textbutton _("Television / OUYA"):
action LaunchEmulator("tv", "small tv ouya android")
hovered tt.Action(OUYA_TEXT)
add SPACER
add SEPARATOR2
frame:
style "l_indent"
has vbox
text _("Build:")
add HALF_SPACER
frame style "l_indent":
has vbox
textbutton _("Install SDK & Create Keys"):
action AndroidIfState(state, ANDROID_NO_SDK, Jump("android_installsdk"))
hovered tt.Action(INSTALL_SDK_TEXT)
textbutton _("Configure"):
action AndroidIfState(state, ANDROID_NO_CONFIG, Jump("android_configure"))
hovered tt.Action(CONFIGURE_TEXT)
textbutton _("Build Package"):
action AndroidIfState(state, ANDROID_OK, AndroidBuild("android_build"))
hovered tt.Action(BUILD_TEXT)
textbutton _("Build & Install"):
action AndroidIfState(state, ANDROID_OK, AndroidBuild("android_build_and_install"))
hovered tt.Action(BUILD_AND_INSTALL_TEXT)
add SPACER
add SEPARATOR2
frame:
style "l_indent"
has vbox
text _("Other:")
add HALF_SPACER
frame style "l_indent":
has vbox
textbutton _("Remote ADB Connect"):
action AndroidIfState(state, ANDROID_OK, Jump("android_connect"))
hovered tt.Action(CONNECT_TEXT)
textbutton _("Remote ADB Disconnect"):
action AndroidIfState(state, ANDROID_OK, Jump("android_disconnect"))
hovered tt.Action(DISCONNECT_TEXT)
# Right side.
frame:
style "l_indent"
xmaximum ONEHALF
xfill True
has vbox
add SEPARATOR2
frame:
style "l_indent"
has vbox
add SPACER
if tt.value:
text tt.value
else:
text AndroidStateText(state)
textbutton _("Back") action Jump("front_page") style "l_left_button"
label android:
if RAPT_PATH is None:
$ interface.yesno(_("Before packaging Android apps, you'll need to download RAPT, the Ren'Py Android Packaging Tool. Would you like to download RAPT now?"), no=Jump("front_page"))
$ add_dlc("rapt", restart=True)
call screen android
label android_installsdk:
python:
with interface.nolinks():
rapt.install_sdk.install_sdk(AndroidInterface())
jump android
label android_configure:
python:
rapt.configure.configure(AndroidInterface(), project.current.path)
jump android
label android_build:
$ android_build([ 'release' ])
jump android
label android_build_and_install:
$ android_build([ 'release', 'install' ])
jump android
label android_connect:
python hide:
if persistent.connect_address is not None:
address = persistent.connect_address
else:
address = ""
while True:
address = interface.input(
_("Remote ADB Address"),
_("Please enter the IP address and port number to connect to, in the form \"192.168.1.143:5555\". Consult your device's documentation to determine if it supports remote ADB, and if so, the address and port to use."),
default=address,
cancel=Jump("android"),
)
address = address.strip()
try:
host, port = address.split(":")
except:
interface.error(_("Invalid remote ADB address"), _("The address must contain one exactly one ':'."), label=None)
continue
if " " in host:
interface.error(_("Invalid remote ADB address"), _("The host may not contain whitespace."), label=None)
continue
try:
int(port)
except:
interface.error(_("Invalid remote ADB address"), _("The port must be a number."), label=None)
continue
break
persistent.connect_address = address
rapt_interface = AndroidInterface()
rapt.build.connect(rapt_interface, address)
jump android
label android_disconnect:
python hide:
rapt_interface = AndroidInterface()
rapt.build.disconnect(rapt_interface)
jump android
init python:
def android_build_command():
ap = renpy.arguments.ArgumentParser()
ap.add_argument("project", help="The path to the project directory.")
ap.add_argument("command", help="Commands to pass to ant. (Try 'release' 'install'.)", nargs='+')
args = ap.parse_args()
p = project.Project(args.project)
android_build(args.command, p=p, gui=False)
return False
renpy.arguments.register_command("android_build", android_build_command)
+85
View File
@@ -0,0 +1,85 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# Ren'Py archiver. This builds a Ren'Py archive file, and the
# associated index file. These files are really easy to
# reverse-engineer, but are probably better than nothing.
init python in archiver:
import sys
import random
import glob
from cPickle import dumps, HIGHEST_PROTOCOL
class Archive(object):
"""
Adds files from disk to a rpa archive.
"""
def __init__(self, filename):
# The archive file.
self.f = open(filename, "wb")
# The index to the file.
self.index = _dict()
# A fixed key minimizes difference between archive versions.
self.key = 0x42424242
padding = "RPA-3.0 XXXXXXXXXXXXXXXX XXXXXXXX\n"
self.f.write(padding)
def add(self, name, path):
"""
Adds a file to the archive.
"""
self.index[name] = _list()
with open(path, "rb") as df:
data = df.read()
dlen = len(data)
# Pad.
padding = "Made with Ren'Py."
self.f.write(padding)
offset = self.f.tell()
self.f.write(data)
self.index[name].append((offset ^ self.key, dlen ^ self.key, ""))
def close(self):
indexoff = self.f.tell()
self.f.write(dumps(self.index, HIGHEST_PROTOCOL).encode("zlib"))
self.f.seek(0)
self.f.write("RPA-3.0 %016x %08x\n" % (indexoff, self.key))
self.f.close()
@@ -1,3 +1,24 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# http://www.csn.ul.ie/~caolan/publink/winresdump/winresdump/doc/pefile.html
# Contains a reasonable description of the format.
@@ -5,40 +26,7 @@
import struct
import sys
import array
# The starting point of the resource segment in the file.
RESOURCE_BASE=0x3600
# The virtual memory location the resource segment is loaded
# to.
RESOURCE_VIRTUAL=0x6000
# The offset of the field that tells us with the alignment need be.
ALIGNMENT_FIELD = 0x130
# The start of the .rsrc segment header.
RSRC_HEADER = 0x268
# Locations in the file where we need to patch in the resource
# segment length.
RESOURCE_LENGTH_PATCHES = [ 0x0184, RSRC_HEADER + 0x8 ]
# Locations in the file where we need to patch in the padded
# resource segment length.
RESOURCE_PADDED_PATCHES = [ RSRC_HEADER + 0x10 ]
# Locations in the file where we need to patch in the change in the
# size of the resource segement (and hence the change in the file's
# total size.)
SIZE_DELTA_PATCHES = [ 0x148 ]
# A location in the file that will be checked to be sure it matches
# RESOURCE_BASE.
CHECK_ADDRESS = RSRC_HEADER + 0x14
# A location in the file that will be checked to make sure it matches
# RESOURCE_VIRTUAL
CHECK_ADDRESS2 = RSRC_HEADER + 0xc
import pefile # @UnresolvedImport
# This class performs various operations on memory-loaded binary files,
# including modifications.
@@ -49,7 +37,7 @@ class BinFile(object):
self.a[addr+1] = (value >> 8) & 0xff
self.a[addr+2] = (value >> 16) & 0xff
self.a[addr+3] = (value >> 24) & 0xff
def u32(self):
addr = self.addr
rv = self.a[addr]
@@ -75,22 +63,21 @@ class BinFile(object):
c = self.u16()
rv = u""
for i in range(c):
for _i in range(c):
rv += unichr(self.u16())
return rv
def seek(self, addr):
self.addr = addr
def tostring(self):
return self.a.tostring()
def substring(self, start, len):
def substring(self, start, len): #@ReservedAssignment
return self.a[start:start+len].tostring()
def __init__(self, fn):
data = open(fn, "rb").read()
def __init__(self, data):
self.a = array.array('B')
self.a.fromstring(data)
@@ -98,54 +85,57 @@ class BinFile(object):
# These functions parse data out of the file. In these functions, offset is
# relative to the start of the file.
# The virtual address of the resource segment.
resource_virtual = 0
# This parses a data block out of the resources.
def parse_data(offset):
pe.seek(RESOURCE_BASE + offset)
data_offset = pe.u32()
data_len = pe.u32()
code_page = pe.u32()
pe.u32()
def parse_data(bf, offset):
bf.seek(offset)
data_offset = bf.u32()
data_len = bf.u32()
code_page = bf.u32()
bf.u32()
l = [ ]
pe.seek(data_offset + RESOURCE_BASE - RESOURCE_VIRTUAL)
for i in range(data_len):
l.append(chr(pe.u8()))
bf.seek(data_offset - resource_virtual)
for _i in range(data_len):
l.append(chr(bf.u8()))
return (code_page, "".join(l))
# This parses a resource directory.
def parse_directory(offset):
def parse_directory(bf, offset):
pe.seek(RESOURCE_BASE + offset)
char = pe.u32()
timedate = pe.u32()
major = pe.u16()
minor = pe.u16()
n_named = pe.u16()
n_id = pe.u16()
bf.seek(offset)
char = bf.u32() #@UnusedVariable
timedate = bf.u32() #@UnusedVariable
major = bf.u16() #@UnusedVariable
minor = bf.u16() #@UnusedVariable
n_named = bf.u16()
n_id = bf.u16()
entries = [ ]
for i in range(n_named + n_id):
entries.append((pe.u32(), pe.u32()))
for _i in range(n_named + n_id):
entries.append((bf.u32(), bf.u32()))
rv = { }
for name, value in entries:
if name & 0x80000000:
pe.seek((name & 0x7fffffff) + RESOURCE_BASE)
name = pe.name()
bf.seek((name & 0x7fffffff))
name = bf.name()
if value & 0x80000000:
value = parse_directory(value & 0x7fffffff)
value = parse_directory(bf, value & 0x7fffffff)
else:
value = parse_data(value)
value = parse_data(bf, value)
rv[name] = value
return rv
return rv
##############################################################################
@@ -155,7 +145,7 @@ def show_resources(d, prefix):
if not isinstance(d, dict):
print prefix, "Codepage", d[0], "length", len(d[1])
return
for k in d:
print prefix, k
show_resources(d[k], prefix + " ")
@@ -172,7 +162,7 @@ class Packer(object):
self.entries = ""
self.entries_offset = 0
head = self.pack_dict(d, 0)
self.data = ""
@@ -183,48 +173,43 @@ class Packer(object):
return self.pack_dict(d, 0) + self.entries + self.data
def pack_name(self, s):
rv = self.data_offset + len(self.data)
l = len(s)
s = s.encode("utf-16le")
self.data += struct.pack("<H", l) + s + "\0\0"
return rv
def pack_tuple(self, t):
codepage, data = t
rv = len(self.entries) + self.entries_offset
rv = len(self.entries) + self.entries_offset
if len(self.data) % 2:
self.data += "P"
daddr = len(self.data) + self.data_offset
self.entries += struct.pack("<IIII", daddr + RESOURCE_VIRTUAL, len(data), codepage, 0)
self.entries += struct.pack("<IIII", daddr + resource_virtual, len(data), codepage, 0)
self.data += data
# if len(self.data) % 1 == 1:
# self.data += 'P'
return rv
def pack_dict(self, d, offset):
name_entries = sorted((a, b) for a, b in d.iteritems() if isinstance(a, unicode))
id_entries = sorted((a, b) for a, b in d.iteritems() if isinstance(a, int))
rv = struct.pack("<IIHHHH", 0, 0, 4, 0, len(name_entries), len(id_entries))
offset += len(rv) + (len(name_entries) + len(id_entries)) * 8
rest = ""
for (name, value) in name_entries + id_entries:
if isinstance(name, unicode):
name = 0x80000000 | self.pack_name(name)
@@ -236,16 +221,16 @@ class Packer(object):
rest += packed
else:
addr = self.pack_tuple(value)
rv += struct.pack("<II", name, addr)
return rv + rest
##############################################################################
# This loads in an icon file, and returns a dictionary that is suitable for
# use in the resources of an exe file.
def load_icon(fn):
f = BinFile(fn)
f = BinFile(file(fn, "rb").read())
f.seek(0)
f.u16()
@@ -255,8 +240,8 @@ def load_icon(fn):
rv = { }
rv[3] = { }
group = struct.pack("HHH", 0, 1, count)
group = struct.pack("HHH", 0, 1, count)
for i in range(count):
width = f.u8()
height = f.u8()
@@ -271,17 +256,17 @@ def load_icon(fn):
f.seek(offset + 16)
if not f.u32():
f.set_u32(offset + 20, 0)
rv[3][i + 1] = { 0 : (1252, f.substring(offset, size)) }
group += struct.pack("BBBBHHIH", width, height, colors, reserved,
planes, bpp, size, i + 1)
f.seek(addr)
rv[14] = { 1 : { 0 : (1252, group) } }
return rv
@@ -289,55 +274,76 @@ def load_icon(fn):
# This is the main function that should be called externally, that copies over
# the icons.
def change_icons(oldexe, icofn):
global pe
pe = BinFile(oldexe)
global resource_virtual
# Check that RESOURCE_BASE and RESOURCE_VIRTUAL are still valid.
pe.seek(CHECK_ADDRESS)
if pe.u32() != RESOURCE_BASE:
raise Exception("RESOURCE_BASE is no longer correct. Please check all relocations.")
pe = pefile.PE(oldexe)
pe.seek(CHECK_ADDRESS2)
if pe.u32() != RESOURCE_VIRTUAL:
raise Exception("RESOURCE_VIRTUAL is no longer correct. Please check all relocations.")
for s in pe.sections:
if s.Name == ".rsrc\0\0\0":
rsrc_section = s
break
else:
raise Exception("Couldn't find resource section.")
resources = parse_directory(0)
# show_resources(resources, "")
base = rsrc_section.PointerToRawData
resource_virtual = rsrc_section.VirtualAddress
physize = rsrc_section.SizeOfRawData
virsize = rsrc_section.Misc_VirtualSize
f = file(oldexe, "rb")
f.seek(base)
data = f.read(physize)
f.close()
bf = BinFile(data)
resources = parse_directory(bf, 0)
# show_resources(resources, "")
resources.update(load_icon(icofn))
# show_resources(resources, "")
rsrc = Packer().pack(resources)
rsrc_len = len(rsrc)
# show_resources(resources, "")
pe.seek(ALIGNMENT_FIELD)
alignment = pe.u32()
rsrc = Packer().pack(resources)
alignment = pe.OPTIONAL_HEADER.SectionAlignment
# print "Alignment is", alignment
if len(rsrc) % alignment:
pad = alignment - (len(rsrc) % alignment)
padding = "RENPYVNE" * (pad / 8 + 1)
padding = padding[:pad]
rsrc += padding
padded_len = len(rsrc)
for addr in RESOURCE_LENGTH_PATCHES:
pe.set_u32(addr, rsrc_len)
newsize = len(rsrc)
for addr in RESOURCE_PADDED_PATCHES:
pe.seek(addr)
size_delta = padded_len - pe.u32()
pe.set_u32(addr, padded_len)
rsrc_section.Misc_VirtualSize += newsize - virsize
rsrc_section.Misc_PhysicalAddress += newsize - virsize
rsrc_section.Misc += newsize - virsize
rsrc_section.SizeOfRawData += newsize - physize
for addr in SIZE_DELTA_PATCHES:
pe.seek(addr)
pe.set_u32(addr, pe.u32() + size_delta)
pe.OPTIONAL_HEADER.SizeOfInitializedData += newsize - physize
# Resource size.
pe.OPTIONAL_HEADER.DATA_DIRECTORY[2].Size += newsize - virsize
# Compute the total size of the image.
total_size = 0
for i in pe.sections:
sec_size = i.Misc_VirtualSize
sec_size = sec_size - (sec_size % alignment) + alignment
total_size += sec_size
pe.OPTIONAL_HEADER.SizeOfImage = total_size
return pe.write()[:base] + rsrc
return pe.tostring()[:RESOURCE_BASE] + rsrc
if __name__ == "__main__":
f = file(sys.argv[3], "wb")
f.write(change_icons(sys.argv[1], sys.argv[2]))
f.close()
+499
View File
@@ -0,0 +1,499 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python:
import random
import codecs
import re
import sys
def theme_names():
"""
Gets a list of all of the theme names we know about.
"""
names = list(theme_data.THEME.keys())
names.sort(key=lambda a : a.lower())
return names
def scheme_names(theme):
"""
Gets a list of the color scheme names corresponding to the given
theme.
"""
names = list(theme_data.THEME[theme].keys())
names.sort(key=lambda a : a.lower())
return names
def theme_yinitial():
names = theme_names()
if len(names) < 2:
return 0
return 1.0 * names.index(current_theme) / (len(names) - 1)
def scheme_yinitial():
names = scheme_names(current_theme)
if len(names) < 2:
return 0
return 1.0 * names.index(current_scheme) / (len(names) - 1)
def pick_theme(theme, scheme):
"""
Returns a theme and scheme that are similar to `theme` and `scheme`.
If the theme is known, picks it, otherwise picks a random theme. If
the scheme is known for that theme, picks it, otherwise picks a
random scheme that is known for the current theme.
"""
if theme not in theme_data.THEME:
theme = random.choice(list(theme_data.THEME))
schemes = theme_data.THEME[theme]
if scheme not in schemes:
if theme in schemes:
scheme = theme
else:
scheme = random.choice(list(schemes))
return theme, scheme
def implement_theme(theme, scheme):
"""
Implement the current theme.
This function uses non-public APIs.
"""
global showing_theme, showing_scheme
if theme == showing_theme and scheme == showing_scheme:
return
renpy.style.restore(style_backup)
exec theme_data.THEME[theme][scheme] in globals()
# Rebuild the style cache.
renpy.style.rebuild(False)
# Bust the render cache, so we re-evaluate the styles.
renpy.display.interface.kill_textures()
showing_theme = theme
showing_scheme = scheme
renpy.restart_interaction()
showing_theme = None
showing_scheme = None
class SetTheme(Action):
def __init__(self, theme):
self.theme = theme
def __call__(self):
global current_theme
global current_scheme
current_theme, current_scheme = pick_theme(self.theme, current_scheme)
implement_theme(current_theme, current_scheme)
renpy.restart_interaction()
def get_selected(self):
return current_theme == self.theme
class SetScheme(Action):
def __init__(self, scheme):
self.scheme = scheme
def __call__(self):
global current_theme
global current_scheme
current_theme, current_scheme = pick_theme(current_theme, self.scheme)
implement_theme(current_theme, current_scheme)
renpy.restart_interaction()
def get_selected(self):
return current_scheme == self.scheme
class PreviewTheme(Action):
def __init__(self, theme, scheme):
self.theme = theme
self.scheme = scheme
def __call__(self):
theme, scheme = pick_theme(self.theme, self.scheme)
implement_theme(theme, scheme)
def unhovered(self):
if (showing_theme == self.theme and showing_scheme == self.scheme):
implement_theme(current_theme, current_scheme)
def value_changed(value):
return None
##########################################################################
# Code to update options.rpy
def list_logical_lines(filename):
"""
This reads in filename, and turns it into a list of logical
lines.
"""
f = codecs.open(filename, "rb", "utf-8")
data = f.read()
f.close()
# The result.
rv = [ ]
# The current position we're looking at in the buffer.
pos = 0
# Looping over the lines in the file.
while pos < len(data):
# The line that we're building up.
line = ""
# The number of open parenthesis there are right now.
parendepth = 0
# Looping over the characters in a single logical line.
while pos < len(data):
c = data[pos]
if c == '\n' and not parendepth:
rv.append(line)
pos += 1
# This helps out error checking.
line = ""
break
# Backslash/newline.
if c == "\\" and data[pos+1] == "\n":
pos += 2
line += "\\\n"
continue
# Parenthesis.
if c in ('(', '[', '{'):
parendepth += 1
if c in ('}', ']', ')') and parendepth:
parendepth -= 1
# Comments.
if c == '#':
while data[pos] != '\n':
line += data[pos]
pos += 1
continue
# Strings.
if c in ('"', "'", "`"):
delim = c
line += c
pos += 1
escape = False
while pos < len(data):
c = data[pos]
if escape:
escape = False
pos += 1
line += c
continue
if c == delim:
pos += 1
line += c
break
if c == '\\':
escape = True
line += c
pos += 1
continue
continue
line += c
pos += 1
if line:
rv.append(line)
return rv
def switch_theme():
"""
Switches the theme of the current project to the current theme
and color scheme. (As set in current_theme and current_scheme.)
"""
theme_code = theme_data.THEME[current_theme][current_scheme]
# Did we change the file at all?
changed = False
filename = os.path.join(project.current.path, "game/options.rpy")
with codecs.open(filename + ".new", "wb", "utf-8") as out:
for l in list_logical_lines(filename):
m = re.match(r' theme.(\w+)\(', l)
if (not changed) and m and (m.group(1) in theme_data.THEME_FUNCTIONS):
l = " " + theme_code
changed = True
out.write(l + "\n")
if changed:
try:
os.unlink(filename + ".bak")
except:
pass
os.rename(filename, filename + ".bak")
os.rename(filename + ".new", filename)
else:
os.unlink(filename + ".new")
interface.error(_("Could not change the theme. Perhaps options.rpy was changed too much."))
# Now give the theme's screen-ops function a chance to make any
# necessary changes to the screens.rpy file
filename = os.path.join(project.current.path, "game/screens.rpy")
changed = False
try:
with codecs.open(filename + ".new", "wb", "utf-8") as out:
lines = list_logical_lines(filename)
lines = theme_data.THEME_SCREEN_OPERATIONS[current_theme](lines)
if lines != None:
for l in lines:
out.write(l + "\n")
changed = True
if changed:
try:
os.unlink(filename + ".bak")
except:
pass
os.rename(filename, filename + ".bak")
os.rename(filename + ".new", filename)
except Exception as inst:
try:
# just in case
os.unlink(filename + ".new")
except:
pass
pass
def make_style_backup():
"""
Call this to back up the styles. This should be called in a
translate python block in each translation.
"""
global style_backup
style_backup = renpy.style.backup()
translate None python:
make_style_backup()
screen theme_demo:
window:
style "gm_root"
xpadding 5
ypadding 5
grid 1 1:
xfill True
style_group "prefs"
vbox:
frame:
style_group "pref"
has vbox
label _("Display")
textbutton _("Window") action SelectedIf(True)
textbutton _("Fullscreen") action ui.returns(None)
textbutton _("Planetarium") action None
frame:
style_group "pref"
has vbox
label _("Sound Volume")
bar style "slider" value .75 range 1.0 changed value_changed
textbutton "Test":
action ui.returns(None)
style "soundtest_button"
init -2 python:
style.pref_frame.xfill = True
style.pref_frame.xmargin = 5
style.pref_frame.top_margin = 5
style.pref_vbox.xfill = True
style.pref_button.size_group = "pref"
style.pref_button.xalign = 1.0
style.pref_slider.xmaximum = 192
style.pref_slider.xalign = 1.0
style.soundtest_button.xalign = 1.0
screen choose_theme:
frame:
style_group "l"
style "l_root"
window:
has vbox
label _("Choose Theme")
hbox:
yfill True
# Theme selector.
frame:
style "l_indent"
bottom_margin HALF_SPACER_HEIGHT
xmaximum 225
has vbox
label _("Theme") style "l_label_small"
viewport:
scrollbars "vertical"
yinitial theme_yinitial()
mousewheel True
has vbox
for i in theme_names():
textbutton "[i]":
action SetTheme(i)
hovered PreviewTheme(i, current_scheme)
style "l_list2"
# Color scheme selector.
frame:
style "l_indent"
bottom_margin HALF_SPACER_HEIGHT
xmaximum 225
has vbox
label _("Color Scheme") style "l_label_small"
viewport:
scrollbars "vertical"
mousewheel True
yinitial scheme_yinitial()
has vbox
for i in scheme_names(current_theme):
textbutton "[i]":
action SetScheme(i)
hovered PreviewTheme(current_theme, i)
style "l_list2"
# Preview
frame:
style "l_default"
background Frame(PATTERN, 0, 0, tile=True)
xpadding 5
ypadding 5
xfill True
yfill True
xmargin 20
bottom_margin 6
use theme_demo
textbutton _("Back") action Jump("front_page") style "l_left_button"
textbutton _("Continue") action Return(True) style "l_right_button"
label choose_theme_callable:
python:
current_theme, current_scheme = pick_theme(None, None)
implement_theme(current_theme, current_scheme)
call screen choose_theme
python hide:
with interface.error_handling("changing the theme"):
switch_theme()
return
label choose_theme:
call choose_theme_callable
jump front_page
File diff suppressed because it is too large Load Diff
+260
View File
@@ -0,0 +1,260 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python:
class PackageToggle(Action):
def __init__(self, name):
self.name = name
def get_selected(self):
return self.name in project.current.data['packages']
def __call__(self):
packages = project.current.data['packages']
if self.name in packages:
packages.remove(self.name)
else:
packages.append(self.name)
project.current.save_data()
renpy.restart_interaction()
class DataToggle(Action):
def __init__(self, field):
self.field = field
def get_selected(self):
return project.current.data[self.field]
def __call__(self):
project.current.data[self.field] = not project.current.data[self.field]
project.current.save_data()
renpy.restart_interaction()
DEFAULT_BUILD_INFO = """
## This section contains information about how to build your project into
## distribution files.
init python:
## The name that's used for directories and archive files. For example, if
## this is 'mygame-1.0', the windows distribution will be in the
## directory 'mygame-1.0-win', in the 'mygame-1.0-win.zip' file.
build.directory_name = "PROJECTNAME-1.0"
## The name that's uses for executables - the program that users will run
## to start the game. For example, if this is 'mygame', then on Windows,
## users can click 'mygame.exe' to start the game.
build.executable_name = "PROJECTNAME"
## If True, Ren'Py will include update information into packages. This
## allows the updater to run.
build.include_update = False
## File patterns:
##
## The following functions take file patterns. File patterns are case-
## insensitive, and matched against the path relative to the base
## directory, with and without a leading /. If multiple patterns match,
## the first is used.
##
##
## In a pattern:
##
## /
## Is the directory separator.
## *
## Matches all characters, except the directory separator.
## **
## Matches all characters, including the directory separator.
##
## For example:
##
## *.txt
## Matches txt files in the base directory.
## game/**.ogg
## Matches ogg files in the game directory or any of its subdirectories.
## **.psd
## Matches psd files anywhere in the project.
## Classify files as None to exclude them from the built distributions.
build.classify('**~', None)
build.classify('**.bak', None)
build.classify('**/.**', None)
build.classify('**/#**', None)
build.classify('**/thumbs.db', None)
## To archive files, classify them as 'archive'.
# build.classify('game/**.png', 'archive')
# build.classify('game/**.jpg', 'archive')
## Files matching documentation patterns are duplicated in a mac app
## build, so they appear in both the app and the zip file.
build.documentation('*.html')
build.documentation('*.txt')
"""
# A screen that displays a file or directory name, and
# lets the user change it,
#
# title
# The title of the link.
# value
# The value of the field.
screen distribute_name:
add SEPARATOR2
frame:
style "l_indent"
has vbox
text title
add HALF_SPACER
frame:
style "l_indent"
text "[value!q]"
add SPACER
screen build_distributions:
frame:
style_group "l"
style "l_root"
window:
has vbox
label _("Build Distributions: [project.current.name!q]")
add HALF_SPACER
hbox:
# Left side.
frame:
style "l_indent"
xmaximum ONEHALF
xfill True
has vbox
use distribute_name(
title=_("Directory Name:"),
value=project.current.dump["build"]["directory_name"])
use distribute_name(
title=_("Executable Name:"),
value=project.current.dump["build"]["executable_name"])
add SEPARATOR2
frame:
style "l_indent"
has vbox
text _("Actions:")
add HALF_SPACER
frame style "l_indent":
has vbox
textbutton _("Edit options.rpy") action editor.Edit("game/options.rpy", check=True)
textbutton _("Refresh") action Jump("build_distributions")
# Right side.
frame:
style "l_indent"
xmaximum ONEHALF
xfill True
has vbox
add SEPARATOR2
frame:
style "l_indent"
has vbox
text _("Build Packages:")
add HALF_SPACER
$ packages = project.current.dump["build"]["packages"]
for pkg in packages:
if not pkg["hidden"]:
$ description = pkg["description"]
textbutton "[description!q]" action PackageToggle(pkg["name"]) style "l_checkbox"
add SPACER
if project.current.dump["build"]["include_update"]:
textbutton _("Build Updates") action DataToggle("build_update") style "l_checkbox"
textbutton _("Back") action Jump("front_page") style "l_left_button"
textbutton _("Build") action Jump("distribute") style "l_right_button"
label build_update_dump:
python:
project.current.update_dump(True)
if project.current.dump.get("error", False):
interface.error(_("Errors were detected when running the project. Please ensure the project runs without errors before building distributions."))
return
label build_distributions:
call build_update_dump
if not project.current.dump["build"]["directory_name"]:
jump build_missing
call screen build_distributions
label build_missing:
python hide:
interface.yesno(_("Your project does not contain build information. Would you like to add build information to the end of options.rpy?"), yes=Return(True), no=Jump("front_page"))
build_info = DEFAULT_BUILD_INFO.replace("PROJECTNAME", project.current.name)
with open(os.path.join(project.current.path, "game", "options.rpy"), "a") as f:
f.write(build_info)
jump build_distributions
+150
View File
@@ -0,0 +1,150 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python:
import urllib2
import os
import threading
import time
class Downloader(object):
def __init__(self, url, dest):
"""
Downloads `url` to `dest`, providing progress reports
as necessary.
"""
self.url = url
# The destination file, and the destination temp file.
self.dest = dest
self.tmp = dest + ".tmp"
# Open the tmpfile.
self.safe_unlink(self.tmp)
self.tmpfile = open(self.tmp, "wb")
# Set by the thread to indicate progress (ranges from 0.0 to 1.0).
self.progress = 0.0
# This is set to true by cancel() to indicate the download should be cancelled.
self.cancelled = False
# Set on succes or failure.
self.success = False
self.failure = None
try:
# Open the URL.
self.urlfile = urllib2.urlopen(url)
t = threading.Thread(target=self.thread)
t.daemon = True
t.start()
except Exception as e:
self.failure = str(e)
def thread(self):
try:
count = 0
if "content-length" in self.urlfile.headers:
length = int(self.urlfile.headers["content-length"])
else:
length = 0
while not self.cancelled:
data = self.urlfile.read(65536)
if not data:
break
count += len(data)
self.tmpfile.write(data)
if length > 0:
self.progress = 1.0 * count / length
self.tmpfile.close()
if self.cancelled:
return
if length and count != length:
self.failure = "Download length does not match content length."
return
self.safe_unlink(self.dest)
os.rename(self.tmp, self.dest)
self.success = True
except Exception as e:
self.failure = str(e)
def safe_unlink(self, fn):
if os.path.exists(fn):
os.unlink(fn)
def cancel(self):
"""
Cancels the download.
"""
self.cancelled = True
def check(self):
"""
Returns True if the download is finished, False if it was cancelled,
None if it's ongoing, and raises an Exception if the download has failed.
"""
if self.success:
return True
if self.cancelled:
return False
if self.failure:
raise Exception("Downloading {} to {} failed: {}".format(self.url, self.dest, self.failure))
return None
class DownloaderValue(BarValue):
"""
A BarValue that reports the progress of a background download.
"""
def __init__(self, d):
self.downloader = d
def get_adjustment(self):
self.adjustment = ui.adjustment(value=0.0, range=1.0, adjustable=False)
return self.adjustment
def periodic(self, st):
self.adjustment.change(self.downloader.progress)
return .25
+498
View File
@@ -0,0 +1,498 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# Editor Support.
#
# This contains code for scanning for editors, and for allowing the user to
# select an editor.
init 1 python in editor:
from store import Action, renpy, config, persistent
import store.project as project
import store.updater as updater
import store.interface as interface
import store.util as util
import store
import glob
import re
import traceback
import os
import os.path
# Should we set up the editor?
set_editor = "RENPY_EDIT_PY" not in os.environ
# A map from editor name to EditorInfo object.
editors = { }
class EditorInfo(object):
def __init__(self, filename):
# The path to the editor info file.
self.filename = filename
# The name of the editor.
self.name = os.path.basename(filename)[:-len(".edit.py")]
# The time the editor file was last modified. We use this
# to decide if we should update the editors mat when we
# have multiple versions of an editor in contention.
self.mtime = os.path.getmtime(filename)
def scan_editor(filename):
"""
Inserts an editor into editors if there isn't a newer
editor there already.
"""
ei = EditorInfo(filename)
if ei.name in editors:
if editors[ei.name].mtime >= ei.mtime:
return
editors[ei.name] = ei
def scan_all():
"""
Finds all *.edit.py files, and uses them to populate the list
of editors.
"""
editors.clear()
for d in [ config.renpy_base, persistent.projects_directory ]:
if d is None:
continue
if not os.path.isdir(d):
continue
for i in util.listdir(d):
i = os.path.join(d, i)
if not os.path.isdir(d):
continue
for j in util.listdir(i):
j = os.path.join(i, j)
if j.endswith(".edit.py"):
scan_editor(j)
########################################################################
# A list of fancy_editor_info objects.
fancy_editors = [ ]
# The error message to display if an editor failed to start.
error_message = None
class FancyEditorInfo(object):
"""
Represents an editor in the selection screen. A FEI knows if the
editor is installed or not.
"""
def __init__(self, priority, name, description=None, dlc=None, dldescription=None, error_message=None):
# The priority of the editor. Lower priorities will come later
# in the list.
self.priority = priority
# The name of the editor.
self.name = name
# Is the editor installed?
self.installed = name in editors
# The dlc needed to install the editor.
self.dlc = dlc
# A description of the editor.
self.description = description
# A description of the download.
self.dldescription = dldescription
# An error message to display if the editor failed to start.
self.error_message = error_message
def fancy_scan_editors():
"""
Creates the list of FancyEditorInfo objects.
"""
global fancy_editors
scan_all()
fei = fancy_editors = [ ]
# Editra.
ED = _("{b}Recommended.{/b} A beta editor with an easy to use interface and features that aid in development, such as spell-checking. Editra currently lacks the IME support required for Chinese, Japanese, and Korean text input.")
EDL = _("{b}Recommended.{/b} A beta editor with an easy to use interface and features that aid in development, such as spell-checking. Editra currently lacks the IME support required for Chinese, Japanese, and Korean text input. On Linux, Editra requires wxPython.")
if renpy.windows:
dlc = "editra-windows"
installed = os.path.exists(os.path.join(config.basedir, "editra/Editra-win32"))
description = ED
error_message = None
elif renpy.macintosh:
dlc = "editra-mac"
installed = os.path.exists(os.path.join(config.basedir, "editra/Editra-mac.app"))
description = ED
error_message = None
else:
dlc = "editra-linux"
installed = os.path.exists(os.path.join(config.basedir, "editra/Editra"))
description = EDL
error_message = _("This may have occured because wxPython is not installed on this system.")
e = FancyEditorInfo(
1,
"Editra",
description,
dlc,
_("Up to 22 MB download required."),
error_message)
e.installed = e.installed or installed
fei.append(e)
# jEdit
fei.append(FancyEditorInfo(
2,
"jEdit",
_("A mature editor that requires Java."),
"jedit",
_("1.8 MB download required."),
_("This may have occured because Java is not installed on this system."),
))
fei.append(FancyEditorInfo(
3,
"System Editor",
_("Invokes the editor your operating system has associated with .rpy files."),
None))
for k in editors:
if k in [ "Editra", "jEdit", "System Editor", "None" ]:
continue
fei.append(FancyEditorInfo(
4,
k,
None,
None))
fei.append(FancyEditorInfo(
5,
"None",
_("Prevents Ren'Py from opening a text editor."),
None))
fei.sort(key=lambda e : (e.priority, e.name.lower()))
# If we're in a linux distro or something, assume all editors work.
if not updater.can_update():
for i in fei:
i.installed = True
def fancy_activate_editor(default=False):
"""
Activates the editor in persistent.editor, if it's installed.
`default`
"""
global error_message
fancy_scan_editors()
if default and not set_editor:
renpy.editor.init()
return
for i in fancy_editors:
if i.name == persistent.editor:
if i.installed and i.name in editors:
ei = editors[i.name]
os.environ["RENPY_EDIT_PY"] = renpy.fsencode(os.path.abspath(ei.filename))
error_message = i.error_message
break
else:
persistent.editor = None
os.environ.pop("RENPY_EDIT_PY", None)
renpy.editor.init()
def fancy_select_editor(name):
"""
Selects the editor with the given name, installing it if it
doesn't already exist.
"""
for fe in fancy_editors:
if fe.name == name:
break
else:
return
if not fe.installed:
# We don't check the status of this because fancy_activate_editor
# will fail if the editor is not installed.
store.add_dlc(fe.dlc)
persistent.editor = fe.name
fancy_activate_editor()
return persistent.editor is not None
# Call fancy_activate_editor on startup.
fancy_activate_editor(True)
class SelectEditor(Action):
def __init__(self, name):
self.name = name
def get_selected(self):
return persistent.editor == self.name
def __call__(self):
return fancy_select_editor(self.name)
def check_editor():
"""
Checks to see if an editor is set. If one isn't asks the user to
select one.
Returns True if the editor is set and editing can proceed, and
False otherwise.
"""
if not set_editor:
return True
if persistent.editor:
return True
return renpy.invoke_in_new_context(renpy.call_screen, "editor")
##########################################################################
# Editing actions.
class Edit(Action):
alt = "Edit [text]."
def __init__(self, filename, line=None, check=False):
"""
An action that opens the given line of the given file in a
text editor.
`filename`
The filename to open.
`line`
The line in the file to jump to.
`check`
If true, we will check to see if the file exists, and gray
out the box if it does not.
"""
self.filename = filename
self.line = line
self.check = check
def get_sensitive(self):
if not self.check:
return True
fn = project.current.unelide_filename(self.filename)
return os.path.exists(fn)
def __call__(self):
if not self.get_sensitive():
return
if not check_editor():
return
fn = project.current.unelide_filename(self.filename)
try:
e = renpy.editor.editor
e.begin()
e.open(fn, line=self.line)
e.end()
except Exception, e:
exception = traceback.format_exception_only(type(e), e)[-1][:-1]
renpy.invoke_in_new_context(interface.error, _("An exception occured while launching the text editor:\n[exception!q]"), error_message, exception=exception)
class EditAbsolute(Action):
def __init__(self, filename, line=None, check=False):
"""
An action that lets us edit an absolutely-specified filename.
`filename`
The filename to open.
`line`
The line in the file to jump to.
`check`
If true, we will check to see if the file exists, and gray
out the box if it does not.
"""
self.filename = filename
self.line = line
self.check = check
def get_sensitive(self):
if not self.check:
return True
return os.path.exists(self.filename)
def __call__(self):
if not self.get_sensitive():
return
if not check_editor():
return
try:
e = renpy.editor.editor
e.begin()
e.open(self.filename, line=self.line)
e.end()
except Exception, e:
exception = traceback.format_exception_only(type(e), e)[-1][:-1]
renpy.invoke_in_new_context(interface.error, _("An exception occured while launching the text editor:\n[exception!q]"), error_message, exception=exception)
class EditAll(Action):
"""
Opens all scripts that are part of the current project in a web browser.
"""
alt = "Edit [text]."
def __init__(self):
return
def __call__(self):
if not check_editor():
return
scripts = project.current.script_files()
scripts = [ i for i in scripts if not i.startswith("game/tl/") ]
scripts.sort(key=lambda fn : fn.lower())
for fn in [ "game/screens.rpy", "game/options.rpy", "game/script.rpy" ]:
if fn in scripts:
scripts.remove(fn)
scripts.insert(0, fn)
try:
e = renpy.editor.editor
e.begin()
for fn in scripts:
fn = project.current.unelide_filename(fn)
e.open(fn)
e.end()
except Exception, e:
exception = traceback.format_exception_only(type(e), e)[-1][:-1]
renpy.invoke_in_new_context(interface.error, _("An exception occured while launching the text editor:\n[exception!q]"), error_message, exception=exception)
screen editor:
frame:
style_group "l"
style "l_root"
window:
has vbox
label _("Select Editor")
add HALF_SPACER
hbox:
frame:
style "l_indent"
xfill True
viewport:
scrollbars "vertical"
mousewheel True
has vbox
text _("A text editor is the program you'll use to edit Ren'Py script files. Here, you can select the editor Ren'Py will use. If not already present, the editor will be automatically downloaded and installed.") style "l_small_text"
for fe in editor.fancy_editors:
add SPACER
textbutton fe.name action editor.SelectEditor(fe.name)
add HALF_SPACER
frame:
style "l_indent"
has vbox
if fe.description:
text fe.description style "l_small_text"
if not fe.installed:
add HALF_SPACER
text fe.dldescription style "l_small_text"
textbutton _("Cancel") action Return(False) style "l_left_button"
label editor_preference:
call screen editor
jump preferences
+288
View File
@@ -0,0 +1,288 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
define PROJECT_ADJUSTMENT = ui.adjustment()
init python:
import os
import subprocess
class OpenDirectory(Action):
"""
Opens `directory` in a file browser. `directory` is relative to
the project root.
"""
alt = _("Open [text] directory.")
def __init__(self, directory, absolute=False):
if absolute:
self.directory = directory
else:
self.directory = os.path.join(project.current.path, directory)
def get_sensitive(self):
return os.path.exists(self.directory)
def __call__(self):
try:
directory = renpy.fsencode(self.directory)
if renpy.windows:
os.startfile(directory)
elif renpy.macintosh:
subprocess.Popen([ "open", directory ])
else:
subprocess.Popen([ "xdg-open", directory ])
except:
pass
# Used for testing.
def Relaunch():
renpy.quit(relaunch=True)
screen front_page:
frame:
alt ""
style_group "l"
style "l_root"
has hbox
# Projects list section - on left.
frame:
style "l_projects"
xmaximum 300
right_margin 2
top_padding 20
bottom_padding 26
side "t c b":
window style "l_label":
has hbox:
xfill True
text "PROJECTS:" style "l_label_text" size 36 yoffset 10
textbutton _("refresh"):
xalign 1.0
yalign 1.0
yoffset 5
style "l_small_button"
action project.Rescan()
right_margin HALF_INDENT
side "c r":
viewport:
yadjustment PROJECT_ADJUSTMENT
mousewheel True
use front_page_project_list
vbar:
style "l_vscrollbar"
adjustment PROJECT_ADJUSTMENT
vbox:
add HALF_SPACER
add SEPARATOR
add HALF_SPACER
hbox:
xfill True
textbutton _("+ Create New Project"):
left_margin (HALF_INDENT)
action Jump("new_project")
# Project section - on right.
if project.current is not None:
use front_page_project
if project.current is not None:
textbutton _("Launch Project") action project.Launch() style "l_right_button"
# This is used by front_page to display the list of known projects on the screen.
screen front_page_project_list:
$ projects = project.manager.projects
$ templates = project.manager.templates
vbox:
if templates and persistent.show_templates:
for p in templates:
textbutton _("[p.name!q] (template)"):
action project.Select(p)
alt _("Select project [text].")
style "l_list"
null height 12
if projects:
for p in projects:
textbutton "[p.name!q]":
action project.Select(p)
alt _("Select project [text].")
style "l_list"
null height 12
textbutton _("Tutorial") action project.Select("tutorial") style "l_list" alt _("Select project [text].")
textbutton _("The Question") action project.Select("the_question") style "l_list" alt _("Select project [text].")
# This is used for the right side of the screen, which is where the project-specific
# buttons are.
screen front_page_project:
$ p = project.current
window:
has vbox
frame style "l_label":
has hbox xfill True
text "[p.name!q]" style "l_label_text"
label _("Active Project") style "l_alternate"
grid 2 1:
xfill True
spacing HALF_INDENT
vbox:
label _("Open Directory") style "l_label_small"
frame style "l_indent":
has vbox
textbutton _("game") action OpenDirectory("game")
textbutton _("base") action OpenDirectory(".")
# textbutton _("images") action OpenDirectory("game/images") style "l_list"
# textbutton _("save") action None style "l_list"
vbox:
label _("Edit File") style "l_label_small"
frame style "l_indent":
has vbox
textbutton "script.rpy" action editor.Edit("game/script.rpy", check=True)
textbutton "options.rpy" action editor.Edit("game/options.rpy", check=True)
textbutton "screens.rpy" action editor.Edit("game/screens.rpy", check=True)
textbutton _("All script files") action editor.EditAll()
add SPACER
add SEPARATOR
add SPACER
frame style "l_indent":
has vbox
textbutton _("Navigate Script") text_size 30 action Jump("navigation")
add SPACER
grid 2 1:
xfill True
spacing HALF_INDENT
frame style "l_indent":
has vbox
textbutton _("Check Script (Lint)") action Jump("lint")
textbutton _("Change Theme") action Jump("choose_theme")
textbutton _("Delete Persistent") action Jump("rmpersistent")
textbutton _("Force Recompile") action Jump("force_recompile")
# textbutton "Relaunch" action Relaunch
frame style "l_indent":
has vbox
if ability.can_distribute:
textbutton _("Build Distributions") action Jump("build_distributions")
textbutton _("Android") action Jump("android")
textbutton _("Generate Translations") action Jump("translate")
textbutton _("Extract Dialogue") action Jump("extract_dialogue")
label main_menu:
return
label start:
show screen bottom_info
label front_page:
call screen front_page
jump front_page
label lint:
python hide:
interface.processing(_("Checking script for potential problems..."))
lint_fn = project.current.temp_filename("lint.txt")
project.current.launch([ 'lint', lint_fn ], wait=True)
e = renpy.editor.editor
e.begin(True)
e.open(lint_fn)
e.end()
jump front_page
label rmpersistent:
python hide:
interface.processing(_("Deleting persistent data..."))
project.current.launch([ 'rmpersistent' ], wait=True)
jump front_page
label force_recompile:
python hide:
interface.processing(_("Recompiling all rpy files into rpyc files..."))
project.current.launch([ 'compile' ], wait=True)
jump front_page
Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Before

Width:  |  Height:  |  Size: 60 KiB

After

Width:  |  Height:  |  Size: 60 KiB

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 687 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 96 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

+481
View File
@@ -0,0 +1,481 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
################################################################################
# Interface actions.
init python in interface:
from store import OpenURL, config, Return
import store
import os.path
import contextlib
RENPY_URL = "http://www.renpy.org"
RENPY_GAMES_URL = "http://games.renpy.org"
DOC_PATH = os.path.join(config.renpy_base, "doc/index.html")
DOC_URL = "http://www.renpy.org/doc/html/"
LICENSE_PATH = os.path.join(config.renpy_base, "doc/license.html")
LICENSE_URL = "http://www.renpy.org/doc/html/license.html"
if os.path.exists(DOC_PATH):
DOC_LOCAL_URL = "file:///" + DOC_PATH
else:
DOC_LOCAL_URL = None
if os.path.exists(LICENSE_PATH):
LICENSE_LOCAL_URL = "file:///" + LICENSE_PATH
else:
LICENSE_LOCAL_URL = None
def OpenDocumentation():
"""
An action that opens the documentation.
"""
if DOC_LOCAL_URL is not None:
return OpenURL(DOC_LOCAL_URL)
else:
return OpenURL(DOC_URL)
def OpenLicense():
"""
An action that opens the license.
"""
if LICENSE_LOCAL_URL is not None:
return OpenURL(LICENSE_LOCAL_URL)
else:
return OpenURL(LICENSE_URL)
# Should we display the bottom links?
links = True
@contextlib.contextmanager
def nolinks():
global links
links = False
try:
yield
finally:
links = True
# This displays the bottom of the screen. If the tooltip is not None, this displays the
# tooltip. Otherwise, it displays a list of links (to various websites, and to the
# preferences and update screen), or is just blank.
screen bottom_info:
zorder 100
if interface.links:
frame:
style_group "l"
style "l_default"
left_margin (10 + INDENT)
right_margin (10 + INDENT)
xfill True
ypos 536
yanchor 0.0
hbox:
xfill True
hbox:
spacing INDENT
textbutton _("Documentation") style "l_link" action interface.OpenDocumentation()
textbutton _("Ren'Py Website") style "l_link" action OpenURL(interface.RENPY_URL)
textbutton _("Ren'Py Games List") style "l_link" action OpenURL(interface.RENPY_GAMES_URL)
textbutton _("About") style "l_link" action Jump("about")
hbox:
spacing INDENT
xalign 1.0
if ability.can_update:
textbutton _("update") action Jump("update") style "l_link"
textbutton _("preferences") style "l_link" action Jump("preferences")
textbutton _("quit") style "l_link" action Quit(confirm=False)
screen common:
default complete = None
default total = None
default yes = None
default no = None
default choices = None
default cancel = None
default bar_value = None
frame:
style "l_root"
frame:
style_group "l_info"
has vbox
text message:
text_align 0.5
xalign 0.5
layout "subtitle"
if complete is not None:
add SPACER
frame:
style "l_progress_frame"
bar:
range total
value complete
style "l_progress_bar"
if bar_value is not None:
add SPACER
frame:
style "l_progress_frame"
bar:
value bar_value
style "l_progress_bar"
if choices:
add SPACER
for v, l in choices:
textbutton l action SetScreenVariable("selected", v)
if selected is not None:
$ continue_ = Return(selected)
else:
$ continue_ = None
if submessage:
add SPACER
text submessage:
text_align 0.5
xalign 0.5
layout "subtitle"
if yes:
add SPACER
hbox:
xalign 0.5
textbutton _("Yes") style "l_button" action yes
null width 160
textbutton _("No") style "l_button" action no
label title text_color title_color style "l_info_label"
if back:
textbutton _("Back") action back style "l_left_button"
elif cancel:
textbutton _("Cancel") action cancel style "l_left_button"
if continue_:
textbutton _("Continue") action continue_ style "l_right_button"
screen launcher_input:
frame:
style "l_root"
frame:
style_group "l_info"
has vbox
text message:
text_align 0.5
xalign 0.5
layout "subtitle"
add SPACER
input style "l_default" size 24 xalign 0.5 default default color INPUT_COLOR
if filename:
add SPACER
text _("Due to package format limitations, non-ASCII file and directory names are not allowed.")
label title style "l_info_label" text_color QUESTION_COLOR
if cancel:
textbutton _("Cancel") action cancel style "l_left_button"
init python in interface:
import traceback
from store import Jump
def common(title, title_color, message, submessage=None, back=None, continue_=None, pause0=False, show_screen=False, **kwargs):
"""
Displays the info, interaction, and processing screens.
`title`
The title of the screen.
`message`
The main message that is displayed when the screen is.
`submessage`
If not None, a message that is displayed below the main message.
`back`
If not None, a back button will be present. `back` is the action that
is called when the button is clicked.
`cancel`
If not None, a cancel button will be present. `cancel` is the action
that is called when the button is clicked.
`continue_`
If True, a continue button will be present. `continue_` gives the action
that is called when that button is clicked.
`pause0`
If True, a zero-length pause will be inserted before calling the
screen. This will display it to the user and then immediately
return.
`show_screen`
If True, the screen will be show, and will return immediately. if False,
the screen will be called, and interaction will pause.
Other keyword arguments are passed to the screen itself.
"""
if show_screen:
screen_func = renpy.show_screen
else:
screen_func = renpy.call_screen
if pause0:
ui.pausebehavior(0)
return screen_func("common", title=title, title_color=title_color, message=message, submessage=submessage, back=back, continue_=continue_, **kwargs)
def hide_screen():
"""
Hides a screen that was shown with show_screen=True.
"""
renpy.hide_screen("common")
def error(message, submessage=None, label="front_page", **kwargs):
"""
Indicates to the user that an error has occured.
`message`
The message to display.
`submessage`
Optional secondary message information. For example, this may be
used to display an exception string.
`label`
The label to redirect to when the user finishes displaying the error. None
to just return False.
Keyword arguments are passed into the screen so that they can be substituted into
the message.
"""
if label is None:
action = Return(False)
else:
action = Jump(label)
common(_("ERROR"), store.ERROR_COLOR, message=message, submessage=submessage, back=action, **kwargs)
@contextlib.contextmanager
def error_handling(what, label="front_page"):
"""
This is a context manager that catches exceptions and displays them using
interface.error.
`what`
What we're doing when the error occurs. This is usually written using
the present participle.
`label`
The label to jump to when error handling finishes.
As an example of usage::
with interface.error_handling("opening the log file"):
f = open("log.txt", "w")
"""
try:
yield
except Exception, e:
import traceback
traceback.print_exc()
error(_("While [what!q], an error occured:"),
_("[exception!q]"),
what=what,
label=label,
exception=traceback.format_exception_only(type(e), e)[-1][:-1])
def input(title, message, filename=False, sanitize=True, cancel=None, default=""):
"""
Requests typewritten input from the user.
"""
rv = default
while True:
rv = renpy.call_screen("launcher_input", title=title, message=message, filename=filename, cancel=cancel, default=rv)
if sanitize:
if ("[" in rv) or ("{" in rv):
error(_("Text input may not contain the {{ or [[ characters."), label=None)
continue
if filename:
if filename and (filename != "withslash") and (("\\" in rv) or ("/" in rv)):
error(_("File and directory names may not contain / or \\."), label=None)
continue
try:
rv.encode("ascii")
except:
error(_("File and directory names must consist of ASCII characters."), label=None)
continue
return rv
def info(message, submessage=None, pause=True, **kwargs):
"""
Displays an informational message to the user. The user will be asked to click to
confirm that he has read the message.
`message`
The message to display.
`pause`
True if we should pause while showing the info.
Keyword arguments are passed into the screen so that they can be substituted into
the message.
"""
if pause:
common(_("INFORMATION"), store.INFO_COLOR, message, submessage, continue_=Return(True), **kwargs)
else:
common(_("INFORMATION"), store.INFO_COLOR, message, submessage, pause0=True, **kwargs)
def interaction(title, message, submessage=None, pause=0, **kwargs):
"""
Put up on the screen while an interaction with an external program occurs.
This shows the message, then immediately returns.
`title`
The title of the interaction.
`message`
The message itself.
`submessage`
An optional sub message.
`pause`
The amount of time to pause for after showing the message.
"""
common(title, store.INTERACTION_COLOR, message, submessage=None, pause=pause, show_screen=True, **kwargs)
renpy.pause(pause)
def processing(message, submessage=None, complete=None, total=None, **kwargs):
"""
Indicates to the user that processing is taking place. This should be used when
there is an indefinite amount of work to be done.
`message`
The message to display.
`submessage`
An additional message to display.
`complete`
The fraction complete the step is.
`total`
The total amount of work to do in this step.
Keyword arguments are passed into the screen so that they can be substituted into
the message.
"""
common(_("PROCESSING"), store.INTERACTION_COLOR, message, submessage, pause0=True, complete=complete, total=total, **kwargs)
def yesno(message, yes=Return(True), no=Return(False), **kwargs):
"""
Asks the user a yes or no question.
`message`
The question to ask.
`yes`
The action to perform if the user answers yes.
`no`
The action to perform if the user answer no.
"""
return common(_("QUESTION"), store.QUESTION_COLOR, message, yes=yes, no=no, **kwargs)
def choice(message, choices, selected, **kwargs):
"""
Asks the user to pick a choice from a menu.
`choices`
A list of (value, label) tuples, giving the choices.
`selected`
The default choice that we mark as selected.
"""
return common(_("CHOICE"), store.QUESTION_COLOR, message, choices=choices, selected=selected, **kwargs)
+280
View File
@@ -0,0 +1,280 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python in navigation:
import store.interface as interface
import store.project as project
import store.editor as editor
from store import persistent, Action
# The last navigation screen we've seen. This is the scree we try to go
# to the next time we enter navigation. (We may not be able to go there,
# if the screen is empty.)
if persistent.navigation is None:
persistent.navigation = "label"
# A map from a kind of information, to how we should sort it. Possible
# sorts are alphabetical, by-file, natural.
if persistent.navigation_sort is None:
persistent.navigation_sort = { }
if persistent.navigate_private is None:
persistent.navigate_private = False
if persistent.navigate_library is None:
persistent.navigate_library = False
# A list of kinds of navigation we support.
KINDS = [ "file", "label", "define", "transform", "screen", "callable", "todo" ]
# A map from kind name to adjustment.
adjustments = { }
for i in KINDS:
persistent.navigation_sort.setdefault(i, "by-file")
adjustments[i] = ui.adjustment()
def group_and_sort(kind):
"""
This is responsible for pulling navigation information of the
appropriate kind out of project.current.dump, grouping it,
and sorting it.
This returns a list of (group, list of (name, filename, line)). The
group may be a string or None.
"""
project.current.update_dump()
sort = persistent.navigation_sort[kind]
name_map = project.current.dump.get("location", {}).get(kind, { })
groups = { }
for name, loc in name_map.items():
filename, line = loc
filename = filename.replace("\\", "/")
if sort == "alphabetical":
group = None
else:
group = filename
if group.startswith("game/"):
group = group[5:]
g = groups.get(group, None)
if g is None:
groups[group] = g = [ ]
g.append((name, filename, line))
for g in groups.values():
if sort == "natural":
g.sort(key=lambda a : a[2])
else:
g.sort(key=lambda a : a[0].lower())
rv = list(groups.items())
rv.sort()
return rv
def group_and_sort_files():
rv = [ ]
for fn in project.current.script_files():
shortfn = fn
shortfn = shortfn.replace("\\", "/")
if shortfn.startswith("game/"):
shortfn = fn[5:]
rv.append((shortfn, fn, None))
rv.sort()
return [ (None, rv) ]
class ChangeKind(Action):
"""
Changes the kind of thing we're navigating over.
"""
def __init__(self, kind):
self.kind = kind
def get_selected(self):
return persistent.navigation == self.kind
def __call__(self):
if persistent.navigation == self.kind:
return
persistent.navigation = self.kind
renpy.jump("navigation_loop")
class ChangeSort(Action):
"""
Changes the sort order.
"""
def __init__(self, sort):
self.sort = sort
def get_selected(self):
return persistent.navigation_sort[persistent.navigation] == self.sort
def __call__(self):
if self.get_selected():
return
persistent.navigation_sort[persistent.navigation] = self.sort
renpy.jump("navigation_loop")
screen navigation:
frame:
style_group "l"
style "l_root"
window:
has vbox
frame style "l_label":
has hbox xfill True
text _("Navigate: [project.current.name]") style "l_label_text"
frame:
style "l_alternate"
style_group "l_small"
has hbox
if persistent.navigation != "file":
text _("Order: ")
textbutton _("alphabetical") action navigation.ChangeSort("alphabetical")
text " | "
textbutton _("by-file") action navigation.ChangeSort("by-file")
text " | "
textbutton _("natural") action navigation.ChangeSort("natural")
null width HALF_INDENT
textbutton _("refresh") action Jump("navigation_refresh")
add HALF_SPACER
frame style "l_indent":
hbox:
spacing HALF_INDENT
text _("Category:")
textbutton _("files") action navigation.ChangeKind("file")
textbutton _("labels") action navigation.ChangeKind("label")
textbutton _("defines") action navigation.ChangeKind("define")
textbutton _("transforms") action navigation.ChangeKind("transform")
textbutton _("screens") action navigation.ChangeKind("screen")
textbutton _("callables") action navigation.ChangeKind("callable")
textbutton _("TODOs") action navigation.ChangeKind("todo")
add SPACER
add SEPARATOR
frame style "l_indent_margin":
if groups:
viewport:
mousewheel True
scrollbars "vertical"
yadjustment navigation.adjustments[persistent.navigation]
vbox:
style_group "l_navigation"
for group_name, group in groups:
if group_name is not None:
text "[group_name!q]"
if persistent.navigation == "todo":
vbox:
for name, filename, line in group:
textbutton "[name!q]" action editor.Edit(filename, line)
else:
hbox:
box_wrap True
for name, filename, line in group:
textbutton "[name!q]" action editor.Edit(filename, line)
if group_name is not None:
add SPACER
if persistent.navigation == "file":
add SPACER
textbutton _("+ Add script file") action Jump("add_file") style "l_button"
else:
fixed:
if persistent.navigation == "todo":
text _("No TODO comments found.\n\nTo create one, include \"# TODO\" in your script."):
text_align 0.5
xalign 0.5
yalign 0.5
else:
text _("The list of names is empty."):
xalign 0.5
yalign 0.5
textbutton _("Back") action Jump("front_page") style "l_left_button"
textbutton _("Launch Project") action project.Launch() style "l_right_button"
label navigation:
label navigation_loop:
python in navigation:
kind = persistent.navigation
if kind == "file":
groups = group_and_sort_files()
else:
groups = group_and_sort(kind)
renpy.call_screen("navigation", groups=groups)
label navigation_refresh:
$ project.current.update_dump(True)
jump navigation_loop
+128
View File
@@ -0,0 +1,128 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python:
import shutil
import os
import time
import re
screen select_template:
default result = project.manager.get("english")
frame:
style_group "l"
style "l_root"
window:
has vbox
label _("Choose Project Template")
hbox:
frame:
style "l_indent"
xmaximum ONETHIRD
viewport:
scrollbars "vertical"
vbox:
for p in project.manager.templates:
textbutton "[p.name!q]" action SetScreenVariable("result", p) style "l_list"
frame:
style "l_indent"
xmaximum TWOTHIRDS
text _("Please select a template to use for your new project. The template sets the default font and the user interface language. If your language is not supported, choose 'english'.")
textbutton _("Back") action Jump("front_page") style "l_left_button"
textbutton _("Continue") action Return(result) style "l_right_button"
label new_project:
if persistent.projects_directory is None:
call choose_projects_directory
if persistent.projects_directory is None:
$ interface.error(_("The projects directory could not be set. Giving up."))
python hide:
project_name = interface.input(
_("PROJECT NAME"),
_("Please enter the name of your project:"),
filename=True,
cancel=Jump("front_page"))
project_name = project_name.strip()
if not project_name:
interface.error(_("The project name may not be empty."))
project_dir = os.path.join(persistent.projects_directory, project_name)
if project.manager.get(project_name) is not None:
interface.error(_("[project_name!q] already exists. Please choose a different project name."), project_name=project_name)
if os.path.exists(project_dir):
interface.error(_("[project_dir!q] already exists. Please choose a different project name."), project_dir=project_dir)
if len(project.manager.templates) == 1:
template = project.manager.templates[0]
else:
template = renpy.call_screen("select_template")
template_path = template.path
with interface.error_handling("creating a new project"):
shutil.copytree(template_path, project_dir, symlinks=False)
# Delete the tmp directory, if it exists.
if os.path.isdir(os.path.join(project_dir, "tmp")):
shutil.rmtree(os.path.join(project_dir, "tmp"))
# Delete project.json, which must exist.
os.unlink(os.path.join(project_dir, "project.json"))
# Change the save directory in options.rpy
fn = os.path.join(project_dir, "game/options.rpy")
with open(fn, "rb") as f:
options = f.read().decode("utf-8")
options = options.replace("PROJECT_NAME", project_name)
options = options.replace("UNIQUE", str(int(time.time())))
with open(fn, "wb") as f:
f.write(options.encode("utf-8"))
# Activate the project.
with interface.error_handling("activating the new project"):
project.manager.scan()
project.Select(project.manager.get(project_name))()
call choose_theme_callable
jump front_page
+346
View File
@@ -0,0 +1,346 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
## This file contains some of the options that can be changed to customize
## your Ren'Py game. It only contains the most common options... there
## is quite a bit more customization you can do.
##
## Lines beginning with two '#' marks are comments, and you shouldn't
## uncomment them. Lines beginning with a single '#' mark are
## commented-out code, and you may want to uncomment them when
## appropriate.
init -1 python hide:
## Should we enable the use of developer tools? This should be
## set to False before the game is released, so the user can't
## cheat using developer tools.
config.developer = True
## These control the width and height of the screen.
config.screen_width = 800
config.screen_height = 600
## This controls the title of the window, when Ren'Py is
## running in a window.
config.window_title = u"Ren'Py Launcher"
# These control the name and version of the game, that are reported
# with tracebacks and other debugging logs.
config.name = "Ren'Py Launcher"
config.version = renpy.version().split()[1]
#########################################
# Themes
## We then want to call a theme function. themes.roundrect is
## a theme that features the use of rounded rectangles. It's
## the only theme we currently support.
##
## The theme function takes a number of parameters that can
## customize the color scheme.
theme.roundrect(
## Theme: Roundrect
## Color scheme: Basic Blue
## The color of an idle widget face.
widget = "#003c78",
## The color of a focused widget face.
widget_hover = "#0050a0",
## The color of the text in a widget.
widget_text = "#c8ffff",
## The color of the text in a selected widget. (For
## example, the current value of a preference.)
widget_selected = "#ffffc8",
## The color of a disabled widget face.
disabled = "#404040",
## The color of disabled widget text.
disabled_text = "#c8c8c8",
## The color of informational labels.
label = "#ffffff",
## The color of a frame containing widgets.
frame = "#6496c8",
## The background of the main menu. This can be a color
## beginning with '#', or an image filename. The latter
## should take up the full height and width of the screen.
mm_root = "#dcebff",
## The background of the game menu. This can be a color
## beginning with '#', or an image filename. The latter
## should take up the full height and width of the screen.
gm_root = "#dcebff",
## If this is True, the in-game window is rounded. If False,
## the in-game window is square.
rounded_window = False,
## And we're done with the theme. The theme will customize
## various styles, so if we want to change them, we should
## do so below.
)
#########################################
## Help.
## This lets you configure the help option on the Ren'Py menus.
## It may be:
## - A label in the script, in which case that label is called to
## show help to the user.
## - A file name relative to the base directory, which is opened in a
## web browser.
## - None, to disable help.
config.help = "README.html"
#########################################
## Transitions.
## Used when entering the game menu from the game.
config.enter_transition = None
## Used when exiting the game menu to the game.
config.exit_transition = None
## Used between screens of the game menu.
config.intra_transition = None
## Used when entering the game menu from the main menu.
config.main_game_transition = None
## Used when returning to the main menu from the game.
config.game_main_transition = None
## Used when entering the main menu from the splashscreen.
config.end_splash_transition = None
## Used when entering the main menu after the game has ended.
config.end_game_transition = None
## Used when a game is loaded.
config.after_load_transition = None
## Used when the window is shown.
config.window_show_transition = None
## Used when the window is hidden.
config.window_hide_transition = None
#########################################
## This is the name of the directory where the game's data is
## stored. (It needs to be set early, before any other init code
## is run, so the persistent information can be found by the init code.)
python early:
config.save_directory = "launcher-4"
init -1 python hide:
#########################################
## Default values of Preferences.
## Note: These options are only evaluated the first time a
## game is run. To have them run a second time, delete
## game/saves/persistent
## Should we start in fullscreen mode?
config.default_fullscreen = False
## The default text speed in characters per second. 0 is infinite.
config.default_text_cps = 0
#########################################
## More customizations can go here.
config.sound = False
config.quit_action = Quit(confirm=False)
config.gl_resize = False
config.window_icon = "images/logo.png"
config.windows_icon = "images/logo32.png"
config.has_autosave = False
config.log_enable = False
config.mouse_hide_time = 86400 * 366
_game_menu_screen = None
config.underlay = [
renpy.Keymap(
quit = renpy.quit_event,
iconify = renpy.iconify,
choose_renderer = renpy.curried_call_in_new_context("_choose_renderer"),
self_voicing = Preference("self voicing", "toggle"),
),
]
config.rollback_enabled = False
translate None python:
config.rtl = False
## This section controls how to build Ren'Py. (Building the launcher is how
## we build Ren'Py distributions.)
init python:
## We're building Ren'Py tonight.
build.renpy = True
## The version number that's supplied to the updater.
build.version = "Ren'Py {}".format(config.version)
## The name that's used for directories and archive files. For example, if
## this is 'mygame-1.0', the windows distribution will be in the
## directory 'mygame-1.0-win', in the 'mygame-1.0-win.zip' file.
if 'RENPY_NIGHTLY' in os.environ:
build.directory_name = os.environ['RENPY_NIGHTLY']
else:
build.directory_name = "renpy-" + config.version.rsplit('.', 1)[0]
## The name that's uses for executables - the program that users will run
## to start the game. For example, if this is 'mygame', then on Windows,
## users can click 'mygame.exe' to start the game.
build.executable_name = "renpy"
## If True, Ren'Py will include update information into packages. This
## allows the updater to run.
build.include_update = True
## Clear out various file patterns.
build.renpy_patterns = [ ]
build.early_base_patterns = [ ]
build.base_patterns = [ ]
build.late_base_patterns = [ ]
# We don't need to clear out the executable patterns, since they're
# correct for Ren'Py.
## Now, add the Ren'Py distribution in using classify_renpy.
build.classify_renpy("rapt/**", "rapt")
build.classify_renpy("**~", None)
build.classify_renpy("**/#*", None)
build.classify_renpy("**/thumbs.db", None)
build.classify_renpy("**/.*", None)
build.classify_renpy("**.old", None)
build.classify_renpy("**.new", None)
build.classify_renpy("**.bak", None)
build.classify_renpy("**.pyc", None)
build.classify_renpy("**/log.txt", None)
build.classify_renpy("**/traceback.txt", None)
build.classify_renpy("**/errors.txt", None)
build.classify_renpy("**/saves/", None)
build.classify_renpy("**/tmp/", None)
build.classify_renpy("**/.Editra", None)
# main source.
def source_and_binary(pattern):
"""
Classifies source and binary files beginning with `pattern`.
.pyo, .rpyc, .rpycm, and .rpyb go into binary, everything
else goes into source.
"""
build.classify_renpy(pattern + ".pyo", "binary")
build.classify_renpy(pattern + ".rpyc", "binary")
build.classify_renpy(pattern + ".rpymc", "binary")
build.classify_renpy(pattern + ".rpyb", "binary")
build.classify_renpy(pattern, "source")
build.classify_renpy("renpy.py", "source")
source_and_binary("renpy/**")
# games.
build.classify_renpy("launcher/game/theme/", None)
source_and_binary("launcher/**")
source_and_binary("templates/**")
source_and_binary("the_question/**")
source_and_binary("tutorial/**")
# docs.
build.classify_renpy("doc/", "source")
build.classify_renpy("doc/.doctrees/", None)
build.classify_renpy("doc/_sources/", None)
build.classify_renpy("doc/**", "source")
build.classify_renpy("LICENSE.txt", "source")
# module.
build.classify_renpy("module/", "source")
build.classify_renpy("module/*.c", "source")
build.classify_renpy("module/gen/", "source")
build.classify_renpy("module/gen/*.c", "source")
build.classify_renpy("module/*.h", "source")
build.classify_renpy("module/*.py*", "source")
build.classify_renpy("module/include/", "source")
build.classify_renpy("module/include/*.pxd", "source")
build.classify_renpy("module/pysdlsound/", "source")
build.classify_renpy("module/pysdlsound/*.py", "source")
build.classify_renpy("module/pysdlsound/*.pyx", "source")
# all-platforms binary.
build.classify_renpy("lib/*/renpy", None)
build.classify_renpy("lib/*/renpy.exe", None)
build.classify_renpy("lib/**", "binary")
build.classify_renpy("renpy.sh", "binary")
build.classify_renpy("renpy.exe", "binary")
# renpy.app is now built from scratch from distribute.rpy.
# jedit rules.
build.classify_renpy("jedit/**", "jedit")
# editra rules.
build.classify_renpy("editra/", "editra-all")
build.classify_renpy("editra/Editra.edit.py", "editra-all")
build.classify_renpy("editra/Editra/**", "editra-linux editra-windows")
build.classify_renpy("editra/Editra-mac.app/**", "editra-mac")
build.classify_renpy("editra/lib/**", "editra-windows")
build.classify_renpy("editra/editra.exe", "editra-windows")
# Executable rules.
build.executable("editra/Editra/Editra")
# Packages.
build.packages = [ ]
build.package("sdk", "zip tar.bz2", "source binary")
build.package("source", "tar.bz2", "source", update=False)
build.package("jedit", "zip", "jedit", dlc=True)
build.package("editra-linux", "tar.bz2", "editra-all editra-linux", dlc=True)
build.package("editra-mac", "zip", "editra-all editra-mac", dlc=True)
build.package("editra-windows", "zip", "editra-all editra-windows", dlc=True)
build.package("rapt", "zip", "rapt", dlc=True)
+226
View File
@@ -0,0 +1,226 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python in distribute:
import time
import zipfile
import tarfile
import zlib
import struct
import stat
import shutil
from zipfile import crc32
zlib.Z_DEFAULT_COMPRESSION = 9
class ZipFile(zipfile.ZipFile):
def write_with_info(self, zinfo, filename):
"""Put the bytes from filename into the archive under the name
arcname."""
if not self.fp:
raise RuntimeError(
"Attempt to write to ZIP archive that was already closed")
st = os.stat(filename)
isdir = stat.S_ISDIR(st.st_mode)
zinfo.file_size = st.st_size
zinfo.flag_bits = 0x00
zinfo.header_offset = self.fp.tell() # Start of header bytes
self._writecheck(zinfo)
self._didModify = True
if isdir:
zinfo.file_size = 0
zinfo.compress_size = 0
zinfo.CRC = 0
self.filelist.append(zinfo)
self.NameToInfo[zinfo.filename] = zinfo
self.fp.write(zinfo.FileHeader())
return
with open(filename, "rb") as fp:
# Must overwrite CRC and sizes with correct data later
zinfo.CRC = CRC = 0
zinfo.compress_size = compress_size = 0
zinfo.file_size = file_size = 0
self.fp.write(zinfo.FileHeader())
if zinfo.compress_type == zipfile.ZIP_DEFLATED:
cmpr = zlib.compressobj(zlib.Z_DEFAULT_COMPRESSION,
zlib.DEFLATED, -15)
else:
cmpr = None
while 1:
buf = fp.read(1024 * 1024)
if not buf:
break
file_size = file_size + len(buf)
CRC = crc32(buf, CRC) & 0xffffffff
if cmpr:
buf = cmpr.compress(buf)
compress_size = compress_size + len(buf)
self.fp.write(buf)
if cmpr:
buf = cmpr.flush()
compress_size = compress_size + len(buf)
self.fp.write(buf)
zinfo.compress_size = compress_size
else:
zinfo.compress_size = file_size
zinfo.CRC = CRC
zinfo.file_size = file_size
# Seek backwards and write CRC and file sizes
position = self.fp.tell() # Preserve current position in file
self.fp.seek(zinfo.header_offset + 14, 0)
self.fp.write(struct.pack("<LLL", zinfo.CRC, zinfo.compress_size,
zinfo.file_size))
self.fp.seek(position, 0)
self.filelist.append(zinfo)
self.NameToInfo[zinfo.filename] = zinfo
class ZipPackage(object):
"""
A class that creates a zip file.
"""
def __init__(self, filename):
self.zipfile = ZipFile(filename, "w", zipfile.ZIP_DEFLATED)
def add_file(self, name, path, xbit):
if path is None:
raise Exception("path for " + name + " must not be None.")
zi = zipfile.ZipInfo(name)
try:
s = os.stat(path)
zi.date_time = time.gmtime(s.st_mtime)[:6]
except:
zi.date_time = time.gmtime()[:6]
zi.compress_type = zipfile.ZIP_DEFLATED
zi.create_system = 3
if xbit:
zi.external_attr = long(0100755) << 16
else:
zi.external_attr = long(0100644) << 16
self.zipfile.write_with_info(zi, path)
def add_directory(self, name, path):
if path is None:
return
zi = zipfile.ZipInfo(name + "/")
s = os.stat(path)
zi.date_time = time.gmtime(s.st_mtime)[:6]
zi.compress_type = zipfile.ZIP_STORED
zi.create_system = 3
zi.external_attr = (long(0040755) << 16) | 0x10
self.zipfile.write_with_info(zi, path)
def close(self):
self.zipfile.close()
class TarPackage(object):
def __init__(self, filename, mode, notime=False):
"""
notime
If true, times will be forced to the epoch.
"""
self.tarfile = tarfile.open(filename, mode)
self.tarfile.dereference = True
self.notime = notime
def add_file(self, name, path, xbit):
if path is not None:
info = self.tarfile.gettarinfo(path, name)
else:
info = tarfile.TarInfo(name)
info.size = 0
info.mtime = int(time.time())
info.type = tarfile.DIRTYPE
if xbit:
info.mode = 0755
else:
info.mode = 0644
info.uid = 1000
info.gid = 1000
info.uname = "renpy"
info.gname = "renpy"
if self.notime:
info.mtime = 0
if info.isreg():
with open(path, "rb") as f:
self.tarfile.addfile(info, f)
else:
self.tarfile.addfile(info)
def add_directory(self, name, path):
self.add_file(name, path, True)
def close(self):
self.tarfile.close()
class DirectoryPackage(object):
def mkdir(self, path):
if not os.path.isdir(path):
os.mkdir(path, 0755)
def __init__(self, path):
self.path = path
self.mkdir(path)
def add_file(self, name, path, xbit):
fn = os.path.join(self.path, name)
shutil.copy2(path, fn)
if xbit:
os.chmod(fn, 0755)
else:
os.chmod(fn, 0644)
def add_directory(self, name, path):
fn = os.path.join(self.path, name)
self.mkdir(fn)
def close(self):
return
File diff suppressed because it is too large Load Diff
+234
View File
@@ -0,0 +1,234 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python:
if persistent.gl_enable is None:
persistent.gl_enable = True
config.gl_enable = persistent.gl_enable
if persistent.windows_console is None:
persistent.windows_console = False
def scan_translations():
languages = renpy.known_languages()
if not languages:
return None
rv = [ ( "English", None) ]
for i in languages:
rv.append((i.replace("_", " ").title(), i))
rv.sort()
return rv
screen preferences:
$ translations = scan_translations()
frame:
style_group "l"
style "l_root"
alt "Preferences"
window:
has vbox
label _("Launcher Preferences")
add HALF_SPACER
hbox:
frame:
style "l_indent"
xmaximum ONETHIRD
xfill True
has vbox
# Projects directory selection.
add SEPARATOR2
frame:
style "l_indent"
yminimum 75
has vbox
text _("Projects Directory:")
add HALF_SPACER
frame style "l_indent":
if persistent.projects_directory:
textbutton _("[persistent.projects_directory!q]"):
action Jump("projects_directory_preference")
alt _("Projects directory: [text]")
else:
textbutton _("Not Set"):
action Jump("projects_directory_preference")
alt _("Projects directory: [text]")
add SPACER
# Text editor selection.
add SEPARATOR2
frame:
style "l_indent"
yminimum 75
has vbox
text _("Text Editor:")
add HALF_SPACER
frame style "l_indent":
if persistent.editor:
textbutton persistent.editor action Jump("editor_preference") alt _("Text editor: [text]")
else:
textbutton _("Not Set") action Jump("editor_preference") alt _("Text editor: [text]")
add SPACER
if ability.can_update:
# Update URL selection.
add SEPARATOR2
frame:
style "l_indent"
yminimum 75
has vbox
text _("Update Channel:")
add HALF_SPACER
frame style "l_indent":
textbutton persistent.update_channel action Jump("update_preference")
frame:
style "l_indent"
xmaximum ONETHIRD
xfill True
has vbox
add SEPARATOR2
frame:
style "l_indent"
yminimum 75
has vbox
text _("Navigation Options:")
add HALF_SPACER
textbutton _("Include private names") style "l_checkbox" action ToggleField(persistent, "navigate_private")
textbutton _("Include library names") style "l_checkbox" action ToggleField(persistent, "navigate_library")
add SPACER
add SEPARATOR2
frame:
style "l_indent"
yminimum 75
has vbox
text _("Launcher Options:")
add HALF_SPACER
textbutton _("Hardware rendering") style "l_checkbox" action ToggleField(persistent, "gl_enable")
textbutton _("Show templates") style "l_checkbox" action ToggleField(persistent, "show_templates")
textbutton _("Large fonts") style "l_checkbox" action [ ToggleField(persistent, "large_print"), renpy.utter_restart ]
if renpy.windows:
textbutton _("Console output") style "l_checkbox" action ToggleField(persistent, "windows_console")
frame:
style "l_indent"
xmaximum ONETHIRD
xfill True
has vbox
add SEPARATOR2
frame:
style "l_indent"
yminimum 75
has vbox
text _("Actions:")
add HALF_SPACER
textbutton _("Open launcher project") style "l_nonbox" action [ project.Select("launcher"), Jump("front_page") ]
if translations:
add SPACER
# Text editor selection.
add SEPARATOR2
frame:
style "l_indent"
yminimum 75
has vbox
text _("Language:")
add HALF_SPACER
viewport:
scrollbars "vertical"
mousewheel True
has vbox
# frame style "l_indent":
for tlname, tlvalue in translations:
textbutton tlname action Language(tlvalue) style "l_list"
textbutton _("Back") action Jump("front_page") style "l_left_button"
label projects_directory_preference:
call choose_projects_directory
jump preferences
label preferences:
call screen preferences
jump preferences
+640
View File
@@ -0,0 +1,640 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# Code that manages projects.
init python:
try:
import EasyDialogsWin as EasyDialogs
except:
EasyDialogs = None
import os
init python in project:
from store import persistent, config, Action, renpy
import store.util as util
import store.interface as interface
import sys
import os.path
import json
import subprocess
import re
import tempfile
if persistent.blurb is None:
persistent.blurb = 0
LAUNCH_BLURBS = [
_("After making changes to the script, press shift+R to reload your game."),
_("Press shift+O (the letter) to access the console."),
_("Press shift+D to access the developer menu."),
_("Have you backed up your projects recently?"),
]
class Project(object):
def __init__(self, path):
while path.endswith("/"):
path = path[:-1]
if not os.path.exists(path):
raise Exception("{} does not exist.".format(path))
# The name of the project.
if path.endswith(".app/Contents/Resources/autorun"):
self.name = os.path.basename(path[:-len(".app/Contents/Resources/autorun")])
else:
self.name = os.path.basename(path)
# The path to the project.
self.path = path
# The path to the game directory.
gamedir = os.path.join(path, "game")
if os.path.isdir(gamedir):
self.gamedir = gamedir
else:
self.gamedir = path
# Load the data.
self.load_data()
# The project's temporary directory.
self.tmp = None
# This contains the result of dumping information about the game
# to disk.
self.dump = { }
# The mtime of the last dump file loaded.
self.dump_mtime = 0
def get_dump_filename(self):
self.make_tmp()
return os.path.join(self.tmp, "navigation.json")
def load_data(self):
try:
f = open(os.path.join(self.path, "project.json"), "rb")
self.data = json.load(f)
f.close()
except:
self.data = { }
self.update_data()
def save_data(self):
"""
Saves the project data.
"""
try:
with open(os.path.join(self.path, "project.json"), "wb") as f:
json.dump(self.data, f)
except:
self.load_data()
def update_data(self):
data = self.data
data.setdefault("build_update", False)
data.setdefault("packages", [ "all" ])
def make_tmp(self):
"""
Makes the project's temporary directory, if it doesn't exist
yet.
"""
if self.tmp and os.path.isdir(self.tmp):
return
tmp = os.path.join(self.path, "tmp")
try:
os.mkdir(tmp)
except:
pass
if os.path.isdir(tmp):
self.tmp = tmp
return
self.tmp = tempfile.mkdtemp()
def temp_filename(self, filename):
"""
Returns a filename in the temporary directory.
"""
self.make_tmp()
return os.path.join(self.tmp, filename)
def launch(self, args=[], wait=False, env={}):
"""
Launches the project.
`args`
Additional arguments to give to the project.
`wait`
If true, waits for the launched project to terminate before
continuing.
`env`
Additional variables to include in the environment.
"""
self.make_tmp()
# Find the python executable to run.
executable_path = os.path.dirname(sys.executable)
if renpy.renpy.windows:
extension = ".exe"
else:
extension = ""
if persistent.windows_console:
executables = [ "python" + extension ]
else:
executables = [ "pythonw" + extension ]
executables.append(sys.executable)
for i in executables:
executable = os.path.join(executable_path, i)
if os.path.exists(executable):
break
else:
raise Exception("Python interpreter not found: %r", executables)
# Put together the basic command line.
cmd = [ executable, "-EO", sys.argv[0] ]
cmd.append(self.path)
cmd.extend(args)
# Add flags to dump game info.
cmd.append("--json-dump")
cmd.append(self.get_dump_filename())
if persistent.navigate_private:
cmd.append("--json-dump-private")
if persistent.navigate_library:
cmd.append("--json-dump-common")
environ = dict(os.environ)
environ.update(env)
for k in environ:
environ[k] = renpy.fsencode(environ[k])
# Launch the project.
cmd = [ renpy.fsencode(i) for i in cmd ]
p = subprocess.Popen(cmd, env=environ)
if wait:
if p.wait():
interface.error(_("Launching the project failed."), _("Please ensure that your project launches normally before running this command."))
def update_dump(self, force=False, gui=True):
"""
If the dumpfile does not exist, runs Ren'Py to create it. Otherwise,
loads it in iff it's newer than the one that's already loaded.
"""
dump_filename = self.get_dump_filename()
if force or not os.path.exists(dump_filename):
if gui:
interface.processing(_("Ren'Py is scanning the project..."))
self.launch(["quit"], wait=True)
if not os.path.exists(dump_filename):
self.dump["error"] = True
return
file_mtime = os.path.getmtime(dump_filename)
if file_mtime == self.dump_mtime:
return
self.dump_mtime = file_mtime
try:
with open(dump_filename, "r") as f:
self.dump = json.load(f)
# add todo list to dump data
self.update_todos()
except:
self.dump["error"] = True
def update_todos(self):
"""
Scans the scriptfiles for lines TODO comments and add them to
the dump data.
"""
todos = self.dump.setdefault("location", {})["todo"] = {}
files = self.script_files()
for f in files:
data = file(self.unelide_filename(f))
for l, line in enumerate(data):
l += 1
try:
line = line.decode("utf-8")
except:
continue
m = re.search(ur".*#\s*TODO(\s*:\s*|\s+)(.*)", line, re.I)
if m is None:
continue
raw_todo_text = m.group(2).strip()
todo_text = raw_todo_text
index = 0
while not todo_text or todo_text in todos:
index += 1
todo_text = u"{0} ({1})".format(raw_todo_text, index)
todos[todo_text] = [f, l]
def unelide_filename(self, fn):
"""
Unelides the filename relative to the project base.
"""
fn1 = os.path.join(self.path, fn)
if os.path.exists(fn1):
return fn1
fn2 = os.path.join(config.renpy_base, fn)
if os.path.exists(fn2):
return fn2
return fn
def script_files(self):
"""
Return a list of the script files that make up the project. These
are elided, and so need to be passed to unelide_filename before they
can be included in the project.
"""
rv = [ ]
rv.extend(i for i, isdir in util.walk(self.path)
if (not isdir) and (i.endswith(".rpy") or i.endswith(".rpym")) and (not i.startswith("tmp/")) )
return rv
class ProjectManager(object):
"""
This maintains a list of the various types of projects that
we know about.
"""
def __init__(self):
# The projects directory.
self.projects_directory = ""
# Normal projects, in alphabetical order by lowercase name.
self.projects = [ ]
# Template projects.
self.templates = [ ]
# All projects - normal, template, and hidden.
self.all_projects = [ ]
# Directories that have been scanned.
self.scanned = set()
self.scan()
def scan(self):
"""
Scans for projects.
"""
if (persistent.projects_directory is not None) and not os.path.isdir(persistent.projects_directory):
persistent.projects_directory = None
self.projects_directory = persistent.projects_directory
self.projects = [ ]
self.templates = [ ]
self.all_projects = [ ]
self.scanned = set()
if self.projects_directory is not None:
self.scan_directory(self.projects_directory)
self.scan_directory(config.renpy_base)
self.scan_directory(os.path.join(config.renpy_base, "templates"))
self.projects.sort(key=lambda p : p.name.lower())
self.templates.sort(key=lambda p : p.name.lower())
def scan_directory(self, d):
"""
Scans for projects in directories directly underneath `d`.
"""
global current
d = os.path.abspath(d)
if not os.path.isdir(d):
return
for pdir in util.listdir(d):
ppath = os.path.join(d, pdir)
# A project must be a directory.
if not os.path.isdir(ppath):
continue
autorun = os.path.join(ppath, "Contents", "Resources", "autorun")
if os.path.exists(autorun):
ppath = autorun
# A project has either a game/ directory, or a project.json
# file.
if (not os.path.isdir(os.path.join(ppath, "game"))) and (not os.path.exists(os.path.join(ppath, "project.json"))):
continue
if ppath in self.scanned:
continue
self.scanned.add(ppath)
# We have a project directory, so create a Project.
p = Project(ppath)
project_type = p.data.get("type", "normal")
if project_type == "hidden":
pass
elif project_type == "template":
self.templates.append(p)
else:
self.projects.append(p)
self.all_projects.append(p)
# Select the default project.
if persistent.active_project is not None:
p = self.get(persistent.active_project)
if p is not None:
current = p
return
p = self.get("tutorial")
if p is not None:
current = p
return
current = None
def get(self, name):
"""
Gets the project with the given name.
Returns None if the project doesn't exist.
"""
for p in self.all_projects:
if p.name == name:
return p
return None
manager = ProjectManager()
# The current project.
current = None
# Actions
class Select(Action):
"""
An action that causes p to become the selected project when it was
clicked. If label is not None, jumps to the given label.
"""
def __init__(self, p, label=None):
"""
`p`
Either a project object, or a string giving the name of a
project.
`label`
The label to jump to when clicked.
"""
if isinstance(p, basestring):
p = manager.get(p)
self.project = p
self.label = label
def get_selected(self):
if self.project is None:
return False
if current is None:
return False
return current.path == self.project.path
def get_sensitive(self):
return self.project is not None
def __call__(self):
global current
current = self.project
persistent.active_project = self.project.name
renpy.restart_interaction()
if self.label is not None:
renpy.jump(self.label)
class Launch(Action):
"""
An action that launches the supplied project, or the current
project if no project is supplied.
"""
def __init__(self, p=None):
if p is None:
self.project = current
elif isinstance(p, basestring):
self.project = manager.get(p)
else:
self.project = p
def get_sensitive(self):
return self.project is not None
def post_launch(self):
blurb = LAUNCH_BLURBS[persistent.blurb % len(LAUNCH_BLURBS)]
persistent.blurb += 1
interface.interaction(_("Launching"), blurb, pause=2.5)
def __call__(self):
self.project.launch()
renpy.invoke_in_new_context(self.post_launch)
class Rescan(Action):
def __call__(self):
"""
Rescans the projects directory.
"""
manager.scan()
renpy.restart_interaction()
manager.scan()
if isinstance(persistent.projects_directory, str):
persistent.projects_directory = renpy.fsdecode(persistent.projects_directory)
###############################################################################
# Code to choose the projects directory.
label choose_projects_directory:
python hide:
interface.interaction(_("PROJECTS DIRECTORY"), _("Please choose the projects directory using the directory chooser.\n{b}The directory chooser may have opened behind this window.{/b}"), _("This launcher will scan for projects in this directory, will create new projects in this directory, and will place built projects into this directory."),)
path = persistent.projects_directory
if path:
default_path = path
else:
try:
default_path = os.path.dirname(os.path.abspath(config.renpy_base))
except:
default_path = os.path.abspath(config.renpy_base)
if EasyDialogs:
choice = EasyDialogs.AskFolder(defaultLocation=default_path, wanted=unicode)
if choice is not None:
path = choice
else:
path = None
else:
try:
cmd = [ "/usr/bin/python", os.path.join(config.gamedir, "tkaskdir.py"), renpy.fsencode(default_path) ]
p = subprocess.Popen(cmd, stdout=subprocess.PIPE)
choice = p.stdout.read()
code = p.wait()
except:
import traceback
traceback.print_exc()
code = 0
choice = ""
path = None
interface.error(_("Ren'Py was unable to run python with tkinter to choose the projects directory. Please install the python-tk or tkinter package."), label=None)
if code:
interface.error(_("Ren'Py was unable to run python with tkinter to choose the projects directory. Please install the python-tk or tkinter package."), label=None)
elif choice:
path = choice.decode("utf-8")
if path is None:
path = default_path
interface.info(_("Ren'Py has set the projects directory to:"), "[path!q]", path=path)
path = renpy.fsdecode(path)
if os.path.isdir(path):
persistent.projects_directory = path
else:
path = os.path.abspath(config.renpy_base)
project.manager.scan()
return
init python:
def set_projects_directory_command():
ap = renpy.arguments.ArgumentParser()
ap.add_argument("projects", help="The path to the projects directory.")
args = ap.parse_args()
persistent.projects_directory = args.projects
renpy.save_persistent()
return False
renpy.arguments.register_command("set_projects_directory", set_projects_directory_command)
def get_projects_directory_command():
ap = renpy.arguments.ArgumentParser()
args = ap.parse_args()
print persistent.projects_directory
return False
renpy.arguments.register_command("get_projects_directory", get_projects_directory_command)
+8
View File
@@ -0,0 +1,8 @@
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAnEdzfwV6FFnmjkbJHJKJ59jqLTGkPSES5LBFbxwweGuC3LU2sNs+
tRlWx+2+kbW6azb5yteP/O05/hzHdtIa4slao7s8A/wf0zA6HbLX4H5iqSosDvuw
FP9DAF46vH0Qn1a3k97JFV2eXoGAbwHZICKhbIPCm7qR39G8FvUrw7grCS+5Scb+
LzqkBv6TnwRDB4agcwhlkA432s6BTU8p9RIFmyldCEgq0SXeK07lkuDmOplp6IdL
bVwLoRWg6pngIEoPo/Qxt8ZnLdBthN+TAsMRiquz17GaAvERbkUBwYtlt7R8qx01
F3vzweKXSCguzr9XQBQflkVu2y6cmIEwPQIDAQAB
-----END RSA PUBLIC KEY-----
+343
View File
@@ -0,0 +1,343 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init -1 python:
# The color of non-interactive text.
TEXT = "#545454"
# Colors for buttons in various states.
IDLE = "#42637b"
HOVER = "#d86b45"
DISABLED = "#808080"
# Colors for reversed text buttons (selected list entries).
REVERSE_IDLE = "#78a5c5"
REVERSE_HOVER = "#d86b45"
REVERSE_TEXT = "#ffffff"
# Colors for the scrollbar thumb.
SCROLLBAR_IDLE = "#dfdfdf"
SCROLLBAR_HOVER = "#d86b45"
# An image used as a separator pattern.
PATTERN = "images/pattern.png"
# A displayable used for the background of everything.
BACKGROUND = "images/background.png"
# A displayable used for the background of windows
# containing commands, preferences, and navigation info.
WINDOW = Frame("images/window.png", 0, 0, tile=True)
# A displayable used for the background of the projects list.
PROJECTS_WINDOW = Null()
# A displayable used the background of information boxes.
INFO_WINDOW = "#f9f9f9"
# Colors for the titles of information boxes.
ERROR_COLOR = "#d15353"
INFO_COLOR = "#545454"
INTERACTION_COLOR = "#d19753"
QUESTION_COLOR = "#d19753"
# The color of input text.
INPUT_COLOR = "#d86b45"
# FONTS/WEIGHTS
LIGHT = "Roboto-Light.ttf"
REGULAR = "Roboto-Regular.ttf"
if persistent.large_print:
LIGHT = REGULAR
init 1 python:
def size(n):
"""
Adjusts the font size if we're in large-print mode.
"""
if persistent.large_print and n < 18:
n = 18
return n
INDENT = 20
HALF_INDENT = 10
SCROLLBAR_SIZE = 16
SEPARATOR = Frame(PATTERN, 0, 0, tile=True, ymaximum=5, yalign=1.0)
SEPARATOR2 = Frame(PATTERN, 0, 0, tile=True, ymaximum=10, yalign=1.0)
SPACER_HEIGHT = 12
SPACER = Null(height=SPACER_HEIGHT)
HALF_SPACER_HEIGHT = 6
HALF_SPACER = Null(height=HALF_SPACER_HEIGHT)
# DIVIDING THE SCREEN
ONETHIRD = 258
TWOTHIRDS = 496
ONEHALF = 377
def checkbox(full, color):
if full:
return im.Twocolor("images/checkbox_full.png", color, color, yalign=0.5)
else:
return im.Twocolor("images/checkbox_empty.png", color, color, yalign=0.5)
init 1:
# The default style.
style l_default is default:
font LIGHT
color TEXT
idle_color IDLE
hover_color HOVER
size size(18)
style l_text is l_default
style l_button is l_default
style l_button_text is l_default:
insensitive_color DISABLED
selected_font REGULAR
# A small button, used at the bottom of the screen.
style l_link is l_default
style l_link_text is l_default:
size size(14)
font LIGHT
# Action buttons on the bottom of the screen.
style l_right_button is l_default:
xalign 1.0
ypos 600 - 128 + 12
left_margin 8 + INDENT
right_margin 10 + INDENT
style l_right_button_text is l_default:
size size(30)
style l_left_button is l_right_button:
xalign 0.0
style l_left_button_text is l_right_button_text
# The root frame. This contains everything but the bottom navigation,
# and buttons.
style l_root is l_default:
background BACKGROUND
xpadding 10
top_padding 64
bottom_padding 128
# An inner window.
style l_window is l_default:
background WINDOW
left_padding 6
xfill True
yfill True
# Normal size labels.
style l_label is l_default:
xfill True
top_padding 10
bottom_padding 8
bottom_margin 12
background SEPARATOR
style l_label_text is l_default:
size size(24)
xpos INDENT
yoffset 6
style l_label_small is l_default:
xfill True
bottom_padding 8
bottom_margin HALF_SPACER_HEIGHT
background SEPARATOR
# Small labels.
style l_label_small_text is l_default:
xpos INDENT
yoffset 6
size size(20)
# Alternate labels. This nests inside an l_label, and gives a button
# or label that's nested inside another label.
style l_alternate is l_default:
xalign 1.0
yalign 1.0
yoffset 4
right_margin INDENT
style l_alternate_text is l_default:
size size(14)
font LIGHT
text_align 1.0
style l_small_button is l_button
style l_small_button_text is l_button_text:
size size(14)
style l_small_text is l_text:
size size(14)
# Indents its contents.
style l_indent is l_default:
left_margin INDENT
# Indents its contents and pads vertically.
style l_indent_margin is l_indent:
ymargin 6
# Lists.
style l_list is l_default:
left_padding HALF_INDENT
xfill True
selected_background REVERSE_IDLE
selected_hover_background REVERSE_HOVER
style l_list_text is l_default:
idle_color IDLE
hover_color HOVER
selected_idle_color REVERSE_TEXT
selected_hover_color REVERSE_TEXT
insensitive_color DISABLED
style l_list2 is l_list:
left_padding (HALF_INDENT + INDENT)
style l_list2_text is l_list_text
# Scrollbar.
style l_vscrollbar is l_default:
thumb Fixed(
Solid(SCROLLBAR_IDLE, xmaximum=8, xalign=0.5),
Image("images/vscrollbar_center.png", xalign=0.5, yalign=0.5),
xmaximum = SCROLLBAR_SIZE)
hover_thumb Fixed(
Solid(SCROLLBAR_HOVER, xmaximum=8, xalign=0.5),
Image("images/vscrollbar_center.png", xalign=0.5, yalign=0.5),
xmaximum = SCROLLBAR_SIZE)
xmaximum SCROLLBAR_SIZE
bar_vertical True
bar_invert True
unscrollable "hide"
# Information window.
style l_info_vbox is vbox:
yalign 0.5
xalign 0.5
xfill True
style l_info_frame is l_default:
ypadding 21
xfill True
background Fixed(
INFO_WINDOW,
Frame(PATTERN, 0, 0, tile=True, ymaximum=5, yalign=0.0, yoffset=8),
Frame(PATTERN, 0, 0, tile=True, ymaximum=5, yalign=1.0, yoffset=-8),
)
yminimum 180
ypos 75
style l_info_label is l_default:
xalign 0.5
ypos 75
yanchor 1.0
yoffset 12
style l_info_label_text is l_default:
size size(36)
style l_info_text is l_default:
xalign 0.5
style l_info_button is l_button:
xalign 0.5
xmargin 50
style l_info_button_text is l_button_text:
text_align 0.5
layout "subtitle"
# Progress bar.
style l_progress_frame is l_default:
background Frame(PATTERN, 0, 0, tile=True)
ypadding 5
style l_progress_bar is l_default:
left_bar REVERSE_IDLE
right_bar Null()
ymaximum 24
# Navigation.
style l_navigation_button is l_button:
size_group "navigation"
right_margin INDENT
top_margin 3
style l_navigation_button_text is l_button_text:
size size(14)
font REGULAR
style l_navigation_text is l_text:
size size(14)
font LIGHT
color TEXT
# Checkboxes.
style l_checkbox is l_button:
left_padding INDENT
background checkbox(False, IDLE)
hover_background checkbox(False, HOVER)
selected_idle_background checkbox(True, IDLE)
selected_hover_background checkbox(True, HOVER)
insensitive_background checkbox(False, DISABLED)
style l_checkbox_text is l_button_text:
selected_font LIGHT
# Lines up with a checkbox.
style l_nonbox is l_button:
xpadding INDENT
style l_nonbox_text is l_button_text:
selected_font LIGHT
# Projects list.
style l_projects is l_default:
background PROJECTS_WINDOW
style hyperlink_text:
size size(18)
font LIGHT
color IDLE
hover_color HOVER
+68
View File
@@ -0,0 +1,68 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python:
class FileTail(object):
def __init__(self, filename, lines=8):
self.filename = filename
self.text = ""
self.lines = lines
def update(self):
try:
with open(self.filename) as f:
text = f.read()
try:
text = renpy.fsdecode(text)
except:
text = text.decode("latin-1")
text = text.strip()
text = text.split("\n")
newtext = [ ]
for l in text:
if "\r" in l:
_head, _sep, l = l.rpartition("\r")
while l:
newtext.append(l[:100])
l = l[100:]
text = newtext
text = text[-self.lines:]
text = "\n".join(text)
if text != self.text:
self.text = text
renpy.restart_interaction()
except:
pass
+609
View File
@@ -0,0 +1,609 @@
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
init python in theme_data:
def __PerformScreenOperations(lines, file_picker_rows=5, file_picker_cols=2):
import re
x = 0
correct_section = False
while x < len(lines):
l = lines[x]
m = re.match(r'^screen\s+\w+\s*:\s*$', l)
if m:
correct_section = False
m = re.match(r'^screen\s+file_picker\s*:\s*$', l)
if m:
correct_section = True
if correct_section:
m = re.match(r'^\s+\$\s*columns\s*=\s*(\d+)\s*$', l)
if m:
l = l.replace(str(m.group(1)), str(file_picker_cols))
m = re.match(r'^\s+\$\s*rows\s*=\s*(\d+)\s*$', l)
if m:
l = l.replace(str(m.group(1)), str(file_picker_rows))
lines[x] = l
x = x + 1
return lines
def roundrect_screen_ops(lines):
return __PerformScreenOperations(lines)
def awt_screen_ops(lines):
return __PerformScreenOperations(lines, file_picker_rows=3)
# theme name -> (color scheme name -> code that implements it)
THEME = { }
# The set of theme functions.
THEME_FUNCTIONS = set()
# theme name -> function name to call to munge screens.rpy as appropriate
# for that theme.
THEME_SCREEN_OPERATIONS = { }
# Color schemes that work (technically - some are eye-melting) with the
# roundrect-style themes.
ROUNDRECT_SCHEMES = {
'Basic Blue': {'disabled': '#404040',
'disabled_text': '#c8c8c8',
'frame': '#6496c8',
'gm_root': '#dcebff',
'label': '#ffffff',
'mm_root': '#dcebff',
'widget': '#003c78',
'widget_hover': '#0050a0',
'widget_selected': '#ffffc8',
'widget_text': '#c8ffff'},
'Bloody Mary': {'disabled': '#400000',
'disabled_text': '#260000',
'frame': '#400808',
'gm_root': '#000000',
'label': '#ffffff',
'mm_root': '#000000',
'widget': '#000000',
'widget_hover': '#830000',
'widget_selected': '#ffffff',
'widget_text': '#C2C2C2'},
'Colorblind': {'disabled': '#898989',
'disabled_text': '#666666',
'frame': '#252525',
'gm_root': '#393939',
'label': '#c2c2c2',
'mm_root': '#393939',
'widget': '#898989',
'widget_hover': '#464646',
'widget_selected': '#F2F2F2',
'widget_text': '#CCCCCC'},
'Cotton Candy': {'disabled': '#C8AFA1',
'disabled_text': '#E1D4C9',
'frame': '#FCF5F2',
'gm_root': '#D0B4BA',
'label': '#805C40',
'mm_root': '#D0B4BA',
'widget': '#ECC7D0',
'widget_hover': '#E1D4C9',
'widget_selected': '#805C40',
'widget_text': '#805C40'},
'Creamsicle': {'disabled': '#FFECBF',
'disabled_text': '#ffffff',
'frame': '#FFECBF',
'gm_root': '#FDF5E3',
'label': '#502F13',
'mm_root': '#FDF5E3',
'widget': '#D96B00',
'widget_hover': '#FD9B1C',
'widget_selected': '#ffffff',
'widget_text': '#FCE6B1'},
'Dramatic Flesh': {'disabled': '#ab6038',
'disabled_text': '#BF7C51',
'frame': '#49271b',
'gm_root': '#2a201f',
'label': '#ffffff',
'mm_root': '#2a201f',
'widget': '#BF7C51',
'widget_hover': '#dda570',
'widget_selected': '#ffffff',
'widget_text': '#E5DFDF'},
'Easter Baby': {'disabled': '#DDE9FF',
'disabled_text': '#A6AFBF',
'frame': '#CCF8DC',
'gm_root': '#FBF9DF',
'label': '#698071',
'mm_root': '#FBF9DF',
'widget': '#F5D4EE',
'widget_hover': '#F0DDFF',
'widget_selected': '#000000',
'widget_text': '#698071'},
'Favorite Jeans': {'disabled': '#919994',
'disabled_text': '#B6BFB9',
'frame': '#6f7571',
'gm_root': '#b0b8ba',
'label': '#ffffff',
'mm_root': '#b0b8ba',
'widget': '#8699a7',
'widget_hover': '#9eb1ad',
'widget_selected': '#ffffff',
'widget_text': '#dcdfd6'},
'Fine China': {'disabled': '#ADB9CC',
'disabled_text': '#DFBA14',
'frame': '#ADB9CC',
'gm_root': '#F7F7FA',
'label': '#39435E',
'mm_root': '#F7F7FA',
'widget': '#6A7183',
'widget_hover': '#1A2B47',
'widget_selected': '#E3E3E4',
'widget_text': '#C9C9CB'},
'First Valentines': {'disabled': '#F8F2D0',
'disabled_text': '#BFA1A1',
'frame': '#F8F2D0',
'gm_root': '#D98989',
'label': '#5D1010',
'mm_root': '#D98989',
'widget': '#F09898',
'widget_hover': '#D6C5BB',
'widget_selected': '#B31E1E',
'widget_text': '#593131'},
'Ice Queen': {'disabled': '#F0F2F2',
'disabled_text': '#FBFBFB',
'frame': '#ffffff',
'gm_root': '#E6E6E6',
'label': '#D9D9D9',
'mm_root': '#E6E6E6',
'widget': '#D9D9D9',
'widget_hover': '#F0F2F2',
'widget_selected': '#737373',
'widget_text': '#ffffff'},
'Mocha Latte': {'disabled': '#614D3A',
'disabled_text': '#80654D',
'frame': '#926841',
'gm_root': '#1A140E',
'label': '#F1EBE5',
'mm_root': '#1A140E',
'widget': '#4D3B29',
'widget_hover': '#996E45',
'widget_selected': '#ffffff',
'widget_text': '#B99D83'},
'Muted Horror': {'disabled': '#73735C',
'disabled_text': '#8C8C70',
'frame': '#555544',
'gm_root': '#1A0001',
'label': '#1A0001',
'mm_root': '#1A0001',
'widget': '#777777',
'widget_hover': '#73735C',
'widget_selected': '#000000',
'widget_text': '#404033'},
'Old Polaroid': {'disabled': '#A89E7D',
'disabled_text': '#CCC097',
'frame': '#49403E',
'gm_root': '#A84A3E',
'label': '#ffffff',
'mm_root': '#A84A3E',
'widget': '#A89E7D',
'widget_hover': '#8DB6B9',
'widget_selected': '#ffffff',
'widget_text': '#49403E'},
'Really Red': {'disabled': '#404040',
'disabled_text': '#c8c8c8',
'frame': '#e17373',
'gm_root': '#ffd0d0',
'label': '#ffffff',
'mm_root': '#ffd0d0',
'widget': '#963232',
'widget_hover': '#c83232',
'widget_selected': '#ffffc8',
'widget_text': '#ffffff'},
'Summer Sky': {'disabled': '#6074BF',
'disabled_text': '#7383BF',
'frame': '#6074BF',
'gm_root': '#B4CDD4',
'label': '#94C7D4',
'mm_root': '#B4CDD4',
'widget': '#F2E6AA',
'widget_hover': '#FCFCA4',
'widget_selected': '#1A5766',
'widget_text': '#7DA8B3'},
'Swamp Critter': {'disabled': '#A2521D',
'disabled_text': '#753D00',
'frame': '#797C1C',
'gm_root': '#B09D5A',
'label': '#ffffff',
'mm_root': '#B09B4F',
'widget': '#753D00',
'widget_hover': '#B19A48',
'widget_selected': '#ffffff',
'widget_text': '#CCCAC2'},
'Urban Sprawl': {'disabled': '#8F0000',
'disabled_text': '#333333',
'frame': '#8F0000',
'gm_root': '#000000',
'label': '#ffffff',
'mm_root': '#000000',
'widget': '#333333',
'widget_hover': '#000000',
'widget_selected': '#ffffff',
'widget_text': '#6C8A2F'},
'Victorian Gingerbread': {'disabled': '#7A674F',
'disabled_text': '#664F33',
'frame': '#BF8A73',
'gm_root': '#695640',
'label': '#F2EDC4',
'mm_root': '#695640',
'widget': '#7A674F',
'widget_hover': '#BDA77D',
'widget_selected': '#FDFBEE',
'widget_text': '#F2EDC4'},
'Watermelon Pie': {'disabled': '#FABF46',
'disabled_text': '#FFE06D',
'frame': '#C3CD91',
'gm_root': '#F7F7C5',
'label': '#FCFCD7',
'mm_root': '#F7F7C5',
'widget': '#FFE06D',
'widget_hover': '#E38A4F',
'widget_selected': '#996600',
'widget_text': '#FAA700'},
'White Chocolate': {'disabled': '#614D3A',
'disabled_text': '#80654D',
'frame': '#926841',
'gm_root': '#FBF9EA',
'label': '#F1EBE5',
'mm_root': '#FBF9EA',
'widget': '#33271C',
'widget_hover': '#ECE7C4',
'widget_selected': '#ffffff',
'widget_text': '#B99D83'},
'Winter Mint': {'disabled': '#426143',
'disabled_text': '#819981',
'frame': '#245536',
'gm_root': '#e5f1e5',
'label': '#ffffff',
'mm_root': '#e5f1e5',
'widget': '#7AA27B',
'widget_hover': '#A3C7A3',
'widget_selected': '#ffffff',
'widget_text': '#CDE0CE'},
'Mint Chocolate': {'disabled': '#ffe69c',
'disabled_text': '#ddbc7e',
'frame': '#8ab395',
'gm_root': '#7a4229',
'label': '#7a4229',
'mm_root': '#7a4229',
'widget': '#ffe69c',
'widget_hover': '#f5c153',
'widget_selected': '#7a4229',
'widget_text': '#b5743a'},
'Parachute Pants': {'disabled': '#53c7bb',
'disabled_text': '#97d7bd',
'frame': '#457b9f',
'gm_root': '#37397f',
'label': '#cce2ae',
'mm_root': '#37397f',
'widget': '#53c7bb',
'widget_hover': '#97d7bd',
'widget_selected': '#37397f',
'widget_text': '#457b9f'},
'Strawberry Orchard': {'disabled': '#b3c292',
'disabled_text': '#525748',
'frame': '#d8ebae',
'gm_root': '#e7f3cb',
'label': '#525748',
'mm_root': '#e7f3cb',
'widget': '#525748',
'widget_hover': '#f45c73',
'widget_selected': '#ffce95',
'widget_text': '#e7f3cb'},
'Grape Jelly': {'disabled': '#81859a',
'disabled_text': '#5e2862',
'frame': '#8ea9b0',
'gm_root': '#5e2862',
'label': '#ffffff',
'mm_root': '#5e2862',
'widget': '#c45693',
'widget_hover': '#5e2862',
'widget_selected': '#e59eae',
'widget_text': '#ffffff'},
'Dreamscape': {'disabled': '#966077',
'disabled_text': '#c75f77',
'frame': '#836177',
'gm_root': '#c75f77',
'label': '#fefab6',
'mm_root': '#c75f77',
'widget': '#77a493',
'widget_hover': '#8accb3',
'widget_selected': '#c75f77',
'widget_text': '#ffffff'},
'Unrequited Love': {'disabled': '#dbe4dd',
'disabled_text': '#bd9ca9',
'frame': '#fffeed',
'gm_root': '#b38698',
'label': '#23000e',
'mm_root': '#b38698',
'widget': '#7fa1b3',
'widget_hover': '#b38698',
'widget_selected': '#fffeed',
'widget_text': '#ffffff'},
'Watermelon': {'disabled': '#f9cdad',
'disabled_text': '#fc9d9a',
'frame': '#f9cdad',
'gm_root': '#83af9b',
'label': '#fe4365',
'mm_root': '#83af9b',
'widget': '#fc9d9a',
'widget_hover': '#fe4365',
'widget_selected': '#e5fcc2',
'widget_text': '#ffffff'},
'City Lights': {'disabled': '#638e89',
'disabled_text': '#594f4f',
'frame': '#547980',
'gm_root': '#594f4f',
'label': '#e5fcc2',
'mm_root': '#594f4f',
'widget': '#45ada8',
'widget_hover': '#2e5860',
'widget_selected': '#e5fcc2',
'widget_text': '#9de0ad'},
'Vampire Bite': {'disabled': '#971140',
'disabled_text': '#bd4b40',
'frame': '#bd1550',
'gm_root': '#490a3d',
'label': '#f8ca00',
'mm_root': '#490a3d',
'widget': '#e97f02',
'widget_hover': '#f5a240',
'widget_selected': '#490a3d',
'widget_text': '#bd1550'},
'Underground Rave': {'disabled': '#57cdff',
'disabled_text': '#717be5',
'frame': '#04b4ff',
'gm_root': '#cd249b',
'label': '#000000',
'mm_root': '#cd249b',
'widget': '#8833ce',
'widget_hover': '#cd249b',
'widget_selected': '#b6d754',
'widget_text': '#000000'},
'Tree Frog': {'disabled': '#ffffff',
'disabled_text': '#1c140d',
'frame': '#cbe86b',
'gm_root': '#ffffff',
'label': '#1c140d',
'mm_root': '#ffffff',
'widget': '#1c140d',
'widget_hover': '#86827e',
'widget_selected': '#f2e9e1',
'widget_text': '#cbe86b'},
'Sun Kissed': {'disabled': '#ffffff',
'disabled_text': '#ec4c51',
'frame': '#f0874d',
'gm_root': '#f8c821',
'label': '#ffffff',
'mm_root': '#f8c821',
'widget': '#ec4c51',
'widget_hover': '#dc454a',
'widget_selected': '#f8c821',
'widget_text': '#ffffff'},
'Vintage Faded': {'disabled': '#b17d6f',
'disabled_text': '#8c4e3d',
'frame': '#ab7464',
'gm_root': '#935844',
'label': '#f7d3c8',
'mm_root': '#935844',
'widget': '#8c4e3d',
'widget_hover': '#734032',
'widget_selected': '#fcf5ed',
'widget_text': '#e2b9ad'},
'Vintage': {'disabled': '#883e35',
'disabled_text': '#b86258',
'frame': '#b86258',
'gm_root': '#a24637',
'label': '#ffffff',
'mm_root': '#a24637',
'widget': '#6c2921',
'widget_hover': '#832f26',
'widget_selected': '#ffc7c0',
'widget_text': '#fff4eb'},
'Earth Tones': {'disabled': '#12612f',
'disabled_text': '#2c6e44',
'frame': '#00551f',
'gm_root': '#6b4a27',
'label': '#ffffff',
'mm_root': '#568153',
'widget': '#ad8c31',
'widget_hover': '#568153',
'widget_selected': '#f2edc4',
'widget_text': '#ffffff'},
'Kindergarten': {'disabled': '#1ca4b2',
'disabled_text': '#22d5b3',
'frame': '#22d5b3',
'gm_root': '#ffeca6',
'label': '#ffffff',
'mm_root': '#ffeca6',
'widget': '#1781b1',
'widget_hover': '#12678e',
'widget_selected': '#f2edc4',
'widget_text': '#fdfbee'},
'Phone Operator': {'disabled': '#929292',
'disabled_text': '#ababab',
'frame': '#d2d2d2',
'gm_root': '#59667a',
'label': '#343e4d',
'mm_root': '#59667a',
'widget': '#59667a',
'widget_hover': '#343e4d',
'widget_selected': '#bed4f6',
'widget_text': '#ffffff'},
}
ROUNDRECT_VARIANTS = [
("Roundrect", "roundrect"),
("Bordered", "bordered"),
("Diamond", "diamond"),
("Regal", "regal"),
("Austen", "austen"),
("TV", "tv"),
("3D", "threeD"),
("Glow", "glow"),
("Marker", "marker"),
("Crayon", "crayon"),
]
ROUNDRECT_CODE = """theme.%(function)s(
## Theme: %(theme)s
## Color scheme: %(scheme)s
## The color of an idle widget face.
widget = "%(widget)s",
## The color of a focused widget face.
widget_hover = "%(widget_hover)s",
## The color of the text in a widget.
widget_text = "%(widget_text)s",
## The color of the text in a selected widget. (For
## example, the current value of a preference.)
widget_selected = "%(widget_selected)s",
## The color of a disabled widget face.
disabled = "%(disabled)s",
## The color of disabled widget text.
disabled_text = "%(disabled_text)s",
## The color of informational labels.
label = "%(label)s",
## The color of a frame containing widgets.
frame = "%(frame)s",
## The background of the main menu. This can be a color
## beginning with '#', or an image filename. The latter
## should take up the full height and width of the screen.
mm_root = "%(mm_root)s",
## The background of the game menu. This can be a color
## beginning with '#', or an image filename. The latter
## should take up the full height and width of the screen.
gm_root = "%(gm_root)s",
## If this is True, the in-game window is rounded. If False,
## the in-game window is square.
rounded_window = False,
## And we're done with the theme. The theme will customize
## various styles, so if we want to change them, we should
## do so below.
)"""
for theme, function in ROUNDRECT_VARIANTS:
THEME[theme] = { }
THEME_FUNCTIONS.add(function)
THEME_SCREEN_OPERATIONS[theme] = roundrect_screen_ops
for scheme, colors in ROUNDRECT_SCHEMES.iteritems():
subs = dict(colors)
subs["function"] = function
subs["theme"] = theme
subs["scheme"] = scheme
THEME[theme][scheme] = ROUNDRECT_CODE % (subs)
AWT_CODE = """theme.a_white_tulip(
## Theme: A White Tulip
## Scheme %(scheme)s
## The color of an idle widget face.
widget = "%(widget)s",
## The color of a focused widget face.
widget_hover = "%(widget_hover)s",
## The color of the text in a selected widget. (For
## example, the current value of a preference.)
widget_selected = "%(widget_selected)s",
## The color of a disabled widget face.
disabled = "%(disabled)s",
## The color of a frame containing widgets.
frame = "%(frame)s",
## The background of the main menu. This can be a color
## beginning with '#', or an image filename. The latter
## should take up the full height and width of the screen.
mm_root = "%(mm_root)s",
## The background of the game menu. This can be a color
## beginning with '#', or an image filename. The latter
## should take up the full height and width of the screen.
gm_root = "%(gm_root)s",
## The fonts used by this theme. The default fonts may not be
## suitable for non-English languages.
regular_font = "_theme_awt/Quicksand-Regular.ttf",
bold_font = "_theme_awt/Quicksand-Bold.ttf",
## And we're done with the theme. The theme will customize
## various styles, so if we want to change them, we should
## do so below.
)"""
THEME["A White Tulip"] = { }
THEME_FUNCTIONS.add("a_white_tulip")
THEME_SCREEN_OPERATIONS["A White Tulip"] = awt_screen_ops
for scheme, colors in ROUNDRECT_SCHEMES.iteritems():
subs = dict(colors)
subs["scheme"] = scheme
THEME["A White Tulip"][scheme] = AWT_CODE % (subs)
THEME["A White Tulip"]["A White Tulip"] = AWT_CODE % dict(
scheme = "A White Tulip",
widget = "#c1c6d3",
widget_hover = "#d7dbe5",
widget_text = "#6b6b6b",
widget_selected = "#c1c6d3",
disabled = "#b4b4b4",
disabled_text = "#6b6b6b",
label = "#6b6b6b",
frame = "#9391c9",
mm_root = "#ffffff",
gm_root = "#ffffff",
)
+50
View File
@@ -0,0 +1,50 @@
#!/usr/bin/env python
# Copyright 2004-2014 Tom Rothamel <pytom@bishoujo.us>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so,
# subject to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# This is used on Linux and Mac to prompt the user for the projects
# directory.
import sys
# Python3 and Python2-style imports.
try:
from tkinter import Tk
from tkinter.filedialog import askdirectory
except ImportError:
from Tkinter import Tk
from tkFileDialog import askdirectory
# Binary mode stdout for python3.
try:
sys.stdout = sys.stdout.buffer
except:
pass
# Create the TK canvas.
if __name__ == "__main__":
root = Tk()
root.withdraw()
result = askdirectory(initialdir=sys.argv[1], parent=root, title="Select Ren'Py Projects Directory")
sys.stdout.write(result.encode("utf8"))
+15
View File
@@ -0,0 +1,15 @@
translate arabic strings:
# game/about.rpy:21
old "[version!q]"
new "[version!q]"
# game/about.rpy:25
old "View license"
new "عرض الرخصة"
# game/about.rpy:27
old "Back"
new "عودة"
+23
View File
@@ -0,0 +1,23 @@
translate arabic strings:
# game/add_file.rpy:7
old "FILENAME"
new "اسم الملف"
# game/add_file.rpy:7
old "Enter the name of the script file to create."
new "إختر اسم لملف الحوار الذي سيتم تكوينه"
# game/add_file.rpy:10
old "The filename must have the .rpy extension."
new "يجب ان ينتهي اسم الملف بالصيغة .rpy"
# game/add_file.rpy:18
old "The file already exists."
new "هذا الملف موجود مسبقاً"
# game/add_file.rpy:21
old "# Ren'Py automatically loads all script files ending with .rpy. To use this\n# file, define a label and jump to it from another file.\n"
new "رينباي يقوم بتشغيل الملفات المنتهية بـ .rpy تلقائياً. لكي تستعمل هذا الملف, اختر له تبويب وافتحه عبر ملف آخر."
+164
View File
@@ -0,0 +1,164 @@
# : Translation updated at 2013-11-17 23:18
translate arabic strings:
# game/android.rpy:12
old "To build Android packages, please download RAPT (from {a=http://www.renpy.org/dl/android}here{/a}), unzip it, and place it into the Ren'Py directory. Then restart the Ren'Py launcher."
new "لتجهيز اللعبة للعمل على اجهزة اندرويد يمكنك تحميل الحزمة الخاصة بذلك {a=http://www.renpy.org/dl/android}here{/a}) و فك الضغط عنها, ثم نسخها إلى مجلد رينباي الرئيسي ثم إعادة فتح هذا المشغِّل."
# game/android.rpy:13
old "RAPT has been installed, but you'll need to install the Android SDK before you can build Android packages. Choose Install SDK to do this."
new "حزمة الاندرويد RAPT موجوده, لكنك تحتاج لتنصيب Android SDK قبل ان تبدأ بتجهيز حزم للعمل على اندرويد. الرجاء اختيار تنصيب Android SDK لتستطيع ذلك."
# game/android.rpy:14
old "RAPT has been installed, but a key hasn't been configured. Please create a new key, or restore android.keystore."
new "حزمة اندرويد RAPT موجوده, لكن المفتاح لم يتم تجهيزه. الرجاء تكوين مفتاح جديد او استرجاع android.keystore"
# game/android.rpy:15
old "The current project has not been configured. Use \"Configure\" to configure it before building."
new "المشروع الحالي لم يتم تجهيز إعدادته. الرجاء اختيار \"Configure\" لتقوم بتجهيزها قبل بناء الحزمة."
# game/android.rpy:16
old "Choose \"Build\" to build the current project, or attach an Android device and choose \"Build & Install\" to build and install it on the device."
new "قم باختيار زر \"Build\" لتقوم بتجهيز المشروع الحالي إلى حزمة قابلة للعمل على اندرويد. او قم بربط جهاز اندرويد و اختيار \"Build & Install\" ليتم تنصيبها مباشرة على الجهاز المطلوب."
# game/android.rpy:18
old "Attempts to emulate an Android phone.\n\nTouch input is emulated through the mouse, but only when the button is held down. Escape is mapped to the menu button, and PageUp is mapped to the back button."
new "يقوم بمحاكاة جهاز اندرويد هاتفي محمول. \n\n خاصية اللمس يتم محاكاتها عبر مؤشر الفأره, لكن فقط حين يكون زر الفأره مضغوطاً. زر الخروج يقوم باستدعاء نافذة القائمة الرئيسية, و PageUp هو زر العودة إلى الوراء."
# game/android.rpy:19
old "Attempts to emulate an Android tablet.\n\nTouch input is emulated through the mouse, but only when the button is held down. Escape is mapped to the menu button, and PageUp is mapped to the back button."
new "يقوم بمحاكاة جهاز اندرويد تابلت. \n\n خاصية اللمس يتم محاكاتها عبر مؤشر الفأره, لكن فقط حين يكون زر الفأره مضغوطاً. زر الخروج يقوم باستدعاء نافذة القائمة الرئيسية, و PageUp هو زر العودة إلى الوراء"
# game/android.rpy:20
old "Attempts to emulate an OUYA console.\n\nController input is mapped to the arrow keys, Enter is mapped to the select button, Escape is mapped to the menu button, and PageUp is mapped to the back button."
new "يقوم بمحاكاة جهاز Ouya. \n\n يد التحكم تتم محاكاتها بأزرار الإتجاهات, زر الإدخال يحاكي select, زر الخروج يحاكي زر menu, و PageUp يحاكي زر العودة."
# game/android.rpy:22
old "Downloads and installs the Android SDK and supporting packages. Optionally, generates the keys required to sign the package."
new "يقوم بتحميل و تنصيب Android SDK والحزم المساندة لها. يعطيك خيار تكوين المفاتيح المطلوبة لتتمكن من استعمال الحزمة."
# game/android.rpy:23
old "Configures the package name, version, and other information about this project."
new "يقوم بتجهيز إعدادات الحزمة, رقم النسخة, و معلومات أخرى تتعلق بهذا المشروع."
# game/android.rpy:24
old "Opens the file containing the Google Play keys in the editor.\n\nThis is only needed if the application is using an expansion APK. Read the documentation for more details."
new "يفتح الملف الخاص بمعلومات مفتاح Google Play في محرر النصوص. \n\n هذه الخطوة غير مطلوبة إلا لو كان البرنامج يحتاج إحدى الحوم المساندة expansion APK. الرجاء الإطلاع على ملفات المساعدة للحصول على المزيد من المعلومات."
# game/android.rpy:25
old "Builds the Android package."
new "يقوم ببناء حزمة للأندرويد."
# game/android.rpy:26
old "Builds the Android package, and installs it on an Android device connected to your computer."
new "يقوم ببناء حزمة للأندرويد, ثم يقوم بتنصيبها على جهاز أندرويد المتصل بحاسوبك."
# game/android.rpy:142
old "{a=%s}%s{/a}"
new "{a=%s}%s{/a}"
# game/android.rpy:361
old "Android: [project.current.name!q]"
new "أندرويد: [project.current.name!q]"
# game/android.rpy:381
old "Emulation:"
new "محاكاة"
# game/android.rpy:389
old "Phone"
new "هاتف"
# game/android.rpy:393
old "Tablet"
new "تابلت/ لوحي"
# game/android.rpy:397
old "Television / OUYA"
new "تلفزيون / OUYA"
# game/android.rpy:409
old "Build:"
new ""
# game/android.rpy:417
old "Install SDK & Create Keys"
new "تنصيب SDK و اختلاق مفاتيح"
# game/android.rpy:421
old "Configure"
new "إعدادات"
# game/android.rpy:425
old "Build Package"
new "بناء الحزمة"
# game/android.rpy:429
old "Build & Install"
new "بناء و تنصيب"
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# game/android.rpy:30
old "To build Android packages, please download RAPT, unzip it, and place it into the Ren'Py directory. Then restart the Ren'Py launcher."
new "لبناء ملفات الأندرويد, الرجاء تحميل RAPT, ثم فك الضغط عن الملف ووضعه في مجلد رينباي. قد تحتاج لإعادة تشغيل رينباي ليعمل بشكل صحيح."
# game/android.rpy:31
old "A 32-bit Java Development Kit is required to build Android packages on Windows. The JDK is different from the JRE, so it's possible you have Java without having the JDK.\n\nPlease {a=http://www.oracle.com/technetwork/java/javase/downloads/index.html}download and install the JDK{/a}, then restart the Ren'Py launcher."
new "تحتاج لنسخة برمجية من جافا تعتمد الـ 32-بت لتستطيع إنشاء ملفات الأندرويد على نظام الوندوز. حزمة JDK تختلف عن JRE, قد تكون الجافا لديك موجوده لكنها تفتقد الـ JDK. \n\n الرجاء {a=http://www.oracle.com/technetwork/java/javase/downloads/index.html}تحميل و تنصيب JDK{/a} ثم إعادة تشغيل رينباي"
# game/android.rpy:39
old "Attempts to emulate a televison-based Android console, like the OUYA or Fire TV.\n\nController input is mapped to the arrow keys, Enter is mapped to the select button, Escape is mapped to the menu button, and PageUp is mapped to the back button."
new "يحاول محاكاة نظام تلفزيوني للأندرويد مثل جهاز OUYA او Fire TV. \n\n يتم تخطيط الأزرار لعصا التحكم لتناسب ازرار جهاز التحكم عن بعد. Controller input is mapped to the arrow keys, Enter is mapped to the select button, Escape is mapped to the menu button, and PageUp is mapped to the back button."
# game/android.rpy:47
old "Connects to an Android device running ADB in TCP/IP mode."
new "يتصل بجهاز أندرويد يعمل على نظام ADB عن طريق TCP/IP mode"
# game/android.rpy:48
old "Disconnects from an Android device running ADB in TCP/IP mode."
new "يفصل الاتصال عن جهاز أندرويد يعمل على نظام ADB عن طريق TCP/IP mode"
# game/android.rpy:516
old "Other:"
new "آخر:"
# game/android.rpy:524
old "Remote ADB Connect"
new "الإتصال عن بعد عن طريق ADB"
# game/android.rpy:528
old "Remote ADB Disconnect"
new "قطع إتصال ADB عن بعد"
# game/android.rpy:561
old "Before packaging Android apps, you'll need to download RAPT, the Ren'Py Android Packaging Tool. Would you like to download RAPT now?"
new "قبل ان تصتطيع إنشاء ملفات للأندرويد, عليك ان تقوم بتحميل ملفات RAPT الخاصة بتحويل ملفات رينباي للأندرويد. هل تريد ان تقوم بتحميل الحزمة الآن؟"
# game/android.rpy:608
old "Remote ADB Address"
new "عنوان ADB عن بعد"
# game/android.rpy:609
old "Please enter the IP address and port number to connect to, in the form \"192.168.1.143:5555\". Consult your device's documentation to determine if it supports remote ADB, and if so, the address and port to use."
new "الرجاء إدخال عنوان الأي بي ورقم المنفذ المطلوب للإتصال, على شكل \"192.168.1.143:5555\". الرجاء العودة لدليل المستخدم الخاص بجهازك لتعرف إن كان يدعم الإتصال عن بعد للـ ADB و إن كان قادراً على ذلك, ستجد العنوان و المنفذ المطلوبان."
# game/android.rpy:619
old "Invalid remote ADB address"
new "عنوان ِADB خاطيء"
# game/android.rpy:619
old "The address must contain one exactly one ':'."
new "العنوان يجب ان يحتوي على علامة ':' واحده فقط لا غير"
# game/android.rpy:623
old "The host may not contain whitespace."
new "الخادم يجب ان لا يحتوي على مساحات فارغة"
# game/android.rpy:629
old "The port must be a number."
new "يجب ان يكون العنوان مكون من أرقام فقط"
+43
View File
@@ -0,0 +1,43 @@
translate arabic strings:
# game/choose_theme.rpy:274
old "Could not change the theme. Perhaps options.rpy was changed too much."
new "لم يتمكن رينباي من تغيير المظهر, ربما ملف options.rpy قد تغير بشكل كبير"
# game/choose_theme.rpy:332
old "Display"
new "عرض"
# game/choose_theme.rpy:333
old "Window"
new "نافذة"
# game/choose_theme.rpy:334
old "Fullscreen"
new "ملء الشاشة"
# game/choose_theme.rpy:335
old "Planetarium"
new "Planetarium"
# game/choose_theme.rpy:342
old "Sound Volume"
new "مستوى الصوت"
# game/choose_theme.rpy:376
old "Choose Theme"
new "إختر المظهر"
# game/choose_theme.rpy:389
old "Theme"
new "المظهر"
# game/choose_theme.rpy:413
old "Color Scheme"
new "توليفة الألوان"
# game/choose_theme.rpy:444
old "Continue"
new "استمرار"
+528
View File
@@ -0,0 +1,528 @@
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/00action_file.rpy:118
old "%b %d, %H:%M"
new "%b %d, %H:%M"
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/00gltest.rpy:50
old "Graphics Acceleration"
new "تسريع الرسومات"
# renpy/common/00gltest.rpy:54
old "Automatically Choose"
new "إختر بشكل اوتوماتيكي"
# renpy/common/00gltest.rpy:59
old "Force Angle/DirectX Renderer"
new "فرض استعمال محركات Angle/DirectX"
# renpy/common/00gltest.rpy:63
old "Force OpenGL Renderer"
new "فرض استعمال محركات OpenGL"
# renpy/common/00gltest.rpy:67
old "Force Software Renderer"
new "فرض استعمال المحركات البرمجية software renderer"
# renpy/common/00gltest.rpy:73
old "Changes will take effect the next time this program is run."
new "سيتم تفعيل التغييرات في المرة القادمة التي تفتح فيها البرنامج"
# renpy/common/00gltest.rpy:77
old "Quit"
new "خروج"
# renpy/common/00gltest.rpy:82
old "Return"
new "عودة"
# renpy/common/00gltest.rpy:112
old "Performance Warning"
new "تحذير عن الأداء"
# renpy/common/00gltest.rpy:117
old "This computer is using software rendering."
new "هذا الجهاز يستعمل software rendering"
# renpy/common/00gltest.rpy:119
old "This computer is not using shaders."
new "هذا الجهاز لا يستعمل shaders"
# renpy/common/00gltest.rpy:121
old "This computer is displaying graphics slowly."
new "هذا الجهاز يستعرض الرسوميات بشكل بطيء"
# renpy/common/00gltest.rpy:123
old "This computer has a problem displaying graphics: [problem]."
new "هذا الجهاز يواجه مشكلة في استعراض الرسوميات [problem]"
# renpy/common/00gltest.rpy:128
old "Its graphics drivers may be out of date or not operating correctly. This can lead to slow or incorrect graphics display. Updating DirectX could fix this problem."
new "محركات الرسوميات قد تكون قديمة او لا تعمل بشكل صحيح. قد يسبب ذلك بطء او اخطاء في الاستعراض, القيام بتحديث directX قد يساعد في حل المشكلة."
# renpy/common/00gltest.rpy:130
old "Its graphics drivers may be out of date or not operating correctly. This can lead to slow or incorrect graphics display."
new " محركات الرسوميات قد تكون قديمة او لا تعمل بشكل صحيح. قد يسبب ذلك بطء او اخطاء في الاستعراض."
# renpy/common/00gltest.rpy:135
old "Update DirectX"
new "تحديث DirectX"
# renpy/common/00gltest.rpy:141
old "Continue, Show this warning again"
new "استمرار, الرجاء عرض هذا التحذير في المرة الثادمة ايضاً"
# renpy/common/00gltest.rpy:145
old "Continue, Don't show warning again"
new "استمرار, لا تعرض هذا التحذير مرة اخرى"
# renpy/common/00gltest.rpy:171
old "Updating DirectX."
new "يتم تحديث DirectX"
# renpy/common/00gltest.rpy:175
old "DirectX web setup has been started. It may start minimized in the taskbar. Please follow the prompts to install DirectX."
new "يتم الآن تنصيب DirectX, قد يبدأ ذلك بشكل مصغر في شريط المهام. الرجاء اتباع التعليمات لاكمال التنصيب."
# renpy/common/00gltest.rpy:179
old "{b}Note:{/b} Microsoft's DirectX web setup program will, by default, install the Bing toolbar. If you do not want this toolbar, uncheck the appropriate box."
new "{b}ملاحظة:{/b} مايكروسوفت دايركت أكس يقوم تلقائياً بتنصيب شريط بينق Bing toolbar. إذا لم ترغب بذلك الرجاء القيام بإلغاء تحديد خانة الاختيار"
# renpy/common/00gltest.rpy:183
old "When setup finishes, please click below to restart this program."
new "حيثن ينتهي التنصيب, الرجاء الضغط ادناه لإعادة تشغيل البرنامج"
# renpy/common/00gltest.rpy:185
old "Restart"
new "إعادة تشغيل"
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/00keymap.rpy:167
old "Saved screenshot as %s."
new "تم حفظ الصورة كـ %s"
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/00layout.rpy:421
old "Are you sure?"
new "هل انت متأكد؟"
# renpy/common/00layout.rpy:422
old "Are you sure you want to delete this save?"
new "هل انت متأكد من رغبتك في حذف خانة الحفظ هذه؟"
# renpy/common/00layout.rpy:423
old "Are you sure you want to overwrite your save?"
new "هل انت متأكد من رغبتك في الحفظ على هذه الخانة؟"
# renpy/common/00layout.rpy:424
old "Loading will lose unsaved progress.\nAre you sure you want to do this?"
new "الاسترجاع سيضيع كل ما فعلته منذ خانة الحفظ السابقة. \n هل انت متأكد من رغبتك في الاسترجاع إلى هذه النقطة؟"
# renpy/common/00layout.rpy:425
old "Are you sure you want to quit?"
new "هل انت متأكد من رغبتك في الخروج؟"
# renpy/common/00layout.rpy:426
old "Are you sure you want to return to the main menu?\nThis will lose unsaved progress."
new "هل انت متأكد من رغبتك في العودة للقائمة الرئيسية؟ \n كل ما لم تقم بحفظة سيضيع."
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/00library.rpy:77
old "Skip Mode"
new "وضع التسريع"
# renpy/common/00library.rpy:80
old "Fast Skip Mode"
new "وضع التسريع السريع"
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/00updater.rpy:1258
old "Updater"
new "برنامج التحديث"
# renpy/common/00updater.rpy:1267
old "This program is up to date."
new "هذه النسخة هي الأحدث"
# renpy/common/00updater.rpy:1269
old "[u.version] is available. Do you want to install it?"
new "النسخة [u.version] متوفرة, هل ترغب في تنصيبها؟"
# renpy/common/00updater.rpy:1271
old "Preparing to download the updates."
new "يتم التجهيز لتحميل البرنامج من الانترنت"
# renpy/common/00updater.rpy:1273
old "Downloading the updates."
new "يتم تنزيل التحديثات"
# renpy/common/00updater.rpy:1275
old "Unpacking the updates."
new "يتم فك الضغط عن التحديثات"
# renpy/common/00updater.rpy:1279
old "The updates have been installed. The program will restart."
new "تم التحديث.. سيتم إعادة تشغيل البرنامج."
# renpy/common/00updater.rpy:1281
old "The updates have been installed."
new "تم التحديث."
# renpy/common/00updater.rpy:1283
old "The updates were cancelled."
new "تم إلغاء التحديث."
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/_compat/gamemenu.rpym:180
old "Empty Slot."
new "خانة فارغة"
# renpy/common/_compat/gamemenu.rpym:337
old "Previous"
new "السابق"
# renpy/common/_compat/gamemenu.rpym:344
old "Next"
new "التالي"
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/_compat/preferences.rpym:411
old "Joystick Mapping"
new "خيارات عصى التحكم"
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/_errorhandling.rpym:408
old "An exception has occurred."
new "حصل استثناء"
# renpy/common/_errorhandling.rpym:434
old "Rollback"
new "تراجع"
# renpy/common/_errorhandling.rpym:436
old "Attempts a roll back to a prior time, allowing you to save or choose a different choice."
new "يقوم بالتراجع لنقطة سابقة لكي تستطيع اختيار شيء آخر"
# renpy/common/_errorhandling.rpym:439
old "Ignore"
new "تجاهل"
# renpy/common/_errorhandling.rpym:441
old "Ignores the exception, allowing you to continue. This often leads to additional errors."
new "يتجاهل الاستثناء مما يستمح لك بالاستمرار. قد يسبب هذا المزيد من الاخطاء."
# renpy/common/_errorhandling.rpym:444
old "Reload"
new "إعادة المحاولة"
# renpy/common/_errorhandling.rpym:446
old "Reloads the game from disk, saving and restoring game state if possible."
new "يعيد تشغيل اللعبة من القرص الصلب, مع محاولة استعمادة آخر نقطة وحفظها عند الإستطاعة."
# renpy/common/_errorhandling.rpym:448
old "Open Traceback"
new "قراءة التقرير"
# renpy/common/_errorhandling.rpym:450
old "Opens the traceback.txt file in a text editor."
new "يفتح تقرير الخطأ في برنامج الملفات النصية."
# renpy/common/_errorhandling.rpym:456
old "Quits the game."
new "يخرج من اللعبة."
# renpy/common/_errorhandling.rpym:483
old "Parsing the script failed."
new "حصل خطأ أثناء تشغيل النص."
# renpy/common/_errorhandling.rpym:510
old "Open Parse Errors"
new "يفتح قائمة اخطاء التشغيل."
# renpy/common/_errorhandling.rpym:512
old "Opens the errors.txt file in a text editor."
new "يفتح ملف errors.txt في برنامج الملفات النصية"
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# renpy/common/_layout/classic_load_save.rpym:152
old "a"
new "a"
# renpy/common/_layout/classic_load_save.rpym:161
old "q"
new "q"
# : Translation updated at 2013-11-17 23:18
translate arabic strings:
# renpy/common/00action_file.rpy:587
old "Quick save complete."
new "تم الحفظ السريع بنجاح"
# : Translation updated at 2013-11-17 23:18
translate arabic strings:
# renpy/common/00gallery.rpy:521
old "Image [index] of [count] locked."
new "يوجد عدد صور [index] من أصل [count] مقفل"
# renpy/common/00gallery.rpy:539
old "prev"
new "السابق"
# renpy/common/00gallery.rpy:540
old "next"
new "التالي"
# renpy/common/00gallery.rpy:541
old "slideshow"
new "عرض الشرائح"
# renpy/common/00gallery.rpy:542
old "return"
new "العودة"
# : Translation updated at 2013-11-17 23:18
translate arabic strings:
# renpy/common/00layout.rpy:427
old "Are you sure you want to begin skipping?"
new "هل أنت متأكد من رغبتك في البدء بالتسريع؟"
# renpy/common/00layout.rpy:428
old "Are you sure you want to skip to the next choice?"
new "هل انت متأكد من رغبتك في التسريع حتى الخيار التالي؟"
# renpy/common/00layout.rpy:429
old "Are you sure you want to skip to unseen dialogue or the next choice?"
new "هل انت متأكد من رغبتك في تسريع الخيارات و الحوار الذي لم يسبق لك قرائته؟"
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# renpy/common/00console.rpy:179
old "%(version)s console, originally by Shiz, C, and delta.\n"
new ""
# renpy/common/00console.rpy:180
old "Press <esc> to exit console. Type help for help.\n"
new "إضغط زر الخروج لإغلاق لوحة التحكم, اكتب كلمة help للمساعدة"
# renpy/common/00console.rpy:184
old "Ren'Py script enabled."
new "لغة برمحة رينباي متاحه"
# renpy/common/00console.rpy:186
old "Ren'Py script disabled."
new "لغة برمجة رينباي غير متاحه"
# renpy/common/00console.rpy:392
old "help: show this help"
new "مساعده: عرض هذه المساعده"
# renpy/common/00console.rpy:397
old "commands:\n"
new "أوامر: \n"
# renpy/common/00console.rpy:407
old " <renpy script statement>: run the statement\n"
new "<renpy script statement>: عرض الأوامر\n"
# renpy/common/00console.rpy:409
old " <python expression or statement>: run the expression or statement"
new " <python expression or statement>: عرض التعبير او الأوامر"
# renpy/common/00console.rpy:417
old "clear: clear the console history"
new "clear: مسح تاريخ لوحة التحكم"
# renpy/common/00console.rpy:421
old "exit: exit the console"
new "exit: الخروج من لوحة التحكم"
# renpy/common/00console.rpy:429
old "load <slot>: loads the game from slot"
new "استرجاع <slot>: يقوم باسترجاع اللعب من نقطة الحفظ"
# renpy/common/00console.rpy:442
old "save <slot>: saves the game in slot"
new "حفظ <slot>: يقوم بحفظ اللعب في نقطة الحفظ"
# renpy/common/00console.rpy:453
old "reload: reloads the game, refreshing the scripts"
new "reload: يعيد تشغيل اللعبة مع عرض التغييرات في النص"
# renpy/common/00console.rpy:461
old "watch <expression>: watch a python expression"
new "مشاهده <expression>: يقوم بعرض تبيرات بايثون"
# renpy/common/00console.rpy:470
old "unwatch <expression>: stop watching an expression"
new "unwatch <expression>: يقوم بإيقاف تعبير بايثون"
# renpy/common/00console.rpy:478
old "unwatchall: stop watching all expressions"
new "unwatchall: يقوم بإيقاف كل تعبيرات بايثون"
# renpy/common/00console.rpy:484
old "jump <label>: jumps to label"
new "jump <label>: يقفز للعنوان"
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# renpy/common/00keymap.rpy:332
old "Autoreload"
new "إعادة التحميل تلقائياً"
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# renpy/common/_developer/developer.rpym:65
old "Developer Menu"
new "قائمة المبرمج"
# renpy/common/_developer/developer.rpym:67
old "Reload Game (Shift+R)"
new "إعادة تشغيل اللعبة (Shift+R)"
# renpy/common/_developer/developer.rpym:69
old "Console (Shift+O)"
new "لوحة التحكم (Shift+O)"
# renpy/common/_developer/developer.rpym:71
old "Variable Viewer"
new "مستعرض الأوامر"
# renpy/common/_developer/developer.rpym:73
old "Theme Test"
new "اختبار القوالب"
# renpy/common/_developer/developer.rpym:75
old "Image Location Picker"
new "مكان الصور المطلوبة"
# renpy/common/_developer/developer.rpym:77
old "Filename List"
new "قائمة اسماء الملفات"
# renpy/common/_developer/developer.rpym:81
old "Show Image Load Log"
new "عرض قائمة الصور "
# renpy/common/_developer/developer.rpym:84
old "Hide Image Load Log"
new "إخفاء قائمة الصور"
# renpy/common/_developer/developer.rpym:149
old "No variables have changed since the game started."
new "لم يتم تغيير اي من الأوامر منذ ان بدأت اللعبة"
# renpy/common/_developer/developer.rpym:152
old "Return to the developer menu"
new "العودة للوحة المبرمج"
# renpy/common/_developer/developer.rpym:272
old "{b}Missing Images{/b}"
new "{b}صور مفقودة{/b}"
# renpy/common/_developer/developer.rpym:424
old "Rectangle: %r"
new "مثلث: %r"
# renpy/common/_developer/developer.rpym:429
old "Mouse position: %r"
new "مكان المؤشر: %r"
# renpy/common/_developer/developer.rpym:431
old "Right-click or escape to quit."
new "إضغط بالزر الايمن او إضغط زر الخروح للإغلاق"
# renpy/common/_developer/developer.rpym:482
old "Done"
new "تم"
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# renpy/common/_developer/inspector.rpym:43
old "Displayable Inspector"
new "اختبار المستعرضات"
# renpy/common/_developer/inspector.rpym:49
old "Nothing to inspect."
new "لا يوجد شيء ليتم اختباره"
# renpy/common/_developer/inspector.rpym:58
old "Size"
new "حجم"
# renpy/common/_developer/inspector.rpym:63
old "Style"
new "مظهر"
# renpy/common/_developer/inspector.rpym:123
old "Inspecting Styles of [displayable_name!q]"
new "يتم اختبار المظهر الخاص بـ [displayable_name!q]"
# renpy/common/_developer/inspector.rpym:135
old "displayable:"
new "مستعرضات"
# renpy/common/_developer/inspector.rpym:142
old " (no properties affect the displayable)"
new " (لا توجد اي مؤثرات على هذا المستعرض)"
# renpy/common/_developer/inspector.rpym:144
old " (default properties omitted)"
new " (تم استبعاد تأثير المؤثرات القياسية)"
# renpy/common/_developer/inspector.rpym:174
old "<repr() failed>"
new "<repr() failed>"
# Translation updated at 2014-09-30 23:01
translate arabic strings:
# renpy/common/_developer/inspector.rpym:80
old "Location"
new "الموقع"
+52
View File
@@ -0,0 +1,52 @@
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# game/distribute.rpy:333
old "Nothing to do."
new "لا شيء لإنجازه"
# game/distribute.rpy:337
old "Scanning project files..."
new "يتم فحص الملفات..."
# game/distribute.rpy:344
old "Scanning Ren'Py files..."
new "يتم فحص ملفات رينباي..."
# game/distribute.rpy:494
old "Archiving files..."
new "يتم أرشفة الملفات..."
# game/distribute.rpy:745
old "Writing the [variant] [format] package."
new "يتم كتابة ملفات [variant] [format]"
# game/distribute.rpy:758
old "Making the [variant] update zsync file."
new "Making the [variant] update zsync file."
# game/distribute.rpy:854
old "Processed {b}[complete]{/b} of {b}[total]{/b} files."
new "تم انهاء {b}[complete]{/b} من عدد {b}[total]{/b} من الملفات."
# game/distribute.rpy:915
old "All packages have been built.\n\nDue to the presence of permission information, unpacking and repacking the Linux and Macintosh distributions on Windows is not supported."
new "تم الإنتهاء من تكوين رزمة البيانات لنشر اللعبة. بسبب اختلاف نظام الملفات في الأنظمة التشغيلية ماك و لينوكس, لا يمكن فك الضغط عن الرزمة الخاصة بتلك الأنظمة على نظام وندوز."
# : Translation updated at 2013-11-17 23:18
translate arabic strings:
# game/distribute.rpy:358
old "No packages are selected, so there's nothing to do."
new "لم يتم اختيار اي حزمة, لم يحصل اي شيء."
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# game/distribute.rpy:335
old "Building distributions failed:\n\nThe build.directory_name variable may not include the space, colon, or semicolon characters."
new "فشل بناء ملفات النشر. build.directory_name يجب أن لا يحتوي على مساحات فارغة, فواصل, او فواصل منقوطة في إسم المجلد "
@@ -0,0 +1,47 @@
translate arabic strings:
# game/distribute_gui.rpy:139
old "Build Distributions: [project.current.name!q]"
new "تجميع الملفات تجهيزاً للنشر: [project.current.name!q]"
# game/distribute_gui.rpy:154
old "Directory Name:"
new "اسم المجلد:"
# game/distribute_gui.rpy:158
old "Executable Name:"
new "اسم الملف التشغيلي:"
# game/distribute_gui.rpy:167
old "Actions:"
new "الأوامر:"
# game/distribute_gui.rpy:175
old "Edit options.rpy"
new "تحرير options.rpy"
# game/distribute_gui.rpy:176
old "Refresh"
new "إعادة تحميل"
# game/distribute_gui.rpy:193
old "Build Packages:"
new "بناء الرزمة البيانية:"
# game/distribute_gui.rpy:208
old "Build Updates"
new "بناء تحديثات:"
# game/distribute_gui.rpy:212
old "Build"
new "بناء"
# game/distribute_gui.rpy:219
old "Errors were detected when running the project. Please ensure the project runs without errors before building distributions."
new "تم ايجاد بعض الاخطاء في المشروع. الرجاء التأكد من خلو المشروع من الأخطاء قبل نشره بشكل نهائي."
# game/distribute_gui.rpy:236
old "Your project does not contain build information. Would you like to add build information to the end of options.rpy?"
new "مشروعك يخلو من معلومات النشر, هل ترغب في إضافة هذه المعلومات في نهاية ملف options.rpy؟"
+64
View File
@@ -0,0 +1,64 @@
# Translation updated at 2013-04-30 07:54
translate arabic strings:
# game/editor.rpy:120
old "{b}Recommended.{/b} A beta editor with an easy to use interface and features that aid in development, such as spell-checking. Editra currently lacks the IME support required for Chinese, Japanese, and Korean text input."
new "{b}نقترح.{/b} محرر نص له واجهة سهلة الاستعمال ويعين على كتابة النصوص البرمجية يفضل برنامج يحتوي على مدقق لغوي. Editraحالياً لا يدعم اللغات الأجنبية مثل اللغه الكورية و الصينية و اليابانية."
# game/editor.rpy:121
old "{b}Recommended.{/b} A beta editor with an easy to use interface and features that aid in development, such as spell-checking. Editra currently lacks the IME support required for Chinese, Japanese, and Korean text input. On Linux, Editra requires wxPython."
new "{b}نقترح.{/b} محرر نص له واجهة سهلة الاستعمال ويعين على كتابة النصوص البرمجية يفضل برنامج يحتوي على مدقق لغوي. Editraحالياً لا يدعم اللغات الأجنبية مثل اللغه الكورية و الصينية و اليابانية. على نظام لينوكس, Editra يحتاج wxPython."
# game/editor.rpy:137
old "The may have occured because wxPython is not installed on this system."
new "قد يكون السبب ان wxPython غير موجود على هذا الجهاز."
# game/editor.rpy:144
old "Up to 22 MB download required."
new "مطلوب تحميل ملف بحجم 22 ميغا بايت."
# game/editor.rpy:157
old "1.8 MB download required."
new "مطلوب تحميل ملف بحجم 1.8 ميغا بايت."
# game/editor.rpy:158
old "This may have occured because Java is not installed on this system."
new "قد يكون السبب ان الجافا غير موجوده على هذا الجهاز."
# game/editor.rpy:327
old "An exception occured while launching the text editor:\n[exception!q]"
new "حصل استثناء اثناء فتح المحرر: \n[exception!q]"
# game/editor.rpy:378
old "Select Editor"
new "الرجاء اختيار المحرر"
# game/editor.rpy:393
old "A text editor is the program you'll use to edit Ren'Py script files. Here, you can select the editor Ren'Py will use. If not already present, the editor will be automatically downloaded and installed."
new "محرر النصوص هو برنامج يساعدك على تعديل ملفات رينباي البرمجية والحوار. هنا, يمكنك اختيار المحرر الذي سيستعلمه رينباي. إذا لم يكن لديك مسبقاً, سيتم تحميله و تنصيبه بشكل اوتوماتيكي."
# game/editor.rpy:415
old "Cancel"
new "إلغاء الامر"
# Translation updated at 2013-11-17 23:18
translate arabic strings:
# game/editor.rpy:137
old "This may have occured because wxPython is not installed on this system."
new "قد يكون سبب ذلك ان wxPython غير موجود في نظام التشغيل لديك"
# game/editor.rpy:155
old "A mature editor that requires Java."
new "محرر متخصص يستعمل لغة جافا"
# game/editor.rpy:164
old "Invokes the editor your operating system has associated with .rpy files."
new "يقوم بفتح البرنامج المسؤول عن تحرير ملفات .rpy في نظامك التشغيلي"
# game/editor.rpy:180
old "Prevents Ren'Py from opening a text editor."
new "يمنع رينباي من فتح اي محرر نصوص"
+116
View File
@@ -0,0 +1,116 @@
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# game/front_page.rpy:79
old "+ Create New Project"
new "+ إبدأ مشروعاً جديداً"
# game/front_page.rpy:90
old "Launch Project"
new "تشغيل المشروع"
# game/front_page.rpy:111
old "Tutorial"
new "الدليل العملي"
# game/front_page.rpy:112
old "The Question"
new "السؤال"
# game/front_page.rpy:128
old "Active Project"
new "المشروع الحالي"
# game/front_page.rpy:136
old "Open Directory"
new "فتح مجلد"
# game/front_page.rpy:141
old "game"
new "اللعبة"
# game/front_page.rpy:142
old "base"
new "المشروع كله"
# game/front_page.rpy:148
old "Edit File"
new "تحرير ملف"
# game/front_page.rpy:156
old "All script files"
new "جميع الملفات النصية"
# game/front_page.rpy:165
old "Navigate Script"
new "مهام إضافية"
# game/front_page.rpy:176
old "Check Script (Lint)"
new "فحص الملف (لينت)"
# game/front_page.rpy:177
old "Change Theme"
new "تغيير المظهر"
# game/front_page.rpy:178
old "Delete Persistent"
new "حذف الملفات المؤقتة"
# game/front_page.rpy:186
old "Build Distributions"
new "تجميع المشروع للنشر"
# game/front_page.rpy:188
old "Generate Translations"
new "تجهيز ملفات للترجمة"
# game/front_page.rpy:204
old "Checking script for potential problems..."
new "يتم فحص الملفات لأي اخطاء محتملة..."
# game/front_page.rpy:219
old "Deleting persistent data..."
new "يتم الآن حذف الملفات المؤقتة "
# : Translation updated at 2013-11-17 23:18
translate arabic strings:
# game/front_page.rpy:204
old "Android"
new "أندرويد"
# game/front_page.rpy:206
old "Extract Dialogue"
new "استخراج النص"
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# game/front_page.rpy:144
old "[p.name!q] (template)"
new "[p.name!q] (template)"
# Translation updated at 2014-09-30 23:01
translate arabic strings:
# game/front_page.rpy:35
old "Open [text] directory."
new "فتح المجلد [text]"
# game/front_page.rpy:150
old "Select project [text]."
new "اختر المشروع [text]"
# game/front_page.rpy:234
old "Force Recompile"
new "إعادة حزم الملفات"
# game/front_page.rpy:285
old "Recompiling all rpy files into rpyc files..."
new "يتم إعادة حزم الملفات من صيغة rpy إلى rpyc..."
+90
View File
@@ -0,0 +1,90 @@
translate arabic strings:
# game/interface.rpy:89
old "Documentation"
new "المستندات المرفقة"
# game/interface.rpy:90
old "Ren'Py Website"
new "موقع رينباي"
# game/interface.rpy:91
old "Ren'Py Games List"
new "قائمة ألعاب رينباي"
# game/interface.rpy:92
old "About"
new "معلومات"
# game/interface.rpy:99
old "update"
new "تحديث"
# game/interface.rpy:101
old "preferences"
new "خيارات"
# game/interface.rpy:102
old "quit"
new "خروج"
# game/interface.rpy:149
old "Yes"
new "نعم"
# game/interface.rpy:151
old "No"
new "لا"
# game/interface.rpy:181
old "Due to package format limitations, non-ASCII file and directory names are not allowed."
new "بسبب محدودية التجميع, الاحرف الغير لاتينيه غير مسموح بها في اسم الملف او المجلدات"
# game/interface.rpy:183
old "[title]"
new "[title]"
# game/interface.rpy:248
old "ERROR"
new "خطأ"
# game/interface.rpy:280
old "While [what!q], an error occured:"
new "حصل خطأ أثناء [what!q]"
# game/interface.rpy:281
old "[exception!q]"
new "[exception!q]"
# game/interface.rpy:298
old "Text input may not contain the {{ or [[ characters."
new "لا يمكن استعمال الرمزان {{ و ]] هنا"
# game/interface.rpy:303
old "File and directory names may not contain / or \\."
new "غير مسموح ان يحتوي اسم الملف او المجلد على الرمزان / أو \\"
# game/interface.rpy:309
old "File and directory names must consist of ASCII characters."
new "اسم الملف و المجلدات التي تحتويه يجب ان تكون مكتوبة بأحرف ASCII "
# game/interface.rpy:330
old "INFORMATION"
new "معلومات"
# game/interface.rpy:373
old "PROCESSING"
new "يتم إجراء العمليات"
# game/interface.rpy:390
old "QUESTION"
new "سؤال"
translate arabic strings:
# game/interface.rpy:451
old "CHOICE"
new "إختيار"
+71
View File
@@ -0,0 +1,71 @@
translate arabic strings:
# game/navigation.rpy:150
old "Navigate: [project.current.name]"
new "الذهاب إلى: [project.current.name]"
# game/navigation.rpy:159
old "Order: "
new "الترتيب:"
# game/navigation.rpy:160
old "alphabetical"
new "أبجدي"
# game/navigation.rpy:162
old "by-file"
new "ملف ملف"
# game/navigation.rpy:164
old "natural"
new "طبيعي"
# game/navigation.rpy:168
old "refresh"
new "إعادة تحميل"
# game/navigation.rpy:176
old "Category:"
new "فئة:"
# game/navigation.rpy:178
old "files"
new "ملفات"
# game/navigation.rpy:179
old "labels"
new "وسم"
# game/navigation.rpy:180
old "defines"
new "تحديد"
# game/navigation.rpy:181
old "transforms"
new "التحول"
# game/navigation.rpy:182
old "screens"
new "النوافذ"
# game/navigation.rpy:183
old "callables"
new "ما يمكن استجلابه"
# game/navigation.rpy:184
old "TODOs"
new "TODOs"
# game/navigation.rpy:223
old "+ Add script file"
new "+إضافة ملف نص"
# game/navigation.rpy:231
old "No TODO comments found.\n\nTo create one, include \"# TODO\" in your script."
new "No TODO comments found.\n\nTo create one, include \"# TODO\" in your script."
# game/navigation.rpy:238
old "The list of names is empty."
new "قائمة الأسماء فارغة"
+48
View File
@@ -0,0 +1,48 @@
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# game/new_project.rpy:22
old "Choose Project Template"
new "الرجاء اختيار تصميم المظهر للمشروع"
# game/new_project.rpy:40
old "Please select a template to use for your new project. Ren'Py ships with a default template that creates an English-language game with standard screens."
new "الرجاء اختيار التصميم الذي ترغبه لمشروعك الجديد. رينباي يأتي بعدة تصاميم قياسية يمكنك التعديل عليها لاحقاً."
# game/new_project.rpy:55
old "PROJECT NAME"
new "اسم المشروع"
# game/new_project.rpy:56
old "Please enter the name of your project:"
new "الرجاء اختيار اسم لمشروعك الجديد"
# game/new_project.rpy:62
old "The project name may not be empty."
new "لا يمكن ان يكون اسم المشروع فارغاً"
# game/new_project.rpy:67
old "[project_name!q] already exists. Please choose a different project name."
new "الاسم [project_name!q] يوجد مسبقاً, الرجاء اختيار اسم مختلف."
# game/new_project.rpy:70
old "[project_dir!q] already exists. Please choose a different project name."
new "[project_dir!q] يوجد مسبقاً, الرجاء اختيار اسم مختلف."
# : Translation updated at 2013-11-17 23:18
translate arabic strings:
# game/new_project.rpy:40
old "Please select a template to use for your new project. The template sets the default font and the user interface language. If your language is not supported, choose 'english'."
new "الرجاء اختيار القالب المطلوب للمشروع الجديد. هذه القوالب تقوم بتجهيز اتجاه النص و اللغه المستخدمة في الواجهة لتسهل عملية البدء. إذا لم تكن لغتك مدعومة الرجاء اختيار اللغة الانجليزية."
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# game/new_project.rpy:71
old "The projects directory could not be set. Giving up."
new "لم يتم تحديد مجلد المشاريع, سيتم الإلغاء"
+84
View File
@@ -0,0 +1,84 @@
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# game/preferences.rpy:40
old "Launcher Preferences"
new "خيارات برنامج التشغيل"
# game/preferences.rpy:61
old "Projects Directory:"
new "دليل المشاريع:"
# game/preferences.rpy:68
old "[persistent.projects_directory!q]"
new "[persistent.projects_directory!q]"
# game/preferences.rpy:70
old "Not Set"
new "غير محدد"
# game/preferences.rpy:84
old "Text Editor:"
new "محرر الملفات النصية:"
# game/preferences.rpy:106
old "Update Channel:"
new "مصدر التحديثات:"
# game/preferences.rpy:126
old "Navigation Options:"
new "خيارات استعراض المجلدات"
# game/preferences.rpy:130
old "Include private names"
new "تضمين الأسماء الخاصة"
# game/preferences.rpy:131
old "Include library names"
new "تضمين اسماء المكتبات"
# game/preferences.rpy:141
old "Launcher Options:"
new "خيارات برنامج التشغيل:"
# game/preferences.rpy:145
old "Hardware rendering"
new "الإستعراض بواسطة قطع الجهاز الداخلية"
# game/preferences.rpy:148
old "Console output"
new "الإستعراض بواسطة البرمجيات المتوفرة"
# game/preferences.rpy:169
old "Open launcher project"
new "فتح الواجهة التشغيلية كمشروع"
# game/preferences.rpy:183
old "Language:"
new "اللغة:"
# Translation updated at 2014-04-17 13:01
translate arabic strings:
# game/preferences.rpy:164
old "Show templates"
new "عرض القوالب"
# Translation updated at 2014-09-30 23:01
translate arabic strings:
# game/preferences.rpy:91
old "Projects directory: [text]"
new "مجلد المشاريع [text]"
# game/preferences.rpy:114
old "Text editor: [text]"
new "محرر النصوص [text]"
# game/preferences.rpy:171
old "Large fonts"
new "خط كبير"
+68
View File
@@ -0,0 +1,68 @@
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# game/project.rpy:196
old "Ren'Py is scanning the project..."
new "رينباي يقوم بفحص المشروع"
# game/project.rpy:485
old "PROJECTS DIRECTORY"
new "سياق مجلدات المشاريع"
# game/project.rpy:485
old "Please choose the projects directory using the directory chooser.\n{b}The directory chooser may have opened behind this window.{/b}"
new "الرجاء اختيار نسق المشاريع من الصفحة الخاصة بذلك. \n{b}قد تكون النافذة ظهرت خلف هذه النافذة.{/b}"
# game/project.rpy:485
old "This launcher will scan for projects in this directory, will create new projects in this directory, and will place built projects into this directory."
new "سيقوم البرنامج بفحص المجلد هذا لإيجاد المشاريع السابقة, أو ليضع المشاريع الجديده فيه, و ايضاً لوضع المشاريع المنتهيه عند تجهيزها للنشر."
# game/project.rpy:525
old "Ren'Py was unable to run python with tkinter to choose the projects directory."
new "رينباي لم يستطع تشغيل برمجيات بايثون للبحث عن مجلد المشاريع."
# game/project.rpy:529
old "Ren'Py has set the projects directory to:"
new "رينباي قام بتحديد مجلد المشاريع إلى المكان التالي:"
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# game/project.rpy:48
old "After making changes to the script, press shift+R to reload your game."
new "عند إجراء أي تغييرات في ملف الحوار, يمكنك ضغط shift+R لترى التغييرات داخل اللعبة"
# game/project.rpy:49
old "Press shift+O (the letter) to access the console."
new "إضغط shift+O للدخول على لوحة التحكم"
# game/project.rpy:50
old "Press shift+D to access the developer menu."
new "إضغط shift+D للدخول على لوحة تحكم المبرمج"
# game/project.rpy:219
old "Launching the project failed."
new "لم تنجح محاولة إقلاع المشروع"
# game/project.rpy:219
old "Please ensure that your project launches normally before running this command."
new "الرجاء التأكد من سلامة إقلاع المشروع قبل تشغيل هذا الأمر البرمجي"
# game/project.rpy:516
old "Launching"
new "جاري الإقلاع"
# game/project.rpy:585
old "Ren'Py was unable to run python with tkinter to choose the projects directory. Please install the python-tk or tkinter package."
new "رينباي لم يتمكن من تشغيل بايثون مع tkinter لكي يختار مجلد المشاريع, الرجاء تنصيب Python-tk او tkinter"
# Translation updated at 2014-09-30 23:01
translate arabic strings:
# game/project.rpy:47
old "Have you backed up your projects recently?"
new "هل قمت بعمل نسخة احتياطية من مشاريعك مؤخراً؟"
+17
View File
@@ -0,0 +1,17 @@
translate arabic python:
al = "DejaVuSans.ttf"
style.l_default.font = al
style.l_default.size = 16
style.l_button_text.selected_font = al
style.l_button_text.selected_bold = True
style.l_link_text.font = al
style.l_alternate_text.font = al
style.l_navigation_button_text.font = al
style.l_navigation_text.font = al
style.l_navigation_text.bold = True
style.l_checkbox_text.selected_font = al
style.l_nonbox_text.selected_font = al
style.hyperlink_text.font = al
make_style_backup()
config.rtl = True
+38
View File
@@ -0,0 +1,38 @@
translate arabic strings:
# game/translations.rpy:10
old "Create or Update Translations"
new "صنع او تحديث الترجمات"
# game/translations.rpy:10
old "Please enter the name of the language for which you want to create or update translations."
new "الرجاء كتابة اسم اللغة التي ستقوم بالترجمة إليها و الضغط على زر انتر"
# game/translations.rpy:15
old "The language name can not be the empty string."
new "لا يمكن ان يكون اسم اللغة فارغاً"
# game/translations.rpy:26
old "Ren'Py is generating translations...."
new "يقوم رينباي بتصنيع ملفات الترجمة..."
# game/translations.rpy:30
old "Ren'Py has finished generating [language] translations."
new "انتهى رينباي من صناعة ملفات الترجمة إلى [language]"
translate arabic strings:
# game/translations.rpy:44
old "What format would you like for the extracted dialogue?"
new "ما هي الصيغة التي تريدها للنص المستخرج؟"
# game/translations.rpy:56
old "Ren'Py is extracting dialogue...."
new "رينباي يقوم باستخراج الحوار إلى ملف نص"
# game/translations.rpy:60
old "Ren'Py has finished extracting dialogue. The extracted dialogue can be found in dialogue.[format] in the base directory."
new "رينباي انتهى من استخراج الحوار. الحوار المستخرج يوجد الآن في [format] في المجلد الرئيسي"
+100
View File
@@ -0,0 +1,100 @@
# : Translation updated at 2013-04-30 07:54
translate arabic strings:
# game/updater.rpy:54
old "Select Update Channel"
new "الرجاء اختيار طريقة التحديث"
# game/updater.rpy:65
old "The update channel controls the version of Ren'Py the updater will download. Please select an update channel:"
new "طريقة التحديث تحدد لبرنامج رينباي اي المواقع يستخدم لإيجاد النسخ الجديدة. الرجاء اختيار الطريقة التي تناسبك."
# game/updater.rpy:70
old "Release"
new "نسخة مكتملة"
# game/updater.rpy:76
old "{b}Recommended.{/b} The version of Ren'Py that should be used in all newly-released games."
new "{b}موصى به.{/b} نسخة رينباي التي يفضل استعمالها مع كل الالعاب الجديدة."
# game/updater.rpy:81
old "Prerelease"
new "نسخة مبدأية"
# game/updater.rpy:87
old "A preview of the next version of Ren'Py that can be used for testing and taking advantage of new features, but not for final releases of games."
new "عينة من نسخة رينباي القادمة تسمح لك بتجربة الإضافات الجديدة. لا ننصح باستعمالها لصناعة ألعاب معدة للنشر."
# game/updater.rpy:93
old "Experimental"
new "نسخة تجريبية"
# game/updater.rpy:99
old "Experimental versions of Ren'Py. You shouldn't select this channel unless asked by a Ren'Py developer."
new "النسخ التجريبية من رينباي. الأفضل ألا تستعمل هذه النسخ إلا لو طلب منك ذلك احد مبرمجي رينباي"
# game/updater.rpy:119
old "An error has occured:"
new "حصل خطأ:"
# game/updater.rpy:121
old "Checking for updates."
new "يتم البحث عن تحديثات."
# game/updater.rpy:123
old "Ren'Py is up to date."
new "نسخة رينباي التي لديك هي الأحدث."
# game/updater.rpy:125
old "[u.version] is now available. Do you want to install it?"
new "النسخة [u.version] متوفرة, هل ترغب في تنصيبها؟"
# game/updater.rpy:127
old "Preparing to download the update."
new "يتم التجهيز لتنزيل التحديث."
# game/updater.rpy:129
old "Downloading the update."
new "يتم تنزيل التحديث."
# game/updater.rpy:131
old "Unpacking the update."
new "يتم فك الضغط عن التحديث."
# game/updater.rpy:133
old "Finishing up."
new "اللمسات النهائية."
# game/updater.rpy:135
old "The update has been installed. Ren'Py will restart."
new "تم تنصيب التحديثات بنجاح, سيتم إعادة تشغيل رينباي الآن."
# game/updater.rpy:137
old "The update has been installed."
new "تم تنصيب التحديثات."
# game/updater.rpy:139
old "The update was cancelled."
new "تم إلغاء التحديث."
# game/updater.rpy:156
old "Ren'Py Update"
new "تحديثات رينباي."
# game/updater.rpy:162
old "Proceed"
new "استمرار."
# : Translation updated at 2014-04-17 13:01
translate arabic strings:
# game/updater.rpy:129
old "Nightly"
new "مسائي"
# game/updater.rpy:135
old "The bleeding edge of Ren'Py development. This may have the latest features, or might not run at all."
new "أحدث نسخة طازجة من رينباي التجريبي, قد يحتوي على آخر مستجدات رينباي و قد لا يعمل مطلقاً"
+10
View File
@@ -0,0 +1,10 @@
translate french strings:
# game/about.rpy:21
old "[version!q]"
new "[version!q]"
# game/about.rpy:25
old "View license"
new "Voir la licence"
+22
View File
@@ -0,0 +1,22 @@
translate french strings:
# game/add_file.rpy:7
old "FILENAME"
new "NOM DU FICHIER"
# game/add_file.rpy:7
old "Enter the name of the script file to create."
new "Entrez le nom du fichier de script à créer."
# game/add_file.rpy:10
old "The filename must have the .rpy extension."
new "Le fichier doit avoir l'extension .rpy."
# game/add_file.rpy:18
old "The file already exists."
new "Le fichier éxiste déjà."
# game/add_file.rpy:21
old "# Ren'Py automatically loads all script files ending with .rpy. To use this\n# file, define a label and jump to it from another file.\n"
new "Ren'Py charge automatiquement tous les fichiers de script finissant par .rpy. Pour utiliser ce ficher\n#, définissez un label et faites un «jump» vers lui depuis un autre fichier.\n"

Some files were not shown because too many files have changed in this diff Show More