From c6095ad062eaa0f5576cfab1c4fe436b90c2fbfe Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Sat, 10 Apr 2021 00:45:07 -0300 Subject: Add initial tools --- update/addmods.sh | 32 +++++ update/adler32.c | 79 ++++++++++++ update/commit.txt | 1 + update/commit_old.txt | 1 + update/createnew.sh | 36 ++++++ update/evol_news.txt | 324 +++++++++++++++++++++++++++++++++++++++++++++++++ update/musiccommit.txt | 1 + update/musicnew.sh | 31 +++++ update/news.txt | 30 +++++ update/update.sh | 39 ++++++ update/update_music.sh | 40 ++++++ 11 files changed, 614 insertions(+) create mode 100755 update/addmods.sh create mode 100644 update/adler32.c create mode 100644 update/commit.txt create mode 100644 update/commit_old.txt create mode 100755 update/createnew.sh create mode 100644 update/evol_news.txt create mode 100644 update/musiccommit.txt create mode 100755 update/musicnew.sh create mode 100644 update/news.txt create mode 100755 update/update.sh create mode 100755 update/update_music.sh (limited to 'update') diff --git a/update/addmods.sh b/update/addmods.sh new file mode 100755 index 0000000..a45f9ed --- /dev/null +++ b/update/addmods.sh @@ -0,0 +1,32 @@ +#!/usr/bin/env bash + +# Copyright (C) 2010-2012 Evol Online +# Author: Andrei Karas (4144) + +dir=`pwd` +CC=${CC:=gcc} + +rm adler32 +$CC -lz adler32.c -o adler32 + +mkdir files +mkdir upload + +previous=`cat commit.txt` + +cd ../../client-data/mods + +FILES=`ls` + +for file in $FILES; do + cd $file + find . -type f | xargs zip -9 -r ../../../../evol-tools/update/files/mod-$file.zip + cd $dir/files + sum=`../adler32 1 mod-$file.zip` + echo " " >> xml_header.txt + cp xml_header.txt resources.xml + cat xml_footer.txt >>resources.xml + cp mod-$file.zip ../upload/ + cp resources2.txt ../upload/ + cp resources.xml ../upload/ +done diff --git a/update/adler32.c b/update/adler32.c new file mode 100644 index 0000000..606c739 --- /dev/null +++ b/update/adler32.c @@ -0,0 +1,79 @@ +/* + * adler32.c (c) 2006 Bjorn Lindeijer + * License: GPL, v2 or later + * + * Calculates Adler-32 checksums for all files passed as argument. + * + * Usage: adler32 [file]... + */ + +#include +#include +#include + +/** + * Calculates the Adler-32 checksum for the given file. + */ +unsigned long fadler32(FILE *file) +{ + // Obtain file size + fseek(file, 0, SEEK_END); + long fileSize = ftell(file); + rewind(file); + + // Calculate Adler-32 checksum + char *buffer = (char*) malloc(fileSize); + fread(buffer, 1, fileSize, file); + unsigned long adler = adler32(0L, Z_NULL, 0); + adler = adler32(adler, (Bytef*) buffer, fileSize); + free(buffer); + + return adler; +} + +/** + * Prints out usage and exists. + */ +void print_usage() +{ + printf("Usage: adler32 mode [file]...\n"); + exit(0); +} + +int main(int argc, char *argv[]) +{ + int i; /**< Loops through arguments. */ + + if (argc < 2) + { + print_usage(); + } + + int mode = atoi(argv[1]); + + for (i = 2; i < argc; ++i) + { + FILE *file = fopen(argv[i], "r"); + + if (!file) + { + printf("Error while opening '%s' for reading!\n", argv[i]); + exit(1); + } + + unsigned long adler = fadler32(file); + switch (mode) + { + case 0: + default: + printf("%s %lx\n", argv[i], adler); + break; + case 1: + printf("%lx", adler); + break; + } + fclose(file); + } + + return 0; +} diff --git a/update/commit.txt b/update/commit.txt new file mode 100644 index 0000000..ab9dd1d --- /dev/null +++ b/update/commit.txt @@ -0,0 +1 @@ +c7eaf530e07572c69cb31e112d615a4bd0eef443 diff --git a/update/commit_old.txt b/update/commit_old.txt new file mode 100644 index 0000000..98b6b40 --- /dev/null +++ b/update/commit_old.txt @@ -0,0 +1 @@ +1cf6ff982c76e5ab116d8ed953ef8ff5005d1dde diff --git a/update/createnew.sh b/update/createnew.sh new file mode 100755 index 0000000..0c28040 --- /dev/null +++ b/update/createnew.sh @@ -0,0 +1,36 @@ +#!/usr/bin/env bash + +# Copyright (C) 2011-2012 Evol Online +# Author: Andrei Karas (4144) + +dir=`pwd` +#CC=${CC:=gcc} + +#rm adler32 +#$CC -lz adler32.c -o adler32 + +mkdir files +mkdir upload + +rm files/revolt.zip +cd ../../client-data +find -iregex ".+[.]\(xml\|png\|tmx\|ogg\|txt\|po\|tsx\)" -exec touch --date=2015-01-01 {} \; +find -iregex ".+[.]\(xml\|png\|tmx\|ogg\|txt\|po\|tsx\)" -printf "%P\n" | zip -X -@ ../tools/update/files/revolt.zip +git log --pretty=oneline -n 1 | awk '{print $1}' >../tools/update/commit.txt + +cd $dir/files +sum=`adler32 revolt.zip` +echo "revolt.zip ${sum}" >resources2.txt + +echo ' +' >xml_header.txt +echo '' >xml_footer.txt + +echo " " >> xml_header.txt +cp xml_header.txt resources.xml +cat xml_footer.txt >>resources.xml + +cp revolt.zip ../upload/ +cp resources2.txt ../upload/ +cp resources.xml ../upload/ +cp ../news.txt ../upload/ diff --git a/update/evol_news.txt b/update/evol_news.txt new file mode 100644 index 0000000..3f8acc9 --- /dev/null +++ b/update/evol_news.txt @@ -0,0 +1,324 @@ +##9 Latest client version: ##6ManaPlus 1.8.9.1 +##0 Actual Release: ##1Beta3-H2 +##0 Welcome to ##BEvol Online##b! +##0 You can find every ##1rules##0 of ##BEvol Online##b here: +##1 [@@http://www.evolonline.org/guide_rules.html|http://www.evolonline.org/guide_rules.html@@] + +##7 Update from master branch + +##7 ##BThe adventure begins!##b + +##7 Season 2, Episode 1! + +##0 The long awaited Aurora1 release is finally online. +##0 You can now fully explore Artis, the principale port city of Aurora, +##0 and benefit of the latest fishing and digging support! + +##0 A lot of quests will help you to explore the city and will show off +##0 the historical and political aspect of the Archipelagos of Andorra. + +##0 Welcome our new support, such as walking NPCs, pets, and various +##0 interactive map elements! + +##0 Have fun, the adventure starts now! + +##9 -- Crocs, Reid +##9 February 2016 + + +##7 Hallowe'en Event + +##0 Our special Hallowe'en update is out! + +##0 This event brings back some old monsters from the beta releases, but +##0 it also introduces an angry bat monster named "Crafty". +##0 We have also reworked many graphics and music from the previous +##0 Hallowe'en theme with the help of Aeonchild and Eric Matyas. + +##0 The event will stay online for 3 weeks, it should be enough time to +##0 re-visit the island and, who knows... Maybe you'll find a new +##0 place to explore... ;) + +##0 We all wish you a happy Hallowe'en and we hope to see you around! + +##9 -- Cheers, Reid and WildX +##9 October 2015 + + +##7 Season 1, Episode 4 + +##0 The Evol Online Project is pleased to announce you the release of +##0 the new server software! +##0 First of all, remember to update your server list. + +##0 This server includes better support for all the main features of +##0 Evol. You won't actually see much difference from other Beta +##0 releases, but we still need your help to assure that the current +##0 server build works with our little world while we work on the first +##0 release. + +##0 we will also release most of our current changes on the island and +##0 some bug fixes which were waiting in queue since the end of the Beta +##0 Session. +##0 And yet much more work in progress which should be soon available +##0 through the Aurora1 release this year! + +##9 -- Cheers, Reid and WildX +##9 March 2015 + + +##7 Season 1, Episode 3! + +##0 Greetings to you all, fellow players! Welcome to this new version of +##0 Evol Online! This third Beta release will maybe be followed by a +##0 Beta3.1 if bugs are to be discovered, so don't hesitate to tell us +##0 about anything you dislike in game. Then you may deserve a cookie... + +##0 Thanks to Kenny690, we made great progress on sound effects and more +##0 will come! We also worked very hard on art, we for example added a +##0 a new hairstyle, weapons are now visible, lots of icons were remade, +##0 etc... Furthermore, new unit names got introduced such as Esperin +##0 for the in-game currency or Florin as weight value. + +##0 Last but not least, we did an incredible work on balancing the game, +##0 this took us most of our time thus we think it'll bring a new game +##0 experience to this adventure. We hope you'll enjoy this new version +##0 of Evol Online, and remember, cookies are a source of life. + +##9 -- Regards, Alige. +##9 July 2013 + + +##7 Get ready for summer! + +##0 Fellow players, we are pleased to inform you that during this year, +##0 all of us worked hard on this project and also in real life, thus +##0 most of our developers and contributors graduated! Congratulations +##0 to all of them! + +##0 The change of license from GPLv2 to CC BY-SA 3.0 has made great +##0 progress too! There are very few graphics left that are still GPLv2 +##0 and we're doing our best to get rid of these as soon as possible. + +##0 On top of that, we also continued working on our new website, we +##0 hope you'll enjoy it as much as we do. Don't forget to register on +##0 our forums too! + +##0 The Beta3 is coming very soon, so if you want a very special cookie, +##0 please come and help us translate the last few sentences left. + +##0 On the ManaPlus development side, we are proud to announce the +##0 release of that client on Debian and Ubuntu 13.10. Note that +##0 http://manaplus.org/ is finally out too! + +##9 -- Regards, Alige. +##9 June 2013 + + +##7 Spring time everybody! + +##0 Beta2.1 was a great success, more than what we thought it would be. +##0 We are proud of this release and of the players too! Your bug +##0 reports helped us a lot, as well as your feedbacks. Thank you! + +##0 We started working on Beta3 even before the launch of Beta2.1 +##0 because much needs to be done. We fixed all known in-game issues +##0 and improved a lot of old content. + +##0 To sump up, Beta3 can be compared as a full balancing release, it'll +##0 bring new weight and currency measures, which will offer a new game +##0 experience to you all! We'll let you discover all of the other new +##0 features and modifications by yourself! + +##0 Lastly, we think it is important for you to know that we spend a lot +##0 of time trying to change our game art's license from GPLv2 to +##0 CC BY-SA 3.0. This will help us develop much faster in the future. + +##0 Beta3 will soon be released, such as its news post! + +##9 -- Cheers, Reid. +##9 March 2013 + + +##7 Finally, Beta2.1 is out! + +##0 We are proud to announce the launch of Beta2.1 tonight. This +##0 update brings a lot of bug fixes. We also did a lot of dialogues and +##0 quest fixes. Translators greatly helped too! Thanks to everyone +##0 who contributed. + +##0 As Evol developers already started working on future releases, +##0 some improvements, that were not supposed to come in so soon, were +##0 implemented in this release. We improved and added graphics, +##0 cleaned databases, added a new indoor sunlight effect. We hope +##0 you'll like it! + +##0 ManaPlus also got improved along with its awesome new Jewelry +##0 Theme! You can now play Evol Online on Android and Mac OS X, +##0 enjoy! Special thanks to Socapex for his wonderful work, creating +##0 the ManaPlus Mac OS X application. + +##0 Check out our Facebook and Google+ pages regularly so that you +##0 don't miss anything. Note that we're already working on the Beta3 +##0 and Aurora1 releases, meaning which releases will come much sooner +##0 than you think! + +##9 -- Regards, Alige. +##9 February 2013 + + +##7 End of the World, Epic Fail! + +##0 We just released Beta2 and we hope you enjoyed all of the cool new +##0 features it brang! This took us a lot of time to put in place but +##0 sadly, we will soon need to release a small update to fix several +##0 bugs. + +##0 Some of us also started working on future releases, that is why +##0 this bug fixing release, called Beta2.1, will be release in a +##0 month. In addition, we need to let translators do their job, and +##0 that takes time! + +##0 Moreover, ManaPlus never stops getting better, as well as the +##0 brand new Jewelry Theme, thanks to 4144 and Hal9000! Check it out! + +##0 Stay tuned for the Beta2.1 release! + +##9 -- Regards, Alige. +##9 January 2013 + + +##7 Season 1, Episode 2! + +##0 After over 10 months of intense work, here is the new version of +##0 Evol Online! A whole new dynamic has been added to the game, +##0 everything has been rewritten, rethought and redrew. +##0 We are proud to present you this Beta2 release! + +##0 Along with the story comes new game and client features, and new +##0 interactions with the environment. This is in fact an entirely new +##0 gaming experience. + +##0 Developers modified the whole game and here are some major +##0 additions: savepoints, quest window, maps, graphics, etc... + +##0 You can check the full list of changes at +##0 http://wiki.evolonline.org/changelog +##0 And all of the new contributors at +##0 http://wiki.evolonline.org/contributors + +##0 Enough said, check out everything by yourself! + +##9 -- Regards, Alige. +##9 December 2012 + + +##7 What a scary... I mean... weird development team! + +##0 Hey, why did the ship stop?! Was that under Nard's orders? Lets +##0 find out! Oh no, giant pumpkins overran all of the boat! It seems +##0 you must get ready for battle. You can sense something very +##0 powerful and evil at the far bottom of the ship. You should check +##0 it out. Maybe Bachus, the party spirit, could help you throughout +##0 this. We hope you'll enjoy this Halloween event. + +##0 Once again, Evol Online developers are in a rush. Beta2 takes a +##0 whole lot longer than they thought but this is of course to avoid +##0 any kind of issue. Again, a numerous amount of bugs were fixed and +##0 scripts were mostly all rewritten for a better game experience. + +##0 As a lot of dialogues were added and improved for Beta2, +##0 translations are needed more than ever. Even though some developers +##0 also work on these, they cannot afford working on all of them. + +##0 If you feel like you can help developers in any way, especially for +##0 translations if you speak english fluently, feel free to contact +##0 them using Evol Online's IRC developer channel. + +##9 -- Regards, Alige. +##9 November 2012 + + +##7 End of summer, beginning of Beta2! + +##0 Summer holidays are now over for the Evol Online developers. We are +##0 proud to announce the arrival of Beta2 soon, even though we +##0 unfortunately find ourselves currently behind schedule. + +##0 However, a lot of efforts were made to create a lot of new content +##0 and great new tilesets which took for ever to create and fix. +##0 We are currently fixing bugs and preparing the release. Final +##0 modifications are being made to give you the best release ever made +##0 for this project. + +##0 Among the new features is a Quest Window that has been added to the +##0 client. It will help you see your progress in game. + +##0 When the Beta2 release will be out, we would like you to promote it +##0 by simply spreading the word around you. Players will then be aware +##0 of the news and this may help us expand our community. + +##0 As you already now, new contributors are always welcome! +##0 Translators, artists and even writers are free to contact us for +##0 more information. + +##9 -- Regards, Alige. +##9 August 2012 + + +##7 Some people just never stop working! + +##0 Once more, a lot of work has been done, recently on the consistency +##0 and quality of the game. A lot of new graphics will be part of the +##0 next release, Beta2. Interactivity between the player and the game +##0 was our main goal the past weeks. + +##0 This new dynamic and gaming experience will be revealed throughout +##0 animations full of mysteries. Treasure chests, coconuts and new +##0 have appeared on a brand new map! + +##0 The work on the translations, the repository reorganizations and +##0 on top of all, the client, were one of our main concerns lately. +##0 The developers still need a bit of time in order to finish this +##0 release, thus we thank you for waiting. + +##9 -- Regards, Alige. +##9 July 2012 + + +##7 Season 1, Episode 1! + +##0 After a mysterious past, you find yourself adrift on the waves in +##0 the middle of Oceania. A noble-minded crew, sails by your body +##0 decides to rescue and take care of you. + +##0 You now wake up about seven days later in their wooden ship. +##0 Take some time to know the crew who saved you and try to +##0 discover what happened to you before this terrible event! + +##9 -- Cheers, Reid. +##9 January 2012 + + +##7 Evol Online Beta releases! + +##0 After several months of work, the world of ##BEvol Online##b is +##0 finally opened to everyone for its first Beta release! + +##0 This Beta will be the first among two other ones which will help +##0 the developers finding out the qualities and problems of the +##0 chosen gameplay. + +##0 We welcome you to give us your thoughts about this, but we also +##0 hope you will have fun being part of this amazing adventure. + +##0 We also need to warn you that at the end of the third release, +##0 all characters will be wiped out as we are trying to have a +##0 perfect balance for this game and start it over with it. +##0 We kindly ask you to accept this. + +##9 -- Cheers, Reid. +##9 January 2012 + +##0 You can check out this page for older news entries: +##1 [@@http://wiki.evolonline.org/news|http://wiki.evolonline.org/news@@] diff --git a/update/musiccommit.txt b/update/musiccommit.txt new file mode 100644 index 0000000..e5352e1 --- /dev/null +++ b/update/musiccommit.txt @@ -0,0 +1 @@ +663e049146ec1c2637338f7834cee445ab653ebb diff --git a/update/musicnew.sh b/update/musicnew.sh new file mode 100755 index 0000000..91a9f5e --- /dev/null +++ b/update/musicnew.sh @@ -0,0 +1,31 @@ +#!/usr/bin/env bash + +# Copyright (C) 2011-2012 Evol Online +# Author: Andrei Karas (4144) + +dir=`pwd` +CC=${CC:=gcc} + +rm adler32 +$CC -lz adler32.c -o adler32 + +mkdir files +mkdir upload + +rm files/music.zip +cd ../../music +find -iregex ".+[.]\(ogg\)" -exec touch --date=2015-01-01 {} \; +find -iregex ".+[.]\(ogg\)" -printf "%P\n" | zip -X -@ ../tools/update/files/music.zip +git log --pretty=oneline -n 1 | awk '{print $1}' >../tools/update/musiccommit.txt + +cd $dir/files +sum=`../adler32 1 music.zip` + +echo " " >> xml_header.txt + +cp xml_header.txt resources.xml +cat xml_footer.txt >>resources.xml + +cp music.zip ../upload/ +cp resources.xml ../upload/ +cp ../news.txt ../upload/ diff --git a/update/news.txt b/update/news.txt new file mode 100644 index 0000000..a35d7d0 --- /dev/null +++ b/update/news.txt @@ -0,0 +1,30 @@ +##0 Actual Release: ##1Unreleased +##0 Welcome to ##BThe Mana World##b! +##0 You can find every ##1rules##0 of ##BThe Mana World: rEvolt##b here: +##1 [@@https://wiki.themanaworld.org/index.php/Game_Rules|https://wiki.themanaworld.org/index.php/Game_Rules@@] + +##7 Update from master branch + +##7 ##BThere is no release title yet##b + +##7 Insert here version number + +##0 I wish I could show you the news, but it is too troublesome updating +##0 this file every time we add something new to the game. +##0 So why don't you explore around, and find out all exciting things +##0 we already add? Please report every bug you find, as well. + +##0 We would also like to show you our bright new ##BWallpaper##b. +##0 Thanks for testing in advance, we'll add something more serious +##0 to this file at release date. + +##0 Have fun, the adventure starts now! + +##9 -- Crocs, Author Name +##9 Insert here date + +##0 You can check out this page for Evol Online news entries: +##1 [@@http://wiki.evolonline.org/news|http://wiki.evolonline.org/news@@] + +##0 You can check out this page for The Mana World Legacy news entries: +##1 [@@https://www.themanaworld.org/news|https://www.themanaworld.org/news@@] diff --git a/update/update.sh b/update/update.sh new file mode 100755 index 0000000..37882d3 --- /dev/null +++ b/update/update.sh @@ -0,0 +1,39 @@ +#!/usr/bin/env bash + +# Copyright (C) 2010-2012 Evol Online +# Author: Andrei Karas (4144) + +dir=`pwd` +CC=${CC:=gcc} + +rm adler32 +$CC -lz adler32.c -o adler32 + +mkdir files +mkdir upload + +previous=`cat commit.txt` + +cd ../../client-data +head=`git log --pretty=oneline -n 1 | awk '{print $1}'` +u1=`echo ${previous} | cut -c 1-7` +u2=`echo ${head} | cut -c 1-7` +git log --name-status ${previous}..${head} | awk '/^(A|M)\t/ {print $2}' | \ + grep -e "[.]\(xml\|png\|tmx\|ogg\|txt\|po\|tsx\)" | sort | uniq | \ + xargs zip -X -9 -r ../tools/update/files/revolt-${u1}..${u2}.zip + +cd $dir/files +if [ -f revolt-${u1}..${u2}.zip ]; then + mv ../commit.txt ../commit_old.txt + echo ${head} >../commit.txt + sum=`../adler32 1 revolt-${u1}..${u2}.zip` + echo "revolt-${u1}..${u2}.zip ${sum}" >>resources2.txt + echo " " >> xml_header.txt + cp xml_header.txt resources.xml + cat xml_footer.txt >>resources.xml + + cp revolt-${u1}..${u2}.zip ../upload/ + cp resources2.txt ../upload/ + cp resources.xml ../upload/ + cp ../news.txt ../upload +fi diff --git a/update/update_music.sh b/update/update_music.sh new file mode 100755 index 0000000..7954b45 --- /dev/null +++ b/update/update_music.sh @@ -0,0 +1,40 @@ +#!/usr/bin/env bash + +# Copyright (C) 2010-2012 Evol Online +# Author: Andrei Karas (4144) + +dir=`pwd` +CC=${CC:=gcc} + +rm adler32 +$CC -lz adler32.c -o adler32 + +mkdir files +mkdir upload + +previous=`cat musiccommit.txt` + +cd ../../music +head=`git log --pretty=oneline -n 1 | awk '{print $1}'` +u1=`echo ${previous} | cut -c 1-7` +u2=`echo ${head} | cut -c 1-7` +git log --name-status ${previous}..${head} \ +| awk '/^(A|M)\t/ {print $2}' +# grep -e "[.]\(ogg\)" | sort | uniq | \ +# xargs zip -X -9 -r ../../evol-tools/update/files/music-${u1}..${u2}.zip +exit + +cd $dir/files +if [ -f evol-${u1}..${u2}.zip ]; then + mv ../muciscommit.txt ../muciscommit_old.txt + echo ${head} >../muciscommit.txt + sum=`../adler32 1 music-${u1}..${u2}.zip` + echo " " >> xml_header.txt + cp xml_header.txt resources.xml + cat xml_footer.txt >>resources.xml + + cp music-${u1}..${u2}.zip ../upload/ + cp resources2.txt ../upload/ + cp resources.xml ../upload/ + cp ../news.txt ../upload +fi -- cgit v1.2.3-70-g09d2