ZTBS Skript
Nun das Skript hier:
http://www.rpg-studio.de/itzamna/script/…tle-System.html
Hätte Ich sehr gerne, da mir das Standart KS nicht gefällt. Wenn Ich aber das ZTBS im Skript Editor einfüge und einen Battle Test mache habe Ich immer noch das Standart KS. Könnte mir jemand sagen wie das genau funktioniert? Und die Demo funzt bei mir irgendwie nicht.
Mfg TD
http://www.rpg-studio.de/itzamna/script/…tle-System.html
Hätte Ich sehr gerne, da mir das Standart KS nicht gefällt. Wenn Ich aber das ZTBS im Skript Editor einfüge und einen Battle Test mache habe Ich immer noch das Standart KS. Könnte mir jemand sagen wie das genau funktioniert? Und die Demo funzt bei mir irgendwie nicht.
Mfg TD
Benutzerinformationen überspringen
Motto: Wer anderen eine Bratwurst brät, der hat ein Bratwurstbratgerät.
Gar nicht. Du musst es aus einem normalen Start heraus probieren.
Zitat
Hätte Ich sehr gerne, da mir das Standart KS nicht gefällt. Wenn Ich aber das ZTBS im Skript Editor einfüge und einen Battle Test mache habe Ich immer noch das Standart KS. Könnte mir jemand sagen wie das genau funktioniert?
Im Battle Test wirds nicht funktionieren =)
Dann bringst du sie eben irgendwie zum funzen
Zitat
Und die Demo funzt bei mir irgendwie nicht.
Willkommen im Forum 
Was Neo wohl sagen will, ist das der BattleTest der Database, automatisch das Standard KS benutzt. Wen es interessiert das kann man auch betrachten wenn man sich das Scene_Title Script mal durchließt.
Aber deine Angabe, die Demo funzt nicht, ist zu ungenau. Beschreib bitte was genau passiert, und wo der Fehler ist. Fehlermeldung?
Bitte erklär was nicht klappt, sonst kann man dir nicht helfen.

Was Neo wohl sagen will, ist das der BattleTest der Database, automatisch das Standard KS benutzt. Wen es interessiert das kann man auch betrachten wenn man sich das Scene_Title Script mal durchließt.
Aber deine Angabe, die Demo funzt nicht, ist zu ungenau. Beschreib bitte was genau passiert, und wo der Fehler ist. Fehlermeldung?
Bitte erklär was nicht klappt, sonst kann man dir nicht helfen.
Das große Scientia Wiki zur Spielentwicklung 
Was ist das RGSS ? RGSS-Dokumentation auf Sc
Kyoshiros Makerkurs
Musik von Shabraxxx für euch
Guide zu den Audioformaten
Skripte von mir (Auswahl):
Atmungssystem
| Streichholzsystem
| Animiert durch Bücher blättern
Random : Marktsystem für Kardor
| Staterelated Battlergraphic
| Hinweis auf mögliche Aktionen
SelfSwitchExpirationtimer Skript - Gameplayerweiterung für Pilzesammler und Farmspiele
Meine Skripte werden gerade hier gesammelt.

Was ist das RGSS ? RGSS-Dokumentation auf Sc
Kyoshiros Makerkurs

Musik von Shabraxxx für euch
Guide zu den Audioformaten

Skripte von mir (Auswahl):
Atmungssystem
| Streichholzsystem
| Animiert durch Bücher blättern
Random : Marktsystem für Kardor
| Staterelated Battlergraphic
| Hinweis auf mögliche Aktionen
SelfSwitchExpirationtimer Skript - Gameplayerweiterung für Pilzesammler und Farmspiele
Meine Skripte werden gerade hier gesammelt.
Im Script ändern 
Falls du RGSS nicht so gut kannst, zeig das Script und wir sagen dir wo du das änderst.

Falls du RGSS nicht so gut kannst, zeig das Script und wir sagen dir wo du das änderst.
Das große Scientia Wiki zur Spielentwicklung 
Was ist das RGSS ? RGSS-Dokumentation auf Sc
Kyoshiros Makerkurs
Musik von Shabraxxx für euch
Guide zu den Audioformaten
Skripte von mir (Auswahl):
Atmungssystem
| Streichholzsystem
| Animiert durch Bücher blättern
Random : Marktsystem für Kardor
| Staterelated Battlergraphic
| Hinweis auf mögliche Aktionen
SelfSwitchExpirationtimer Skript - Gameplayerweiterung für Pilzesammler und Farmspiele
Meine Skripte werden gerade hier gesammelt.

Was ist das RGSS ? RGSS-Dokumentation auf Sc
Kyoshiros Makerkurs

Musik von Shabraxxx für euch
Guide zu den Audioformaten

Skripte von mir (Auswahl):
Atmungssystem
| Streichholzsystem
| Animiert durch Bücher blättern
Random : Marktsystem für Kardor
| Staterelated Battlergraphic
| Hinweis auf mögliche Aktionen
SelfSwitchExpirationtimer Skript - Gameplayerweiterung für Pilzesammler und Farmspiele
Meine Skripte werden gerade hier gesammelt.
Falls du die nicht finden solltest:
Tippe dies:
Tippe dies:
|
|
Quellcode |
1 |
[spoiler='titel'][ruby]hier zwischen dein code[/ruby][/spoiler] |
Edit: Kopier den Code am besten ganz neu zwischen die 2 BB-Codes, damit die Tabs wieder da sind => erleichtert das Lesen ungemein
-
Werbung -
1plus3
-
Nuuuhminaaah
-
compétences(Dieser Tab ist rein satirisch.)mes compétences
max.
Maps machen
Musik machen
Scripts machen
Story ausdenken
Pixeln und so
Events proggen
-
mes projets-
Silentium
Name: Silentium
Maker: Eigenbau (C++, x86-SSE/AVX-Assembly, Ruby/Lua)
Story
NPCs
Scripts
Ressis
Maps
Gesamt(3+4)% 42 69% 0815 -17.438 103.38% ± 6.3mm²
(Die Tabelle erfüllt lediglich satirische Zwecke.) -
OnyxEine in C++ implementierte, modulare, plattformunabhängige, virtuelle Maschine. Die Test-Version ist bereits halb fertig. Ab dann gibt es vielleicht mehr Infos. Sie soll die auf dem ersten Blick LISP-artige und eigens dafür konstruierte Sprache Obsidian ausführen können. Experimentell wird auch ein Lua-Compiler für Onyx gebaut. Ziel ist eine leistungsfähige, virtuelle Maschine für beliebige Scriptsprachen. Theoretisch gesehen müsste man bloß noch einen kompatiblen Compiler schreiben, der Quellcode jener Sprache in Onyx-Assembly, oder direkt in Onyx-Bytecode übersetzt. Ob die jemand nutzen wird, ist eine andere Frage und nur ein sekundäres... nein, eher tertiäres Ziel dieser VM. Primär dient es mir lediglich dazu, mein Verständnis von Hardware, ISA, und Assembly zu vertiefen, sowie eigene Grenzen auszutesten.
Warnung!
Das Entwickeln einer virtuellen Maschine oder Programmiersprache (im wahnsinnigsten Fall beides) ist eine höchst komplizierte Tätigkeit, aus der viel Frust und Hirnmatsche hervor gehen. Sollte sich dennoch ein ähnlich wahnsinniger finden, der sowas zusammen schustern will, so lege ich ihm/ihr die folgenden Bücher ans Herz:- Compiler - Das Drachenbuch [978-3-8273-7097-6]
Dieses Buch schlachtet ausführlich und leicht verständlich die Grundlagen bis hoch zu den Experten-Techniken des Compilerbaus aus. Es fängt mit der Automaten-Theorie und formalen Sprachen an, arbeitet sich durch Analysetechniken vor, und landet schließlich bei Techniken wie Optimierung und Register-Zuweisung. Das Buch wiegt 3Kg oder 4Kg. Hab's mal gewogen. Ist also nicht gerade die Lektüre für unterwegs.
- Computerarchitektur [3-8273-7016-7]
Hier werden leicht verständlich die wichtigsten Entwicklungen der Rechnerarchitekturen erklärt (Gut, das Buch ist in die Jahre gekommen, aber der Weg zu heute ist ein winziger Schritt, den man sich nach diesem Buch selbst erdenken kann). Hauptbestandteil des Buchs ist eine relativ umfassende Betrachtung der Funktionsweise dreier gänzlich unterschiedlicher, aber dominierender Prozessor-Typen am Beispiel des Pentium II, UltraSPARC II, sowie picoJava. Die meisten Elemente dieses Buchs sind zwar für die Konstruktion einer virtuellen Maschine irrelevant, oder aufgrund der Tatsache, dass die VM Software ist und z.B. Byte-Grenzen hat, sogar zu Leistungseinbußen führen kann, doch ist ein hinreichendes Verständnis dieser Maschinen, mit denen wir arbeiten, äußerst hilfreich für die Überlegungen, wie die VM arbeiten soll.
Es kann sehr hilfreich und inspirierend sein, den Code quelloffener, virtueller Maschinen anderer Sprachen zu überfliegen. Meine Lieblings-Quelle war und ist stets die VM von Lua. Sie ist schlank, verständlich, in C implementiert, und basiert im Gegensatz zu vielen anderen Scriptsprachen-VMs auf einer Register-Maschine statt einer Stapelmaschine. Es wäre natürlich vorteilhaft, die entsprechende Sprache zu verstehen, in der man auch die eigene VM implementieren will. Weiterhin ist es äußerst vorteilhaft, eine leistungsstarke und bequeme Sprache wie C++ zu beherrschen, um die VM zu implementieren. Und bevor irgendwer auf die Idee kommt: Assembly ist NICHT als dominierende Sprache für den Bau einer VM geeignet. Wer die Frage des "Warum?" nicht beantworten kann, sollte zunächst die gewählte Sprache und Assembly hinreichend verstehen lernen, und es dann erneut mit der Frage versuchen. Es lohnt sich dennoch, Assembly zu lernen. Allein schon, um erneut das Verständnis zu vertiefen, zumal ihr mehr oder weniger gezwungen seid, auch für eure VM eine Assembler-Sprache zu entwickeln (Außer natürlich ihr schreibt eure Test-Programme Bit für Bit ;3). - Compiler - Das Drachenbuch [978-3-8273-7097-6]
-
-
enfinJe ne peux pas parler français.
C'est tout ce que Goodle et les restes de cours de français.
Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von »Evrey« (6. Juni 2009, 20:15)
|
|
Ruby Quellcode |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 |
class Bitmap if not method_defined?('original_draw_text') alias original_draw_text draw_text def draw_text(*arg) original_color = self.font.color.dup self.font.color = Color.new(0, 0, 0, 128) if arg[0].is_a?(Rect) arg[0].x = 2 arg[0].y = 2 self.original_draw_text(*arg) arg[0].x -= 2 arg[0].y -= 2 else arg[0] = 2 arg[1] = 2 self.original_draw_text(*arg) arg[0] -= 2 arg[1] -= 2 end self.font.color = original_color self.original_draw_text(*arg) end end def gradation_rect(x, y, width, height, color1, color2, align = 0) if align == 0 for i in x...x width red = color1.red (color2.red - color1.red) * (i - x) / (width - 1) green = color1.green (color2.green - color1.green) * (i - x) / (width - 1) blue = color1.blue (color2.blue - color1.blue) * (i - x) / (width - 1) alpha = color1.alpha (color2.alpha - color1.alpha) * (i - x) / (width - 1) color = Color.new(red, green, blue, alpha) fill_rect(i, y, 1, height, color) end elsif align == 1 for i in y...y height red = color1.red (color2.red - color1.red) * (i - y) / (height - 1) green = color1.green (color2.green - color1.green) * (i - y) / (height - 1) blue = color1.blue (color2.blue - color1.blue) * (i - y) / (height - 1) alpha = color1.alpha (color2.alpha - color1.alpha) * (i - y) / (height - 1) color = Color.new(red, green, blue, alpha) fill_rect(x, i, width, 1, color) end elsif align == 2 for i in x...x width for j in y...y height red = color1.red (color2.red - color1.red) * ((i - x) / (width - 1.0) (j - y) / (height - 1.0)) / 2 green = color1.green (color2.green - color1.green) * ((i - x) / (width - 1.0) (j - y) / (height - 1.0)) / 2 blue = color1.blue (color2.blue - color1.blue) * ((i - x) / (width - 1.0) (j - y) / (height - 1.0)) / 2 alpha = color1.alpha (color2.alpha - color1.alpha) * ((i - x) / (width - 1.0) (j - y) / (height - 1.0)) / 2 color = Color.new(red, green, blue, alpha) set_pixel(i, j, color) end end elsif align == 3 for i in x...x width for j in y...y height red = color1.red (color2.red - color1.red) * ((x width - i) / (width - 1.0) (j - y) / (height - 1.0)) / 2 green = color1.green (color2.green - color1.green) * ((x width - i) / (width - 1.0) (j - y) / (height - 1.0)) / 2 blue = color1.blue (color2.blue - color1.blue) * ((x width - i) / (width - 1.0) (j - y) / (height - 1.0)) / 2 alpha = color1.alpha (color2.alpha - color1.alpha) * ((x width - i) / (width - 1.0) (j - y) / (height - 1.0)) / 2 color = Color.new(red, green, blue, alpha) set_pixel(i, j, color) end end end end end module RPG class Sprite < ::Sprite def damage(value, critical) dispose_damage if value.is_a?(Numeric) damage_string = value.abs.to_s else damage_string = value.to_s end bitmap = Bitmap.new(160, 48) bitmap.font.name = "Arial Black" bitmap.font.size = 32 bitmap.font.color.set(0, 0, 0) bitmap.draw_text(-1, 12-1, 160, 36, damage_string, 1) bitmap.draw_text( 1, 12-1, 160, 36, damage_string, 1) bitmap.draw_text(-1, 12 1, 160, 36, damage_string, 1) bitmap.draw_text( 1, 12 1, 160, 36, damage_string, 1) if value.is_a?(Numeric) and value < 0 bitmap.font.color.set(176, 255, 144) else bitmap.font.color.set(255, 255, 255) end bitmap.draw_text(0, 12, 160, 36, damage_string, 1) if critical bitmap.font.size = 20 bitmap.font.color.set(0, 0, 0) bitmap.draw_text(-1, -1, 160, 20, "CRITICAL", 1) bitmap.draw_text( 1, -1, 160, 20, "CRITICAL", 1) bitmap.draw_text(-1, 1, 160, 20, "CRITICAL", 1) bitmap.draw_text( 1, 1, 160, 20, "CRITICAL", 1) bitmap.font.color.set(255, 255, 255) bitmap.draw_text(0, 0, 160, 20, "CRITICAL", 1) end @_damage_sprite = ::Sprite.new @_damage_sprite.bitmap = bitmap @_damage_sprite.ox = 80 self.viewport.ox @_damage_sprite.oy = 20 self.viewport.oy @_damage_sprite.x = self.x self.viewport.rect.x @_damage_sprite.y = self.y - self.oy / 2 self.viewport.rect.y @_damage_sprite.z = 3000 @_damage_duration = 40 end def animation(animation, hit) dispose_animation @_animation = animation return if @_animation == nil @_animation_hit = hit @_animation_duration = @_animation.frame_max animation_name = @_animation.animation_name animation_hue = @_animation.animation_hue bitmap = RPG::Cache.animation(animation_name, animation_hue) if @@_reference_count.include?(bitmap) @@_reference_count[bitmap] = 1 else @@_reference_count[bitmap] = 1 end @_animation_sprites = [] if @_animation.position != 3 or not @@_animations.include?(animation) for i in 0..15 sprite = ::Sprite.new sprite.bitmap = bitmap sprite.visible = false @_animation_sprites.push(sprite) end unless @@_animations.include?(animation) @@_animations.push(animation) end end update_animation end def loop_animation(animation) return if animation == @_loop_animation dispose_loop_animation @_loop_animation = animation return if @_loop_animation == nil @_loop_animation_index = 0 animation_name = @_loop_animation.animation_name animation_hue = @_loop_animation.animation_hue bitmap = RPG::Cache.animation(animation_name, animation_hue) if @@_reference_count.include?(bitmap) @@_reference_count[bitmap] = 1 else @@_reference_count[bitmap] = 1 end @_loop_animation_sprites = [] for i in 0..15 sprite = ::Sprite.new sprite.bitmap = bitmap sprite.visible = false @_loop_animation_sprites.push(sprite) end update_loop_animation end def animation_set_sprites(sprites, cell_data, position) for i in 0..15 sprite = sprites pattern = cell_data[i, 0] if sprite == nil or pattern == nil or pattern == -1 sprite.visible = false if sprite != nil next end sprite.visible = true sprite.src_rect.set(pattern % 5 * 192, pattern / 5 * 192, 192, 192) if position == 3 if self.viewport != nil sprite.x = self.viewport.rect.width / 2 sprite.y = self.viewport.rect.height - 160 else sprite.x = 320 sprite.y = 240 end else sprite.x = self.x self.viewport.rect.x - self.ox self.src_rect.width / 2 sprite.y = self.y self.viewport.rect.y - self.oy self.src_rect.height / 2 sprite.y -= self.src_rect.height / 4 if position == 0 sprite.y = self.src_rect.height / 4 if position == 2 end sprite.x = cell_data[i, 1] sprite.y = cell_data[i, 2] sprite.z = 2000 sprite.ox = 96 sprite.oy = 96 sprite.zoom_x = cell_data[i, 3] / 100.0 sprite.zoom_y = cell_data[i, 3] / 100.0 sprite.angle = cell_data[i, 4] sprite.mirror = (cell_data[i, 5] == 1) sprite.opacity = cell_data[i, 6] * self.opacity / 255.0 sprite.blend_type = cell_data[i, 7] end end end end class Game_Actor < Game_Battler def screen_x if self.index != nil n_split = [($game_party.actors.length * 0.5).ceil, 4].min case n_split when 1 n_index = self.index * 2 when 2 if self.index < ($game_party.actors.length - 2) n_index = 0.5 (2 * self.index) else if $game_party.actors.length == 3 then n_index = (self.index * 2) 2 elsif $game_party.actors.length == 4 then n_index = self.index * 2 end end when 3 n_index = self.index (0.25 * (self.index 1)) if $game_party.actors.length == 5 if self.index < 2 n_index = self.index (0.25 * (self.index 1)) else n_index = self.index (0.25 * (self.index 2)) 1 end end when 4 n_index = self.index if $game_party.actors.length == 7 if self.index < 3 n_index = self.index else n_index = self.index 1 end end end return (n_index - ((n_index / 4).floor) * 4) * ((160 / (4)) / 5) 480 ((n_index / 4).floor * 60) else return 0 end end #-------------------------------------------------------------------------- # ? ????? Y ????? #-------------------------------------------------------------------------- def screen_y n_split = [($game_party.actors.length * 0.5).ceil, 4].min case n_split when 1 n_index = self.index * 2 when 2 if self.index < ($game_party.actors.length - 2) n_index = 0.5 (2 * self.index) else if $game_party.actors.length == 3 then n_index = (self.index * 2) 2 elsif $game_party.actors.length == 4 then n_index = self.index * 2 end end when 3 n_index = self.index (0.25 * (self.index 1)) if $game_party.actors.length == 5 if self.index < 2 n_index = self.index (0.25 * (self.index 1)) else n_index = self.index (0.25 * (self.index 2)) 1 end end when 4 n_index = self.index if $game_party.actors.length == 7 if self.index < 3 n_index = self.index else n_index = self.index 1 end end end return (n_index - ((n_index / 4).floor) * 4) * ((160 / (4)) * 1.6) 270 - ((n_index / 4).floor * (110 - (4 * 20))) end #-------------------------------------------------------------------------- # ? ????? Z ????? #-------------------------------------------------------------------------- def screen_z # ??????????? Z ????????? if self.index != nil return self.index else return 0 end end end class Game_Enemy < Game_Battler def screen_x n_split = [($game_troop.enemies.length * 0.5).ceil, 4].min case n_split when 1 n_index = self.index * 2 when 2 if self.index < ($game_troop.enemies.length - 2) n_index = 0.5 (2 * self.index) else if $game_troop.enemies.length == 3 then n_index = (self.index * 2) 2 elsif $game_troop.enemies.length == 4 then n_index = self.index * 2 end end when 3 n_index = self.index (0.25 * (self.index 1)) if $game_troop.enemies.length == 5 if self.index < 2 n_index = self.index (0.25 * (self.index 1)) else n_index = self.index (0.25 * (self.index 2)) 2 end end when 4 n_index = self.index if $game_troop.enemies.length == 7 if self.index < 3 n_index = self.index else n_index = self.index 1 end end end return (n_index - ((n_index / 4).floor) * 4) * ((-160 / (4)) / 5) 160 - ((n_index / 4).floor * 60) end #-------------------------------------------------------------------------- # ? ????? Y ????? #-------------------------------------------------------------------------- def screen_y n_split = [($game_troop.enemies.length * 0.5).ceil, 4].min case n_split when 1 n_index = self.index * 2 when 2 if self.index < ($game_troop.enemies.length - 2) n_index = 0.5 (2 * self.index) else if $game_troop.enemies.length == 3 then n_index = (self.index * 2) 2 elsif $game_troop.enemies.length == 4 then n_index = self.index * 2 end end when 3 n_index = self.index (0.25 * (self.index 1)) if $game_troop.enemies.length == 5 if self.index < 2 n_index = self.index (0.25 * (self.index 1)) else n_index = self.index (0.25 * (self.index 2)) 1 end end when 4 n_index = self.index if $game_troop.enemies.length == 7 if self.index < 3 n_index = self.index else n_index = self.index 1 end end end return (n_index - ((n_index / 4).floor) * 4) * ((160 / (4)) * 1.6) 270 - ((n_index / 4).floor * (110 - (4 * 20))) end #-------------------------------------------------------------------------- # ? ????? Z ????? #-------------------------------------------------------------------------- def screen_z return @member_index 1 end end #============================================================================== # ¦ Sprite_Battler #------------------------------------------------------------------------------ # ????????????????Game_Battler ??????????????? # ???????????????????? #============================================================================== class Sprite_Battler < RPG::Sprite #-------------------------------------------------------------------------- # ? ?????????? #-------------------------------------------------------------------------- attr_accessor :battler # ???? attr_accessor :moving # Is the sprite moving? attr_reader :index attr_accessor :target_index attr_accessor :direction attr_accessor :pattern #-------------------------------------------------------------------------- # ? ????????? # viewport : ?????? # battler : ???? (Game_Battler) #-------------------------------------------------------------------------- def initialize(viewport, battler = nil) super(viewport) change @old = Graphics.frame_count # For the delay method @goingup = true # Increasing animation? (if @rm2k_mode is true) @once = false # Is the animation only played once? @animated = true # Used to stop animation when @once is true self.opacity = 0 @index = 0 @pattern_b = 0 @counter_b = 0 @trans_sprite = Sprite.new @trans_sprite.opacity = 0 @bar_hp_sprite = Sprite.new @bar_hp_sprite.bitmap = Bitmap.new(64, 10) @bar_sp_sprite = Sprite.new @bar_sp_sprite.bitmap = Bitmap.new(64, 10) @color1 = Color.new(0, 0, 0, 192) @color2 = Color.new(255, 255, 192, 192) @color3 = Color.new(0, 0, 0, 192) @color4 = Color.new(64, 0, 0, 192) @old_hp = -1 @old_sp = -1 @battler = battler @battler_visible = false @first = true @pattern = 0 if $target_index == nil $target_index = 0 end @battler.is_a?(Game_Enemy) ? enemy_pose(0, 1) : pose(0, 1) end #-------------------------------------------------------------------------- # ? ?? #-------------------------------------------------------------------------- def dispose if self.bitmap != nil self.bitmap.dispose end if @trans_sprite.bitmap != nil @trans_sprite.bitmap.dispose end @trans_sprite.dispose @bar_hp_sprite.bitmap.dispose @bar_hp_sprite.dispose @bar_sp_sprite.bitmap.dispose @bar_sp_sprite.dispose super end def change(frames = 0, delay = 0, offx = 0, offy = 0, startf = 0, once = false) @frames = frames @delay = delay @offset_x, @offset_y = offx, offy @current_frame = startf @once = once @goingup = true @animated = true end #-------------------------------------------------------------------------- # ? ?????? #-------------------------------------------------------------------------- def update bar_check = true if @_damage_duration == 1 super @trans_sprite.blend_type = self.blend_type @trans_sprite.color = self.color if @_collapse_duration > 0 @trans_sprite.opacity = self.opacity else @trans_sprite.opacity = [self.opacity, 160].min end if (@_damage_duration == 0 and bar_check == true) or @first == true @first = false if @first == true bar_check = false @bar_must_change = true end @bar_hp_sprite.opacity = self.opacity @bar_sp_sprite.opacity = self.opacity # ????? nil ??? if @battler == nil self.bitmap = nil @trans_sprite.bitmap = nil loop_animation(nil) return end # ???????????????????? if @battler.battler_name != @battler_name or @battler.battler_hue != @battler_hue # ???????????? @battler_name = @battler.battler_name @battler_hue = @battler.battler_hue if @battler.is_a?(Game_Actor) @battler_name = @battler.character_name @battler_hue = @battler.character_hue @direction = 4 else @direction = 6 end self.bitmap = RPG::Cache.character(@battler_name, @battler_hue) @width = bitmap.width / 4 @height = bitmap.height / 4 @frame_width = @width @frame_height = @height self.ox = @width / 2 self.oy = @height @pattern = @current_frame @direction = @offset_y sx = @pattern * @width sy = (@direction - 2) / 2 * @height self.src_rect.set(sx, sy, @width, @height) @current_frame = (@current_frame 1) unless @frames == 0 @animated = false if @current_frame == @frames and @once @current_frame %= @frames @trans_sprite.bitmap = self.bitmap @trans_sprite.ox = self.ox @trans_sprite.oy = self.oy @trans_sprite.src_rect.set(sx, sy, @width, @height) # ?????????????????? 0 ??? if @battler.dead? or @battler.hidden self.opacity = 0 @trans_sprite.opacity = 0 @bar_hp_sprite.opacity = 0 @bar_sp_sprite.opacity = 0 end self.x = @battler.screen_x self.y = @battler.screen_y self.z = @battler.screen_z end change_sp_bar if @old_sp != @battler.sp if delay(@delay) and @animated @pattern = @current_frame @direction = @offset_y sx = @pattern * @width sy = (@direction - 2) / 2 * @height self.src_rect.set(sx, sy, @width, @height) @current_frame = (@current_frame 1) unless @frames == 0 @animated = false if @current_frame == @frames and @once @current_frame %= @frames @trans_sprite.ox = self.ox @trans_sprite.oy = self.oy @trans_sprite.src_rect.set(sx, sy, @width, @height) end # ??????? ID ???????????? if @battler.damage == nil and @battler.state_animation_id != @state_animation_id @state_animation_id = @battler.state_animation_id loop_animation($data_animations[@state_animation_id]) end # ?????????????? #if @battler.is_a?(Game_Actor) and @battler_visible # ??????????????????????? #if $game_temp.battle_main_phase #self.opacity = 3 if self.opacity < 255 #else #self.opacity -= 3 if self.opacity > 207 #end #end # ?? if @battler.blink blink_on else blink_off end # ?????? unless @battler_visible # ?? if not @battler.hidden and not @battler.dead? and (@battler.damage == nil or @battler.damage_pop) appear @battler_visible = true end end # ????? if @battler_visible # ?? if @battler.hidden $game_system.se_play($data_system.escape_se) escape @trans_sprite.opacity = 0 @battler_visible = false end # ?????? if @battler.white_flash whiten @battler.white_flash = false end # ??????? if @battler.animation_id != 0 animation = $data_animations[@battler.animation_id] animation(animation, @battler.animation_hit) @battler.animation_id = 0 end # ???? if @battler.damage_pop damage(@battler.damage, @battler.critical) @battler.damage = nil @battler.critical = false @battler.damage_pop = false end if @bar_must_change == true @bar_must_change = false if @old_hp != @battler.hp change_hp_bar end if @battler.damage == nil and @battler.dead? if @battler.is_a?(Game_Enemy) $game_system.se_play($data_system.enemy_collapse_se) else $game_system.se_play($data_system.actor_collapse_se) end collapse @battler_visible = false end end end # ??????????? @trans_sprite.x = self.x @trans_sprite.y = self.y @trans_sprite.z = self.z @bar_hp_sprite.x = @battler.screen_x - 32 @bar_hp_sprite.y = @battler.screen_y - (@height 18) if @height != nil @bar_hp_sprite.z = 100 @bar_sp_sprite.x = @battler.screen_x - 32 @bar_sp_sprite.y = @battler.screen_y - (@height 8) if @height != nil @bar_sp_sprite.z = 100 end #-------------------------------------------------------------------------- # - Move the sprite # x : X coordinate of the destination point # y : Y coordinate of the destination point # speed : Speed of movement (0 = delayed, 1 = faster) # delay : Movement delay if speed is at 0 #-------------------------------------------------------------------------- def move(x, y, speed = 1, delay = 0) @destx = x @desty = y @move_speed = speed @move_delay = delay @move_old = Graphics.frame_count @moving = true end #-------------------------------------------------------------------------- # - Move sprite to destx and desty #-------------------------------------------------------------------------- def update_move return unless @moving movinc = @move_speed == 0 ? 1 : @move_speed if Graphics.frame_count - @move_old > @move_delay or @move_speed != 0 self.x = movinc if self.x < @destx self.x -= movinc if self.x > @destx self.y = movinc if self.y < @desty self.y -= movinc if self.y > @desty @move_old = Graphics.frame_count end if @move_speed > 1 # Check if sprite can't reach that point self.x = @destx if (@destx - self.x).abs % @move_speed != 0 and (@destx - self.x).abs <= @move_speed self.y = @desty if (@desty - self.y).abs % @move_speed != 0 and (@desty - self.y).abs <= @move_speed end if self.x == @destx and self.y == @desty @moving = false end end #-------------------------------------------------------------------------- # - Pause animation, but still updates movement # frames : Number of frames #-------------------------------------------------------------------------- def delay(frames) update_move if (Graphics.frame_count - @old >= frames) @old = Graphics.frame_count return true end return false end def change_hp_bar j = false @old_hp = @battler.hp if @old_hp == -1 i = @old_hp loop do i -= 10 if i < @battler.hp i = @battler.hp j = true end rate = i.to_f / @battler.maxhp @color5 = Color.new(80 - 24 * rate, 80 * rate, 14 * rate, 192) @color6 = Color.new(240 - 72 * rate, 240 * rate, 62 * rate, 192) @bar_hp_sprite.bitmap.clear @bar_hp_sprite.bitmap.fill_rect(0, 0, 64, 10, @color1) @bar_hp_sprite.bitmap.fill_rect(1, 1, 62, 8, @color2) @bar_hp_sprite.bitmap.gradation_rect(2, 2, 60, 6, @color3, @color4, 1) #@bar_hp_sprite.bitmap.fill_rect(2, 2, 60, 6, @color3) @bar_hp_sprite.bitmap.gradation_rect(2, 2, 64 * rate - 4, 6, @color5, @color6, 2) #@bar_hp_sprite.bitmap.fill_rect(2, 2, 64 * rate - 4, 6, @color5) @bar_hp_sprite.opacity = self.opacity Graphics.update if j == true j = false break end end @old_hp = @battler.hp end def change_sp_bar j = false @old_sp = @battler.sp if @old_sp == -1 i = @old_sp loop do i -= 10 if i < @battler.sp i = @battler.sp j = true end rate = i.to_f / @battler.maxsp @color7 = Color.new(14 * rate, 80 - 24 * rate, 80 * rate, 192) @color8 = Color.new(62 * rate, 240 - 72 * rate, 240 * rate, 192) @bar_sp_sprite.bitmap.clear @bar_sp_sprite.bitmap.fill_rect(0, 0, 64, 10, @color1) @bar_sp_sprite.bitmap.fill_rect(1, 1, 62, 8, @color2) @bar_sp_sprite.bitmap.gradation_rect(2, 2, 60, 6, @color3, @color4, 1) #@bar_hp_sprite.bitmap.fill_rect(2, 2, 60, 6, @color3) @bar_sp_sprite.bitmap.gradation_rect(2, 2, 64 * rate - 4, 6, @color7, @color8, 0) #@bar_hp_sprite.bitmap.fill_rect(2, 2, 64 * rate - 4, 6, @color5) @bar_sp_sprite.opacity = self.opacity Graphics.update if j == true j = false break end end @old_sp = @battler.sp end def enemy # $target_index = $game_troop.enemies.size $target_index %= $game_troop.enemies.size return $game_troop.enemies[$target_index] # end # def actor # $target_index = $game_party.actors.size $target_index %= $game_party.actors.size return $game_party.actors[$target_index] # end def index=(index) @index = index update end def pose(number, frames = 4) case number when 0 change(frames, 4, 0, 4, 0) when 1 change(frames, 4, 0, 4) when 2 change(frames, 4, 0, 6) else change(frames, 4, 0, 0, 0) end end def enemy_pose(number ,enemy_frames = 4) case number when 0 change(enemy_frames, 4, 0, 6, 0) when 1 change(enemy_frames, 4, 0, 4) when 2 change(enemy_frames, 4, 0, 6) else change(enemy_frames, 4, 0, 0, 0) end end def default_pose pose(0, 1) end end #============================================================================== # ¦ Spriteset_Battle #------------------------------------------------------------------------------ # ???????????????????????????? Scene_Battle ?? # ???????????? #============================================================================== class Spriteset_Battle #-------------------------------------------------------------------------- # ? ?????????? #-------------------------------------------------------------------------- attr_reader :viewport1 # ???????????? attr_reader :viewport2 # ???????????? attr_accessor :actor_sprites attr_accessor :enemy_sprites #-------------------------------------------------------------------------- # ? ????????? #-------------------------------------------------------------------------- def initialize # ????????? @viewport1 = Viewport.new(0, 0, 640, 480) @viewport2 = Viewport.new(0, 0, 640, 480) @viewport3 = Viewport.new(0, 0, 640, 480) @viewport4 = Viewport.new(0, 0, 640, 480) @viewport2.z = 101 @viewport3.z = 200 @viewport4.z = 5000 if $game_temp.battleback_name == "" @battleback_sprite = nil @tilemap = Tilemap.new(@viewport1) @tilemap.tileset = RPG::Cache.tileset($game_map.tileset_name) for i in 0..6 autotile_name = $game_map.autotile_names @tilemap.autotiles = RPG::Cache.autotile(autotile_name) end @tilemap.map_data = $game_map.data @tilemap.priorities = $game_map.priorities else # ?????????????? @tilemap = nil @battleback_sprite = Sprite.new(@viewport1) end # ???????????? @enemy_sprites = [] for enemy in $game_troop.enemies#.reverse @enemy_sprites.push(Sprite_Battler.new(@viewport1, enemy)) end # ???????????? @actor_sprites = [] for j in 0..7 # %u0192A%u0192N%u0192^[%u0192X%u0192v%u0192%u2030%u0192C%u0192g%u201Að%u2019Ç%u2030Á @actor_sprites.push(Sprite_Battler.new(@viewport1, $game_party.actors[j])) end # ????? @weather = RPG::Weather.new(@viewport1) # ???????????? @picture_sprites = [] for i in 51..100 @picture_sprites.push(Sprite_Picture.new(@viewport3, $game_screen.pictures)) end # ???????????? @timer_sprite = Sprite_Timer.new # ?????? update end #-------------------------------------------------------------------------- # ? ?? #-------------------------------------------------------------------------- def dispose if @tilemap != nil # ????????? @tilemap.tileset.dispose for i in 0..6 @tilemap.autotiles.dispose end @tilemap.dispose end # ?????????????? if @battleback_sprite != nil # ?????????????????????? if @battleback_sprite.bitmap != nil @battleback_sprite.bitmap.dispose end @battleback_sprite.dispose end # ?????????????????????? for sprite in @enemy_sprites @actor_sprites sprite.dispose end # ????? @weather.dispose # ???????????? for sprite in @picture_sprites sprite.dispose end # ???????????? @timer_sprite.dispose # ????????? @viewport1.dispose @viewport2.dispose @viewport3.dispose @viewport4.dispose end #-------------------------------------------------------------------------- # ? ?????????? #-------------------------------------------------------------------------- def effect? # ??????????????? true ??? for sprite in @enemy_sprites @actor_sprites return true if sprite.effect? end return false end #-------------------------------------------------------------------------- # ? ?????? #-------------------------------------------------------------------------- def update # ??????????????????????? if @battleback_sprite != nil if @battleback_name != $game_temp.battleback_name @battleback_name = $game_temp.battleback_name if @battleback_sprite.bitmap != nil @battleback_sprite.bitmap.dispose end bg_bitmap = RPG::Cache.battleback(@battleback_name) bg_bitmap_stretch = Bitmap.new(640, 480) bg_bitmap_stretch.stretch_blt(Rect.new(0, 0, 640, 480), bg_bitmap, bg_bitmap.rect) @battleback_sprite.bitmap = bg_bitmap_stretch end end if @tilemap != nil @tilemap.ox = $game_map.display_x / 4 @tilemap.oy = $game_map.display_y / 4 @tilemap.update end # ???????????? for sprite in @enemy_sprites @actor_sprites sprite.update end # ??????????? @weather.type = $game_screen.weather_type @weather.max = $game_screen.weather_max @weather.update # ???????????? for sprite in @picture_sprites sprite.update end # ???????????? @timer_sprite.update # ??????????????? @viewport1.tone = $game_screen.tone @viewport1.ox = $game_screen.shake # ???????????? @viewport4.color = $game_screen.flash_color # ????????? @viewport1.update @viewport2.update @viewport4.update end end #============================================================================== # ¦ Window_Command #------------------------------------------------------------------------------ # ????????????????????? #============================================================================== class Window_Command < Window_Selectable #-------------------------------------------------------------------------- # ? ????????? # width : ??????? # commands : ?????????? #-------------------------------------------------------------------------- def initialize(width, commands, column_max = 1, style = 0, inf_scroll = 1) # ???????????????????? super(0, 0, width, (commands.size * 1.0 / column_max).ceil * 32 32) @inf_scroll = inf_scroll @item_max = commands.size @commands = commands @column_max = column_max @style = style self.contents = Bitmap.new(width - 32, (@item_max * 1.0 / @column_max).ceil * 32) self.contents.font.name = "Tahoma" self.contents.font.size = 22 refresh self.index = 0 end #-------------------------------------------------------------------------- # ? ?????? #-------------------------------------------------------------------------- def refresh self.contents.clear for i in 0...@item_max draw_item(i, normal_color) end end #-------------------------------------------------------------------------- # ? ????? # index : ???? # color : ??? #-------------------------------------------------------------------------- def draw_item(index, color) self.contents.font.color = color rect = Rect.new(index%@column_max * (self.width / @column_max) 4, 32 * (index/@column_max), self.width / @column_max - 40, 32) self.contents.fill_rect(rect, Color.new(0, 0, 0, 0)) self.contents.draw_text(rect, @commands[index], @style) end #-------------------------------------------------------------------------- # ? ?????? # index : ???? #-------------------------------------------------------------------------- def disable_item(index) draw_item(index, disabled_color) end def update_help @help_window.set_actor($game_party.actors[$scene.actor_index]) end end #============================================================================== # ¦ Arrow_Enemy #------------------------------------------------------------------------------ # ????????????????????????????? Arrow_Base ?? # ???????? #============================================================================== class Arrow_Enemy < Arrow_Base #-------------------------------------------------------------------------- # ? ????????????????? #-------------------------------------------------------------------------- def enemy return $game_troop.enemies[@index] end #-------------------------------------------------------------------------- # ? ?????? #-------------------------------------------------------------------------- def update super # ??????????????????? $game_troop.enemies.size.times do break if self.enemy.exist? @index = 1 @index %= $game_troop.enemies.size end # ????? if Input.repeat?(Input::DOWN) $game_system.se_play($data_system.cursor_se) $game_troop.enemies.size.times do @index = 1 @index %= $game_troop.enemies.size break if self.enemy.exist? end end # ????? if Input.repeat?(Input::UP) $game_system.se_play($data_system.cursor_se) $game_troop.enemies.size.times do @index = $game_troop.enemies.size - 1 @index %= $game_troop.enemies.size break if self.enemy.exist? end end if Input.repeat?(Input::RIGHT) $game_system.se_play($data_system.cursor_se) $game_troop.enemies.size.times do @index = ((($game_troop.enemies.length) * 0.5).ceil) @index %= $game_troop.enemies.size break if self.enemy.exist? end end if Input.repeat?(Input::LEFT) $game_system.se_play($data_system.cursor_se) $game_troop.enemies.size.times do @index = $game_troop.enemies.size - ((($game_troop.enemies.length) * 0.5).ceil) @index %= $game_troop.enemies.size break if self.enemy.exist? end end # ??????????? if self.enemy != nil self.x = self.enemy.screen_x 4 self.y = self.enemy.screen_y 36 self.z = self.enemy.screen_z 1 end end #-------------------------------------------------------------------------- # ? ????????? #-------------------------------------------------------------------------- def update_help # ???????????????????????? @help_window.set_enemy(self.enemy) end end #============================================================================== # ¦ Arrow_Actor #------------------------------------------------------------------------------ # ????????????????????????????? Arrow_Base ?? # ???????? #============================================================================== class Arrow_Actor < Arrow_Base #-------------------------------------------------------------------------- # ? ????????????????? #-------------------------------------------------------------------------- def actor return $game_party.actors[@index] end #-------------------------------------------------------------------------- # ? ?????? #-------------------------------------------------------------------------- def update super # ????? if Input.repeat?(Input::DOWN) $game_system.se_play($data_system.cursor_se) @index = 1 @index %= $game_party.actors.size end # ????? if Input.repeat?(Input::UP) $game_system.se_play($data_system.cursor_se) @index = $game_party.actors.size - 1 @index %= $game_party.actors.size end if Input.repeat?(Input::RIGHT) $game_system.se_play($data_system.cursor_se) @index = ($game_party.actors.length * 0.5).ceil @index %= $game_party.actors.size end # ????? if Input.repeat?(Input::LEFT) $game_system.se_play($data_system.cursor_se) @index = $game_party.actors.size - (($game_party.actors.length * 0.5).ceil) @index %= $game_party.actors.size end # ??????????? if self.actor != nil self.x = self.actor.screen_x self.y = self.actor.screen_y 36 self.z = self.actor.screen_z 1 end end #-------------------------------------------------------------------------- # ? ????????? #-------------------------------------------------------------------------- def update_help # ?????????????????????? @help_window.set_actor(self.actor) end end class Scene_Battle attr_accessor :actor_index def main # ??????????????? $game_temp.in_battle = true $game_temp.battle_turn = 0 $game_temp.battle_event_flags.clear $game_temp.battle_abort = false $game_temp.battle_main_phase = false $game_temp.battleback_name = $game_map.battleback_name $game_temp.forcing_battler = nil # ?????????????????? $game_system.battle_interpreter.setup(nil, 0) # ??????? @troop_id = $game_temp.battle_troop_id $game_troop.setup(@troop_id) # ???????????????? s1 = $data_system.words.attack s1 = $data_system.words.attack s2 = $data_system.words.skill s3 = $data_system.words.guard s4 = $data_system.words.item @actor_command_window = Window_Command.new(640, [s1, s2, s3, s4], 4) @actor_command_window.y = 64 @actor_command_window.back_opacity = 160 @actor_command_window.active = false @actor_command_window.visible = false # ???????????? @party_command_window = Window_PartyCommand.new @help_window = Window_Help.new @help_window.back_opacity = 160 @help_window.visible = false #@status_window = Window_BattleStatus.new @message_window = Window_Message.new # ??????????? @spriteset = Spriteset_Battle.new # ???????????? @wait_count = 0 # ????????? if $data_system.battle_transition == "" Graphics.transition(20) else Graphics.transition(40, "Graphics/Transitions/" $data_system.battle_transition) end # ??????????? start_phase1 # ?????? loop do # ???????? Graphics.update # ??????? Input.update # ?????? update # ???????????????? if $scene != self break end end # ?????????? $game_map.refresh # ????????? Graphics.freeze # ???????? @actor_command_window.dispose @party_command_window.dispose @help_window.dispose #@status_window.dispose @message_window.dispose if @skill_window != nil @skill_window.dispose end if @item_window != nil @item_window.dispose end if @result_window != nil @result_window.dispose end # ??????????? @spriteset.dispose # ??????????????? if $scene.is_a?(Scene_Title) # ?????????? Graphics.transition Graphics.freeze end # ??????????????????????????? if $BTEST and not $scene.is_a?(Scene_Gameover) $scene = nil end end def update # ????????????? if $game_system.battle_interpreter.running? # ????????? $game_system.battle_interpreter.update # ????????????????????????? if $game_temp.forcing_battler == nil # ????????????????? unless $game_system.battle_interpreter.running? # ?????????????????????????? unless judge setup_battle_event end end # ???????????????? if @phase != 5 # ????????????????? #@status_window.refresh end end end # ???? (????)?????? $game_system.update $game_screen.update # ????? 0 ?????? if $game_system.timer_working and $game_system.timer == 0 # ????? $game_temp.battle_abort = true end # ???????? @help_window.update @party_command_window.update @actor_command_window.update #@status_window.update @message_window.update # ??????????? @spriteset.update # ????????????? if $game_temp.transition_processing # ????????????????? $game_temp.transition_processing = false # ????????? if $game_temp.transition_name == "" Graphics.transition(20) else Graphics.transition(40, "Graphics/Transitions/" $game_temp.transition_name) end end # ???????????????? if $game_temp.message_window_showing return end # ??????????? if @spriteset.effect? return end # ?????????? if $game_temp.gameover # ?????????????? $scene = Scene_Gameover.new return end # ??????????? if $game_temp.to_title # ??????????? $scene = Scene_Title.new return end # ???????? if $game_temp.battle_abort # ??????? BGM ??? $game_system.bgm_play($game_temp.map_bgm) # ????? battle_end(1) return end # ???????? if @wait_count > 0 # ???????????? @wait_count -= 1 return end # this one holds the battle while the player moves for actor in @spriteset.actor_sprites if actor.moving return end end # and this one is for the enemy... for enemy in @spriteset.enemy_sprites if enemy.moving# and $game_system.animated_enemy return end end # ??????????????????????? # ???????????????? if $game_temp.forcing_battler == nil and $game_system.battle_interpreter.running? return end # ?????????? case @phase when 1 # ????????? update_phase1 when 2 # ???????????? update_phase2 when 3 # ???????????? update_phase3 when 4 # ??????? update_phase4 when 5 # ??????????? update_phase5 end end def start_phase2 # ???? 2 ??? @phase = 2 # ????????????? @actor_index = -1 @active_battler = nil # ????????????????? @party_command_window.active = true @party_command_window.visible = true # ????????????????? @actor_command_window.active = false @actor_command_window.visible = false @help_window.visible = false # ?????????????? $game_temp.battle_main_phase = false # ???????????????? $game_party.clear_actions # ???????????? unless $game_party.inputable? # ????????? start_phase4 end end def update_phase2_escape # ?????????????? enemies_agi = 0 enemies_number = 0 for enemy in $game_troop.enemies if enemy.exist? enemies_agi = enemy.agi enemies_number = 1 end end if enemies_number > 0 enemies_agi /= enemies_number end # ?????????????? actors_agi = 0 actors_number = 0 for actor in $game_party.actors if actor.exist? actors_agi = actor.agi actors_number = 1 end end if actors_number > 0 actors_agi /= actors_number end # ?????? success = rand(100) < 50 * actors_agi / enemies_agi # ??????? if success # ?? SE ??? $game_system.se_play($data_system.escape_se) for actor in $game_party.actors @spriteset.actor_sprites[actor.index].pose(2) @spriteset.actor_sprites[actor.index].move(660, actor.screen_y, 10) end check = escape_move until check == false @spriteset.update Graphics.update check = escape_move end # ??????? BGM ??? $game_system.bgm_play($game_temp.map_bgm) # ????? battle_end(1) # ??????? else # ???????????????? $game_party.clear_actions # ????????? start_phase4 end end def escape_move for actor in @spriteset.actor_sprites if actor.moving return true end end return false end def start_phase5 # ???? 5 ??? @phase = 5 # ????? ME ??? $game_system.me_play($game_system.battle_end_me) # ??????? BGM ??? $game_system.bgm_play($game_temp.map_bgm) # EXP??????????????? exp = 0 gold = 0 treasures = [] # ??? for enemy in $game_troop.enemies # ?????????????? unless enemy.hidden # ?? EXP???????? exp = enemy.exp gold = enemy.gold # ????????? if rand(100) < enemy.treasure_prob if enemy.item_id > 0 treasures.push($data_items[enemy.item_id]) end if enemy.weapon_id > 0 treasures.push($data_weapons[enemy.weapon_id]) end if enemy.armor_id > 0 treasures.push($data_armors[enemy.armor_id]) end end end end # ???????? 6 ?????? treasures = treasures[0..5] # EXP ?? for i in 0...$game_party.actors.size actor = $game_party.actors if actor.cant_get_exp? == false last_level = actor.level actor.exp = exp if actor.level > last_level #@status_window.level_up(i) end end end # ?????? $game_party.gain_gold(gold) # ??????? for item in treasures case item when RPG::Item $game_party.gain_item(item.id, 1) when RPG::Weapon $game_party.gain_weapon(item.id, 1) when RPG::Armor $game_party.gain_armor(item.id, 1) end end # ??????????????? @result_window = Window_BattleResult.new(exp, gold, treasures) # ??????????? @phase5_wait_count = 100 end #-------------------------------------------------------------------------- # ? ?????? (???????????) #-------------------------------------------------------------------------- def update_phase5 # ????????? 0 ??????? if @phase5_wait_count > 0 # ???????????? @phase5_wait_count -= 1 # ????????? 0 ?????? if @phase5_wait_count == 0 # ???????????? @result_window.visible = true # ?????????????? $game_temp.battle_main_phase = false # ????????????????? #@status_window.refresh end return end # C ?????????? if Input.trigger?(Input::C) # ????? battle_end(0) end end def phase3_setup_command_window # ????????????????? @party_command_window.active = false @party_command_window.visible = false # ????????????????? @actor_command_window.active = true @actor_command_window.visible = true @help_window.visible = true # ??????????????????? if @actor_command_window.help_window == nil @actor_command_window.help_window = @help_window end @actor_command_window.update_help #@actor_command_window.x = @actor_index * 160 # ??????? 0 ??? @actor_command_window.index = 0 end def start_enemy_select # ?????????? @enemy_arrow = Arrow_Enemy.new(@spriteset.viewport2) # ????????????? @enemy_arrow.help_window = @help_window # ????????????????? @actor_command_window.active = false @actor_command_window.visible = false end def update_phase4 case @phase4_step when 1 update_phase4_step1 when 2 update_phase4_step2 when 3 update_phase4_step3 when 4 update_phase4_step4 when 5 update_phase4_step5 when 6 update_phase4_step6 when 7 update_phase4_step7 end end def update_phase4_step1 # Change actor poses to default #if @active_battler.is_a?(Game_Actor) # @spriteset.actor_sprites[@active_battler.index].default_pose #end for i in 0...$game_party.actors.size actor = $game_party.actors @spriteset.actor_sprites.default_pose end @help_window.visible = false if judge return end if $game_temp.forcing_battler == nil setup_battle_event if $game_system.battle_interpreter.running? return end end if $game_temp.forcing_battler != nil @action_battlers.delete($game_temp.forcing_battler) @action_battlers.unshift($game_temp.forcing_battler) end if @action_battlers.size == 0 start_phase2 return end @animation1_id = 0 @animation2_id = 0 @common_event_id = 0 @active_battler = @action_battlers.shift if @active_battler.index == nil return end if @active_battler.hp > 0 and @active_battler.slip_damage? @active_battler.slip_damage_effect @active_battler.damage_pop = true end @active_battler.remove_states_auto #@status_window.refresh @phase4_step = 2 end def make_basic_action_result if @active_battler.is_a?(Game_Actor) $actor_on_top = true elsif @active_battler.is_a?(Game_Enemy) $actor_on_top = false end if @active_battler.current_action.basic == 0 @animation1_id = @active_battler.animation1_id @animation2_id = @active_battler.animation2_id if @active_battler.is_a?(Game_Enemy) if @active_battler.restriction == 3 target = $game_troop.random_target_enemy elsif @active_battler.restriction == 2 target = $game_party.random_target_actor else index = @active_battler.current_action.target_index target = $game_party.smooth_target_actor(index) end #======== here is the setting for the movement & animation... x = target.screen_x - 32 @spriteset.enemy_sprites[@active_battler.index].enemy_pose(2) @spriteset.enemy_sprites[@active_battler.index].move(x, target.screen_y, 10) #========= here if you look at the RPG's movement settings you'll see #========= that he takes the number 40 for the speed of the animation... #========= i thing thats too fast so i settet it down to 10 so looks smoother... end if @active_battler.is_a?(Game_Actor) weapon = $data_weapons[@active_battler.weapon_id] range = false if weapon != nil for id in weapon.element_set if $data_system.elements[23] == "Range" range = true break end end end if @active_battler.restriction == 3 target = $game_party.random_target_actor elsif @active_battler.restriction == 2 target = $game_troop.random_target_enemy else index = @active_battler.current_action.target_index target = $game_troop.smooth_target_enemy(index) end #======= the same thing for the player... ^-^ x = target.screen_x 32 @spriteset.actor_sprites[@active_battler.index].pose(1) @spriteset.actor_sprites[@active_battler.index].move(x * (range ? 2 : 1), target.screen_y, 10) range = false end @target_battlers = [target] for target in @target_battlers target.attack_effect(@active_battler) end return end if @active_battler.current_action.basic == 1 if @active_battler.is_a?(Game_Actor) @spriteset.actor_sprites[@active_battler.index].pose(0, 1) #defence else @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0, 1) #defence end @help_window.set_text($data_system.words.guard, 1) return end if @active_battler.is_a?(Game_Enemy) and @active_battler.current_action.basic == 2 @help_window.set_text("Escape", 1) @active_battler.escape return end if @active_battler.current_action.basic == 3 $game_temp.forcing_battler = nil @phase4_step = 1 return end if @active_battler.current_action.basic == 4 if $game_temp.battle_can_escape == false $game_system.se_play($data_system.buzzer_se) return end $game_system.se_play($data_system.decision_se) update_phase2_escape return end end def make_skill_action_result @skill = $data_skills[@active_battler.current_action.skill_id] unless @active_battler.current_action.forcing unless @active_battler.skill_can_use?(@skill.id) $game_temp.forcing_battler = nil @phase4_step = 1 return end end @active_battler.sp -= @skill.sp_cost #@status_window.refresh @help_window.set_text(@skill.name, 1) @animation1_id = @skill.animation1_id @animation2_id = @skill.animation2_id if @active_battler.is_a?(Game_Enemy) #@spriteset.enemy_sprites[@active_battler.index].change_sp_bar x = @active_battler.screen_x 48 @spriteset.enemy_sprites[@active_battler.index].enemy_pose(2) @spriteset.enemy_sprites[@active_battler.index].move(x, @active_battler.screen_y, 5) @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0, 1) end if @active_battler.is_a?(Game_Actor) #@spriteset.actor_sprites[@active_battler.index].change_sp_bar x = @active_battler.screen_x - 48 @spriteset.actor_sprites[@active_battler.index].pose(1) @spriteset.actor_sprites[@active_battler.index].move(x, @active_battler.screen_y, 5) @spriteset.actor_sprites[@active_battler.index].pose(0, 1) end @common_event_id = @skill.common_event_id set_target_battlers(@skill.scope) for target in @target_battlers target.skill_effect(@active_battler, @skill) end end def make_item_action_result # sorry i didnt work on this... # couse i dont have a sprite that uses items.... # so i just added the standby sprite here... # when i get more time for this i'll try what i can do for this one... ^-^ # its the same as the ones above... if @active_battler.is_a?(Game_Actor) @spriteset.actor_sprites[@active_battler.index].pose(0, 1) else @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0, 1) end @item = $data_items[@active_battler.current_action.item_id] unless $game_party.item_can_use?(@item.id) @phase4_step = 1 return end if @item.consumable $game_party.lose_item(@item.id, 1) end @help_window.set_text(@item.name, 1) @animation1_id = @item.animation1_id @animation2_id = @item.animation2_id @common_event_id = @item.common_event_id index = @active_battler.current_action.target_index target = $game_party.smooth_target_actor(index) set_target_battlers(@item.scope) for target in @target_battlers target.item_effect(@item) end end def update_phase4_step3 if @active_battler.current_action.kind == 0 and @active_battler.current_action.basic == 0 # in this one... we have our weapon animations... for player and monster if @active_battler.is_a?(Game_Actor) @spriteset.actor_sprites[@active_battler.index].pose(0,1) elsif @active_battler.is_a?(Game_Enemy) @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0,1) end end if @animation1_id == 1 @active_battler.white_flash = true else @active_battler.animation_id = @animation1_id @active_battler.animation_hit = true end @phase4_step = 4 end def update_phase4_step4 # this here is for the hit animation... for target in @target_battlers target.animation_id = @animation2_id target.animation_hit = (target.damage != "Miss") end @wait_count = 8 @phase4_step = 5 end def update_phase4_step5 if @active_battler.hp > 0 and @active_battler.slip_damage? @active_battler.slip_damage_effect @active_battler.damage_pop = true end # ??????????? @help_window.visible = false # ????????????????? #@status_window.refresh # ?????? if @active_battler.is_a?(Game_Actor) @spriteset.actor_sprites[@active_battler.index].pose(0, 1) else @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0, 1) end for target in @target_battlers if target.damage != nil target.damage_pop = true if @active_battler.is_a?(Game_Actor) @spriteset.actor_sprites[@active_battler.index].pose(0, 1) else @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0, 1) end end end # ???? 6 ??? @phase4_step = 6 end def update_phase4_step6 # here we are asking if the player is dead and is a player or an enemy... # these lines are for the running back and standby animation.... if @active_battler.is_a?(Game_Actor) if @active_battler.current_action.basic == 1 @spriteset.actor_sprites[@active_battler.index].pose(0, 1) else @spriteset.actor_sprites[@active_battler.index].move(@active_battler.screen_x, @active_battler.screen_y, 20) @spriteset.actor_sprites[@active_battler.index].pose(2) end else if @active_battler.current_action.basic == 1 @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0, 1) else @spriteset.enemy_sprites[@active_battler.index].move(@active_battler.screen_x, @active_battler.screen_y, 20) @spriteset.enemy_sprites[@active_battler.index].enemy_pose(1) end end for target in @target_battlers if target.is_a?(Game_Actor) @spriteset.actor_sprites[target.index].pose(0, 1) else @spriteset.enemy_sprites[target.index].enemy_pose(0, 1) end end $game_temp.forcing_battler = nil if @common_event_id > 0 common_event = $data_common_events[@common_event_id] $game_system.battle_interpreter.setup(common_event.list, 0) end @phase4_step = 7 end def update_phase4_step7 # here we are asking if the player is dead and is a player or an enemy... # these lines are for the running back and standby animation.... if @active_battler.is_a?(Game_Actor) @spriteset.actor_sprites[@active_battler.index].pose(0, 1) else @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0, 1) end $game_temp.forcing_battler = nil if @common_event_id > 0 common_event = $data_common_events[@common_event_id] $game_system.battle_interpreter.setup(common_event.list, 0) end @phase4_step = 1 end end |
zum Lesen den Text mit der Maus markieren
Benutzerinformationen überspringen
Motto: wenn du fragen hast dann frag, versuche aber so zu fragen, dass man dich versteht.
WOW, 1937 zeilen und nicht eine eingerückt...
@Taxidriver : kleiner Tipp für die zukunft, bitte immer die codes eingerückt posten, speziell wenn sie so lang sind. (bei so einer länge würde ich sogar noch zum splitten tendieren). es giebt näm. sehr viele hier, die dir gerne helfen, aber das wird keiner tun so lange du gewisse regeln nicht beachtest
denn codes sollte man immer eingerückt posten, da man den scriptern, die sowiso bei der länge viel arbeit haben, das ganze enorm erleichtert, hier ein bsp.:
aber ich kann dich beruhigen, das machen fast alle am anfang falsch beim posten ^^
gruß agenty
@Taxidriver : kleiner Tipp für die zukunft, bitte immer die codes eingerückt posten, speziell wenn sie so lang sind. (bei so einer länge würde ich sogar noch zum splitten tendieren). es giebt näm. sehr viele hier, die dir gerne helfen, aber das wird keiner tun so lange du gewisse regeln nicht beachtest
denn codes sollte man immer eingerückt posten, da man den scriptern, die sowiso bei der länge viel arbeit haben, das ganze enorm erleichtert, hier ein bsp.:aber ich kann dich beruhigen, das machen fast alle am anfang falsch beim posten ^^
gruß agenty
Du sollst deinen richtig langen, ellenlangen, ultralangen post der diesen Thread hier richtig streckt so dass man ewig scrollen muss, in Spoiler-Tags einpacken ^^"
Per klick auf "Bearbeiten" kannst du alte Posts von dir editieren.
Schneller laden sich die Balken auf, wenn die Kämpfer eine höhere AGI haben.
Per klick auf "Bearbeiten" kannst du alte Posts von dir editieren.
Schneller laden sich die Balken auf, wenn die Kämpfer eine höhere AGI haben.
Benutzerinformationen überspringen
Motto: wenn du fragen hast dann frag, versuche aber so zu fragen, dass man dich versteht.
Das kapiere Ich nicht ganz...
das mit dem einrücken is doch ganz einfach bei codes..
wenn du irgendwo einen teil des codes hast, der auf end endet dann rückst du alles, was sich darin befindet um zwei leerzeichen ein..
wie hier im beispielcode gezeigt wird ein code nach seinen elmenten eingerückt. in dem fall steht die klasse ganz außen, sie enthällt eine methode, die um 2 eingerückt ist folglich ist der algorythmus der methode insgesammt um 4 eingerückt. dieser wiederum enthällt eine if-condition, die bei erfüllen (hier: abfrage ob @var = 1 den wert true zurückgibt) ihren "eigenen" algorythmus "abspielt", welcher natürlich im code dann wieder eingerückt ist (insgesammt folglich also um 6 leerzeichen).
auf diese weise solltest du codes posten, sonst sind sie zu unübersichtlich. was manchmal auch recht praktisch ist, wenn man bei so langen codes mehrere spoiler mit codes anfertigt, also z.B., wenn man sich überhaupt auskennt mit rgss/ruby, die klassen nach ihrem sinn im code ordnet und für jedes gebiet einen spoiler macht und den entsprechend benennt. das erwartet aber keiner von dir, schön wäre es trotzdem wenn du dich so weit mit rgss beschäftigst, bist du die klassen erkennst und einfach da dann nach länge unterteilst und splittest. es kommt nämlich meistens weniger gut an, wenn man hilfe will, sich aber nichtmal die mühe gemacht hat, sich mit den grundlagen zu beschäftigen. jetz mal nur meine meinung, denn ich weis nicht wie die anderen dazu stehn: ich finde man sollte zumindest die rgss tuts gemacht haben bevor man in rgss probleme/talk postet, denn das erleichtert den scriptern ihre arbeit ziemlich ^^
sry an alle wegen diesem off-topic post aber da war meiner meinung nach n bisschen erklärungsbedarf da ^^
gruß agenty
Ich kann es leider nicht testen, da dem Script anscheinend mehrere Zeichen verlohren gegangen sind, aber teste mal was passiert wenn du in der Methode 'change_hp_bar' (hier Zeile 708 ) mal den i-Wert veränderst, ob dich das weiterbringt.
Das große Scientia Wiki zur Spielentwicklung 
Was ist das RGSS ? RGSS-Dokumentation auf Sc
Kyoshiros Makerkurs
Musik von Shabraxxx für euch
Guide zu den Audioformaten
Skripte von mir (Auswahl):
Atmungssystem
| Streichholzsystem
| Animiert durch Bücher blättern
Random : Marktsystem für Kardor
| Staterelated Battlergraphic
| Hinweis auf mögliche Aktionen
SelfSwitchExpirationtimer Skript - Gameplayerweiterung für Pilzesammler und Farmspiele
Meine Skripte werden gerade hier gesammelt.

Was ist das RGSS ? RGSS-Dokumentation auf Sc
Kyoshiros Makerkurs

Musik von Shabraxxx für euch
Guide zu den Audioformaten

Skripte von mir (Auswahl):
Atmungssystem
| Streichholzsystem
| Animiert durch Bücher blättern
Random : Marktsystem für Kardor
| Staterelated Battlergraphic
| Hinweis auf mögliche Aktionen
SelfSwitchExpirationtimer Skript - Gameplayerweiterung für Pilzesammler und Farmspiele
Meine Skripte werden gerade hier gesammelt.Benutzerinformationen überspringen
Motto: wenn du fragen hast dann frag, versuche aber so zu fragen, dass man dich versteht.
Sorg einfach dafür, dass deine Helden in der Database einen höheren Wert in Geschwindigkeit haben... das meinte ich ^^"
ich glaub das ist nicht das, was er sucht. ich denke ihm ist die reaktionsgeschwindigkeit des hud von dem ks zu langsam. wenn ich das richtig sehe will er ne möglichkeit das script so zu verändern, dass das hud schneller reagiert...
@taxidriver: so lange du den code nicht einrückst kann ich damit nur herzlich wenig anfangen, denn es wäre mir ehrlich gestanden zu mühsam das ganze so wie´s is durchzukauen... es giebt viele mögliche gründe für das zögerliche verhalten des huds, aber ich denke dass es entweder an der performance des scripts als solches liegt, woran man nichts ändern könnte, da man ja dann gleich das ganze script neu schreiben könnte/müsste, oder aber die für den balkenrückgang verantwortliche methode einfach an der falschen stelle aufgerufen wird, was man wie gesagt erst gut erkennen kann wenn der code richtig eingerückt ist, also tu uns doch bitte den gefallen und mach dir die mühe und rück den code ein, dann können wir mal anständig drüber schaun.
gruß agenty
Mir kam jetzt nur Playm's Idee...
Aber was ist da weiter unten passiert?! o__O" Da sind ja hunderte Zeilen schwarz o__O" Nix gegen Schwarz, aber in diesem Zusammenhang stört's!
Ach und falls i-wann ein Admin reinschaut: Der Zeilenzähler ist immernoch enorm ungenau!
Ach und falls i-wann ein Admin reinschaut: Der Zeilenzähler ist immernoch enorm ungenau!
-
Werbung -
1plus3
-
Nuuuhminaaah
-
compétences(Dieser Tab ist rein satirisch.)mes compétences
max.
Maps machen
Musik machen
Scripts machen
Story ausdenken
Pixeln und so
Events proggen
-
mes projets-
Silentium
Name: Silentium
Maker: Eigenbau (C++, x86-SSE/AVX-Assembly, Ruby/Lua)
Story
NPCs
Scripts
Ressis
Maps
Gesamt(3+4)% 42 69% 0815 -17.438 103.38% ± 6.3mm²
(Die Tabelle erfüllt lediglich satirische Zwecke.) -
OnyxEine in C++ implementierte, modulare, plattformunabhängige, virtuelle Maschine. Die Test-Version ist bereits halb fertig. Ab dann gibt es vielleicht mehr Infos. Sie soll die auf dem ersten Blick LISP-artige und eigens dafür konstruierte Sprache Obsidian ausführen können. Experimentell wird auch ein Lua-Compiler für Onyx gebaut. Ziel ist eine leistungsfähige, virtuelle Maschine für beliebige Scriptsprachen. Theoretisch gesehen müsste man bloß noch einen kompatiblen Compiler schreiben, der Quellcode jener Sprache in Onyx-Assembly, oder direkt in Onyx-Bytecode übersetzt. Ob die jemand nutzen wird, ist eine andere Frage und nur ein sekundäres... nein, eher tertiäres Ziel dieser VM. Primär dient es mir lediglich dazu, mein Verständnis von Hardware, ISA, und Assembly zu vertiefen, sowie eigene Grenzen auszutesten.
Warnung!
Das Entwickeln einer virtuellen Maschine oder Programmiersprache (im wahnsinnigsten Fall beides) ist eine höchst komplizierte Tätigkeit, aus der viel Frust und Hirnmatsche hervor gehen. Sollte sich dennoch ein ähnlich wahnsinniger finden, der sowas zusammen schustern will, so lege ich ihm/ihr die folgenden Bücher ans Herz:- Compiler - Das Drachenbuch [978-3-8273-7097-6]
Dieses Buch schlachtet ausführlich und leicht verständlich die Grundlagen bis hoch zu den Experten-Techniken des Compilerbaus aus. Es fängt mit der Automaten-Theorie und formalen Sprachen an, arbeitet sich durch Analysetechniken vor, und landet schließlich bei Techniken wie Optimierung und Register-Zuweisung. Das Buch wiegt 3Kg oder 4Kg. Hab's mal gewogen. Ist also nicht gerade die Lektüre für unterwegs.
- Computerarchitektur [3-8273-7016-7]
Hier werden leicht verständlich die wichtigsten Entwicklungen der Rechnerarchitekturen erklärt (Gut, das Buch ist in die Jahre gekommen, aber der Weg zu heute ist ein winziger Schritt, den man sich nach diesem Buch selbst erdenken kann). Hauptbestandteil des Buchs ist eine relativ umfassende Betrachtung der Funktionsweise dreier gänzlich unterschiedlicher, aber dominierender Prozessor-Typen am Beispiel des Pentium II, UltraSPARC II, sowie picoJava. Die meisten Elemente dieses Buchs sind zwar für die Konstruktion einer virtuellen Maschine irrelevant, oder aufgrund der Tatsache, dass die VM Software ist und z.B. Byte-Grenzen hat, sogar zu Leistungseinbußen führen kann, doch ist ein hinreichendes Verständnis dieser Maschinen, mit denen wir arbeiten, äußerst hilfreich für die Überlegungen, wie die VM arbeiten soll.
Es kann sehr hilfreich und inspirierend sein, den Code quelloffener, virtueller Maschinen anderer Sprachen zu überfliegen. Meine Lieblings-Quelle war und ist stets die VM von Lua. Sie ist schlank, verständlich, in C implementiert, und basiert im Gegensatz zu vielen anderen Scriptsprachen-VMs auf einer Register-Maschine statt einer Stapelmaschine. Es wäre natürlich vorteilhaft, die entsprechende Sprache zu verstehen, in der man auch die eigene VM implementieren will. Weiterhin ist es äußerst vorteilhaft, eine leistungsstarke und bequeme Sprache wie C++ zu beherrschen, um die VM zu implementieren. Und bevor irgendwer auf die Idee kommt: Assembly ist NICHT als dominierende Sprache für den Bau einer VM geeignet. Wer die Frage des "Warum?" nicht beantworten kann, sollte zunächst die gewählte Sprache und Assembly hinreichend verstehen lernen, und es dann erneut mit der Frage versuchen. Es lohnt sich dennoch, Assembly zu lernen. Allein schon, um erneut das Verständnis zu vertiefen, zumal ihr mehr oder weniger gezwungen seid, auch für eure VM eine Assembler-Sprache zu entwickeln (Außer natürlich ihr schreibt eure Test-Programme Bit für Bit ;3). - Compiler - Das Drachenbuch [978-3-8273-7097-6]
-
-
enfinJe ne peux pas parler français.
C'est tout ce que Goodle et les restes de cours de français.
Nun bei mir ist das selbe einige Zeilen sind einfach komplett schwarz...Mir kam jetzt nur Playm's Idee...
Aber was ist da weiter unten passiert?! o__O" Da sind ja hunderte Zeilen schwarz o__O" Nix gegen Schwarz, aber in diesem Zusammenhang stört's!
Ach und falls i-wann ein Admin reinschaut: Der Zeilenzähler ist immernoch enorm ungenau!
@Taxidriver: Mich würde interessiern ob meine Idee funktioniert hat, beim kopieren sind so viele Zeichen verlohren gegangen das ich es selber nicht testen kann.
oT: Was meint ihr mit 'Schwarz'?
oT: Was meint ihr mit 'Schwarz'?
Das große Scientia Wiki zur Spielentwicklung 
Was ist das RGSS ? RGSS-Dokumentation auf Sc
Kyoshiros Makerkurs
Musik von Shabraxxx für euch
Guide zu den Audioformaten
Skripte von mir (Auswahl):
Atmungssystem
| Streichholzsystem
| Animiert durch Bücher blättern
Random : Marktsystem für Kardor
| Staterelated Battlergraphic
| Hinweis auf mögliche Aktionen
SelfSwitchExpirationtimer Skript - Gameplayerweiterung für Pilzesammler und Farmspiele
Meine Skripte werden gerade hier gesammelt.

Was ist das RGSS ? RGSS-Dokumentation auf Sc
Kyoshiros Makerkurs

Musik von Shabraxxx für euch
Guide zu den Audioformaten

Skripte von mir (Auswahl):
Atmungssystem
| Streichholzsystem
| Animiert durch Bücher blättern
Random : Marktsystem für Kardor
| Staterelated Battlergraphic
| Hinweis auf mögliche Aktionen
SelfSwitchExpirationtimer Skript - Gameplayerweiterung für Pilzesammler und Farmspiele
Meine Skripte werden gerade hier gesammelt.Benutzerinformationen überspringen
Motto: Wer anderen eine Bratwurst brät, der hat ein Bratwurstbratgerät.
Schwarz isses bei mirn icht, aber ich denke sie meinen diesen Fehler:
Zitat
oT: Was meint ihr mit 'Schwarz'?
Ähnliche Themen
-
Kampfsysteme »-
ZTBS - Zenith Tactical Battle System V1.2
(17. Mai 2009, 09:18)
-
RGSS 1 Probleme & Talk »-
Enemy Bild wird nicht angezeigt.
(2. Februar 2009, 21:46)
-
Skript-Anfragen »-
Suche
(31. Januar 2009, 18:26)
-
RGSS 1 Probleme & Talk »-
ZTBS Tutorial
(17. Januar 2009, 20:11)
-
Skript-Anfragen »-
ist es möglich den eventnamen per script zu ändern?
(20. September 2008, 12:32)




