Compare commits
718 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2c728bc9a4 | |||
| a573008ef1 | |||
| 72a8e029ad | |||
| 4142473dc0 | |||
| 6e2bb81a1c | |||
| dd4fc916ec | |||
| 8e755eb157 | |||
| b33b9628fd | |||
| b9a6dfea88 | |||
| e16489fc5e | |||
| 1b0c5477f4 | |||
| d85565910d | |||
| 1201924c28 | |||
| 02be062444 | |||
| 7a113712e1 | |||
| c046a7fd56 | |||
| 07c1599821 | |||
| 9d5154b50a | |||
| 3982c45886 | |||
| 90772350fb | |||
| fd250df032 | |||
| 9ea3c36a88 | |||
| 4cc4cae8bb | |||
| d4d9543019 | |||
| bf2cf5b5e3 | |||
| 99cf00ad54 | |||
| 0ddb47ce6d | |||
| 52f6898ffd | |||
| cc8d2823cd | |||
| 03e09f45c0 | |||
| 061a04cd84 | |||
| 0b555d73ab | |||
| c05606aa94 | |||
| 98a37cb84f | |||
| 94f2fa7a9a | |||
| 1cf9bb29ab | |||
| 771311a955 | |||
| a647a670a4 | |||
| 00e0dfb5c7 | |||
| e1f5a7e9de | |||
| e959d3e694 | |||
| affd6d986f | |||
| f30f82262f | |||
| 39e17a5872 | |||
| b2c3480b8e | |||
| f822e9a0e9 | |||
| 4238849c4b | |||
| 23ad4f0140 | |||
| de85018794 | |||
| cfa85aeb37 | |||
| f81fdd55e2 | |||
| 5a8cf4c4ed | |||
| 98292a2dc3 | |||
| 1f16af50aa | |||
| f24af00189 | |||
| 704546149c | |||
| 259e4bbb9b | |||
| 004a05a49b | |||
| 1a91b29cf5 | |||
| 79b2f36088 | |||
| 8b52a0c515 | |||
| 01689987d5 | |||
| 9b9b8aed61 | |||
| 325299f342 | |||
| 3384fc378f | |||
| 6b66f3cce8 | |||
| d3e54853d6 | |||
| 6aa927c39a | |||
| d70374a5c0 | |||
| 67c4b55663 | |||
| 0cbb4a6c0e | |||
| 6f063c92de | |||
| 5504397bb8 | |||
| 08a15c417d | |||
| ff05b590be | |||
| eb603088ae | |||
| 1363792d17 | |||
| 21ef05b0fa | |||
| 7b34af584f | |||
| 4b5ec57624 | |||
| ccf3ce6f5b | |||
| 0fff7e9bbe | |||
| 90bda7dd23 | |||
| f845f787ad | |||
| c16774c325 | |||
| c2842286c7 | |||
| ee8744b490 | |||
| f14c68d047 | |||
| be76ab63e8 | |||
| ea825dfe23 | |||
| a0c87efac8 | |||
| b55bad9e27 | |||
| 72af1de7e6 | |||
| 85e07b8cb8 | |||
| 55c4369d6e | |||
| d860378a73 | |||
| 1943a31628 | |||
| d7a26f722f | |||
| 9af1b75fda | |||
| 4787441d1f | |||
| 9b47c3c4fd | |||
| 5c63e14ae7 | |||
| ca606112bc | |||
| e0f1fe2847 | |||
| 2179a13ea5 | |||
| 4873db2a6a | |||
| 6768f9da67 | |||
| 1a10e6d4e7 | |||
| 2159888b07 | |||
| 478135fe56 | |||
| 701bfcb23a | |||
| 3d0b9b14c8 | |||
| ad73b70c9e | |||
| c04826f663 | |||
| 9bcb811bb2 | |||
| 61d403f032 | |||
| 7651a34206 | |||
| f2334d05fd | |||
| 20a98290bd | |||
| 870db9d610 | |||
| 7ef94349bd | |||
| 987e38e2e1 | |||
| 547dbf5e16 | |||
| 9e7c373d58 | |||
| c271293b8b | |||
| eed02c98c5 | |||
| c08400cee4 | |||
| 99bf5c7e29 | |||
| 3ee7f91523 | |||
| 3715590a19 | |||
| 81c265ce46 | |||
| 112788b597 | |||
| 6b58675000 | |||
| a0872d1cdc | |||
| 1cad8b6c1e | |||
| 4a25c62fe4 | |||
| 113716bfd3 | |||
| 282b315c77 | |||
| 91b541617e | |||
| 82f634f98e | |||
| 25068cb249 | |||
| 81047a4375 | |||
| d90d91f484 | |||
| f113661745 | |||
| b87ba78b9f | |||
| 60241ad0f3 | |||
| 01471d51c5 | |||
| 8ba8b92d79 | |||
| e12935ed38 | |||
| c0ce664d7c | |||
| 39c06631bf | |||
| de3fd83810 | |||
| 015389dfeb | |||
| da69ef70bd | |||
| 2a47037f7e | |||
| 3fb7aace9c | |||
| 1a33949a5b | |||
| 4ea4a22ec9 | |||
| 55c50e62f1 | |||
| 2b5ebc443e | |||
| 705a9556e7 | |||
| ce1d05b019 | |||
| fb8151f656 | |||
| eb90c6a4e3 | |||
| 33ecff8633 | |||
| fdf7bd8112 | |||
| 8dd4ac2259 | |||
| eafc62936c | |||
| a6991d4950 | |||
| 6be3c59c0f | |||
| d961dd609b | |||
| 0a71291e24 | |||
| 7ec34e80ed | |||
| a124dce48c | |||
| fe191f364a | |||
| 9fd83f56c6 | |||
| bdaa617f65 | |||
| 1b93566780 | |||
| b10af0a3d1 | |||
| b19fe5788b | |||
| e8729a086d | |||
| 9f96864edb | |||
| ae9c2a0af7 | |||
| 76ba294af3 | |||
| 0be10220b3 | |||
| d27549bfdb | |||
| 63d7ee70e0 | |||
| 350af3ccd9 | |||
| cfa355d944 | |||
| 1bb2a49479 | |||
| ed05c4b98c | |||
| b39bb13527 | |||
| 8484b63c2d | |||
| 58d0f71df1 | |||
| f6e9262b0e | |||
| bf2da27703 | |||
| 9c9864528d | |||
| 23f3636fbb | |||
| b84d9e5ca0 | |||
| 9b030c2297 | |||
| 98c4ed746d | |||
| 09e2cbd45c | |||
| 3ff2f0cd56 | |||
| cb6c4d6953 | |||
| acfac50066 | |||
| a90c3e1255 | |||
| 91f5f40fd8 | |||
| a1616b5e65 | |||
| 739ea64fa0 | |||
| 010007b0a1 | |||
| 13fe854082 | |||
| 249c98f320 | |||
| 46e84d3661 | |||
| 171eb33966 | |||
| 35cdadbcee | |||
| fd501a7a03 | |||
| d27ea92fd1 | |||
| 0a701ed929 | |||
| b5e6cb97c7 | |||
| b2671013fd | |||
| 3eada61cc7 | |||
| f693e26ab0 | |||
| f575a1f233 | |||
| 9834b85ced | |||
| b8d96d86b7 | |||
| d58eaaf387 | |||
| 67adb17ad3 | |||
| 435e919326 | |||
| 37f35e4f34 | |||
| 3c6353f73e | |||
| dfc573d307 | |||
| 6758b6acc7 | |||
| 2c9bfddb4e | |||
| 81bf4c2288 | |||
| b38ae1fb13 | |||
| 7f0ce7a40b | |||
| 0f5da2d89b | |||
| c80095f511 | |||
| a9414d4692 | |||
| d2de95afc1 | |||
| 718a8fb4f8 | |||
| 7c603578db | |||
| 86e3c7f12f | |||
| 7d8f8b8f12 | |||
| 546a16e23c | |||
| 80571b8fbd | |||
| 7b1a634701 | |||
| 3e4efa344e | |||
| 13c76f6cb5 | |||
| a71e6cf6ec | |||
| b1dbbeeef8 | |||
| 1d3216b6c9 | |||
| 11bbe2cff8 | |||
| ff83ef5676 | |||
| dcfc3a173e | |||
| 2f83caea2d | |||
| 17ed25387d | |||
| 4d8c1031cd | |||
| 89f4b81b57 | |||
| ad50aa7602 | |||
| 316c64bb48 | |||
| 19920b37ca | |||
| ef5d6a4b66 | |||
| 2ea0299615 | |||
| 4cd605c134 | |||
| c2ddd39f2c | |||
| 47209c9f63 | |||
| bb9c7dfe46 | |||
| d95192e018 | |||
| 68b76e2306 | |||
| 6f0c5125ae | |||
| 7b6da918a7 | |||
| 0c05990db3 | |||
| a3581860b3 | |||
| f371ed6f5f | |||
| 17ea9736cd | |||
| a1e13e3eab | |||
| 1de06e650e | |||
| f92f14f68a | |||
| a3c5e57616 | |||
| 5840d6c464 | |||
| ba751a8a93 | |||
| 29c7d33c0a | |||
| dfb053dbd6 | |||
| 5918606f33 | |||
| 794f8955e3 | |||
| e90754e2dc | |||
| 976b4fc2fc | |||
| ddb7bd2167 | |||
| 74fd442303 | |||
| 66555facd5 | |||
| 83b9ca6b96 | |||
| dddeb56b91 | |||
| 39a799e995 | |||
| 88032a1478 | |||
| 90e547b0a5 | |||
| cc9ea22354 | |||
| ea3d409c19 | |||
| 5ef40f8c3e | |||
| 71ccf249f2 | |||
| 45d9d640ee | |||
| 14c38ded81 | |||
| d90d68fd68 | |||
| 9abd26d76c | |||
| 3f0b27ba26 | |||
| 70276655c8 | |||
| b07b6aa32f | |||
| bcce21b0d5 | |||
| 967e0d6539 | |||
| 383193d478 | |||
| 6b640a7070 | |||
| e22a2c16bd | |||
| 67f356f1b4 | |||
| 2eee3c772b | |||
| 7b14755607 | |||
| 8c8940dcbb | |||
| 5aadfa5ca4 | |||
| 46ef0cbf04 | |||
| be6d4fdf77 | |||
| c663b71114 | |||
| e9b8a16a80 | |||
| 2750bcf927 | |||
| 320dc92092 | |||
| 790bdb03e7 | |||
| 619addc5f0 | |||
| 47fb3f9438 | |||
| 7ac22328b2 | |||
| 91989a56e9 | |||
| 34070e63e6 | |||
| 1a5a7ef82a | |||
| e2ae6828be | |||
| 9f02ad9a82 | |||
| 0289c770b4 | |||
| 6c5ce3198e | |||
| 7acc54daa3 | |||
| 08192c47fc | |||
| b94a84b931 | |||
| 82576c5ed6 | |||
| 19333248d9 | |||
| 4774017317 | |||
| 21a667d645 | |||
| 81276aeb26 | |||
| 8e975217f5 | |||
| 3d47c7bae3 | |||
| c93a2ed5d5 | |||
| eb9b83860b | |||
| d9b7c73e8f | |||
| 0f5b7267fb | |||
| eac1b02212 | |||
| cc8396a8ab | |||
| 31a8cd2a3c | |||
| 295e64a02c | |||
| ee566fc6c8 | |||
| fb60c4acfe | |||
| 8381b5184c | |||
| 9e5570b1b4 | |||
| 2caaebc1f5 | |||
| abb99e19e2 | |||
| 63ed2b8632 | |||
| 07d1391c4a | |||
| b69c0c2007 | |||
| 6bda5fa459 | |||
| 5e9f4e71c8 | |||
| d2188c860f | |||
| b60ad5f3ec | |||
| 5305670f1c | |||
| bfb9380de0 | |||
| 25c7bc5726 | |||
| 63acf7eb05 | |||
| 2f134f69f1 | |||
| bf17e281c9 | |||
| 2b40f1b84d | |||
| e6617caeef | |||
| 34eee81a55 | |||
| bec2a832ea | |||
| 6d86238f0a | |||
| 758d5bad17 | |||
| 291ff22366 | |||
| f4f0b8f8ce | |||
| b8abc5aa16 | |||
| 28fd3c9c89 | |||
| 2c94cd19f6 | |||
| 8add2bca63 | |||
| 77041374ea | |||
| 3d54904e89 | |||
| a9d1f16cd8 | |||
| 0439b22269 | |||
| 3fe8abf25c | |||
| 04299ac0f5 | |||
| 96397ea768 | |||
| 6580b36e35 | |||
| 4af4384dac | |||
| ebaaf0b242 | |||
| bea36e2aa2 | |||
| 247ec17be3 | |||
| 577c378517 | |||
| 52e631f229 | |||
| f8307f725e | |||
| c13fbcaab2 | |||
| 6c4eff321e | |||
| 54b8b73d45 | |||
| 0e88b7629e | |||
| 012f148622 | |||
| 56a20cc877 | |||
| b8df922459 | |||
| 896232d308 | |||
| 0207327ded | |||
| e6815a3a4f | |||
| 179bbaea92 | |||
| c7889bc7a2 | |||
| ce9ecd124a | |||
| 426a12d50c | |||
| eefd0ed728 | |||
| 6604043df0 | |||
| a3271bb290 | |||
| aeed3598a1 | |||
| 4b43986a6c | |||
| 4f79180a8e | |||
| a635c4c35c | |||
| afc42f4ed3 | |||
| 547accfd44 | |||
| ccb51c7a26 | |||
| 33190bba34 | |||
| b3147011d4 | |||
| 4c987901b6 | |||
| ce332b895f | |||
| 9b5823109f | |||
| 7a84fb8cdd | |||
| 94c5c525a7 | |||
| 0d25e419b4 | |||
| b669f8363c | |||
| 8e44aa6f88 | |||
| 3ef70f862e | |||
| e4d99edb65 | |||
| 5f611786dd | |||
| 657711a0a7 | |||
| 0f1e6e7702 | |||
| e379ffae51 | |||
| b10d5e715c | |||
| 2f54637881 | |||
| eda1e01a71 | |||
| 8fdc4b8f58 | |||
| 3048825824 | |||
| 704685c11a | |||
| 7fba3a04da | |||
| bfc57ecfc6 | |||
| c0dba7f121 | |||
| ce3e63f3a5 | |||
| 0105503855 | |||
| 0d8525f1b1 | |||
| bfd4a1e846 | |||
| c74343d2dd | |||
| 6f7f545cd8 | |||
| 303885776e | |||
| cabcf5b73c | |||
| a8a1972418 | |||
| 347778d8aa | |||
| 9646c951bb | |||
| 7b4128f6b2 | |||
| 7ac623fc99 | |||
| e9328255b7 | |||
| 11ce47287b | |||
| a1ab25955d | |||
| 3f59b82c2a | |||
| 0e6cded6cd | |||
| e18f73b317 | |||
| e65146503c | |||
| a6a5c65067 | |||
| afb58fa423 | |||
| 8762636374 | |||
| d1b53fb56c | |||
| c7b028b8cf | |||
| d0ee364a81 | |||
| a48fdc0d2c | |||
| a464034fd0 | |||
| 51955cae76 | |||
| f2633d528e | |||
| 33090e1aa4 | |||
| ffc801eaca | |||
| 49e77a1fa1 | |||
| 13c5ddc5fa | |||
| 1ee54eecbd | |||
| b7ac285aeb | |||
| b6b50f1842 | |||
| d283792193 | |||
| 0c5ccd267c | |||
| 81108e2d26 | |||
| 3c3590bafe | |||
| b9e1120f69 | |||
| 9f943337bb | |||
| ab8964be1d | |||
| 37c1ba3926 | |||
| 364d077c8a | |||
| 626f86b500 | |||
| d6488e4e7d | |||
| 846abef17f | |||
| 60e65a4d01 | |||
| 4057365ff1 | |||
| f7d95e2791 | |||
| db812e7f7b | |||
| 66e51bab0d | |||
| d0d82a5e22 | |||
| 2d99e76007 | |||
| 102ff2145f | |||
| 0e00282758 | |||
| 337d12e490 | |||
| 916e125f4b | |||
| 752ef70000 | |||
| b67c70dbe3 | |||
| 8277ba6b5b | |||
| 2db2a4a94d | |||
| a477b862dd | |||
| 0a5cf3bcee | |||
| 2d6e2bcd61 | |||
| 8d8b52dead | |||
| 3409759271 | |||
| 3109dad59b | |||
| 16c35e21f4 | |||
| 509b33477a | |||
| 4fcfdd24d1 | |||
| 473e8ea861 | |||
| 0bbbde3fb6 | |||
| 0576bb71de | |||
| e91d35abda | |||
| da638df367 | |||
| bf8467aaa0 | |||
| 3a8eea3223 | |||
| 566ed9bae6 | |||
| 132341c9b5 | |||
| 3f2a18a387 | |||
| 296f940437 | |||
| dc7833e0fe | |||
| 7f38694341 | |||
| 0a25f4e488 | |||
| 88d5b6ea16 | |||
| b775916a8d | |||
| c1e4d3d598 | |||
| 2435b50e6d | |||
| 466c40f501 | |||
| e76f4205cb | |||
| 1961d467d9 | |||
| 3cb9b3637d | |||
| cf0232d24a | |||
| d1c786aa4a | |||
| 209b2b2099 | |||
| efd378e71c | |||
| 50edf2ad83 | |||
| 27aae8a8f0 | |||
| b07cae5959 | |||
| f786704d9a | |||
| 9f46f7a824 | |||
| 9b98a0f442 | |||
| 165c6886c1 | |||
| c79f9f585b | |||
| 486ea3dc70 | |||
| 765566acb0 | |||
| 06e06c3504 | |||
| a16cf65808 | |||
| b65a5e6452 | |||
| ec88378641 | |||
| e22cc152d8 | |||
| db8adea231 | |||
| 7c7c92fe91 | |||
| 7a8dec6afa | |||
| 49637c2dbd | |||
| 51372d281a | |||
| 3a4973ba20 | |||
| e447c6170b | |||
| 90b25d3ea4 | |||
| 951afa8799 | |||
| 644243db31 | |||
| 212a1f0682 | |||
| d700cd9a97 | |||
| 59d4ff87b8 | |||
| 08641efd0c | |||
| 7c81554b39 | |||
| 6fc1792436 | |||
| c2855f7871 | |||
| 5988076d56 | |||
| 4a0164fc7f | |||
| 9bad334102 | |||
| 4dfca9e6c1 | |||
| 8b1dee04cd | |||
| d856bd13be | |||
| e9d198109c | |||
| aed19f9492 | |||
| 126c520d14 | |||
| 6d23374f01 | |||
| 6f0c5873c2 | |||
| b8fb05f30f | |||
| 925b53db58 | |||
| 99c1268051 | |||
| 6be247e07d | |||
| dfa423b62d | |||
| 49b95e1a8a | |||
| 03eedca87c | |||
| 4602f8b43a | |||
| 9b77f044ab | |||
| 7200908ea9 | |||
| b87827f53b | |||
| 173370b905 | |||
| 628703aab3 | |||
| 6bd014b9a6 | |||
| 7feff9e690 | |||
| af300d118a | |||
| 25e74c5f79 | |||
| c63d860d1f | |||
| 32db1082c0 | |||
| 06193b4285 | |||
| 1192c546a1 | |||
| ec3881d5c4 | |||
| 473ae87547 | |||
| 6112741a6b | |||
| b68e23551a | |||
| 817bc804a6 | |||
| 93976e043f | |||
| 07b48bd353 | |||
| 6923507e74 | |||
| 5e1a260546 | |||
| 63e2cc802c | |||
| c4bdd4a800 | |||
| 0fdca7c146 | |||
| 0d35f3709b | |||
| b1e366a31f | |||
| 922e5c0fbb | |||
| 11bc000a85 | |||
| 8ab9bb0e01 | |||
| ea83307012 | |||
| df35b3f955 | |||
| b9b460e549 | |||
| 91f78bee55 | |||
| a0833f0dd7 | |||
| b9a2c8d50c | |||
| dafd79d55b | |||
| 18808fffec | |||
| 29ea80260f | |||
| a61dd71833 | |||
| e1b740eeff | |||
| c99e94e24d | |||
| 7141ae8478 | |||
| b10df22048 | |||
| 986a5822bc | |||
| 5f0057d3f8 | |||
| 8b64077881 | |||
| 61c7e90f86 | |||
| 9ec2752883 | |||
| 192fe79839 | |||
| 51e548d481 | |||
| 045077e983 | |||
| 334195cc8f | |||
| 1d5696e10d | |||
| d4139d026a | |||
| 13520a7e23 | |||
| 49890f230a | |||
| 0bb8c545f0 | |||
| f7d799ea78 | |||
| c7cadc4097 | |||
| 583b4d79af | |||
| d58bea4f19 | |||
| bacab075d8 | |||
| 46b4ca65eb | |||
| 783fdc120a | |||
| 4cce7d9523 | |||
| 065a1736f6 | |||
| 8f5119bb10 | |||
| f5a9eb90ac | |||
| 24f553dfec | |||
| 47be57973e | |||
| 23240e634a | |||
| c13438cee9 | |||
| 3e3cd634a0 | |||
| 72c5974efe | |||
| 5832498bfe | |||
| 965418255d | |||
| 317f981657 | |||
| 8706c55260 | |||
| d29326065e | |||
| e5cdb1346d | |||
| 9b2ff06341 | |||
| 725382a378 | |||
| 61c4cac28e | |||
| 05a0273995 | |||
| 5c30ed7ebe | |||
| 32f7790b1f | |||
| 0926618ed0 | |||
| e4b8b3e726 | |||
| 0615b8432e | |||
| 88ad3fc1dd | |||
| 4187cdafd4 | |||
| 62d4323c95 | |||
| 57f1fb6505 | |||
| c953a71e36 | |||
| db7075753d | |||
| f9709a429e | |||
| 3bc64e4af3 | |||
| 49cf9af762 | |||
| ed14a0576a | |||
| ec3a4ddb5a | |||
| 097479d0b0 | |||
| a995e3f542 | |||
| a0cfb8779d | |||
| 3b137c3e54 | |||
| 50cc54840f | |||
| d9799ac5bb | |||
| 64bf3f1b9c | |||
| b791945564 | |||
| a8cc7abfff | |||
| fa15618437 | |||
| 844f7ac4d2 | |||
| a43426bf64 | |||
| 7015216392 | |||
| 5cc0dbbf08 | |||
| 98acd5b0f3 | |||
| 14f24424ea | |||
| af3a579122 | |||
| ae769272a6 | |||
| 8fdec02557 | |||
| f8cef3d339 |
@@ -1,106 +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
|
||||
Lucy Sprites.zip
|
||||
translate
|
||||
close_bugs.py
|
||||
.logplayer
|
||||
scite-6.10.zip
|
||||
scite-renpy-20090803.zip
|
||||
module/cython.sh
|
||||
old_demo
|
||||
opengl.txt
|
||||
Microsoft.VC90.CRT.manifest
|
||||
console.exe
|
||||
msvcr90.dll
|
||||
python26.dll
|
||||
renpy.exe
|
||||
lib/windows-x86
|
||||
sphinx/source/inc/*
|
||||
doc/*
|
||||
updates/prerelease
|
||||
module/render.c
|
||||
module/_renpy.c
|
||||
module/_renpy_pysdlgl.c
|
||||
module/_renpybidi.c
|
||||
module/sound.c
|
||||
module/winmixer.c
|
||||
module/accelerator.html
|
||||
module/gldraw.html
|
||||
module/glenviron_fixed.html
|
||||
module/glenviron.html
|
||||
module/glenviron_limited.html
|
||||
module/glenviron_shader.html
|
||||
module/glrtt_copy.html
|
||||
module/glshader.html
|
||||
module/gltexture.html
|
||||
module/render.html
|
||||
module/accelerator.c
|
||||
module/gldraw.c
|
||||
module/glenviron.c
|
||||
module/glenviron_fixed.c
|
||||
module/glenviron_limited.c
|
||||
module/glenviron_shader.c
|
||||
module/glrtt_copy.c
|
||||
module/glshader.c
|
||||
module/gltexture.c
|
||||
log.txt
|
||||
lib/linux-x86
|
||||
lib/python
|
||||
lib/update-version.txt
|
||||
sphinx/game/saves
|
||||
tutorial/game/saves
|
||||
doc
|
||||
unparse.py
|
||||
module/glrtt_fbo.c
|
||||
module/glrtt_fbo.html
|
||||
tutorial/game/cache
|
||||
renpy.exe.log
|
||||
@@ -0,0 +1,54 @@
|
||||
*.rpyc
|
||||
*.rpyb
|
||||
*.rpymc
|
||||
*.pyc
|
||||
*.pyo
|
||||
|
||||
*~
|
||||
*.bak
|
||||
|
||||
saves
|
||||
tmp
|
||||
cache
|
||||
|
||||
log.txt
|
||||
|
||||
/build
|
||||
/dist
|
||||
/dists
|
||||
/renpy.app
|
||||
/jedit
|
||||
/lint.txt
|
||||
/renpy.code
|
||||
/traceback.txt
|
||||
/testing*
|
||||
/screenshot*
|
||||
/errors.txt
|
||||
/styles.txt
|
||||
/Microsoft.VC90.CRT.manifest
|
||||
/console.exe
|
||||
/msvcr90.dll
|
||||
/python27.dll
|
||||
/renpy.exe
|
||||
/lib/windows-x86
|
||||
/lib/linux-x86_64
|
||||
/lib/linux-i686
|
||||
/lib/python2.7
|
||||
/doc
|
||||
/.pydevproject
|
||||
/.pydevproject.bak
|
||||
/.project
|
||||
/.settings
|
||||
/LICENSE.txt
|
||||
/template/README.html
|
||||
/the_question/README.html
|
||||
/tutorial/README.html
|
||||
/renpy/angle/*.pyx
|
||||
/renpy/angle/*.pxd
|
||||
/renpy-ppc.zip
|
||||
/module/build
|
||||
/module/gen
|
||||
/editra
|
||||
|
||||
dl
|
||||
renpy/vc_version.py
|
||||
@@ -1,801 +0,0 @@
|
||||
=======
|
||||
License
|
||||
=======
|
||||
|
||||
Most of Ren'Py 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.
|
||||
|
||||
Portions of Ren'Py are derived from code that is copyright using the
|
||||
Lesser GNU Public License, so Ren'Py games must be distributed in a
|
||||
manner that satisfies the LGPL.
|
||||
|
||||
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.
|
||||
|
||||
Ren'Py binaries include code from the following projects:
|
||||
|
||||
* Python (Python License)
|
||||
* Pygame (LGPL)
|
||||
* SDL (LGPL)
|
||||
* SDL_image (LGPL)
|
||||
* SDL_ttf (LGPL)
|
||||
* Freetype (LGPL)
|
||||
* FFmpeg (LGPL)
|
||||
* Fribidi (LGPL)
|
||||
* jpeg (JPEG License)
|
||||
* libpng (PNG license)
|
||||
* zlib (Zlib License)
|
||||
* bzip2 (Bzip2 License)
|
||||
* pyobjc (MIT License)
|
||||
* py2exe (MIT License)
|
||||
* GLEW (Modified BSD, MIT)
|
||||
|
||||
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.
|
||||
|
||||
|
||||
Modified BSD License
|
||||
====================
|
||||
|
||||
::
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright notice,
|
||||
this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright notice,
|
||||
this list of conditions and the following disclaimer in the documentation
|
||||
and/or other materials provided with the distribution.
|
||||
* The name of the author may be used to endorse or promote products
|
||||
derived from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "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 COPYRIGHT OWNER OR CONTRIBUTORS 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.
|
||||
@@ -1,15 +1,4 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ "x$1" = "x" ]; then
|
||||
echo need version
|
||||
exit
|
||||
fi
|
||||
|
||||
rsync -av updates tom@onegeek.org:/home/tom/WWW.update/renpy/
|
||||
|
||||
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
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
ln -s ../help.html tutorial/README.html
|
||||
ln -s ../help.html the_question/README.html
|
||||
ln -s ../help.html template/README.html
|
||||
|
||||
ln -s sphinx/source/license.rst LICENSE.txt
|
||||
ln -s sphinx/build/html doc
|
||||
@@ -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' },
|
||||
)
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
import modulefinder
|
||||
import shutil
|
||||
from distutils.core import setup
|
||||
import py2exe
|
||||
import py2exe #@UnresolvedImport @UnusedImport
|
||||
import sys
|
||||
import zipfile
|
||||
import traceback
|
||||
@@ -27,7 +27,7 @@ def move_from_dist(fn):
|
||||
os.rename("dist/" + fn, fn)
|
||||
|
||||
import renpy
|
||||
renpy.setup_modulefinder(modulefinder)
|
||||
renpy.setup_modulefinder(modulefinder) #@UndefinedVariable
|
||||
|
||||
def main():
|
||||
|
||||
@@ -49,17 +49,15 @@ def main():
|
||||
'pygame.surfarray',
|
||||
'pygame.mixer',
|
||||
'pygame.mixer_music',
|
||||
'pygame.font',
|
||||
'_ssl',
|
||||
'_hashlib',
|
||||
'win32con',
|
||||
'win32api',
|
||||
'Numeric',
|
||||
'locale',
|
||||
'gettext',
|
||||
'os2emxpath',
|
||||
'macpath',
|
||||
'posixpath',
|
||||
'multiprocessing',
|
||||
'_multiprocessing',
|
||||
],
|
||||
'optimize' : 2,
|
||||
} },
|
||||
@@ -95,15 +93,16 @@ def main():
|
||||
os.unlink("dist/lib/windows-x86/renpy.code")
|
||||
os.rename("dist/lib/windows-x86/renpy.code.new", "dist/lib/windows-x86/renpy.code")
|
||||
|
||||
# Take these files from the old python.
|
||||
shutil.copy("c:/Python26/Microsoft.VC90.CRT.manifest", "Microsoft.VC90.CRT.manifest")
|
||||
shutil.copy("c:/Python26/msvcr90.dll", "msvcr90.dll")
|
||||
|
||||
move_from_dist("lib/windows-x86")
|
||||
move_from_dist("console.exe")
|
||||
move_from_dist("python26.dll")
|
||||
move_from_dist("python27.dll")
|
||||
move_from_dist("renpy.exe")
|
||||
|
||||
|
||||
|
||||
|
||||
try:
|
||||
main()
|
||||
except:
|
||||
|
||||
@@ -3,8 +3,6 @@
|
||||
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.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This file contains warpers that are used by ATL. They need to be defined
|
||||
|
||||
@@ -0,0 +1,301 @@
|
||||
|
||||
# Contains functions and variables that control the building of
|
||||
# distributions.
|
||||
|
||||
init -1000 python in build:
|
||||
|
||||
def make_file_lists(s):
|
||||
"""
|
||||
Turns `s` into a (perhaps empty) list of file_lists.
|
||||
|
||||
If `s` is a list or None, then returns it. If it's a string, splits
|
||||
it on whitespace. Otherwise, errors out.
|
||||
"""
|
||||
|
||||
if s is None:
|
||||
return s
|
||||
elif isinstance(s, list):
|
||||
return s
|
||||
elif isinstance(s, basestring):
|
||||
return s.split()
|
||||
|
||||
raise Exception("Expected a string, list, or None.")
|
||||
|
||||
|
||||
|
||||
def pattern_list(l):
|
||||
"""
|
||||
Apply file_lists to the second argument of each tuple in a list.
|
||||
"""
|
||||
|
||||
rv = [ ]
|
||||
|
||||
for pattern, groups in l:
|
||||
rv.append((pattern, make_file_lists(groups)))
|
||||
|
||||
return rv
|
||||
|
||||
# Patterns that are used to classify Ren'Py.
|
||||
renpy_patterns = pattern_list([
|
||||
( "**~", None),
|
||||
( "**/#*", None),
|
||||
( "**/.*", None),
|
||||
( "**.old", None),
|
||||
( "**.new", None),
|
||||
( "**.rpa", None),
|
||||
|
||||
( "**/*.pyc", None),
|
||||
|
||||
( "renpy.py", "all"),
|
||||
( "renpy/**", "all"),
|
||||
( "common/**", "all"),
|
||||
|
||||
# Windows-specific patterns.
|
||||
( "python*.dll", "windows" ),
|
||||
( "msvcr*.dll", "windows"),
|
||||
( "Microsoft.VC*.CRT.manifest", "windows"),
|
||||
( "lib/dxwebsetup.exe", "windows"),
|
||||
( "lib/windows-x86/**", "windows"),
|
||||
|
||||
# Linux patterns.
|
||||
( "renpy.sh", "linux"),
|
||||
( "lib/linux-x86_64/**", "linux"),
|
||||
( "lib/linux-i686/**", "linux"),
|
||||
( "lib/python2.7/**", "linux"),
|
||||
|
||||
# Mac patterns.
|
||||
( "renpy.app/Contents/Ren'Py Launcher", None),
|
||||
( "renpy.app/Contents/Info.plist", None),
|
||||
( "renpy.app/Contents/Resources/launcher.py", None),
|
||||
( "renpy.app/Contents/Resources/launcher.icns", None),
|
||||
( "renpy.app/**", "mac"),
|
||||
|
||||
# Shared patterns.
|
||||
( "/lib/", "windows linux"),
|
||||
])
|
||||
|
||||
|
||||
def classify_renpy(pattern, groups):
|
||||
"""
|
||||
Classifies files in the Ren'Py base directory according to pattern.
|
||||
"""
|
||||
|
||||
renpy_patterns.append((pattern, make_file_lists(groups)))
|
||||
|
||||
# Patterns that are relative to the base directory.
|
||||
|
||||
early_base_patterns = pattern_list([
|
||||
("*.py", None),
|
||||
("*.sh", None),
|
||||
("*.app/", None),
|
||||
("*.dll", None),
|
||||
("*.manifest", None),
|
||||
|
||||
("lib/", None),
|
||||
("renpy/", None),
|
||||
("update/", None),
|
||||
("common/", None),
|
||||
("update/", None),
|
||||
|
||||
("icon.ico", None),
|
||||
("icon.icns", None),
|
||||
("project.json", None),
|
||||
|
||||
("tmp/", None),
|
||||
("game/saves/", None),
|
||||
|
||||
("archived/", None),
|
||||
("launcherinfo.py", None),
|
||||
("android.txt", None),
|
||||
])
|
||||
|
||||
base_patterns = [ ]
|
||||
|
||||
late_base_patterns = pattern_list([
|
||||
("**", "all")
|
||||
])
|
||||
|
||||
def classify(pattern, file_list):
|
||||
"""
|
||||
:doc: build
|
||||
|
||||
Classifies files that match `pattern` into `file_list`.
|
||||
"""
|
||||
|
||||
base_patterns.append((pattern, make_file_lists(file_list)))
|
||||
|
||||
def clear():
|
||||
"""
|
||||
:doc: build
|
||||
|
||||
Clears the list of patterns used to classify files.
|
||||
"""
|
||||
|
||||
base_patterns[:] = [ ]
|
||||
|
||||
def remove(l, pattern):
|
||||
"""
|
||||
Removes the pattern from the list.
|
||||
"""
|
||||
|
||||
l[:] = [ (p, fl) for i in l if p != pattern ]
|
||||
|
||||
# Archiving.
|
||||
|
||||
archives = [ ]
|
||||
|
||||
def archive(name, file_list="all"):
|
||||
"""
|
||||
:doc: build
|
||||
|
||||
Declares the existence of an archive. If one or more files are
|
||||
classified with `name`, `name`.rpa is build as an archive. The
|
||||
archive is included in the named file lists.
|
||||
"""
|
||||
|
||||
archives.append((name, make_file_lists(file_list)))
|
||||
|
||||
archive("archive", "all")
|
||||
|
||||
# Documentation patterns.
|
||||
|
||||
documentation_patterns = [ ]
|
||||
|
||||
def documentation(pattern):
|
||||
"""
|
||||
:doc: build
|
||||
|
||||
Declares a pattern that matches documentation. In a mac app build,
|
||||
files matching the documentation pattern are stored twice - once
|
||||
inside the app package, and again outside of it.
|
||||
"""
|
||||
|
||||
documentation_patterns.append(pattern)
|
||||
|
||||
xbit_patterns = [
|
||||
"**.sh",
|
||||
"**/*.so.*",
|
||||
"**/*.so",
|
||||
"**/*.dylib",
|
||||
"**.app/Contents/MacOS/*",
|
||||
"lib/**/python",
|
||||
"lib/**/zsync",
|
||||
"lib/**/zsyncmake",
|
||||
]
|
||||
|
||||
def executable(pattern):
|
||||
"""
|
||||
:doc: build
|
||||
|
||||
Adds a pattern marking files as executable on platforms that support it.
|
||||
(Linux and Macintosh)
|
||||
"""
|
||||
|
||||
xbit_patterns.append(pattern)
|
||||
|
||||
# Packaging.
|
||||
|
||||
packages = [ ]
|
||||
|
||||
def package(name, format, file_lists, description=None, update=True, dlc=False):
|
||||
"""
|
||||
:doc: build
|
||||
|
||||
Declares a package that can be built by the packaging
|
||||
tool.
|
||||
|
||||
`name`
|
||||
The name of the package.
|
||||
|
||||
`format`
|
||||
The format of the package. A string containing a space separated
|
||||
list of:
|
||||
|
||||
zip
|
||||
A zip file.
|
||||
app-zip
|
||||
A zip file containing a macintosh application.
|
||||
tar.bz2
|
||||
A tar.bz2 file.
|
||||
|
||||
The empty string will not build any package formats (this
|
||||
makes dlc possible).
|
||||
|
||||
`file_lists`
|
||||
A list containing the file lists that will be contained
|
||||
within the package.
|
||||
|
||||
`description`
|
||||
An optional description of the package to be built.
|
||||
|
||||
`update`
|
||||
If true and updates are being built, an update will be
|
||||
built for this package.
|
||||
|
||||
`dlc`
|
||||
If true, any zip or tar.bz2 file will be built in
|
||||
standalone DLC mode, without an update directory.
|
||||
"""
|
||||
|
||||
formats = format.split()
|
||||
|
||||
for i in formats:
|
||||
if i not in [ "zip", "app-zip", "tar.bz2" ]:
|
||||
raise Exception("Format {} not known.".format(i))
|
||||
|
||||
if description is None:
|
||||
description = name
|
||||
|
||||
d = {
|
||||
"name" : name,
|
||||
"formats" : formats,
|
||||
"file_lists" : make_file_lists(file_lists),
|
||||
"description" : description,
|
||||
"update" : update,
|
||||
"dlc" : dlc,
|
||||
}
|
||||
|
||||
packages.append(d)
|
||||
|
||||
package("all", "zip", "windows mac linux all", "All Desktop Platforms")
|
||||
package("linux", "tar.bz2", "linux all", "Linux x86/x86_64")
|
||||
package("mac", "app-zip", "mac all", "Macintosh x86")
|
||||
package("win", "zip", "windows all", "Windows x86")
|
||||
|
||||
# Data that we expect the user to set.
|
||||
|
||||
# The name of directories in the archives.
|
||||
directory_name = ""
|
||||
|
||||
# The name of executables.
|
||||
executable_name = ""
|
||||
|
||||
# Should we include update information into the archives?
|
||||
include_update = False
|
||||
|
||||
# A verbose version to include in the update.
|
||||
version = None
|
||||
|
||||
# Are we building Ren'Py?
|
||||
renpy = False
|
||||
|
||||
# This function is called by the json_dump command to dump the build data
|
||||
# into the json file.
|
||||
def dump():
|
||||
rv = { }
|
||||
|
||||
rv["directory_name"] = directory_name
|
||||
rv["executable_name"] = executable_name
|
||||
rv["include_update"] = include_update
|
||||
|
||||
rv["packages"] = packages
|
||||
rv["archives"] = archives
|
||||
rv["documentation_patterns"] = documentation_patterns
|
||||
rv["base_patterns"] = early_base_patterns + base_patterns + late_base_patterns
|
||||
rv["renpy_patterns"] = renpy_patterns
|
||||
rv["xbit_patterns"] = xbit_patterns
|
||||
rv["version"] = version or directory_name
|
||||
|
||||
rv["renpy"] = renpy
|
||||
|
||||
return rv
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init -1210 python:
|
||||
@@ -48,9 +48,27 @@ init -1210 python:
|
||||
config.imagereference_respects_position = True
|
||||
config.predict_screens = False
|
||||
config.choice_screen_chosen = False
|
||||
|
||||
if version <= (6, 12, 0):
|
||||
config.keep_running_transform = False
|
||||
config.image_attributes = False
|
||||
config.new_character_image_argument = False
|
||||
config.save_physical_size = False
|
||||
|
||||
|
||||
|
||||
if version <= (6, 12, 2):
|
||||
style.default.language = "western"
|
||||
style.default.layout = "greedy"
|
||||
config.new_substitutions = False
|
||||
config.broken_line_spacing = True
|
||||
|
||||
if (6, 12, 2) < version <= (6, 13, 8):
|
||||
config.old_substitutions = False
|
||||
|
||||
if version <= (6, 13, 12):
|
||||
global MoveTransition
|
||||
MoveTransition = OldMoveTransition
|
||||
|
||||
|
||||
init 1210 python hide::
|
||||
|
||||
# This returns true if the script_version is <= the
|
||||
@@ -103,3 +121,8 @@ init 1210 python hide::
|
||||
|
||||
for i in layout.compat_funcs:
|
||||
i()
|
||||
|
||||
if config.hyperlink_styler or config.hyperlink_callback or config.hyperlink_focus:
|
||||
style.default.hyperlink_functions = (config.hyperlink_styler, config.hyperlink_callback, config.hyperlink_focus)
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This file contains a number of definitions of standard
|
||||
@@ -24,6 +24,15 @@ init -1110:
|
||||
|
||||
transform truecenter:
|
||||
xpos 0.5 xanchor 0.5 ypos 0.5 yanchor 0.5
|
||||
|
||||
transform topleft:
|
||||
xpos 0.0 xanchor 0.0 ypos 0.0 yanchor 0.0
|
||||
|
||||
transform topright:
|
||||
xpos 1.0 xanchor 1.0 ypos 0.0 yanchor 0.0
|
||||
|
||||
transform top:
|
||||
xpos 0.5 xanchor 0.5 ypos 0.0 yanchor 0.0
|
||||
|
||||
# Offscreen positions for use with the move transition. Images at
|
||||
# these positions are still shown (and consume
|
||||
@@ -38,6 +47,20 @@ init -1110:
|
||||
alpha 1 rotate None zoom 1 xzoom 1 yzoom 1 align (0, 0) alignaround (0, 0) subpixel False size None crop None
|
||||
xpos 0.5 xanchor 0.5 ypos 1.0 yanchor 1.0
|
||||
|
||||
# These are used by the transitions to move things offscreen. We don't
|
||||
# expect them to be used by user code.
|
||||
transform _moveleft:
|
||||
xpos 0.0 xanchor 1.0
|
||||
|
||||
transform _moveright:
|
||||
xpos 1.0 xanchor 0.0
|
||||
|
||||
transform _movetop:
|
||||
ypos 0.0 yanchor 1.0
|
||||
|
||||
transform _movebottom:
|
||||
ypos 1.0 yanchor 0.0
|
||||
|
||||
python:
|
||||
config.default_transform = default
|
||||
|
||||
@@ -74,6 +97,7 @@ init -1110 python:
|
||||
|
||||
# Ease images around. These are basically cosine-warped moves.
|
||||
def _ease_out_time_warp(x):
|
||||
print "ZZZ"
|
||||
import math
|
||||
return 1.0 - math.cos(x * math.pi / 2.0)
|
||||
|
||||
@@ -85,70 +109,136 @@ init -1110 python:
|
||||
import math
|
||||
return .5 - math.cos(math.pi * x) / 2.0
|
||||
|
||||
# This defines a family of move transitions.
|
||||
|
||||
# Back up the move transition, so that if MoveTransition gets replaced by
|
||||
# renpy.compat, this still works.
|
||||
__MoveTransition = MoveTransition
|
||||
|
||||
# This defines a family of move transitions, using the old-style methods.
|
||||
def move_transitions(prefix, delay, time_warp=None, in_time_warp=None, out_time_warp=None, old=False, layers=[ 'master' ], **kwargs):
|
||||
"""
|
||||
:doc: transition_family
|
||||
|
||||
This defines a family of move transitions, similar to the move and ease
|
||||
transitions. For a given `prefix`, this defines the transitions:
|
||||
|
||||
* *prefix*- A transition that takes `delay` seconds to move images that
|
||||
changed positions to their new locations.
|
||||
|
||||
* *prefix*\ inleft, *prefix*\ inright, *prefix*\ intop, *prefix*\ inbottom - Transitions
|
||||
that take `delay` seconds to move images that changed positions to their
|
||||
new locations, with newly shown images coming in from the appropriate
|
||||
side.
|
||||
|
||||
* *prefix*\ outleft, *prefix*\ outright, *prefix*\ outtop, *prefix*\ outbottom -
|
||||
Transitions that take `delay` seconds to move images that changed
|
||||
positions to their new locations, with newly hidden images leaving via
|
||||
the appropriate side.
|
||||
|
||||
`time_warp`, `in_time_warp`, `out_time_warp`
|
||||
Time warp functions that are given a time from 0.0 to 1.0 representing
|
||||
the fraction of the move complete, and return a value in the same
|
||||
range giving the fraction of a linear move that is complete.
|
||||
|
||||
This can be used to define functions that ease the images around,
|
||||
rather than moving them at a constant speed.
|
||||
|
||||
The three argument are used for images remaining on the screen,
|
||||
newly shown images, and newly hidden images, respectively.
|
||||
|
||||
`old`
|
||||
If true, the transitions to move the old displayables, rather than the new ones.
|
||||
|
||||
`layers`
|
||||
The layers the transition will apply to.
|
||||
|
||||
::
|
||||
|
||||
# This defines all of the pre-defined transitions beginning
|
||||
# with "move".
|
||||
init python:
|
||||
define.move_transitions("move", 0.5)
|
||||
|
||||
"""
|
||||
|
||||
moves = {
|
||||
"" : MoveTransition(
|
||||
delay,
|
||||
old=old,
|
||||
layers=layers,
|
||||
factory=MoveFactory(time_warp=time_warp, **kwargs)),
|
||||
time_warp=time_warp),
|
||||
|
||||
"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)),
|
||||
enter=_moveright,
|
||||
time_warp=time_warp,
|
||||
enter_time_warp=in_time_warp,
|
||||
),
|
||||
|
||||
"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)),
|
||||
|
||||
enter=_moveleft,
|
||||
time_warp=time_warp,
|
||||
enter_time_warp=in_time_warp,
|
||||
),
|
||||
|
||||
"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)),
|
||||
|
||||
enter=_movetop,
|
||||
time_warp=time_warp,
|
||||
enter_time_warp=in_time_warp,
|
||||
),
|
||||
|
||||
"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)),
|
||||
enter=_movebottom,
|
||||
time_warp=time_warp,
|
||||
enter_time_warp=in_time_warp,
|
||||
),
|
||||
|
||||
"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)),
|
||||
leave=_moveright,
|
||||
time_warp=time_warp,
|
||||
leave_time_warp=out_time_warp,
|
||||
),
|
||||
|
||||
"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)),
|
||||
leave=_moveleft,
|
||||
time_warp=time_warp,
|
||||
leave_time_warp=out_time_warp,
|
||||
),
|
||||
|
||||
"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)),
|
||||
leave=_movetop,
|
||||
time_warp=time_warp,
|
||||
leave_time_warp=out_time_warp,
|
||||
),
|
||||
|
||||
"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)),
|
||||
leave=_movebottom,
|
||||
time_warp=time_warp,
|
||||
leave_time_warp=out_time_warp,
|
||||
),
|
||||
}
|
||||
|
||||
for k, v in moves.iteritems():
|
||||
@@ -160,10 +250,10 @@ init -1110 python:
|
||||
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))
|
||||
# Zoom-based transitions. Legacy - nowadays, these are probably best done with ATL.
|
||||
zoomin = OldMoveTransition(0.5, enter_factory=ZoomInOut(0.01, 1.0))
|
||||
zoomout = OldMoveTransition(0.5, leave_factory=ZoomInOut(1.0, 0.01))
|
||||
zoominout = OldMoveTransition(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.
|
||||
|
||||
@@ -0,0 +1,329 @@
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init -1135 python:
|
||||
|
||||
class __GalleryAllPriorCondition(object):
|
||||
|
||||
def check(self, all_prior):
|
||||
return all_prior
|
||||
|
||||
|
||||
class __GalleryArbitraryCondition(object):
|
||||
def __init__(self, condition):
|
||||
self.condition = condition
|
||||
|
||||
def check(self, all_prior):
|
||||
return eval(self.condition)
|
||||
|
||||
|
||||
class __GalleryUnlockCondition(object):
|
||||
def __init__(self, images):
|
||||
self.images = images
|
||||
|
||||
def check(self, all_prior):
|
||||
for i in self.images:
|
||||
if not renpy.seen_image(i):
|
||||
return False
|
||||
|
||||
return True
|
||||
|
||||
|
||||
class __GalleryImage(object):
|
||||
def __init__(self, gallery, displayables):
|
||||
|
||||
# The gallery object we belong to.
|
||||
self.gallery = gallery
|
||||
|
||||
# A list of conditions for this image to be displayed.
|
||||
self.conditions = [ ]
|
||||
|
||||
# A list of displayables to show.
|
||||
self.displayables = displayables
|
||||
|
||||
# A list of transforms to apply to those displayables, or None
|
||||
# to not apply a transform.
|
||||
self.transforms = [ None ] * len(displayables)
|
||||
|
||||
|
||||
def check_unlock(self, all_prior):
|
||||
"""
|
||||
Returns True if the image is unlocked.
|
||||
"""
|
||||
|
||||
for i in self.conditions:
|
||||
if not i.check(all_prior):
|
||||
return False
|
||||
|
||||
return True
|
||||
|
||||
def show(self, locked, index, count):
|
||||
"""
|
||||
Shows this image when it's unlocked.
|
||||
"""
|
||||
|
||||
renpy.transition(self.gallery.transition)
|
||||
ui.saybehavior()
|
||||
|
||||
displayables = [ ]
|
||||
|
||||
for d, transform in zip(self.displayables, self.transforms):
|
||||
|
||||
if transform is not None:
|
||||
d = transform(d)
|
||||
else:
|
||||
d = config.default_transform(d)
|
||||
|
||||
displayables.append(d)
|
||||
|
||||
renpy.show_screen("_gallery", locked=locked, index=index + 1, count=count, displayables=displayables, gallery=self.gallery)
|
||||
ui.interact()
|
||||
|
||||
class __GalleryButton(object):
|
||||
def __init__(self, gallery):
|
||||
self.gallery = gallery
|
||||
self.images = [ ]
|
||||
self.conditions = [ ]
|
||||
|
||||
def check_unlock(self):
|
||||
for i in self.conditions:
|
||||
if not i.check(True):
|
||||
return False
|
||||
|
||||
for i in self.images:
|
||||
if i.check_unlock(False):
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
def show(self):
|
||||
|
||||
all_prior = True
|
||||
|
||||
for i, img in enumerate(self.images):
|
||||
locked = not img.check_unlock(all_prior)
|
||||
img.show(locked, i, len(self.images))
|
||||
|
||||
renpy.transition(self.gallery.transition)
|
||||
|
||||
class Gallery(object):
|
||||
"""
|
||||
:doc: gallery class
|
||||
|
||||
This class supports the creation of an image gallery by handling the
|
||||
locking of images, providing an action that can show one or more images,
|
||||
and a providing method that creates buttons that use that action.
|
||||
|
||||
.. attribute:: transition
|
||||
|
||||
The transition that is used when changing images.
|
||||
|
||||
.. attribute:: locked_button
|
||||
|
||||
The default displayable used by make_button for a locked button.
|
||||
|
||||
.. attribute:: hover_border
|
||||
|
||||
The default hover border used by make_button.
|
||||
|
||||
.. attribute:: idle_border
|
||||
|
||||
The default idle border used by make_button.
|
||||
"""
|
||||
|
||||
transition = None
|
||||
|
||||
hover_border = None
|
||||
idle_border = None
|
||||
|
||||
locked_button = None
|
||||
|
||||
def __init__(self):
|
||||
|
||||
# A map from button name (or image) to __GalleryButton object.
|
||||
self.buttons = { }
|
||||
|
||||
self.button_ = None
|
||||
self.image_ = None
|
||||
self.unlockable = None
|
||||
|
||||
def button(self, name):
|
||||
"""
|
||||
:doc: gallery method
|
||||
|
||||
Creates a new button, named `name`.
|
||||
|
||||
`name`
|
||||
The name of the button being created.
|
||||
"""
|
||||
|
||||
self.button_ = __GalleryButton(self)
|
||||
self.unlockable = self.button_
|
||||
self.buttons[name] = self.button_
|
||||
|
||||
def image(self, *displayables):
|
||||
"""
|
||||
:doc: gallery method
|
||||
|
||||
Adds a new image to the current button, where an image consists
|
||||
of one or more displayables.
|
||||
"""
|
||||
|
||||
self.image_ = __GalleryImage(self, displayables)
|
||||
self.button_.images.append(self.image_)
|
||||
self.unlockable = self.image_
|
||||
|
||||
display = image
|
||||
|
||||
def transform(self, *transforms):
|
||||
"""
|
||||
:doc: gallery method
|
||||
|
||||
Applies transforms to the last image registered. This should be
|
||||
called with the same number of transforms as the image has
|
||||
displayables. The transforms are applied to the corresponding
|
||||
displayables.
|
||||
|
||||
If a transform is None, the default transform is used.
|
||||
"""
|
||||
|
||||
self.image_.transforms = transforms
|
||||
|
||||
def unlock(self, *images):
|
||||
"""
|
||||
:doc: gallery method
|
||||
|
||||
A condition that takes one or more image names as argument, and
|
||||
is satisfied when all the named images have been seen by the
|
||||
player. The image names should be given as strings.
|
||||
"""
|
||||
|
||||
self.unlockable.conditions.append(__GalleryUnlockCondition(images))
|
||||
|
||||
def condition(self, expression):
|
||||
"""
|
||||
:doc: gallery method
|
||||
|
||||
A condition that is satisfied when an expression evaluates to true.
|
||||
|
||||
`expression`
|
||||
A string giving a python expression.
|
||||
"""
|
||||
|
||||
if not isinstance(expression, basestring):
|
||||
raise Exception("Gallery condition must be a string containing an expression.")
|
||||
|
||||
self.unlockable.conditions.append(__GalleryArbitraryCondition(expression))
|
||||
|
||||
def allprior(self):
|
||||
"""
|
||||
:doc: gallery method
|
||||
|
||||
A condition that is true if all prior images associated with the
|
||||
current button have been unlocked.
|
||||
"""
|
||||
|
||||
self.unlockable.conditions.append(__GalleryAllPriorCondition())
|
||||
|
||||
def unlock_image(self, *images):
|
||||
"""
|
||||
:doc: gallery method
|
||||
|
||||
A convenience method that is equivalent to calling image and unlock
|
||||
with the same parameters. This will cause an image to be displayed
|
||||
if it has been seen before.
|
||||
|
||||
The images should be specified as strings giving image names.
|
||||
"""
|
||||
|
||||
self.image(*images)
|
||||
self.unlock(*images)
|
||||
|
||||
def Action(self, name):
|
||||
"""
|
||||
:doc: gallery method
|
||||
|
||||
An action that displays the images associated with the given button
|
||||
name.
|
||||
"""
|
||||
|
||||
if name not in self.buttons:
|
||||
raise Exception("{0!r} is not a button defined in this gallery.".format(name))
|
||||
|
||||
b = self.buttons[name]
|
||||
|
||||
if b.check_unlock():
|
||||
return ui.invokesinnewcontext(b.show)
|
||||
else:
|
||||
return None
|
||||
|
||||
def make_button(self, name, unlocked, locked=None, hover_border=None, idle_border=None, **properties):
|
||||
"""
|
||||
:doc: gallery method
|
||||
|
||||
This creates a button that displays the images associated with the given
|
||||
button name.
|
||||
|
||||
`name`
|
||||
The name of the button that will be created.
|
||||
|
||||
`unlocked`
|
||||
A displayable that is displayed for this button when it is
|
||||
unlocked.
|
||||
|
||||
`locked`
|
||||
A displayable that is displayed for this button when it is
|
||||
locked. If None, the locked_button field of the gallery
|
||||
object is used instead.
|
||||
|
||||
`hover_border`
|
||||
A displayable that is used to overlay this button when when
|
||||
it is unlocked and has focus. If None, the hover_border
|
||||
field of the gallery object is used.
|
||||
|
||||
`idle_border`
|
||||
A displayable that is used to overlay this button when when
|
||||
it is unlocked but unfocused. If None, the idle_border
|
||||
field of the gallery object is used.
|
||||
|
||||
Additional keyword arguments become style properties of the
|
||||
created button object.
|
||||
"""
|
||||
|
||||
action = self.Action(name)
|
||||
|
||||
if locked is None:
|
||||
locked = self.locked_button
|
||||
|
||||
if hover_border is None:
|
||||
hover_border = self.hover_border
|
||||
|
||||
if idle_border is None:
|
||||
idle_border = self.idle_border
|
||||
|
||||
return Button(action=action, child=unlocked, insensitive_child=locked, hover_foreground=hover_border, idle_foreground=idle_border, **properties)
|
||||
|
||||
|
||||
init -1135:
|
||||
|
||||
# Displays a set of images in the gallery, or indicates that the images
|
||||
# are locked. This is given the following arguments:
|
||||
#
|
||||
# locked
|
||||
# True if the image is locked.
|
||||
# displayables
|
||||
# A list of transformed displayables that should be shown to the user.
|
||||
# index
|
||||
# A 1-based index of the image being shown.
|
||||
# count
|
||||
# The number of images attached to the current button.
|
||||
# gallery
|
||||
# The image gallery object.
|
||||
screen _gallery:
|
||||
if locked:
|
||||
add "#000"
|
||||
text "Image [index] of [count] locked." align (0.5, 0.5)
|
||||
else:
|
||||
for d in displayables:
|
||||
add d
|
||||
|
||||
@@ -1,39 +1,190 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This contains code to choose between OpenGL and Software rendering, when
|
||||
# a system supports both.
|
||||
|
||||
init -1024:
|
||||
screen _gl_test:
|
||||
|
||||
python hide:
|
||||
import os
|
||||
store.__dxwebsetup = os.path.join(config.renpy_base, "lib", "dxwebsetup.exe")
|
||||
|
||||
python:
|
||||
class _SetRenderer(Action):
|
||||
"""
|
||||
Sets the preferred renderer to one of "auto", "angle", "gl", or
|
||||
"sw".
|
||||
"""
|
||||
|
||||
def __init__(self, renderer):
|
||||
self.renderer = renderer
|
||||
|
||||
def __call__(self):
|
||||
_preferences.renderer = self.renderer
|
||||
renpy.restart_interaction()
|
||||
|
||||
def get_selected(self):
|
||||
return _preferences.renderer == self.renderer
|
||||
|
||||
# This is displayed to ask the user to choose the renderer he or she
|
||||
# wants to use. It takes no parameters, doesn't return anything, and
|
||||
# is expected to call _SetRenderer actions and quit when done.
|
||||
#
|
||||
# This screen can be customized by the creator, provided the actions
|
||||
# remain available.
|
||||
screen _choose_renderer:
|
||||
|
||||
frame:
|
||||
style_group ""
|
||||
|
||||
xalign .5
|
||||
yalign .33
|
||||
xpadding 20
|
||||
ypadding 20
|
||||
|
||||
xmaximum 400
|
||||
|
||||
has vbox
|
||||
|
||||
label _("Graphics Acceleration")
|
||||
|
||||
null height 10
|
||||
|
||||
textbutton _("Automatically Choose"):
|
||||
action _SetRenderer("auto")
|
||||
xfill True
|
||||
|
||||
if renpy.renpy.windows:
|
||||
textbutton _("Force Angle/DirectX Renderer"):
|
||||
action _SetRenderer("angle")
|
||||
xfill True
|
||||
|
||||
textbutton _("Force OpenGL Renderer"):
|
||||
action _SetRenderer("gl")
|
||||
xfill True
|
||||
|
||||
textbutton _("Force Software Renderer"):
|
||||
action _SetRenderer("sw")
|
||||
xfill True
|
||||
|
||||
null height 10
|
||||
|
||||
text _("Changes will take effect the next time this program is run.") substitute True
|
||||
|
||||
null height 10
|
||||
|
||||
textbutton _(u"Quit"):
|
||||
action Quit(confirm=False)
|
||||
xfill True
|
||||
|
||||
if not renpy.display.interface.safe_mode:
|
||||
textbutton _("Return"):
|
||||
action Return(0)
|
||||
xfill True
|
||||
|
||||
|
||||
# This is displayed when a display performance problem occurs.
|
||||
#
|
||||
# `problem` is the kind of problem that is occuring. It can be:
|
||||
# - "sw" if the software renderer was selected.
|
||||
# - "slow" if the performance test failed.
|
||||
# - "fixed" if we're operating w/o shaders.
|
||||
# - other things, added in the future.
|
||||
#
|
||||
# `url` is the url of a web page on renpy.org that will include
|
||||
# info on troubleshooting display problems.
|
||||
screen _performance_warning:
|
||||
|
||||
frame:
|
||||
style_group ""
|
||||
|
||||
xalign .5
|
||||
yalign .33
|
||||
|
||||
xpadding 20
|
||||
ypadding 20
|
||||
|
||||
xmaximum 400
|
||||
|
||||
has vbox
|
||||
|
||||
label _(u"Graphics Acceleration")
|
||||
|
||||
label _("Performance Warning")
|
||||
|
||||
null height 10
|
||||
|
||||
textbutton _(u"Automatically Choose"):
|
||||
size_group "gl"
|
||||
action SetField(persistent, "_gl_test", "auto")
|
||||
textbutton _(u"Prefer Software Renderer"):
|
||||
size_group "gl"
|
||||
action SetField(persistent, "_gl_test", "sw")
|
||||
textbutton _(u"Prefer OpenGL Renderer"):
|
||||
size_group "gl"
|
||||
action SetField(persistent, "_gl_test", "gl")
|
||||
if problem == "sw":
|
||||
text _("This computer is using software rendering.")
|
||||
elif problem == "fixed":
|
||||
text _("This computer is not using shaders.")
|
||||
elif problem == "slow":
|
||||
text _("This computer is displaying graphics slowly.")
|
||||
else:
|
||||
text _("This computer has a problem displaying graphics: [problem].") substitute True
|
||||
|
||||
null height 10
|
||||
|
||||
if directx_update:
|
||||
text _("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.")
|
||||
else:
|
||||
text _("Its graphics drivers may be out of date or not operating correctly. This can lead to slow or incorrect graphics display.")
|
||||
|
||||
if directx_update:
|
||||
null height 10
|
||||
|
||||
textbutton _("Update DirectX"):
|
||||
action directx_update
|
||||
xfill True
|
||||
|
||||
null height 10
|
||||
|
||||
textbutton _("Continue, Show this warning again"):
|
||||
action Return(True)
|
||||
xfill True
|
||||
|
||||
textbutton _("Continue, Don't show warning again"):
|
||||
action Return(False)
|
||||
xfill True
|
||||
|
||||
null height 10
|
||||
|
||||
textbutton _("Quit"):
|
||||
action Quit(confirm=False)
|
||||
xfill True
|
||||
|
||||
# Used while a directx update is ongoing.
|
||||
screen _directx_update:
|
||||
|
||||
frame:
|
||||
style_group ""
|
||||
|
||||
xalign .5
|
||||
yalign .33
|
||||
|
||||
xpadding 20
|
||||
ypadding 20
|
||||
|
||||
xmaximum 400
|
||||
|
||||
has vbox
|
||||
|
||||
label _("Updating DirectX.")
|
||||
|
||||
null height 10
|
||||
|
||||
textbutton _(u"Continue"):
|
||||
size_group "gl"
|
||||
action Return(True)
|
||||
text _("DirectX web setup has been started. It may start minimized in the taskbar. Please follow the prompts to install DirectX.")
|
||||
|
||||
null height 10
|
||||
|
||||
text _("{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.")
|
||||
|
||||
null height 10
|
||||
|
||||
text _("When setup finishes, please click below to restart this program.")
|
||||
|
||||
textbutton _("Restart") action Return(True)
|
||||
|
||||
|
||||
|
||||
init -1024 python:
|
||||
# The image that we fill the screen with in GL-test mode.
|
||||
@@ -56,24 +207,30 @@ init -1024 python:
|
||||
self.times = [ ]
|
||||
self.success = False
|
||||
|
||||
renpy.renpy.display.log.write("- Target is {0} frames in {1} seconds.".format(frames, self.target))
|
||||
|
||||
def render(self, width, height, st, at):
|
||||
rv = renpy.Render(width, height)
|
||||
|
||||
if self.success:
|
||||
return rv
|
||||
|
||||
self.times.append(st)
|
||||
|
||||
renpy.redraw(self, 0)
|
||||
|
||||
renpy.renpy.log.info("Frame drawn at %f seconds." % st)
|
||||
renpy.renpy.display.log.write("- Frame drawn at %f seconds." % st)
|
||||
|
||||
if len(self.times) >= self.frames:
|
||||
frames_timing = self.times[-1] - self.times[-self.frames]
|
||||
|
||||
renpy.renpy.log.info("It took %f seconds to render %d frames.", frames_timing, self.frames)
|
||||
renpy.renpy.display.log.write("- %f seconds to render %d frames.", frames_timing, self.frames)
|
||||
|
||||
if frames_timing <= self.target:
|
||||
self.success = True
|
||||
renpy.timeout(0)
|
||||
|
||||
rv = renpy.Render(width, height)
|
||||
return rv
|
||||
|
||||
return rv
|
||||
|
||||
def event(self, ev, x, y, st):
|
||||
|
||||
@@ -84,93 +241,94 @@ init -1024 python:
|
||||
return False
|
||||
|
||||
renpy.timeout(self.timeout - st)
|
||||
|
||||
|
||||
def __gl_prefer_renderers(renderers):
|
||||
"""
|
||||
Forces the current renderer to be renderer, one of gl or sw.
|
||||
"""
|
||||
|
||||
if renpy.display.prefer_renderers == renderers:
|
||||
return
|
||||
|
||||
renpy.display.prefer_renderers = renderers
|
||||
renpy.display_reset()
|
||||
|
||||
def __gl_prompt():
|
||||
"""
|
||||
Decides if we want to prompt the user to enable OpenGL mode.
|
||||
If so, shows a screen that allows the user to alter the
|
||||
OpenGL setting.
|
||||
"""
|
||||
|
||||
if not renpy.display.interface.safe_mode:
|
||||
return
|
||||
|
||||
__gl_prefer_renderers("sw")
|
||||
|
||||
renpy.call_screen("_gl_test")
|
||||
|
||||
renpy.display.interface.safe_mode = False
|
||||
|
||||
config.performance_test = True
|
||||
|
||||
def __gl_test():
|
||||
"""
|
||||
Makes the decision as to if we should use GL or SW mode.
|
||||
"""
|
||||
|
||||
import os
|
||||
if "RENPY_RENDERER" in os.environ:
|
||||
return
|
||||
|
||||
# Our decision survives a restart.
|
||||
# If we've entered safe mode, display the renderer choice screen.
|
||||
# This screen will cause us to quit.
|
||||
|
||||
if _restart:
|
||||
return
|
||||
|
||||
renpy.renpy.log.info("GL test mode: %s", persistent._gl_test)
|
||||
|
||||
# If GL is disabled, don't bother.
|
||||
if not config.gl_enable:
|
||||
return
|
||||
|
||||
__gl_prompt()
|
||||
|
||||
if renpy.display.interface.safe_mode:
|
||||
renpy.call_in_new_context("_choose_renderer")
|
||||
|
||||
if persistent._gl_test == "gl":
|
||||
__gl_prefer_renderers("gl,sw")
|
||||
if not config.performance_test:
|
||||
return
|
||||
|
||||
if persistent._gl_test == "sw":
|
||||
__gl_prefer_renderers("sw")
|
||||
_gl_performance_test()
|
||||
|
||||
def _gl_performance_test():
|
||||
|
||||
import os
|
||||
|
||||
if not _preferences.performance_test and "RENPY_PERFORMANCE_TEST" not in os.environ:
|
||||
return
|
||||
|
||||
__gl_prefer_renderers("gl,sw")
|
||||
# Don't bother on androuid - there's nothing the user can do.
|
||||
if renpy.renpy.android:
|
||||
return
|
||||
|
||||
renpy.renpy.display.log.write("Performance test:")
|
||||
|
||||
# This will cause the screen to start displaying.
|
||||
ui.pausebehavior(0)
|
||||
ui.interact(suppress_underlay=True, suppress_overlay=True)
|
||||
|
||||
# If GL is able to render FRAMES frames at FPS fps in less
|
||||
# than DELAY seconds, we consider it to be operational, and
|
||||
# continue in GL mode. Otherwise, we rever to software
|
||||
# rendering mode.
|
||||
FRAMES = 5
|
||||
FPS = 15
|
||||
DELAY = 1
|
||||
# The problem we have.
|
||||
problem = None
|
||||
|
||||
renderer_info = renpy.get_renderer_info()
|
||||
|
||||
# Software renderer check.
|
||||
if config.renderer != "sw" and renderer_info["renderer"] == "sw":
|
||||
problem = "sw"
|
||||
|
||||
renpy.transition(Dissolve(DELAY), always=True, force=True)
|
||||
ui.add(__GLTest(FRAMES, FPS, DELAY))
|
||||
result = ui.interact(suppress_overlay=True, suppress_underlay=True)
|
||||
# Speed check.
|
||||
if problem is None:
|
||||
|
||||
# The parameters of the performance test. If we do not hit FPS fps
|
||||
# over FRAMES frames before DELAY seconds are up, we fail.
|
||||
FRAMES = 5
|
||||
FPS = 15
|
||||
DELAY = 1.5
|
||||
|
||||
renpy.transition(Dissolve(DELAY), always=True, force=True)
|
||||
ui.add(__GLTest(FRAMES, FPS, DELAY))
|
||||
result = ui.interact(suppress_overlay=True, suppress_underlay=True)
|
||||
|
||||
if not result:
|
||||
problem = "slow"
|
||||
|
||||
if result:
|
||||
__gl_prefer_renderers("gl,sw")
|
||||
# Lack of shaders check.
|
||||
if problem is None:
|
||||
if not "RENPY_GL_ENVIRON" in os.environ:
|
||||
if renderer_info["renderer"] == "gl" and renderer_info["environ"] == "fixed":
|
||||
problem = "fixed"
|
||||
|
||||
if problem is None:
|
||||
return
|
||||
|
||||
if renpy.renpy.windows and os.path.exists(__dxwebsetup):
|
||||
directx_update = Jump("_directx_update")
|
||||
else:
|
||||
__gl_prefer_renderers("sw")
|
||||
directx_update = None
|
||||
|
||||
# Give the warning message to the user.
|
||||
renpy.show_screen("_performance_warning", problem=problem, directx_update=directx_update, _transient=True)
|
||||
result = ui.interact(suppress_overlay=True, suppress_underlay=True)
|
||||
|
||||
|
||||
# Init-time code:
|
||||
# Make a guess as to what modes we should be in.
|
||||
if persistent._gl_test is None:
|
||||
persistent._gl_test = "auto"
|
||||
|
||||
if persistent._gl_test == "sw":
|
||||
renpy.display.prefer_renderers = "sw"
|
||||
# Store the user's choice, and continue.
|
||||
_preferences.performance_test = result
|
||||
return
|
||||
|
||||
|
||||
label _gl_test:
|
||||
@@ -186,3 +344,34 @@ label _gl_test:
|
||||
|
||||
return
|
||||
|
||||
# We can assume we're on windows here. We're also always restart once we
|
||||
# make it here.
|
||||
label _directx_update:
|
||||
|
||||
if renpy.has_label("directx_update"):
|
||||
jump expression "directx_update"
|
||||
|
||||
label _directx_update_main:
|
||||
|
||||
python hide:
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
# Start dxsetup. We have to go through startfile to ensure that UAC
|
||||
# doesn't cause problems.
|
||||
os.startfile(__dxwebsetup)
|
||||
|
||||
renpy.show_screen("_directx_update")
|
||||
ui.interact(suppress_overlay=True, suppress_underlay=True)
|
||||
|
||||
# Restart the current program.
|
||||
subprocess.Popen(sys.argv)
|
||||
renpy.quit()
|
||||
|
||||
label _choose_renderer:
|
||||
scene expression "#000"
|
||||
|
||||
$ renpy.call_screen("_choose_renderer")
|
||||
return
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init -1105 python:
|
||||
@@ -375,6 +375,11 @@ init -1105 python hide:
|
||||
layout.QUIT = u"Are you sure you want to quit?"
|
||||
layout.MAIN_MENU = u"Are you sure you want to return to the main menu?\nThis will lose unsaved progress."
|
||||
|
||||
@layout
|
||||
def invoke_yesno_prompt(*args):
|
||||
_enter_menu()
|
||||
return layout.yesno_prompt(*args)
|
||||
|
||||
@layout
|
||||
def yesno_screen(message, yes=None, no=None):
|
||||
"""
|
||||
@@ -414,10 +419,16 @@ init -1105 python hide:
|
||||
|
||||
return
|
||||
|
||||
if renpy.invoke_in_new_context(layout.yesno_prompt, None, message):
|
||||
if renpy.invoke_in_new_context(layout.invoke_yesno_prompt, None, message):
|
||||
if yes is not None:
|
||||
yes()
|
||||
else:
|
||||
if no is not None:
|
||||
no()
|
||||
|
||||
|
||||
def __auto_save_extra_info():
|
||||
return save_name
|
||||
|
||||
config.auto_save_extra_info = __auto_save_extra_info
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This file consists of renpy functions that aren't expected to be
|
||||
@@ -196,15 +196,12 @@ init -1180 python:
|
||||
except:
|
||||
pass
|
||||
|
||||
|
||||
# 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("/")
|
||||
|
||||
@@ -215,11 +212,11 @@ init -1180 python:
|
||||
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
|
||||
fn = os.path.join(dest, config.screenshot_pattern % i)
|
||||
if not os.path.exists(fn):
|
||||
break
|
||||
i += 1
|
||||
@@ -241,6 +238,9 @@ init -1180 python:
|
||||
_predict_screens = [ ]
|
||||
|
||||
init -1180 python hide:
|
||||
|
||||
import os
|
||||
config.screenshot_pattern = os.environ.get("RENPY_SCREENSHOT_PATTERN", "screenshot%04d.png")
|
||||
|
||||
def dump_styles():
|
||||
if config.developer:
|
||||
@@ -305,6 +305,7 @@ init -1180 python hide:
|
||||
quit = renpy.quit_event,
|
||||
iconify = renpy.iconify,
|
||||
help = _help,
|
||||
choose_renderer = renpy.curried_call_in_new_context("_choose_renderer"),
|
||||
)
|
||||
|
||||
config.underlay = [ km ]
|
||||
@@ -334,7 +335,7 @@ init -1180 python hide:
|
||||
|
||||
config.overlay_functions.append(skip_indicator)
|
||||
|
||||
|
||||
# Hyperlink functions. Duplicated in _errorhandling.rpym.
|
||||
def hyperlink_styler(target):
|
||||
return style.hyperlink_text
|
||||
|
||||
@@ -348,8 +349,7 @@ init -1180 python hide:
|
||||
else:
|
||||
renpy.call_in_new_context(target)
|
||||
|
||||
config.hyperlink_styler = hyperlink_styler
|
||||
config.hyperlink_callback = hyperlink_function
|
||||
style.default.hyperlink_functions = (hyperlink_styler, hyperlink_function, None)
|
||||
|
||||
# Prediction of screens.
|
||||
def predict():
|
||||
@@ -477,47 +477,6 @@ init 1180 python:
|
||||
_preferences.using_afm_enable = False
|
||||
|
||||
|
||||
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
|
||||
@@ -602,27 +561,16 @@ init -1180 python:
|
||||
|
||||
ui.interact()
|
||||
|
||||
def _enter_menu():
|
||||
config.skipping = None
|
||||
|
||||
# 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()._menu = True
|
||||
renpy.context()._main_menu = False
|
||||
renpy.context_dynamic("main_menu")
|
||||
renpy.context_dynamic("_window_subtitle")
|
||||
@@ -639,11 +587,18 @@ label _enter_menu:
|
||||
for i in config.clear_layers:
|
||||
renpy.scene(layer=i)
|
||||
|
||||
return
|
||||
# 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
|
||||
|
||||
# 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
|
||||
$ _enter_menu()
|
||||
|
||||
$ renpy.transition(config.enter_transition)
|
||||
|
||||
@@ -839,7 +794,7 @@ label _invoke_main_menu:
|
||||
# initialize it.
|
||||
label _main_menu(_main_menu_screen="_main_menu_screen"):
|
||||
|
||||
call _enter_menu from _call__enter_menu_1
|
||||
$ _enter_menu()
|
||||
|
||||
python:
|
||||
renpy.dynamic("_load_prompt")
|
||||
@@ -908,7 +863,7 @@ init 1180 python hide:
|
||||
continue
|
||||
|
||||
# Reject if it already exists.
|
||||
if name in renpy.exports.images:
|
||||
if name in renpy.display.image.images:
|
||||
continue
|
||||
|
||||
renpy.image(name, fn)
|
||||
@@ -917,12 +872,17 @@ init 1180 python hide:
|
||||
create_automatic_images()
|
||||
|
||||
|
||||
# Load the developer screen, if necessary.
|
||||
# After init, make some changes based on if config.developer is True.
|
||||
init 1180 python hide:
|
||||
|
||||
if config.developer:
|
||||
if config.debug_sound is None:
|
||||
config.debug_sound = True
|
||||
|
||||
renpy.load_module("_developer")
|
||||
|
||||
|
||||
|
||||
# Entry point for the developer screen. The rest of it is loaded from
|
||||
# _developer.rpym
|
||||
label _developer:
|
||||
@@ -930,6 +890,25 @@ label _developer:
|
||||
if not config.developer:
|
||||
return
|
||||
|
||||
call _enter_menu from _call__enter_menu_4
|
||||
$ _enter_menu()
|
||||
|
||||
jump expression "_developer_screen"
|
||||
|
||||
|
||||
# Translations.
|
||||
init -1180 python:
|
||||
|
||||
def _language_activate():
|
||||
|
||||
if persistent._language:
|
||||
language = persistent._language
|
||||
else:
|
||||
language = "translations"
|
||||
|
||||
if renpy.loadable(language + ".rpt"):
|
||||
config.translator = renpy.Translator(language)
|
||||
else:
|
||||
config.translator = None
|
||||
|
||||
_language_activate()
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# Common stuff that's used by the various Ren'Py menus. This includes
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This file contains code that sets up the various mixers, based on how
|
||||
|
||||
@@ -0,0 +1,221 @@
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This file contains the code to implement Ren'Py's music room function,
|
||||
# which consists of the ability to set up a playlist (the aforementioned
|
||||
# "music room"), and then a series of actions that let the player
|
||||
# navigate through the music room.
|
||||
|
||||
init -1135 python:
|
||||
|
||||
class __MusicRoomPlay(Action):
|
||||
"""
|
||||
The action returned by MusicRoom.Play when called with a file.
|
||||
"""
|
||||
|
||||
def __init__(self, mr, filename):
|
||||
self.mr = mr
|
||||
self.filename = filename
|
||||
self.selected = self.get_selected()
|
||||
|
||||
def __call__(self):
|
||||
self.mr.play(self.filename, 0)
|
||||
|
||||
def get_sensitive(self):
|
||||
return self.mr.is_unlocked(self.filename)
|
||||
|
||||
def get_selected(self):
|
||||
return renpy.music.get_playing(self.mr.channel) == self.filename
|
||||
|
||||
def periodic(self, st):
|
||||
if self.selected != self.get_selected():
|
||||
renpy.restart_interaction()
|
||||
|
||||
return .1
|
||||
|
||||
class MusicRoom(object):
|
||||
"""
|
||||
:doc: music_room class
|
||||
|
||||
A music room that contains a series of songs that can be unlocked
|
||||
by the user, and actions that can play entries from the list in
|
||||
order.
|
||||
"""
|
||||
|
||||
def __init__(self, channel="music", fadeout=0.0, fadein=0.0):
|
||||
"""
|
||||
`channel`
|
||||
The channel that this music room will operate on.
|
||||
|
||||
`fadeout`
|
||||
The number of seconds it takes to fade out the old
|
||||
music when changing tracks.
|
||||
|
||||
`fadein`
|
||||
The number of seconds it takes to fade in the new
|
||||
music when changing tracks.
|
||||
"""
|
||||
|
||||
self.channel = channel
|
||||
self.fadeout = fadeout
|
||||
self.fadein = fadein
|
||||
|
||||
# The list of strings giving the titles of songs that make up the
|
||||
# playlist.
|
||||
self.playlist = [ ]
|
||||
|
||||
# A set of filenames, so we can quickly check if a valid filename
|
||||
# has been provided.
|
||||
self.filenames = set()
|
||||
|
||||
# The set of songs that are always unlocked.
|
||||
self.always_unlocked = set()
|
||||
|
||||
|
||||
def add(self, filename, always_unlocked=False):
|
||||
"""
|
||||
:doc: music_room method
|
||||
|
||||
Adds the music file `filename` to this music room. The music room
|
||||
will play unlocked files in the order that they are added to the
|
||||
room.
|
||||
|
||||
`always_unlocked`
|
||||
If true, the music file will be always unlocked. This allows
|
||||
the file to show up in the music room before it has been
|
||||
played in the game.
|
||||
"""
|
||||
|
||||
self.playlist.append(filename)
|
||||
self.filenames.add(filename)
|
||||
|
||||
if always_unlocked:
|
||||
self.always_unlocked.add(filename)
|
||||
|
||||
def is_unlocked(self, filename):
|
||||
"""
|
||||
:doc: music_room method
|
||||
|
||||
Returns true if the filename has been unlocked (or is always
|
||||
unlocked), and false if it is still locked.
|
||||
"""
|
||||
|
||||
if filename in self.always_unlocked:
|
||||
return True
|
||||
|
||||
return renpy.seen_audio(filename)
|
||||
|
||||
def unlocked_playlist(self):
|
||||
"""
|
||||
Returns a list of filenames in the playlist that have been
|
||||
unlocked.
|
||||
"""
|
||||
|
||||
return [ i for i in self.playlist if self.is_unlocked(i) ]
|
||||
|
||||
def play(self, filename=None, offset=0):
|
||||
"""
|
||||
Starts the music room playing. The file we start playing with is
|
||||
selected in two steps.
|
||||
|
||||
If `filename` is an unlocked file, we start by playing it.
|
||||
Otherwise, we start by playing the currently playing file, and if
|
||||
that doesn't exist or isn't unlocked, we start with the first file.
|
||||
|
||||
We then apply `offset`. If `offset` is positive, we advance that many
|
||||
files, otherwise we go back that many files.
|
||||
|
||||
The selected file is then played.
|
||||
|
||||
"""
|
||||
|
||||
playlist = self.unlocked_playlist()
|
||||
|
||||
if not playlist:
|
||||
return
|
||||
|
||||
if filename is None:
|
||||
filename = renpy.music.get_playing(channel=self.channel)
|
||||
|
||||
try:
|
||||
idx = playlist.index(filename)
|
||||
except ValueError:
|
||||
idx = 0
|
||||
|
||||
idx = (idx + offset) % len(playlist)
|
||||
|
||||
playlist = playlist[idx:] + playlist[:idx]
|
||||
|
||||
renpy.music.play(playlist, channel=self.channel, fadeout=self.fadeout, fadein=self.fadein)
|
||||
|
||||
def stop(self):
|
||||
"""
|
||||
Stops the music from playing.
|
||||
"""
|
||||
|
||||
renpy.music.stop(channel=self.channel, fadeout=self.fadeout)
|
||||
|
||||
def next(self):
|
||||
"""
|
||||
Plays the next file in the playlist.
|
||||
"""
|
||||
|
||||
return self.play(None, 1)
|
||||
|
||||
def previous(self):
|
||||
"""
|
||||
Plays the previous file in the playlist.
|
||||
"""
|
||||
|
||||
return self.play(None, -1)
|
||||
|
||||
def Play(self, filename=None):
|
||||
"""
|
||||
:doc: music_room method
|
||||
|
||||
Causes the music room to start playing. If `filename` is given, that
|
||||
file begins playing. Otherwise, the currently playing file starts
|
||||
over (if it's unlocked), or the first file starts playing.
|
||||
|
||||
If `filename` is given, buttons with this action will be insensitive
|
||||
while `filename` is locked, and will be selected when `filename`
|
||||
is playing.
|
||||
"""
|
||||
|
||||
if filename is None:
|
||||
return self.play
|
||||
|
||||
if filename not in self.filenames:
|
||||
raise Exception("{0!r} is not a filename registered with this music room.".format(filename))
|
||||
|
||||
return __MusicRoomPlay(self, filename)
|
||||
|
||||
def Stop(self):
|
||||
"""
|
||||
:doc: music_room method
|
||||
|
||||
Stops the music.
|
||||
"""
|
||||
|
||||
return self.stop
|
||||
|
||||
|
||||
def Next(self):
|
||||
"""
|
||||
:doc: music_room method
|
||||
|
||||
An action that causes the music room to play the next unlocked file
|
||||
in the playlist.
|
||||
"""
|
||||
|
||||
return self.next
|
||||
|
||||
def Previous(self):
|
||||
"""
|
||||
:doc: music_room method
|
||||
|
||||
An action that causes the music room to play the previous unlocked
|
||||
file in the playlist.
|
||||
"""
|
||||
|
||||
return self.previous
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This is an implementation of NVL-mode, which can be used to show
|
||||
@@ -119,6 +119,7 @@ init -1100 python:
|
||||
"""
|
||||
|
||||
widget_properties, dialogue = __nvl_screen_dialogue()
|
||||
|
||||
renpy.show_screen(screen_name, _transient=True, _widget_properties=widget_properties, dialogue=dialogue, **scope)
|
||||
renpy.shown_window()
|
||||
|
||||
@@ -126,7 +127,7 @@ init -1100 python:
|
||||
|
||||
def nvl_show_core(who=None, what=None):
|
||||
|
||||
# Screen version.
|
||||
# Screen version.
|
||||
if renpy.has_screen("nvl"):
|
||||
return __nvl_show_screen("nvl", items=[ ])
|
||||
|
||||
@@ -214,6 +215,7 @@ init -1100 python:
|
||||
**properties)
|
||||
|
||||
def do_add(self, who, what):
|
||||
|
||||
if store.nvl_list is None:
|
||||
store.nvl_list = [ ]
|
||||
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# Screen system support.
|
||||
|
||||
init -1140 python:
|
||||
@@ -119,6 +122,7 @@ init -1140 python:
|
||||
def __call__(self):
|
||||
_screenshot()
|
||||
|
||||
|
||||
def HideInterface():
|
||||
"""
|
||||
:doc other_action
|
||||
@@ -128,7 +132,25 @@ init -1140 python:
|
||||
|
||||
return ui.callsinnewcontext("_hide_windows")
|
||||
|
||||
|
||||
|
||||
class OpenURL(Action):
|
||||
"""
|
||||
:doc: other_action
|
||||
|
||||
Causes `url` to be opened in a web browser.
|
||||
"""
|
||||
|
||||
def __init__(self, url):
|
||||
self.url = url
|
||||
|
||||
def __call__(self):
|
||||
try:
|
||||
import webbrowser
|
||||
webbrowser.open_new(self.url)
|
||||
except:
|
||||
pass
|
||||
|
||||
|
||||
class With(Action):
|
||||
"""
|
||||
:doc: other_action
|
||||
@@ -159,8 +181,6 @@ init -1140 python:
|
||||
def __call__(self):
|
||||
renpy.notify(self.message)
|
||||
|
||||
|
||||
|
||||
class InvertSelected(Action):
|
||||
"""
|
||||
:doc: other_action
|
||||
@@ -186,6 +206,7 @@ init -1140 python:
|
||||
|
||||
def predict(self):
|
||||
self.action.predict()
|
||||
|
||||
|
||||
def If(expression, true=None, false=None):
|
||||
"""
|
||||
@@ -201,6 +222,55 @@ init -1140 python:
|
||||
return true
|
||||
else:
|
||||
return false
|
||||
|
||||
|
||||
class SelectedIf(Action):
|
||||
"""
|
||||
:doc: other_action
|
||||
|
||||
This allows an expression to control if a button should be marked
|
||||
as selected. It should be used as part of a list with one or more
|
||||
actions. For example::
|
||||
|
||||
# The button is selected if mars_flag is True
|
||||
textbutton "Marsopolis":
|
||||
action [ Jump("mars"), SelectedIf(mars_flag) ]
|
||||
"""
|
||||
|
||||
def __init__(self, expression):
|
||||
self.expression = expression
|
||||
|
||||
def __call__(self):
|
||||
return None
|
||||
|
||||
def get_selected(self):
|
||||
return self.expression
|
||||
|
||||
|
||||
def Rollback():
|
||||
"""
|
||||
:doc: other_action
|
||||
|
||||
This action causes a rollback to occur, when a rollback is possible.
|
||||
Otherwise, nothing happens.
|
||||
"""
|
||||
|
||||
return renpy.rollback
|
||||
|
||||
class RollForward(Action):
|
||||
"""
|
||||
:doc: other_action
|
||||
|
||||
This action causes a rollforward to occur, if a roll forward is
|
||||
possible. Otherwise, it is insensitive.
|
||||
"""
|
||||
|
||||
def __call__(self):
|
||||
return renpy.roll_forward_info()
|
||||
|
||||
def get_sensitive(self):
|
||||
return renpy.roll_forward_info() is not None
|
||||
|
||||
|
||||
##########################################################################
|
||||
# Menu-related actions.
|
||||
@@ -459,6 +529,19 @@ init -1140 python:
|
||||
def get_selected(self):
|
||||
return self.dict[self.key] == self.value
|
||||
|
||||
def SetScreenVariable(name, value):
|
||||
"""
|
||||
:doc: data_action
|
||||
|
||||
Causes the variable `name` associated with the current screen to
|
||||
be set to `value`.
|
||||
"""
|
||||
|
||||
cs = renpy.current_screen()
|
||||
if cs is not None:
|
||||
return SetDict(cs.scope, name, value)
|
||||
else:
|
||||
return None
|
||||
|
||||
class ToggleField(Action):
|
||||
"""
|
||||
@@ -564,6 +647,24 @@ init -1140 python:
|
||||
|
||||
return rv
|
||||
|
||||
def ToggleScreenVariable(name, true_value=None, false_value=None):
|
||||
"""
|
||||
:doc: data_action
|
||||
|
||||
Toggles the value of the variable `name` in the current screen.
|
||||
|
||||
`true_value`
|
||||
If not None, then this is the true value we use.
|
||||
`false_value`
|
||||
If not None, then this is the false value we use.
|
||||
"""
|
||||
|
||||
cs = renpy.current_screen()
|
||||
|
||||
if cs is not None:
|
||||
return ToggleDict(cs.scope, name, true_value=true_value, false_value=None)
|
||||
else:
|
||||
return None
|
||||
|
||||
##########################################################################
|
||||
# Audio actions.
|
||||
@@ -648,8 +749,31 @@ init -1140 python:
|
||||
renpy.music.stop(channel=self.channel, **self.kwargs)
|
||||
renpy.restart_interaction()
|
||||
|
||||
class SetMixer(Action):
|
||||
"""
|
||||
:doc: audio_action
|
||||
|
||||
Sets the volume of `mixer` to `value`.
|
||||
|
||||
`mixer`
|
||||
The mixer to set the volume of. A string, usually one of
|
||||
"music", "sfx", or "voice".
|
||||
`value`
|
||||
The value to set the volume to. A number between 0.0 and 1.0,
|
||||
inclusive.
|
||||
"""
|
||||
|
||||
def __init__(self, mixer, volume):
|
||||
self.mixer = mixer
|
||||
self.volume = volume
|
||||
|
||||
def __call__(self):
|
||||
_preferences.set_volume(self.mixer, self.volume)
|
||||
renpy.restart_interaction()
|
||||
|
||||
def get_selected(self):
|
||||
return _preferences.get_volume(self.mixer) == self.volume
|
||||
|
||||
##########################################################################
|
||||
# BarValues
|
||||
|
||||
@@ -764,15 +888,31 @@ init -1140 python:
|
||||
This is used internally, for some preferences.
|
||||
`style`
|
||||
The styles of the bar created.
|
||||
`offset`
|
||||
An offset to add to the value.
|
||||
`step`
|
||||
The amount to change the bar by. If None, defaults to 1/10th of
|
||||
the bar.
|
||||
"""
|
||||
|
||||
def __init__(self, object, field, range, max_is_zero=False, style="bar"):
|
||||
offset = 0
|
||||
|
||||
def __init__(self, object, field, range, max_is_zero=False, style="bar", offset=0, step=None):
|
||||
self.object = object
|
||||
self.field = field
|
||||
self.range = range
|
||||
self.max_is_zero = max_is_zero
|
||||
self.style = style
|
||||
self.offset = offset
|
||||
|
||||
if step is None:
|
||||
if isinstance(range, float):
|
||||
step = range / 10.0
|
||||
else:
|
||||
step = max(range / 10, 1)
|
||||
|
||||
self.step = step
|
||||
|
||||
def changed(self, value):
|
||||
|
||||
if self.max_is_zero:
|
||||
@@ -781,12 +921,16 @@ init -1140 python:
|
||||
else:
|
||||
value = value + 1
|
||||
|
||||
value += self.offset
|
||||
|
||||
setattr(self.object, self.field, value)
|
||||
|
||||
def get_adjustment(self):
|
||||
|
||||
value = getattr(self.object, self.field)
|
||||
|
||||
value -= self.offset
|
||||
|
||||
if self.max_is_zero:
|
||||
if value == 0:
|
||||
value = self.range
|
||||
@@ -796,7 +940,8 @@ init -1140 python:
|
||||
return ui.adjustment(
|
||||
range=self.range,
|
||||
value=value,
|
||||
changed=self.changed)
|
||||
changed=self.changed,
|
||||
step=self.step)
|
||||
|
||||
def get_style(self):
|
||||
return self.style, "v" + self.style
|
||||
@@ -893,9 +1038,63 @@ init -1140 python:
|
||||
return str((page - 1) * config.linear_saves_page_size + name)
|
||||
except ValueError:
|
||||
pass
|
||||
|
||||
|
||||
return str(page) + "-" + str(name)
|
||||
|
||||
def __unused_slot_name(page):
|
||||
"""
|
||||
Returns an unused slot name.
|
||||
"""
|
||||
|
||||
import time
|
||||
|
||||
rv = int(time.time())
|
||||
|
||||
while True:
|
||||
if not renpy.can_load(__filename(str(rv), page)):
|
||||
return str(rv)
|
||||
|
||||
rv += 1
|
||||
|
||||
def FileCurrentPage():
|
||||
"""
|
||||
:doc: file_action_function
|
||||
|
||||
Returns the current file page as a string.
|
||||
"""
|
||||
|
||||
return str(persistent._file_page)
|
||||
|
||||
def FileUsedSlots(page=None, highest_first=True):
|
||||
"""
|
||||
:doc: file_action_function
|
||||
|
||||
Returns a list of used numeric file slots on the page.
|
||||
|
||||
`page`
|
||||
The name of the page that will be scanned. If None, the current page
|
||||
is used.
|
||||
|
||||
`highest_first`
|
||||
If true, the highest-numbered file slot is listed first.
|
||||
Otherwise, the lowest-numbered slot is listed first.
|
||||
"""
|
||||
|
||||
regexp = __filename(r'\d+', page)
|
||||
|
||||
rv = [ ]
|
||||
|
||||
for fn in renpy.list_saved_games(regexp=regexp, fast=True):
|
||||
_page, _, slot = fn.partition('-')
|
||||
|
||||
rv.append(int(slot))
|
||||
|
||||
rv.sort()
|
||||
if highest_first:
|
||||
rv.reverse()
|
||||
|
||||
return rv
|
||||
|
||||
def FileLoadable(name, page=None):
|
||||
"""
|
||||
:doc: file_action_function
|
||||
@@ -904,10 +1103,7 @@ init -1140 python:
|
||||
if the file is loadable, and false otherwise.
|
||||
"""
|
||||
|
||||
if renpy.scan_saved_game(__filename(name, page)):
|
||||
return True
|
||||
else:
|
||||
return False
|
||||
return renpy.can_load(__filename(name, page))
|
||||
|
||||
def FileScreenshot(name, empty=None, page=None):
|
||||
"""
|
||||
@@ -982,23 +1178,37 @@ init -1140 python:
|
||||
The button with this slot is selected if it's marked as the
|
||||
newest save file.
|
||||
|
||||
`name`
|
||||
The name of the slot to save to. If None, an unused slot
|
||||
(a large number based on the current time) will be
|
||||
will be used.
|
||||
|
||||
`confirm`
|
||||
If true, then we will prompt before overwriting a file.
|
||||
|
||||
`newest`
|
||||
If true, then this file will be marked as the newest save
|
||||
file when it's saved. (Set this to false for a quicksave,
|
||||
for example.)
|
||||
file when it's saved.
|
||||
|
||||
`page`
|
||||
The name of the page that it will be saved to.
|
||||
The name of the page that the slot is on. If None, the current
|
||||
page is used.
|
||||
|
||||
`cycle`
|
||||
If true, then saves on the supplied page will be cycled before
|
||||
being shown to the user.
|
||||
"""
|
||||
|
||||
def __init__(self, name, confirm=True, newest=True, page=None):
|
||||
def __init__(self, name, confirm=True, newest=True, page=None, cycle=False):
|
||||
if name is None:
|
||||
name = __unused_slot_name(page)
|
||||
|
||||
self.name = name
|
||||
self.confirm = confirm
|
||||
self.page = page
|
||||
self.newest = newest
|
||||
self.page = page
|
||||
self.cycle = cycle
|
||||
|
||||
def __call__(self):
|
||||
|
||||
@@ -1007,6 +1217,9 @@ init -1140 python:
|
||||
|
||||
fn = __filename(self.name, self.page)
|
||||
|
||||
if self.cycle:
|
||||
renpy.renpy.loadsave.cycle_saves(self.page + "-", 10)
|
||||
|
||||
if renpy.scan_saved_game(fn):
|
||||
if self.confirm:
|
||||
layout.yesno_screen(layout.OVERWRITE_SAVE, FileSave(self.name, False, self.newest, self.page))
|
||||
@@ -1016,6 +1229,9 @@ init -1140 python:
|
||||
|
||||
if self.newest:
|
||||
persistent._file_newest = fn
|
||||
|
||||
if self.page is not None:
|
||||
persistent._file_page = self.page
|
||||
|
||||
renpy.restart_interaction()
|
||||
|
||||
@@ -1039,14 +1255,30 @@ init -1140 python:
|
||||
|
||||
Loads the file.
|
||||
|
||||
`name`
|
||||
The name of the slot to load from. If None, an unused slot
|
||||
the file will not be loadable.
|
||||
|
||||
`confirm`
|
||||
If true, prompt if loading the file will end the game.
|
||||
|
||||
`page`
|
||||
The page that the file will be loaded from. If None, the
|
||||
current page is used.
|
||||
|
||||
`newest`
|
||||
If true, the button is selected if this is the newest file.
|
||||
"""
|
||||
|
||||
def __init__(self, name, confirm=True, page=None):
|
||||
def __init__(self, name, confirm=True, page=None, newest=True):
|
||||
|
||||
if name is None:
|
||||
name = __unused_slot_name(page)
|
||||
|
||||
self.name = name
|
||||
self.confirm = confirm
|
||||
self.page = page
|
||||
self.newest = newest
|
||||
|
||||
def __call__(self):
|
||||
|
||||
@@ -1063,10 +1295,10 @@ init -1140 python:
|
||||
renpy.load(fn)
|
||||
|
||||
def get_sensitive(self):
|
||||
return renpy.scan_saved_game(__filename(self.name, self.page))
|
||||
return renpy.can_load(__filename(self.name, self.page))
|
||||
|
||||
def get_selected(self):
|
||||
if not self.confirm:
|
||||
if not self.confirm or not self.newest:
|
||||
return False
|
||||
|
||||
return persistent._file_newest == __filename(self.name, self.page)
|
||||
@@ -1100,7 +1332,7 @@ init -1140 python:
|
||||
renpy.unlink_save(fn)
|
||||
|
||||
def get_sensitive(self):
|
||||
return renpy.scan_saved_game(__filename(self.name, self.page))
|
||||
return renpy.can_load(__filename(self.name, self.page))
|
||||
|
||||
def get_selected(self):
|
||||
return persistent._file_newest == __filename(self.name, self.page)
|
||||
@@ -1112,6 +1344,15 @@ init -1140 python:
|
||||
|
||||
"Does the right thing" with the file. This means loading it if the
|
||||
load screen is showing, and saving to it otherwise.
|
||||
|
||||
`name`
|
||||
The name of the slot to save to or load from. If None, an unused slot
|
||||
(a large number based on the current time) will be
|
||||
will be used.
|
||||
|
||||
`page`
|
||||
The page that the file will be saved to or loaded from. If None, the
|
||||
current page is used.
|
||||
"""
|
||||
|
||||
if renpy.current_screen().screen_name[0] == "load":
|
||||
@@ -1137,15 +1378,7 @@ init -1140 python:
|
||||
|
||||
persistent._file_page = self.page
|
||||
renpy.restart_interaction()
|
||||
|
||||
def get_sensitive(self):
|
||||
if self.page == "auto" and not config.has_autosave:
|
||||
return False
|
||||
elif self.page == "quick" and not config.has_quicksave:
|
||||
return False
|
||||
else:
|
||||
return True
|
||||
|
||||
|
||||
def get_selected(self):
|
||||
return self.page == persistent._file_page
|
||||
|
||||
@@ -1315,10 +1548,82 @@ init -1140 python:
|
||||
def __call__(self):
|
||||
renpy.take_screenshot()
|
||||
|
||||
|
||||
def QuickSave(message="Quick save complete.", newest=False):
|
||||
"""
|
||||
:doc: file_action
|
||||
|
||||
Performs a quick save.
|
||||
|
||||
`message`
|
||||
A message to display to the user when the quick save finishes.
|
||||
|
||||
`newest`
|
||||
Set to true to mark the quicksave as the newest save.
|
||||
"""
|
||||
|
||||
return [
|
||||
FileTakeScreenshot(),
|
||||
FileSave(1, page="quick", confirm=False, cycle=True, newest=newest),
|
||||
Notify("Quick save complete.") ]
|
||||
|
||||
def QuickLoad():
|
||||
"""
|
||||
:doc: file_action
|
||||
|
||||
Performs a quick load.
|
||||
"""
|
||||
|
||||
return FileLoad(1, page="quick", confirm=True, newest=False)
|
||||
|
||||
|
||||
##########################################################################
|
||||
# Side Images
|
||||
|
||||
config.side_image_tag = None
|
||||
config.side_image_only_not_showing = False
|
||||
|
||||
def SideImage(prefix_tag="side"):
|
||||
"""
|
||||
:doc: side_image_function
|
||||
|
||||
Returns the side image associated with the currently speaking character,
|
||||
or a Null displayable if no such side image exists.
|
||||
"""
|
||||
|
||||
name = renpy.get_side_image(prefix_tag, image_tag=config.side_image_tag, not_showing=config.side_image_only_not_showing)
|
||||
if name is None:
|
||||
return Null()
|
||||
else:
|
||||
return ImageReference(name)
|
||||
|
||||
|
||||
##########################################################################
|
||||
# Preferences Constructor
|
||||
|
||||
class __DisplayAction(Action):
|
||||
def __init__(self, factor):
|
||||
self.width = int(factor * config.screen_width)
|
||||
self.height = int(factor * config.screen_height)
|
||||
|
||||
def __call__(self):
|
||||
renpy.set_physical_size((self.width, self.height))
|
||||
renpy.restart_interaction()
|
||||
|
||||
def get_sensitive(self):
|
||||
if self.width == config.screen_width and self.height == config.screen_height:
|
||||
return True
|
||||
|
||||
return renpy.get_renderer_info()["resizable"]
|
||||
|
||||
def get_selected(self):
|
||||
if _preferences.fullscreen:
|
||||
return False
|
||||
|
||||
return (self.width, self.height) == renpy.get_physical_size()
|
||||
|
||||
|
||||
config.always_has_joystick = False
|
||||
|
||||
def Preference(name, value=None):
|
||||
"""
|
||||
:doc: preference_action
|
||||
@@ -1332,21 +1637,22 @@ init -1140 python:
|
||||
Actions that can be used with buttons and hotspots are:
|
||||
|
||||
* Preference("display", "fullscreen") - displays in fullscreen mode.
|
||||
* Preference("display", "window") - displays in windowed mode.
|
||||
* Preference("display", "window") - displays in windowed mode at 1x normal size.
|
||||
* Preference("display", 2.0) - displays in windowed mode at 2.0x normal size.
|
||||
* Preference("display", "toggle") - toggle display mode.
|
||||
|
||||
* Preference("transitions", "all") - show all transitions.
|
||||
* Preference("transitions", "none") - do not show transitions.
|
||||
* Preference("transitions", "toggle") - toggle transitions.
|
||||
|
||||
* Preference("text speed", 0) - make test appear instantaneously.
|
||||
* Preference("text speed", 0) - make text appear instantaneously.
|
||||
* Preference("text speed", 142) - set text speed to 142 characters per second.
|
||||
|
||||
* Preference("joystick") - Show the joystick preferences.
|
||||
|
||||
* Preference("skip", "seen") - Only skip seen messages.
|
||||
* Preference("skip", "all") - Skip unseen messages.
|
||||
* Preference("skip", "toggle") - Toggle skipping.
|
||||
* Preference("skip", "toggle") - Toggle between skip seen and skip all.
|
||||
|
||||
* Preference("begin skipping") - Starts skipping.
|
||||
|
||||
@@ -1371,7 +1677,11 @@ init -1140 python:
|
||||
|
||||
* Preference("voice mute", "enable") - Mute the voice mixer.
|
||||
* Preference("voice mute", "disable") - Un-mute the voice mixer.
|
||||
* Preference("voice mute", "toggle") - Toggle voice mute.
|
||||
* Preference("voice mute", "toggle") - Toggle voice mute.
|
||||
|
||||
* Preference("music volume", 0.5) - Set the music volume.
|
||||
* Preference("sound volume", 0.5) - Set the sound volume.
|
||||
* Preference("volice volume", 0.5) - Set the voice volume.
|
||||
|
||||
Values that can be used with bars are:
|
||||
|
||||
@@ -1391,9 +1701,11 @@ init -1140 python:
|
||||
if value == "fullscreen":
|
||||
return SetField(_preferences, "fullscreen", True)
|
||||
elif value == "window":
|
||||
return SetField(_preferences, "fullscreen", False)
|
||||
return __DisplayAction(1.0)
|
||||
elif value == "toggle":
|
||||
return ToggleField(_preferences, "fullscreen")
|
||||
elif isinstance(value, (int, float)):
|
||||
return __DisplayAction(value)
|
||||
|
||||
elif name == "transitions":
|
||||
|
||||
@@ -1415,7 +1727,10 @@ init -1140 python:
|
||||
|
||||
elif name == "joystick" or name == "joystick...":
|
||||
|
||||
return ShowMenu("joystick_preferences")
|
||||
if renpy.display.joystick.enabled or config.always_has_joystick:
|
||||
return ShowMenu("joystick_preferences")
|
||||
else:
|
||||
return None
|
||||
|
||||
elif name == "skip":
|
||||
|
||||
@@ -1451,7 +1766,12 @@ init -1140 python:
|
||||
elif name == "auto-forward time":
|
||||
|
||||
if value is None:
|
||||
return FieldValue(_preferences, "afm_time", range=40, max_is_zero=True, style="slider")
|
||||
|
||||
if config.default_afm_enable is None:
|
||||
return FieldValue(_preferences, "afm_time", range=30.0, max_is_zero=True, style="slider")
|
||||
else:
|
||||
return FieldValue(_preferences, "afm_time", range=29.9, style="slider", offset=.1)
|
||||
|
||||
elif isinstance(value, int):
|
||||
return SetField(_preferences, "afm_time", value)
|
||||
|
||||
@@ -1468,16 +1788,22 @@ init -1140 python:
|
||||
|
||||
if value is None:
|
||||
return MixerValue('music')
|
||||
else:
|
||||
return SetMixer('music', value)
|
||||
|
||||
elif name == "sound volume":
|
||||
|
||||
if value is None:
|
||||
return MixerValue('sfx')
|
||||
else:
|
||||
return SetMixer('sfx', value)
|
||||
|
||||
elif name == "voice volume":
|
||||
|
||||
if value is None:
|
||||
return MixerValue('voice')
|
||||
else:
|
||||
return SetMixer('voice', value)
|
||||
|
||||
elif name == "music mute":
|
||||
|
||||
@@ -1513,7 +1839,84 @@ init -1140 python:
|
||||
# What we do on a quit, by default.
|
||||
config.quit_action = ui.gamemenus("_confirm_quit")
|
||||
|
||||
#########################################################################
|
||||
|
||||
class __TooltipAction(object):
|
||||
|
||||
def __init__(self, tooltip, value):
|
||||
self.tooltip = tooltip
|
||||
self.value = value
|
||||
|
||||
def __call__(self):
|
||||
if self.tooltip.value != self.value:
|
||||
self.tooltip.value = self.value
|
||||
renpy.restart_interaction()
|
||||
|
||||
def unhovered(self):
|
||||
if self.tooltip.value != self.tooltip.default:
|
||||
self.tooltip.value = self.tooltip.default
|
||||
renpy.restart_interaction()
|
||||
|
||||
class Tooltip(object):
|
||||
"""
|
||||
:doc: tooltips class
|
||||
|
||||
A tooltip object can be used to define a portion of a screen that is
|
||||
updated when the mouse hovers an area.
|
||||
|
||||
A tooltip object has a ``value`` field, which is set to the `default`
|
||||
value passed to the constructor when the tooltip is created. When
|
||||
a button using an action creadted by the tooltip is hovered, the
|
||||
value field changes to the value associated with the action.
|
||||
"""
|
||||
|
||||
def __init__(self, default):
|
||||
self.value = default
|
||||
self.default = default
|
||||
|
||||
def Action(self, value):
|
||||
"""
|
||||
:doc: tooltips method
|
||||
:name: Action
|
||||
|
||||
Returns an action that is generally used as the hovered property
|
||||
of a button. When the button is hovered, the value field of this
|
||||
tooltip is set to `value`. When the buttton loses focus, the
|
||||
value field of this tooltip reverts to the default.
|
||||
"""
|
||||
|
||||
return __TooltipAction(self, value)
|
||||
|
||||
action = Action
|
||||
|
||||
#########################################################################
|
||||
|
||||
class Language(Action):
|
||||
"""
|
||||
:doc: other_action
|
||||
|
||||
Changes the language of the game to `language`. A language change
|
||||
causes the current statement to be restarted, and all contexts but
|
||||
the outermost being exited.
|
||||
|
||||
`language`
|
||||
A string giving the language to translate to, or None to use
|
||||
the language given in the game script.
|
||||
"""
|
||||
|
||||
def __init__(self, language):
|
||||
self.language = language
|
||||
|
||||
def __call__(self):
|
||||
persistent._language = self.language
|
||||
_language_activate()
|
||||
renpy.restart_interaction()
|
||||
renpy.rollback(True, 0)
|
||||
|
||||
def get_selected(self):
|
||||
return persistent._language == self.language
|
||||
|
||||
|
||||
# This is used to ensure a fixed click-to-continue indicator is shown on
|
||||
# its own layer.
|
||||
screen _ctc:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# This file contains the spline motion code contributed by Aenakume, at
|
||||
# This file contains the spline motion code contributed by Aenakume, at
|
||||
# http://lemmasoft.renai.us/forums/viewtopic.php?f=8&t=3977
|
||||
|
||||
init -1080 python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This file contains code that creates a few new statements. We'll
|
||||
@@ -7,7 +7,8 @@
|
||||
# Statements can be defined by calling renpy.statements.register. This
|
||||
# function takes a string giving the keywords at the start of the
|
||||
# statement, and then up to 4 functions defining the behavior of the
|
||||
# statement: parse, execute, predict, and lint
|
||||
# statement: parse, execute, predict, and lint. If given the keyword
|
||||
# argument block=True, the statement will take a block.
|
||||
#
|
||||
# The parse function takes a lexer object as an argument, and is
|
||||
# expected to return some parser data. The lexer has the following
|
||||
@@ -31,6 +32,13 @@
|
||||
# l.revert(o) - Given the object returned by l.checkpoint(), returns
|
||||
# there.
|
||||
#
|
||||
# l.subblock_lexer() - Return a lexer that gives a sub-block for the
|
||||
# block associated with the current statement.
|
||||
# l.advance() - In a subblock lexer, advance to the next line. This needs
|
||||
# to be called before the above functions can be called on the first line.
|
||||
#
|
||||
#
|
||||
#
|
||||
# The parse function is expected to return an object, which is passed
|
||||
# to the other functions. Parse should call renpy.error with the error
|
||||
# message to report an error.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This file is responsible for creating and defining the default styles
|
||||
@@ -72,6 +72,7 @@ init -1200 python hide:
|
||||
|
||||
style.hyperlink = Style(style.default, help=None) # ignored
|
||||
style.hyperlink_text = Style(style.default, help='hyperlinked text')
|
||||
style.ruby_text = Style(style.default, help='ruby text')
|
||||
|
||||
style.viewport = Style(style.default, help='default style of viewports')
|
||||
style.transform = Style(style.motion, help='default style of transforms')
|
||||
@@ -130,7 +131,7 @@ init -1090 python:
|
||||
|
||||
# Text properties.
|
||||
style.default.font = "DejaVuSans.ttf"
|
||||
style.default.language = "western"
|
||||
style.default.language = "unicode"
|
||||
style.default.antialias = True
|
||||
style.default.size = 22
|
||||
style.default.color = (255, 255, 255, 255)
|
||||
@@ -139,6 +140,7 @@ init -1090 python:
|
||||
style.default.italic = False
|
||||
style.default.underline = False
|
||||
style.default.strikethrough = False
|
||||
style.default.kerning = 0.0
|
||||
style.default.drop_shadow = None
|
||||
style.default.drop_shadow_color = (0, 0, 0, 255)
|
||||
style.default.outlines = [ ]
|
||||
@@ -149,11 +151,14 @@ init -1090 python:
|
||||
style.default.first_indent = 0
|
||||
style.default.rest_indent = 0
|
||||
style.default.line_spacing = 0
|
||||
style.default.layout = "greedy"
|
||||
style.default.line_leading = 0
|
||||
style.default.line_overlap_split = 0
|
||||
style.default.layout = "tex"
|
||||
style.default.subtitle_width = 0.9
|
||||
style.default.slow_cps = None
|
||||
style.default.slow_cps_multiplier = 1.0
|
||||
style.default.slow_abortable = False
|
||||
# style.default.hyperlink_functions (set in 00library.rpy)
|
||||
|
||||
# Window properties.
|
||||
style.default.background = None
|
||||
@@ -184,6 +189,7 @@ init -1090 python:
|
||||
style.default.spacing = 0
|
||||
style.default.first_spacing = None
|
||||
style.default.box_layout = None
|
||||
style.default.box_wrap = False
|
||||
|
||||
# Focus properties.
|
||||
style.default.focus_mask = None
|
||||
@@ -259,6 +265,11 @@ init -1090 python:
|
||||
style.hyperlink_text.hover_color = "#0ff"
|
||||
style.hyperlink_text.idle_color = "#08f"
|
||||
|
||||
# Ruby.
|
||||
style.ruby_text.size = 22
|
||||
style.ruby_text.xoffset = 0
|
||||
style.default.ruby_style = style.ruby_text
|
||||
|
||||
# Bars.
|
||||
style.default.bar_invert = False
|
||||
style.default.bar_resizing = False
|
||||
@@ -314,3 +325,4 @@ init -1090 python:
|
||||
style.error_title.color = (255, 128, 128, 255)
|
||||
style.error_body.color = (128, 128, 255, 255)
|
||||
|
||||
|
||||
@@ -0,0 +1,170 @@
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This file contains code for the style preferences system, which allows
|
||||
# the user to define preferences that update styles.
|
||||
|
||||
init -1135 python:
|
||||
|
||||
# A map from preference name to list of (alternative, style, property, value)
|
||||
# tuples.
|
||||
__preferences = { }
|
||||
|
||||
# A map from preference name to the list of alternatives for that preference.
|
||||
__alternatives = { }
|
||||
|
||||
# Are style preferences dirty? If so, we need to update them at the start of
|
||||
# the next operation.
|
||||
__spdirty = object()
|
||||
__spdirty.flag = True
|
||||
|
||||
# A map from preference name to alternative.
|
||||
if persistent._style_preferences is None:
|
||||
persistent._style_preferences = { }
|
||||
|
||||
|
||||
def __register_style_preference(preference, alternative, style, property, value):
|
||||
"""
|
||||
:doc: style_preferences
|
||||
:name: renpy.register_style_preference
|
||||
|
||||
Registers information about an alternative for a style preference.
|
||||
|
||||
`preference`
|
||||
A string, the name of the style property.
|
||||
|
||||
`alternative`
|
||||
A string, the name of the alternative.
|
||||
|
||||
`style`
|
||||
The style that will be updated. This may be a style object or a string giving the style name.
|
||||
|
||||
`property`
|
||||
A string giving the name of the style property that will be update.
|
||||
|
||||
`value`
|
||||
The value that will be assigned to the style property.
|
||||
"""
|
||||
|
||||
if preference not in __preferences:
|
||||
__preferences[preference] = [ ]
|
||||
__alternatives[preference] = [ ]
|
||||
|
||||
if alternative not in __alternatives:
|
||||
__alternatives[preference].append(alternative)
|
||||
|
||||
__preferences[preference].append((alternative, style, property, value))
|
||||
|
||||
def __init():
|
||||
"""
|
||||
Called at the end of the init phase, to ensure that each preference
|
||||
has a valid value.
|
||||
"""
|
||||
|
||||
for preference, alternatives in __alternatives.iteritems():
|
||||
alt = persistent._style_preferences.get(preference, None)
|
||||
|
||||
if alt not in alternatives:
|
||||
persistent._style_preferences[preference] = alternatives[0]
|
||||
|
||||
def __update():
|
||||
"""
|
||||
Called at least once per interaction, to update the styles if necessary.
|
||||
"""
|
||||
|
||||
if not __spdirty.flag:
|
||||
return
|
||||
|
||||
for preference, alternatives in __preferences.iteritems():
|
||||
|
||||
alt = persistent._style_preferences.get(preference, None)
|
||||
|
||||
for alternative, style, property, value in alternatives:
|
||||
if alternative == alt:
|
||||
setattr(style, property, value)
|
||||
|
||||
renpy.style.rebuild()
|
||||
|
||||
__spdirty.flag = False
|
||||
|
||||
def __check(preference, alternative=None):
|
||||
|
||||
if preference not in __alternatives:
|
||||
raise Exception("{0} is not a known style preference.".format(preference))
|
||||
|
||||
if alternative is not None:
|
||||
if alternative not in __alternatives[preference]:
|
||||
raise Exception("{0} is not a known alternative for style preference {1}.".format(alternative, preference))
|
||||
|
||||
|
||||
def __set_style_preference(preference, alternative):
|
||||
"""
|
||||
:doc: style_preferences
|
||||
:name: renpy.set_style_preference
|
||||
|
||||
Sets the selected alternative for the style preference.
|
||||
|
||||
`preference`
|
||||
A string giving the name of the style preference.
|
||||
|
||||
`alternative`
|
||||
A string giving the name of the alternative.
|
||||
"""
|
||||
|
||||
__check(preference, alternative)
|
||||
|
||||
persistent._style_preferences[preference] = alternative
|
||||
__spdirty.flag = True
|
||||
|
||||
renpy.restart_interaction()
|
||||
|
||||
def __get_style_preference(preference):
|
||||
"""
|
||||
:doc: style_preferences
|
||||
:name: renpy.get_style_preference
|
||||
|
||||
Returns a string giving the name of the selected alternative for the named style preference.
|
||||
|
||||
`preference`
|
||||
A string giving the name of the style preference.
|
||||
"""
|
||||
|
||||
__check(preference)
|
||||
|
||||
return persistent._style_preferences[preference]
|
||||
|
||||
class StylePreference(Action):
|
||||
"""
|
||||
:doc: style_preferences
|
||||
|
||||
An action that causes `alternative` to become the selected alternative for the given style preference.
|
||||
|
||||
`preference`
|
||||
A string giving the name of the style preference.
|
||||
|
||||
`alternative`
|
||||
A string giving the name of the alternative.
|
||||
"""
|
||||
|
||||
def __init__(self, preference, alternative):
|
||||
|
||||
__check(preference, alternative)
|
||||
|
||||
self.preference = preference
|
||||
self.alternative = alternative
|
||||
|
||||
def __call__(self):
|
||||
__set_style_preference(self.preference, self.alternative)
|
||||
|
||||
def get_selected(self):
|
||||
return __get_style_preference(self.preference) == self.alternative
|
||||
|
||||
renpy.register_style_preference = __register_style_preference
|
||||
renpy.set_style_preference = __set_style_preference
|
||||
renpy.get_style_preference = __get_style_preference
|
||||
|
||||
config.interact_callbacks.append(__update)
|
||||
|
||||
init 1135 python:
|
||||
|
||||
__init()
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init -1110 python:
|
||||
@@ -401,7 +401,11 @@ init -1110 python hide:
|
||||
roundrect_based_theme("diamond", "_theme_diamond/d")
|
||||
roundrect_based_theme("tv", "_theme_tv/t")
|
||||
roundrect_based_theme("glow", "_theme_glow/g", None, "_outline.png")
|
||||
|
||||
roundrect_based_theme("regal", "_theme_regal/re")
|
||||
roundrect_based_theme("crayon", "_theme_crayon/cry")
|
||||
roundrect_based_theme("threeD", "_theme_threeD/th")
|
||||
roundrect_based_theme("marker", "_theme_marker/ink")
|
||||
roundrect_based_theme("austen", "_theme_austen/au")
|
||||
|
||||
@theme
|
||||
def ancient():
|
||||
@@ -720,6 +724,502 @@ init -1110 python hide:
|
||||
config.image_buttons = { }
|
||||
config.image_labels = { }
|
||||
|
||||
# Theme: A White Tulip
|
||||
# Coding: Jake Staines (http://www.eviscerate.net/)
|
||||
# Graphics: Ren (http://x-Ren-x.deviantart.com/)
|
||||
# Font: Andrew Paglinawan (www.andrewpaglinawan.com)
|
||||
init -1110 python:
|
||||
|
||||
def __AWTBox(colour):
|
||||
base_image = im.MatrixColor("_theme_awt/frame.png", im.matrix.opacity(0.45))
|
||||
colour_tint = im.MatrixColor("_theme_awt/frame.png", im.matrix.colorize(colour, colour))
|
||||
colour_tint = im.MatrixColor(colour_tint, im.matrix.opacity(0.4))
|
||||
frame_image = im.Composite(
|
||||
(220, 147),
|
||||
(0, 0), base_image,
|
||||
(0, 0), colour_tint,
|
||||
(0, 0), "_theme_awt/frame_overlay.png"
|
||||
)
|
||||
|
||||
return Frame(frame_image, 4, 4)
|
||||
|
||||
def __AWTButton(image, colour, highlight, low_sat=False):
|
||||
base_image = "_theme_awt/" + image + ".png"
|
||||
colour_tint = im.MatrixColor("_theme_awt/" + image + ".png", im.matrix.colorize(colour, colour))
|
||||
opacity = 0.5
|
||||
if highlight:
|
||||
opacity = 0.3
|
||||
if low_sat:
|
||||
opacity = opacity * 0.4
|
||||
colour_tint = im.MatrixColor(colour_tint, im.matrix.opacity(opacity))
|
||||
if highlight:
|
||||
button_image = im.Composite(
|
||||
(203, 47),
|
||||
(0, 0), base_image,
|
||||
(0, 0), colour_tint,
|
||||
(0, 0), "_theme_awt/" + image + "_overlay_highlight.png"
|
||||
)
|
||||
else:
|
||||
button_image = im.Composite(
|
||||
(203, 47),
|
||||
(0, 0), base_image,
|
||||
(0, 0), colour_tint,
|
||||
(0, 0), "_theme_awt/" + image + "_overlay.png"
|
||||
)
|
||||
|
||||
return Frame(button_image, 4, 6)
|
||||
|
||||
def __AWTBullet(image):
|
||||
return Transform(image, yalign=0.5, xalign=0.0)
|
||||
|
||||
init -1110 python hide:
|
||||
|
||||
@theme
|
||||
def a_white_tulip_frames(frame):
|
||||
|
||||
theme.clear_frames()
|
||||
|
||||
style.frame.background = __AWTBox(frame)
|
||||
|
||||
style.frame.xpadding = 9
|
||||
style.frame.ypadding = 9
|
||||
|
||||
@theme
|
||||
def a_white_tulip_buttons(text_size,
|
||||
widget,
|
||||
widget_hover,
|
||||
widget_text,
|
||||
widget_selected,
|
||||
disabled,
|
||||
disabled_text,
|
||||
small):
|
||||
|
||||
theme.clear_buttons()
|
||||
|
||||
style.button.background = __AWTButton("button", widget, False)
|
||||
style.button.hover_background = __AWTButton("button", widget_hover, True)
|
||||
style.button.selected_background = __AWTButton("button_selected", widget_hover, False, low_sat=True)
|
||||
style.button.selected_hover_background = __AWTButton("button_selected", widget_hover, True, low_sat=True)
|
||||
style.button.insensitive_background = __AWTButton("button", disabled, False)
|
||||
|
||||
style.button_text.font = "_theme_awt/Quicksand-Regular.ttf"
|
||||
style.button_text.size = text_size
|
||||
style.button_text.color = widget_text
|
||||
|
||||
style.button_text.selected_color = widget_text
|
||||
style.button_text.selected_xoffset = 2
|
||||
style.button_text.selected_yoffset = 2
|
||||
|
||||
style.button_text.insensitive_color = "#0000"
|
||||
|
||||
|
||||
style.button_text.outlines = [
|
||||
(2, "#20202008", 2, 2),
|
||||
(1, "#40404015", 2, 2),
|
||||
(0, "#80808030", 2, 2),
|
||||
(0, widget_text, 1, 0),
|
||||
|
||||
]
|
||||
|
||||
style.button_text.hover_outlines = [
|
||||
(2, "#20202008", 2, 2),
|
||||
(1, "#40404015", 2, 2),
|
||||
(0, "#80808030", 2, 2),
|
||||
(0, widget_text, 1, 0),
|
||||
]
|
||||
|
||||
style.button_text.selected_outlines = [
|
||||
(2, "#20202008", 2, 2),
|
||||
(1, "#40404015", 2, 2),
|
||||
(0, "#80808030", 2, 2),
|
||||
(0, widget_text, 1, 0),
|
||||
]
|
||||
|
||||
style.button_text.insensitive_outlines = [
|
||||
(1, "#fff4", 2, 1),
|
||||
(1, "#3334", 0, -1),
|
||||
]
|
||||
|
||||
|
||||
style.button.xpadding = 9
|
||||
|
||||
if small:
|
||||
style.button.ypadding = 2
|
||||
else:
|
||||
style.button.ypadding = 6
|
||||
|
||||
style.button.xmargin = 3
|
||||
style.button.ymargin = 3
|
||||
|
||||
style.button_text.xalign = 0.5
|
||||
style.button_text.yalign = 0.5
|
||||
style.button_text.text_align = 0.5
|
||||
|
||||
# Radio Buttons
|
||||
|
||||
def set_radio_style(s, colour):
|
||||
|
||||
selected = im.MatrixColor("_theme_awt/radio_base.png", im.matrix.colorize(colour, colour))
|
||||
selected = im.MatrixColor(selected, im.matrix.opacity(0.75))
|
||||
selected = im.Composite( (17, 18),
|
||||
(0, 0), "_theme_awt/radio_unselected.png",
|
||||
(0, 0), "_theme_awt/radio_base.png",
|
||||
(0, 0), selected,
|
||||
(0, 0), "_theme_awt/radio_base_overlay.png"
|
||||
)
|
||||
|
||||
hover = im.MatrixColor("_theme_awt/radio_base.png", im.matrix.colorize(colour, colour))
|
||||
hover = im.MatrixColor(hover, im.matrix.opacity(0.75))
|
||||
hover = im.Composite( (17, 18),
|
||||
(0, 0), "_theme_awt/radio_unselected.png",
|
||||
(0, 0), "_theme_awt/radio_base.png",
|
||||
(0, 0), hover,
|
||||
(0, 0), "_theme_awt/radio_selected_hover.png"
|
||||
)
|
||||
|
||||
s.background = __AWTBullet("_theme_awt/radio_unselected.png")
|
||||
s.hover_background = __AWTBullet("_theme_awt/radio_unselected_hover.png")
|
||||
s.insensitive_background = __AWTBullet("_theme_awt/radio_unselected.png")
|
||||
s.selected_background = __AWTBullet(selected)
|
||||
s.selected_hover_background = __AWTBullet(hover)
|
||||
|
||||
s.left_padding = 23
|
||||
s.left_margin = 10
|
||||
|
||||
def set_radio_text_style(s):
|
||||
s.selected_color = widget_text
|
||||
s.xoffset = 2
|
||||
s.yoffset = 2
|
||||
|
||||
|
||||
s.xalign = 0.0
|
||||
s.text_align = 0.0
|
||||
|
||||
set_radio_style(style.radio_button, widget)
|
||||
set_radio_text_style(style.radio_button_text)
|
||||
|
||||
set_radio_style(style.check_button, widget)
|
||||
set_radio_text_style(style.check_button_text)
|
||||
|
||||
@theme
|
||||
def a_white_tulip_large_buttons(text_size,
|
||||
widget,
|
||||
widget_hover,
|
||||
widget_text,
|
||||
widget_selected,
|
||||
disabled,
|
||||
disabled_text,
|
||||
small):
|
||||
|
||||
theme.clear_large_buttons()
|
||||
|
||||
style.large_button.background = __AWTButton("button", widget, False)
|
||||
style.large_button.hover_background = __AWTButton("button", widget_hover, True)
|
||||
style.large_button.selected_background = __AWTButton("button_selected", widget_hover, False)
|
||||
style.large_button.selected_hover_background = __AWTButton("button_selected", widget_hover, True)
|
||||
style.large_button.insensitive_background = __AWTButton("button", disabled, False)
|
||||
|
||||
style.large_button_text.font = "_theme_awt/Quicksand-Regular.ttf"
|
||||
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.outlines = [
|
||||
(2, "#20202008", 2, 2),
|
||||
(1, "#40404015", 2, 2),
|
||||
(0, "#80808030", 2, 2),
|
||||
(0, widget_text, 1, 0),
|
||||
]
|
||||
|
||||
style.large_button_text.selected_outlines = [
|
||||
(2, "#20202008", 2, 2),
|
||||
(1, "#40404015", 2, 2),
|
||||
(0, "#80808030", 2, 2),
|
||||
(0, widget_selected, 1, 0),
|
||||
]
|
||||
|
||||
style.large_button_text.insensitive_outlines = [
|
||||
(2, "#20202008", 2, 2),
|
||||
(1, "#40404015", 2, 2),
|
||||
(0, "#80808030", 2, 2),
|
||||
(0, disabled_text, 1, 0),
|
||||
]
|
||||
|
||||
|
||||
style.large_button.xpadding = 9
|
||||
|
||||
if small:
|
||||
style.large_button.top_padding = 2
|
||||
style.large_button.bottom_padding = 4
|
||||
else:
|
||||
style.large_button.top_padding = 6
|
||||
style.large_button.bottom_padding = 9
|
||||
|
||||
style.large_button.xmargin = 3
|
||||
style.large_button.ymargin = 3
|
||||
|
||||
style.large_button_text.xalign = 0.5
|
||||
style.large_button_text.yalign = 0.5
|
||||
style.large_button_text.text_align = 0.5
|
||||
|
||||
@theme
|
||||
def a_white_tulip_labels(
|
||||
text_size,
|
||||
label):
|
||||
|
||||
theme.clear_labels()
|
||||
|
||||
style.label_text.size = text_size
|
||||
style.label_text.color = label
|
||||
style.label_text.outlines = [
|
||||
(0, label, 1, 0),
|
||||
(1, "#FFF", 0, 0),
|
||||
(1, "#FFF", 1, 0),
|
||||
(2, "#FFF4", 0, 0),
|
||||
(2, "#FFF4", 1, 0),
|
||||
|
||||
]
|
||||
|
||||
style.label.bottom_margin = 5
|
||||
|
||||
@theme
|
||||
def a_white_tulip_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 a_white_tulip_bars(
|
||||
widget,
|
||||
widget_hover):
|
||||
|
||||
theme.clear_bars()
|
||||
|
||||
def img(name, colour, width, height, x, y):
|
||||
i = im.MatrixColor("_theme_awt/" + name + ".png", im.matrix.colorize(colour, colour))
|
||||
i = im.MatrixColor(i, im.matrix.opacity(0.5))
|
||||
i = im.Composite(
|
||||
(width, height),
|
||||
(0, 0), "_theme_awt/" + name + ".png",
|
||||
(0, 0), i,
|
||||
)
|
||||
if x is not None:
|
||||
i = Frame(i, x, y, tile=True)
|
||||
return i
|
||||
|
||||
def himg(name, colour, width, height, x, y):
|
||||
i = im.MatrixColor("_theme_awt/" + name + ".png", im.matrix.colorize(colour, colour))
|
||||
i = im.MatrixColor(i, im.matrix.opacity(0.5))
|
||||
i = im.Composite(
|
||||
(width, height),
|
||||
(0, 0), "_theme_awt/" + name + ".png",
|
||||
(0, 0), i,
|
||||
(0, 0), "_theme_awt/" + name + "_overlay.png"
|
||||
)
|
||||
if x is not None:
|
||||
i = Frame(i, x, y, tile=True)
|
||||
return i
|
||||
|
||||
# Bars.
|
||||
style.bar.ymaximum = 27
|
||||
style.bar.left_gutter = 14
|
||||
style.bar.right_gutter = 12
|
||||
style.bar.thumb_offset = 10
|
||||
|
||||
style.bar.left_bar = himg("bar_full", widget, 42, 27, 13, 0)
|
||||
style.bar.right_bar = Frame("_theme_awt/slider_empty_all.png", 13, 0, tile=True)
|
||||
style.bar.thumb = himg("bar_thumb", widget, 20, 25, None, None)
|
||||
|
||||
style.vbar.xmaximum = 27
|
||||
style.vbar.top_gutter = 11
|
||||
style.vbar.bottom_gutter = 14
|
||||
style.vbar.thumb_offset = 10
|
||||
|
||||
style.vbar.right_bar = himg("v_bar_full", widget, 27, 42, 0, 15)
|
||||
style.vbar.left_bar = Frame("_theme_awt/vslider_empty_all.png", 0, 13, tile=True)
|
||||
style.vbar.thumb = himg("v_bar_thumb", widget, 25, 20, None, None)
|
||||
|
||||
|
||||
# Sliders
|
||||
style.slider.ymaximum = 27
|
||||
style.slider.left_gutter = 13
|
||||
style.slider.right_gutter = 12
|
||||
style.slider.thumb_offset = 14.5
|
||||
|
||||
style.slider.left_bar = himg("slider_full", widget, 42, 27, 13, 0)
|
||||
style.slider.right_bar = Frame("_theme_awt/slider_empty_all.png", 13, 0, tile=True)
|
||||
style.slider.thumb = himg("vthumb", widget, 29, 30, None, None)
|
||||
|
||||
style.slider.hover_left_bar = himg("slider_full", widget_hover, 42, 27, 13, 0)
|
||||
style.slider.hover_thumb = himg("vthumb", widget_hover, 29, 30, None, None)
|
||||
|
||||
style.vslider.xmaximum = 27
|
||||
style.vslider.top_gutter = 14
|
||||
style.vslider.bottom_gutter = 10
|
||||
style.vslider.thumb_offset = 15
|
||||
|
||||
style.vslider.right_bar = himg("vslider_full", widget, 27, 42, 0, 13)
|
||||
style.vslider.left_bar = Frame("_theme_awt/vslider_empty_all.png", 0, 13, tile=True)
|
||||
style.vslider.thumb = himg("vthumb", widget, 29, 30, None, None)
|
||||
|
||||
style.vslider.hover_right_bar = himg("vslider_full", widget_hover, 27, 42, 0, 13)
|
||||
style.vslider.hover_thumb = himg("vthumb", widget_hover, 29, 30, None, None)
|
||||
|
||||
# Scrollbars.
|
||||
style.scrollbar.left_gutter = 30
|
||||
style.scrollbar.right_gutter = 30
|
||||
style.scrollbar.thumb_offset = 32.5
|
||||
style.scrollbar.ymaximum = 27
|
||||
|
||||
style.scrollbar.left_bar = Frame("_theme_awt/slider_empty_all.png", 13, 0, tile=True)
|
||||
style.scrollbar.right_bar = Frame("_theme_awt/slider_empty_all.png", 13, 0, tile=True)
|
||||
style.scrollbar.thumb = himg("scroller", widget, 65, 29, None, None)
|
||||
|
||||
style.scrollbar.hover_left_bar = Frame("_theme_awt/slider_empty_all.png", 13, 0, tile=True)
|
||||
style.scrollbar.hover_thumb = himg("scroller", widget_hover, 65, 29, None, None)
|
||||
|
||||
style.vscrollbar.top_gutter = 30
|
||||
style.vscrollbar.bottom_gutter = 29
|
||||
style.vscrollbar.thumb_offset = 32.5
|
||||
style.vscrollbar.xmaximum = 27
|
||||
|
||||
style.vscrollbar.left_bar = Frame("_theme_awt/vslider_empty_all.png", 0, 13, tile=True)
|
||||
style.vscrollbar.right_bar = Frame("_theme_awt/vslider_empty_all.png", 0, 13, tile=True)
|
||||
style.vscrollbar.thumb = himg("vscroller", widget, 28, 65, None, None)
|
||||
|
||||
style.vscrollbar.hover_left_bar = Frame("_theme_awt/vslider_empty_all.png", 0, 13, tile=True)
|
||||
style.vscrollbar.hover_thumb = himg("vscroller", widget_hover, 28, 65, None, None)
|
||||
|
||||
@theme
|
||||
def a_white_tulip(
|
||||
widget = "#c1c6d3",
|
||||
widget_hover = "#d7dbe5",
|
||||
widget_text = "#6b6b6b",
|
||||
widget_selected = "#c1c6d3",
|
||||
disabled = "#b4b4b4",
|
||||
disabled_text = "#6b6b6b",
|
||||
label = "#6b6b6b",
|
||||
frame = "#9391c9",
|
||||
text_size=None,
|
||||
small_text_size=None,
|
||||
window = None,
|
||||
button_menu = None,
|
||||
mm_root = "#ffffff",
|
||||
gm_root = "#ffffff",
|
||||
|
||||
# for compatibility - unused:
|
||||
**properties
|
||||
):
|
||||
|
||||
# First off, we're hard-coding the text because we're already making everything
|
||||
# brighter and whiter than it was before, so light-coloured text - even when it was
|
||||
# previously over a dark background - just won't look right.
|
||||
|
||||
widget_text = "#636363"
|
||||
disabled_text = "#6b6b6b"
|
||||
label = "#6b6b6b"
|
||||
|
||||
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()
|
||||
|
||||
small = False
|
||||
|
||||
if config.screen_width <= 640:
|
||||
text_size = text_size or 12
|
||||
small_text_size = small_text_size or 8
|
||||
small = True
|
||||
else:
|
||||
text_size = text_size or 17
|
||||
small_text_size = small_text_size or 12
|
||||
|
||||
theme.a_white_tulip_frames(frame)
|
||||
|
||||
theme.a_white_tulip_buttons(
|
||||
text_size,
|
||||
widget,
|
||||
widget_hover,
|
||||
widget_text,
|
||||
widget_selected,
|
||||
disabled,
|
||||
disabled_text,
|
||||
small)
|
||||
|
||||
theme.a_white_tulip_large_buttons(
|
||||
small_text_size,
|
||||
widget,
|
||||
widget_hover,
|
||||
widget_text,
|
||||
widget_selected,
|
||||
disabled,
|
||||
disabled_text,
|
||||
small)
|
||||
|
||||
theme.a_white_tulip_labels(
|
||||
text_size,
|
||||
label)
|
||||
|
||||
theme.a_white_tulip_prompts(
|
||||
text_size,
|
||||
label)
|
||||
|
||||
theme.a_white_tulip_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 None:
|
||||
window = frame
|
||||
|
||||
style.window.background = __AWTBox(window)
|
||||
style.window.xpadding = 9
|
||||
style.window.xmargin = 6
|
||||
style.window.top_padding = 9
|
||||
style.window.bottom_padding = 35
|
||||
style.window.ymargin = 6
|
||||
|
||||
style.say_dialogue.font = "_theme_awt/Quicksand-Regular.ttf"
|
||||
style.say_dialogue.color = widget_text
|
||||
style.say_dialogue.outlines = [
|
||||
(0, widget_text, 1, 0)
|
||||
]
|
||||
|
||||
style.say_label.font = "_theme_awt/Quicksand-Bold.ttf"
|
||||
style.say_label.color = widget_text
|
||||
style.say_label.outlines = [
|
||||
(2, "#20202008", 2, 2),
|
||||
(1, "#40404015", 2, 2),
|
||||
(0, "#80808030", 2, 2)
|
||||
]
|
||||
|
||||
if button_menu:
|
||||
layout.button_menu()
|
||||
|
||||
style.quick_button.bottom_margin = 15
|
||||
style.quick_button.right_margin = 15
|
||||
|
||||
style.file_picker_text.first_indent = 9
|
||||
style.file_picker_text.rest_indent = 9
|
||||
|
||||
|
||||
init 1110 python:
|
||||
|
||||
if not "compat" in _layout.provided:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# This extra contains a basic implementation of voice support. Right
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
@@ -10,11 +10,11 @@ init python:
|
||||
# The contents of the game menu choices.
|
||||
config.game_menu = [
|
||||
( "return", u"Return", ui.jumps("_return"), 'True'),
|
||||
( "skipping", u"Begin Skipping", ui.jumps("_return_skipping"), 'config.allow_skipping and not renpy.context().main_menu'),
|
||||
( "skipping", u"Begin Skipping", ui.jumps("_return_skipping"), 'config.allow_skipping and not renpy.context()._main_menu'),
|
||||
( "prefs", u"Preferences", _intra_jumps("_prefs_screen", "intra_transition"), 'True' ),
|
||||
( "save", u"Save Game", _intra_jumps("_save_screen", "intra_transition"), 'not renpy.context().main_menu' ),
|
||||
( "save", u"Save Game", _intra_jumps("_save_screen", "intra_transition"), 'not renpy.context()._main_menu' ),
|
||||
( "load", u"Load Game", _intra_jumps("_load_screen", "intra_transition"), 'True'),
|
||||
( "mainmenu", u"Main Menu", lambda : _mainmenu_prompt(), 'not renpy.context().main_menu' ),
|
||||
( "mainmenu", u"Main Menu", lambda : _mainmenu_prompt(), 'not renpy.context()._main_menu' ),
|
||||
( "quit", u"Quit", lambda : _quit_prompt("quit"), 'True' ),
|
||||
]
|
||||
|
||||
@@ -463,7 +463,7 @@ label _load_screen:
|
||||
|
||||
fn, exists = _file_picker("load", False )
|
||||
|
||||
if not renpy.context().main_menu and _load_prompt:
|
||||
if not renpy.context()._main_menu and _load_prompt:
|
||||
if _yesno_prompt("load", u"Loading will lose unsaved progress.\nAre you sure you want to do this?"):
|
||||
renpy.load(fn)
|
||||
else:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init -1170 python hide:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# Copyright 2004-2011 Tom Rothamel
|
||||
# Copyright 2004-2012 Tom Rothamel
|
||||
#
|
||||
# Please see the LICENSE.txt distributed with Ren'Py for permission to
|
||||
# copy and modify.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python hide:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
# Copyright 2004-2011 Tom Rothamel
|
||||
# Copyright 2004-2012 Tom Rothamel
|
||||
#
|
||||
# Please see the LICENSE.txt distributed with Ren'Py for permission to
|
||||
# copy and modify.
|
||||
|
||||
@@ -2,30 +2,41 @@
|
||||
# games.
|
||||
|
||||
screen _developer:
|
||||
window style "gm_root"
|
||||
|
||||
frame:
|
||||
style_group "_developer"
|
||||
style_group ""
|
||||
|
||||
align (.025, .05)
|
||||
|
||||
has vbox:
|
||||
first_spacing 10
|
||||
has vbox
|
||||
|
||||
label "Developer Menu"
|
||||
|
||||
textbutton _(u"Return") action Return()
|
||||
textbutton _(u"Reload Game (Shift + R)") action ui.callsinnewcontext("_save_reload_game")
|
||||
textbutton _(u"Variable Viewer") action Jump("_debugger_screen")
|
||||
textbutton _(u"Theme Test") action Jump("_theme_test")
|
||||
textbutton _(u"Style Hierarchy") action Jump("_style_hierarchy")
|
||||
textbutton _(u"Image Location Picker") action Jump("_image_location_picker")
|
||||
textbutton _(u"Filename List") action Jump("_filename_list")
|
||||
|
||||
init python hide:
|
||||
style._developer_button = Style(style.button)
|
||||
style._developer_button.size_group = "_developer"
|
||||
|
||||
textbutton _(u"Reload Game (Shift+R)"):
|
||||
action ui.callsinnewcontext("_save_reload_game")
|
||||
size_group "developer"
|
||||
textbutton _(u"Variable Viewer"):
|
||||
action Jump("_debugger_screen")
|
||||
size_group "developer"
|
||||
textbutton _(u"Theme Test"):
|
||||
action Jump("_theme_test")
|
||||
size_group "developer"
|
||||
textbutton _(u"Style Hierarchy"):
|
||||
action Jump("_style_hierarchy")
|
||||
size_group "developer"
|
||||
textbutton _(u"Image Location Picker"):
|
||||
action Jump("_image_location_picker")
|
||||
size_group "developer"
|
||||
textbutton _(u"Filename List"):
|
||||
action Jump("_filename_list")
|
||||
size_group "developer"
|
||||
|
||||
null height 15
|
||||
|
||||
textbutton _(u"Return"):
|
||||
action Return()
|
||||
size_group "developer"
|
||||
|
||||
label _developer_screen:
|
||||
|
||||
call screen _developer
|
||||
@@ -46,7 +57,7 @@ label _debugger_screen:
|
||||
|
||||
entries = [ ]
|
||||
|
||||
ebc = renpy.game.log.ever_been_changed
|
||||
ebc = store.__dict__.ever_been_changed
|
||||
ebc = list(ebc)
|
||||
ebc.sort()
|
||||
|
||||
@@ -67,7 +78,10 @@ label _debugger_screen:
|
||||
continue
|
||||
|
||||
val = aRepr.repr(getattr(store, var))
|
||||
entries.append((0, (var + " = " + val).replace("{", "{{")))
|
||||
s = (var + " = " + val)
|
||||
s = s.replace("{", "{{")
|
||||
s = s.replace("[", "[[")
|
||||
entries.append((0, s))
|
||||
|
||||
if entries:
|
||||
vp = ui.viewport(mousewheel=True)
|
||||
@@ -150,7 +164,7 @@ label _theme_test:
|
||||
|
||||
ui.frame(style='menu_frame', xmaximum=0.95)
|
||||
ui.vbox(box_spacing=20)
|
||||
layout.prompt("This a prompt. Hopefully, we've made this long enough to wrap around at least once.", None)
|
||||
layout.prompt("This is a prompt. We've made this text long enough to wrap around so it fills multiple lines.", None)
|
||||
ui.close()
|
||||
|
||||
ui.close() # hbox
|
||||
@@ -196,29 +210,11 @@ label _style_hierarchy:
|
||||
ui.interact()
|
||||
|
||||
jump _developer_screen
|
||||
|
||||
|
||||
init -1050 python:
|
||||
config.missing_background = "black"
|
||||
|
||||
init 1050 python:
|
||||
|
||||
if renpy.game.options.remote:
|
||||
|
||||
config.window_title = "Preview: " + config.window_title
|
||||
|
||||
class Remote(renpy.Displayable):
|
||||
|
||||
def render(self, width, height, st, at):
|
||||
return renpy.Render(0, 0)
|
||||
|
||||
def event(self, ev, x, y, st):
|
||||
renpy.remote.remote()
|
||||
renpy.timeout(.05)
|
||||
|
||||
config.underlay.append(Remote())
|
||||
del Remote
|
||||
|
||||
|
||||
if config.developer:
|
||||
|
||||
@@ -246,7 +242,7 @@ init 1050 python:
|
||||
renpy.show(name, what=config.missing_background)
|
||||
__missing_scene = False
|
||||
|
||||
what = " ".join(what).replace("{", "{{")
|
||||
what = " ".join(what).replace("{", "{{").replace("[", "[[")
|
||||
__missing()[name[0]] = what
|
||||
return True
|
||||
|
||||
@@ -444,7 +440,7 @@ label _image_location_picker:
|
||||
|
||||
for fn in image_files:
|
||||
ui.button(clicked=ui.returns(fn), size_group="files", xminimum=1.0)
|
||||
ui.text(fn, style="button_text", xalign=0.0)
|
||||
ui.text(fn.replace("{", "{{").replace("[", "[["), style="button_text", xalign=0.0)
|
||||
|
||||
ui.close()
|
||||
|
||||
@@ -485,8 +481,8 @@ label _filename_list:
|
||||
for fn in files:
|
||||
fn = os.path.join(dirname, fn)
|
||||
fn = fn[len(config.gamedir) + 1:]
|
||||
print >>f, fn
|
||||
print fn
|
||||
print >>f, fn.encode("utf-8", "replace")
|
||||
print fn.encode("utf-8", "replace")
|
||||
|
||||
f.close()
|
||||
|
||||
@@ -494,7 +490,94 @@ label _filename_list:
|
||||
|
||||
|
||||
jump _developer_screen
|
||||
|
||||
# The style inspector.
|
||||
screen _inspector:
|
||||
zorder 1010
|
||||
modal True
|
||||
|
||||
frame:
|
||||
style_group ""
|
||||
|
||||
xfill True
|
||||
yfill True
|
||||
|
||||
|
||||
has vbox
|
||||
|
||||
label _("Style Inspector")
|
||||
|
||||
null height 20
|
||||
|
||||
if not tree:
|
||||
text _("Nothing to inspect.")
|
||||
else:
|
||||
for depth, width, height, d in tree:
|
||||
$ t = ( " " * depth +
|
||||
u" \u2022 " +
|
||||
d.__class__.__name__ + " : " +
|
||||
"style=%s, " % (__format_style(d.style),) +
|
||||
"size=(%dx%d)" % (width, height) )
|
||||
|
||||
text "[t!q]"
|
||||
|
||||
null height 20
|
||||
|
||||
text _("(Click to continue.)")
|
||||
|
||||
python:
|
||||
ui.saybehavior()
|
||||
|
||||
init python:
|
||||
def _image_load_log_function(st, at):
|
||||
|
||||
ill = list(renpy.get_image_load_log(3))
|
||||
|
||||
if not ill:
|
||||
return Null(), .25
|
||||
|
||||
vbox = VBox()
|
||||
|
||||
for when, filename, preload in ill:
|
||||
if preload:
|
||||
color="#ffffff"
|
||||
else:
|
||||
color="#ffcccc"
|
||||
|
||||
vbox.add(Text(filename.replace("{", "{{").replace("[", "[["), size=12, color=color, style="_default"))
|
||||
|
||||
rv = Window(vbox, style="_frame", background="#0004", xpadding=5, ypadding=5, xminimum=200)
|
||||
return rv, .25
|
||||
|
||||
screen _image_load_log:
|
||||
zorder 1000
|
||||
|
||||
add DynamicDisplayable(_image_load_log_function)
|
||||
|
||||
|
||||
init python:
|
||||
|
||||
def __format_style(s):
|
||||
|
||||
while s:
|
||||
if s.name:
|
||||
break
|
||||
|
||||
if s.parent:
|
||||
s = style.get(s.parent)
|
||||
else:
|
||||
break
|
||||
|
||||
return s.name[0] + "".join([ "[%r]" % i for i in s.name[1:] ])
|
||||
|
||||
def __inspect(tree):
|
||||
renpy.context_dynamic("_window")
|
||||
store._window = False
|
||||
|
||||
renpy.exports.show_screen("_inspector", _transient=True, tree=tree)
|
||||
renpy.ui.interact(mouse="screen", type="screen", suppress_overlay=True, suppress_underlay=True)
|
||||
|
||||
config.inspector = __inspect
|
||||
|
||||
init python:
|
||||
config.underlay.append(im.Tile("_transparent_tile.png"))
|
||||
|
||||
@@ -0,0 +1,488 @@
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
#
|
||||
# This file contains the code for in-game Ren'Py error handling. It's a
|
||||
# module (as opposed to a .rpy file) because that allows us to ensure
|
||||
# that it is fully loaded or run before any other Ren'Py code runs.
|
||||
|
||||
|
||||
|
||||
# These styles define the look of the Ren'Py in-game interface (the
|
||||
# amie2-inspired look). They're also used in the launcher.
|
||||
init python:
|
||||
# default
|
||||
style._default = Style(None)
|
||||
|
||||
# Temporarily, until the real styles can be defined.
|
||||
style.default = style._default
|
||||
style.image = style._default
|
||||
style.fixed = style._default
|
||||
|
||||
style._default.font = "DejaVuSans.ttf"
|
||||
style._default.language = "unicode"
|
||||
style._default.antialias = True
|
||||
style._default.size = 14
|
||||
style._default.color = "#111"
|
||||
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.kerning = 0.0
|
||||
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.line_leading = 0
|
||||
style._default.line_overlap_split = 0
|
||||
style._default.layout = "tex"
|
||||
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
|
||||
style._default.box_wrap = False
|
||||
|
||||
# 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
|
||||
style._default.bar_invert = False
|
||||
style._default.bar_vertical = False
|
||||
|
||||
# Misc.
|
||||
style._default.activate_sound = None
|
||||
style._default.clipping = False
|
||||
|
||||
##########################################################################
|
||||
|
||||
# frame
|
||||
style._frame = Style(style._default)
|
||||
style._frame.background = Frame("_theme_amie2/frame.png", 40, 40)
|
||||
style._frame.xmargin = 0
|
||||
style._frame.ymargin = 0
|
||||
style._frame.xpadding = 15
|
||||
style._frame.ypadding = 10
|
||||
|
||||
# text
|
||||
style._text = Style(style._default)
|
||||
|
||||
# boxes/boxlike
|
||||
style._fixed = Style(style._default)
|
||||
style._hbox = Style(style._default)
|
||||
style._vbox = Style(style._default)
|
||||
style._grid = Style(style._default)
|
||||
style._side = Style(style._default)
|
||||
style._viewport = Style(style._default)
|
||||
|
||||
style._hbox.box_layout = 'horizontal'
|
||||
style._vbox.box_layout = 'vertical'
|
||||
style._viewport.clipping = True
|
||||
|
||||
# button
|
||||
style._button = Style(style._default)
|
||||
style._button_text = Style(style._default)
|
||||
style._button.xpadding = 8
|
||||
style._button.ypadding = 6
|
||||
style._button.xoffset = -5
|
||||
|
||||
style._button.background = Frame("_theme_amie2/button.png", 10, 10)
|
||||
style._button.hover_background = Frame("_theme_amie2/button_hover.png", 10, 10)
|
||||
style._button_text.size = 16
|
||||
style._button_text.color = "#111"
|
||||
style._button_text.selected_color = "#11f"
|
||||
style._button_text.insensitive_color = "#ccc"
|
||||
style._button_text.xalign = 0.5
|
||||
style._button_text.yoffset = 0
|
||||
|
||||
# label
|
||||
style._label = Style(style._default)
|
||||
style._label_text = Style(style._default)
|
||||
|
||||
style._label.top_margin = 10
|
||||
style._label.bottom_margin = 5
|
||||
|
||||
style._label_text.color = "#000"
|
||||
style._label_text.bold = True
|
||||
|
||||
# bar
|
||||
style._bar = Style(style._default)
|
||||
|
||||
style._bar.left_bar = Frame("_theme_amie2/hover_frame.png", 10, 10)
|
||||
style._bar.right_bar = Frame("_theme_amie2/bar.png", 10, 10)
|
||||
style._bar.thumb = None
|
||||
style._bar.hover_thumb = None
|
||||
style._bar.ymaximum = 20
|
||||
|
||||
style._scrollbar = Style(style._default)
|
||||
style._vscrollbar = Style(style._default)
|
||||
|
||||
style._scrollbar.left_bar = Frame("_theme_amie2/bar.png", 10, 10)
|
||||
style._scrollbar.right_bar = Frame("_theme_amie2/bar.png", 10, 10)
|
||||
style._scrollbar.thumb = Frame("_theme_amie2/frame.png", 10, 10)
|
||||
style._scrollbar.hover_thumb = Frame("_theme_amie2/hover_frame.png", 10, 10)
|
||||
style._scrollbar.thumb_offset = 10
|
||||
style._scrollbar.left_gutter = 5
|
||||
style._scrollbar.right_gutter = 5
|
||||
style._scrollbar.unscrollable = "hide"
|
||||
|
||||
style._scrollbar.ymaximum = 20
|
||||
style._vscrollbar.xmaximum = 20
|
||||
style._vscrollbar.bar_vertical = True
|
||||
style._vscrollbar.bar_invert = True
|
||||
|
||||
style._hyperlink = Style(style._default)
|
||||
style._hyperlink.color = "#008"
|
||||
style._hyperlink.hover_underline = True
|
||||
|
||||
# Early hyperlink support.
|
||||
init python hide:
|
||||
def hyperlink_styler(target):
|
||||
return style._hyperlink
|
||||
|
||||
def hyperlink_function(target):
|
||||
if target.startswith("http:"):
|
||||
try:
|
||||
import webbrowser
|
||||
webbrowser.open(target)
|
||||
except:
|
||||
pass
|
||||
|
||||
if target.startswith("edit:"):
|
||||
prefix, line, filename = target.split(":", 2)
|
||||
line = int(line)
|
||||
|
||||
renpy.launch_editor([ filename ], line)
|
||||
|
||||
style._default.hyperlink_functions = (hyperlink_styler, hyperlink_function, None)
|
||||
|
||||
init python:
|
||||
|
||||
# Null translation function. This gets redefined once things start
|
||||
# successfully.
|
||||
def _(s):
|
||||
return s
|
||||
|
||||
# This function is responsible for taking a traceback, and converting
|
||||
# it to a string that can be shown with text.
|
||||
def __format_traceback(s):
|
||||
import re
|
||||
|
||||
lines = [ i.replace("{", "{{") for i in s.split("\n") ]
|
||||
|
||||
rv = [ "{b}" + lines[0] + "{/b}" ]
|
||||
|
||||
for i in lines[1:]:
|
||||
i = re.sub(r'(File "(.*)", line (\d+))', r'{a=edit:\3:\2}\1{/a}', i)
|
||||
rv.append(i)
|
||||
|
||||
return "\n".join(rv)
|
||||
|
||||
|
||||
def __format_parse_errors(s):
|
||||
import re
|
||||
|
||||
rv = ""
|
||||
|
||||
lines = s.split("\n")
|
||||
len_lines = len(lines)
|
||||
|
||||
ln = 0
|
||||
|
||||
while ln < len_lines:
|
||||
line = lines[ln]
|
||||
ln += 1
|
||||
|
||||
if ln < len_lines and lines[ln].endswith("^"):
|
||||
highlight = len(lines[ln]) - 1
|
||||
ln += 1
|
||||
else:
|
||||
highlight = -1
|
||||
|
||||
pos = 0
|
||||
|
||||
for c in line:
|
||||
if pos == highlight:
|
||||
rv += u"{color=#c00}\u2192{/color}"
|
||||
highlight = -1
|
||||
|
||||
pos += 1
|
||||
|
||||
if c == "{":
|
||||
rv += "{{"
|
||||
else:
|
||||
rv += c
|
||||
|
||||
if highlight > 0:
|
||||
rv += u"{color=#c00}\u2190{/color}"
|
||||
|
||||
rv += "\n"
|
||||
|
||||
|
||||
rv = re.sub(r'(File "(.*)", line (\d+))', r'{a=edit:\3:\2}\1{/a}', rv)
|
||||
|
||||
return rv
|
||||
|
||||
class __EditFile(Action):
|
||||
def __init__(self, filename):
|
||||
self.filename = filename
|
||||
|
||||
def __call__(self):
|
||||
try:
|
||||
renpy.launch_editor([ self.filename ], 1, transient=1)
|
||||
except:
|
||||
pass
|
||||
|
||||
def __can_open_traceback():
|
||||
return True
|
||||
|
||||
# The transform used for errors. ATL isn't ready yet.
|
||||
def __transform_function(state, st, at):
|
||||
done = min(st / .1, 1.0)
|
||||
state.zoom = .5 + .5 * done
|
||||
state.alpha = done
|
||||
state.xalign = 0.5
|
||||
state.yalign = 0.5
|
||||
|
||||
if done < 1.0:
|
||||
return 0
|
||||
else:
|
||||
return None
|
||||
|
||||
__transform = Transform(function=__transform_function, style='_default')
|
||||
|
||||
class __TooltipAction(object):
|
||||
|
||||
def __init__(self, tooltip, value):
|
||||
self.tooltip = tooltip
|
||||
self.value = value
|
||||
|
||||
def __call__(self):
|
||||
if self.tooltip.value != self.value:
|
||||
self.tooltip.value = self.value
|
||||
renpy.restart_interaction()
|
||||
|
||||
def unhovered(self):
|
||||
if self.tooltip.value != self.tooltip.default:
|
||||
self.tooltip.value = self.tooltip.default
|
||||
renpy.restart_interaction()
|
||||
|
||||
class __Tooltip(object):
|
||||
def __init__(self, default):
|
||||
self.value = default
|
||||
self.default = default
|
||||
|
||||
def action(self, value):
|
||||
return __TooltipAction(self, value)
|
||||
|
||||
class __XScrollValue(BarValue):
|
||||
def __init__(self, viewport):
|
||||
self.viewport = viewport
|
||||
|
||||
def get_adjustment(self):
|
||||
w = renpy.get_widget(None, self.viewport)
|
||||
if not isinstance(w, Viewport):
|
||||
raise Exception("The displayable with id %r is not declared, or not a viewport." % self.viewport)
|
||||
|
||||
return w.xadjustment
|
||||
|
||||
def get_style(self):
|
||||
return "scrollbar", "vscrollbar"
|
||||
|
||||
class __YScrollValue(BarValue):
|
||||
def __init__(self, viewport):
|
||||
self.viewport = viewport
|
||||
|
||||
def get_adjustment(self):
|
||||
w = renpy.get_widget(None, self.viewport)
|
||||
if not isinstance(w, Viewport):
|
||||
raise Exception("The displayable with id %r is not declared, or not a viewport." % self.viewport)
|
||||
|
||||
return w.yadjustment
|
||||
|
||||
def get_style(self):
|
||||
return "scrollbar", "vscrollbar"
|
||||
|
||||
|
||||
# The screen that is used for error handling.
|
||||
screen _exception:
|
||||
modal True
|
||||
zorder 1090
|
||||
|
||||
default tt = __Tooltip("")
|
||||
default fmt_short = __format_traceback(short)
|
||||
default fmt_full = __format_traceback(full)
|
||||
|
||||
add Solid("#000")
|
||||
|
||||
frame:
|
||||
style_group ""
|
||||
xfill True
|
||||
|
||||
at __transform
|
||||
|
||||
has side "t c r b"
|
||||
|
||||
vbox:
|
||||
label _("An exception has occurred.")
|
||||
|
||||
viewport:
|
||||
id "viewport"
|
||||
child_size (4000, None)
|
||||
mousewheel True
|
||||
|
||||
has vbox
|
||||
|
||||
text fmt_short substitute False
|
||||
text fmt_full substitute False
|
||||
|
||||
bar:
|
||||
style "_vscrollbar"
|
||||
value __YScrollValue("viewport")
|
||||
|
||||
vbox:
|
||||
|
||||
bar:
|
||||
style "_scrollbar"
|
||||
value __XScrollValue("viewport")
|
||||
|
||||
hbox:
|
||||
box_wrap True
|
||||
|
||||
if rollback_action:
|
||||
textbutton _("Rollback"):
|
||||
action rollback_action
|
||||
hovered tt.action(_("Attempts a roll back to a prior time, allowing you to save or choose a different choice."))
|
||||
|
||||
if ignore_action:
|
||||
textbutton _("Ignore"):
|
||||
action ignore_action
|
||||
hovered tt.action(_("Ignores the exception, allowing you to continue. This often leads to additional errors."))
|
||||
|
||||
if config.developer:
|
||||
textbutton _("Reload"):
|
||||
action reload_action
|
||||
hovered tt.action(_("Reloads the game from disk, saving and restoring game state if possible."))
|
||||
|
||||
textbutton _("Open Traceback"):
|
||||
action __EditFile(traceback_fn)
|
||||
hovered tt.action(_("Opens the traceback.txt file in a text editor."))
|
||||
|
||||
null width 30
|
||||
|
||||
textbutton _("Quit"):
|
||||
action renpy.quit
|
||||
hovered tt.action(_("Quits the game."))
|
||||
|
||||
# Tooltip.
|
||||
text tt.value size 12
|
||||
|
||||
if config.developer and reload_action:
|
||||
key "R" action reload_action
|
||||
|
||||
# The screen that is used for error handling.
|
||||
screen _parse_errors:
|
||||
modal True
|
||||
zorder 1090
|
||||
|
||||
default tt = __Tooltip("")
|
||||
default fmt_errors = __format_parse_errors(errors)
|
||||
|
||||
add Solid("#000")
|
||||
|
||||
frame:
|
||||
style_group ""
|
||||
xfill True
|
||||
|
||||
at __transform
|
||||
|
||||
has side "t c r b"
|
||||
|
||||
vbox:
|
||||
label _("Parsing the script failed.")
|
||||
|
||||
viewport:
|
||||
id "viewport"
|
||||
child_size (None, None)
|
||||
mousewheel True
|
||||
|
||||
has vbox
|
||||
text fmt_errors substitute False
|
||||
|
||||
bar:
|
||||
style "_vscrollbar"
|
||||
value __YScrollValue("viewport")
|
||||
|
||||
vbox:
|
||||
|
||||
bar:
|
||||
style "_scrollbar"
|
||||
value __XScrollValue("viewport")
|
||||
|
||||
hbox:
|
||||
box_wrap True
|
||||
|
||||
textbutton _("Reload"):
|
||||
action reload_action
|
||||
hovered tt.action(_("Reloads the game from disk, saving and restoring game state if possible."))
|
||||
|
||||
textbutton _("Open Parse Errors"):
|
||||
action __EditFile(error_fn)
|
||||
hovered tt.action(_("Opens the errors.txt file in a text editor."))
|
||||
|
||||
null width 30
|
||||
|
||||
textbutton _("Quit"):
|
||||
action renpy.quit
|
||||
hovered tt.action(_("Quits the game."))
|
||||
|
||||
# Tooltip.
|
||||
text tt.value size 12
|
||||
|
||||
if config.developer and reload_action:
|
||||
key "R" action reload_action
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
@@ -351,11 +351,3 @@ label load_screen:
|
||||
continue
|
||||
|
||||
renpy.load(fn)
|
||||
|
||||
|
||||
|
||||
init python hide:
|
||||
def auto_save_extra_info():
|
||||
return save_name
|
||||
config.auto_save_extra_info = auto_save_extra_info
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python hide:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
@@ -352,9 +352,3 @@ label load_screen:
|
||||
continue
|
||||
|
||||
renpy.load(fn)
|
||||
|
||||
init python hide:
|
||||
def auto_save_extra_info():
|
||||
return save_name
|
||||
config.auto_save_extra_info = auto_save_extra_info
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python hide:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python hide:
|
||||
@@ -6,6 +6,7 @@ init python hide:
|
||||
layout.provides('yesno_prompt')
|
||||
|
||||
def yesno_prompt(screen, message):
|
||||
return renpy.call_screen('yesno_prompt', message=message, yes_action=Return(True), no_action=Return(False))
|
||||
rv = renpy.call_screen('yesno_prompt', message=message, yes_action=Return(True), no_action=Return(False))
|
||||
return rv
|
||||
|
||||
layout.yesno_prompt = yesno_prompt
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
@@ -227,10 +227,3 @@ label load_screen:
|
||||
continue
|
||||
|
||||
renpy.load(fn)
|
||||
|
||||
|
||||
init python hide:
|
||||
def auto_save_extra_info():
|
||||
return save_name
|
||||
config.auto_save_extra_info = auto_save_extra_info
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2004-2011 Tom Rothamel <pytom@bishoujo.us>
|
||||
# Copyright 2004-2012 Tom Rothamel <pytom@bishoujo.us>
|
||||
# See LICENSE.txt for license details.
|
||||
|
||||
init python:
|
||||
|
||||
|
After Width: | Height: | Size: 325 B |
|
After Width: | Height: | Size: 554 B |
|
After Width: | Height: | Size: 534 B |
|
After Width: | Height: | Size: 1.0 KiB |
|
After Width: | Height: | Size: 358 B |
|
After Width: | Height: | Size: 474 B |
|
After Width: | Height: | Size: 954 B |
|
After Width: | Height: | Size: 733 B |
|
After Width: | Height: | Size: 405 B |
|
After Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 656 B |
|
After Width: | Height: | Size: 789 B |
|
After Width: | Height: | Size: 409 B |
|
After Width: | Height: | Size: 1.5 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 623 B |
@@ -0,0 +1,94 @@
|
||||
Copyright (c) 2011, Andrew Paglinawan (www.andrewpaglinawan.com),
|
||||
with Reserved Font Name "Quicksand".
|
||||
|
||||
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
||||
This license is copied below, and is also available with a FAQ at:
|
||||
http://scripts.sil.org/OFL
|
||||
|
||||
|
||||
-----------------------------------------------------------
|
||||
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
||||
-----------------------------------------------------------
|
||||
|
||||
PREAMBLE
|
||||
The goals of the Open Font License (OFL) are to stimulate worldwide
|
||||
development of collaborative font projects, to support the font creation
|
||||
efforts of academic and linguistic communities, and to provide a free and
|
||||
open framework in which fonts may be shared and improved in partnership
|
||||
with others.
|
||||
|
||||
The OFL allows the licensed fonts to be used, studied, modified and
|
||||
redistributed freely as long as they are not sold by themselves. The
|
||||
fonts, including any derivative works, can be bundled, embedded,
|
||||
redistributed and/or sold with any software provided that any reserved
|
||||
names are not used by derivative works. The fonts and derivatives,
|
||||
however, cannot be released under any other type of license. The
|
||||
requirement for fonts to remain under this license does not apply
|
||||
to any document created using the fonts or their derivatives.
|
||||
|
||||
DEFINITIONS
|
||||
"Font Software" refers to the set of files released by the Copyright
|
||||
Holder(s) under this license and clearly marked as such. This may
|
||||
include source files, build scripts and documentation.
|
||||
|
||||
"Reserved Font Name" refers to any names specified as such after the
|
||||
copyright statement(s).
|
||||
|
||||
"Original Version" refers to the collection of Font Software components as
|
||||
distributed by the Copyright Holder(s).
|
||||
|
||||
"Modified Version" refers to any derivative made by adding to, deleting,
|
||||
or substituting -- in part or in whole -- any of the components of the
|
||||
Original Version, by changing formats or by porting the Font Software to a
|
||||
new environment.
|
||||
|
||||
"Author" refers to any designer, engineer, programmer, technical
|
||||
writer or other person who contributed to the Font Software.
|
||||
|
||||
PERMISSION & CONDITIONS
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
||||
redistribute, and sell modified and unmodified copies of the Font
|
||||
Software, subject to the following conditions:
|
||||
|
||||
1) Neither the Font Software nor any of its individual components,
|
||||
in Original or Modified Versions, may be sold by itself.
|
||||
|
||||
2) Original or Modified Versions of the Font Software may be bundled,
|
||||
redistributed and/or sold with any software, provided that each copy
|
||||
contains the above copyright notice and this license. These can be
|
||||
included either as stand-alone text files, human-readable headers or
|
||||
in the appropriate machine-readable metadata fields within text or
|
||||
binary files as long as those fields can be easily viewed by the user.
|
||||
|
||||
3) No Modified Version of the Font Software may use the Reserved Font
|
||||
Name(s) unless explicit written permission is granted by the corresponding
|
||||
Copyright Holder. This restriction only applies to the primary font name as
|
||||
presented to the users.
|
||||
|
||||
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
||||
Software shall not be used to promote, endorse or advertise any
|
||||
Modified Version, except to acknowledge the contribution(s) of the
|
||||
Copyright Holder(s) and the Author(s) or with their explicit written
|
||||
permission.
|
||||
|
||||
5) The Font Software, modified or unmodified, in part or in whole,
|
||||
must be distributed entirely under this license, and must not be
|
||||
distributed under any other license. The requirement for fonts to
|
||||
remain under this license does not apply to any document created
|
||||
using the Font Software.
|
||||
|
||||
TERMINATION
|
||||
This license becomes null and void if any of the above conditions are
|
||||
not met.
|
||||
|
||||
DISCLAIMER
|
||||
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
||||
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
||||
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
||||
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
||||
OTHER DEALINGS IN THE FONT SOFTWARE.
|
||||
|
After Width: | Height: | Size: 404 B |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 86 B |
|
After Width: | Height: | Size: 310 B |
|
After Width: | Height: | Size: 719 B |
|
After Width: | Height: | Size: 2.8 KiB |
|
After Width: | Height: | Size: 298 B |
|
After Width: | Height: | Size: 3.0 KiB |
|
After Width: | Height: | Size: 2.9 KiB |
|
After Width: | Height: | Size: 2.8 KiB |
|
After Width: | Height: | Size: 3.0 KiB |
|
After Width: | Height: | Size: 2.9 KiB |
|
After Width: | Height: | Size: 3.0 KiB |
|
After Width: | Height: | Size: 3.2 KiB |
|
After Width: | Height: | Size: 293 B |
|
After Width: | Height: | Size: 3.4 KiB |
|
After Width: | Height: | Size: 3.3 KiB |
|
After Width: | Height: | Size: 3.3 KiB |
|
After Width: | Height: | Size: 3.3 KiB |
|
After Width: | Height: | Size: 765 B |
|
After Width: | Height: | Size: 1.5 KiB |