Popular Post Aleos Posted July 27, 2017 Group: Development Manager Topic Count: 56 Topics Per Day: 0.01 Content Count: 732 Reputation: 525 Joined: 12/13/11 Last Seen: June 13, 2024 Popular Post Share Posted July 27, 2017 Achievement System As of Git Hash: 7f5411d, rAthena now supports the Achievement System! Thanks to @Luxuri, @Nova, @Lemongrass, and @Tokei for their help with information and implementation! Thanks to all the users who helped test the PR and report issues on the feature!Basic Information Requires client 2015-05-13 and higher. Includes Title System which is integrated into the Achievement System. Rewards are given through the RODEX System. Added new atcommand reloadachievementdb. Added new script commands achievementinfo, achievementadd, achievementremove, achievementcomplete, and achievementexists. TODO Confirm Achievement Level EXP 8-20. Confirm Old Money Pocket Zeny amount. Figure out how AG_CHATTING, AG_EAT, AG_HEAR, and AG_SEE work on official servers. 19 1 Link to comment Share on other sites More sharing options...
Lemongrass Posted July 28, 2017 Group: Developer Topic Count: 28 Topics Per Day: 0.01 Content Count: 547 Reputation: 270 Joined: 11/08/11 Last Seen: June 10, 2024 Share Posted July 28, 2017 Since aleos did not mention it explicitly: We require GCC 5 or newer from now on. Otherwise you will get a ton of warnings for yaml. Link to comment Share on other sites More sharing options...
vBrenth Posted July 30, 2017 Group: Members Topic Count: 35 Topics Per Day: 0.01 Content Count: 311 Reputation: 46 Joined: 11/06/11 Last Seen: 17 hours ago Share Posted July 30, 2017 Question about AG_ADVENTURE If i wanted to add custom maps, or change the current one would that be possible and how? I can't seem to find anything related to the code with the map listing on it. Link to comment Share on other sites More sharing options...
Tokei Posted July 31, 2017 Group: Members Topic Count: 16 Topics Per Day: 0.00 Content Count: 696 Reputation: 722 Joined: 11/12/12 Last Seen: 17 hours ago Share Posted July 31, 2017 4 hours ago, Zell said: Where am I missing? If i put CONQ_KILLNPC = 500 on my Script when killing a mob, the count its not working. Counter type achievements work a bit differently; the target counter that you set (in achievement_db.yml) is your actual goal/condition. So first thing first, you want to add it to your achievement definition: - ID: 500001 Group: "AG_BATTLE" Name: "Name" Target: Count: 500 Score: 10 What you want to do isn't compatible with counter type achievements (you'd have to create a new group, pass it to AG_CHAT, and set the start value manually, etc). However you can do this easily via scripting instead: OnPCKillNPC: if (CONQ_KILLNPC < 500) { CONQ_KILLNPC++; achievementupdate 500001, ACHIEVEINFO_COUNT1, CONQ_KILLNPC; if (CONQ_KILLNPC == 500) { achievementcomplete 500001; } } end; Hmmm, it appears achievementupdate isn't included...! You can add this script function in your source: //BUILDIN_DEF(achievementupdate,"iii?"), BUILDIN_FUNC(achievementupdate) { struct map_session_data *sd; int i, achievement_id, type, value; achievement_id = script_getnum(st, 2); type = script_getnum(st, 3); value = script_getnum(st, 4); if (!script_charid2sd(5, sd)) { return SCRIPT_CMD_FAILURE; } if (achievement_search(achievement_id) == NULL) { ShowWarning("buildin_achievementupdate: Achievement '%d' doesn't exist.\n", achievement_id); return SCRIPT_CMD_FAILURE; } ARR_FIND(0, sd->achievement_data.count, i, sd->achievement_data.achievements[i].achievement_id == achievement_id); if (i == sd->achievement_data.count) achievement_add(sd, achievement_id); ARR_FIND(0, sd->achievement_data.count, i, sd->achievement_data.achievements[i].achievement_id == achievement_id); if (i == sd->achievement_data.count) { return SCRIPT_CMD_FAILURE; } if (type >= ACHIEVEINFO_COUNT1 && type <= ACHIEVEINFO_COUNT10) sd->achievement_data.achievements[i].count[type - 1] = value; else if (type == ACHIEVEINFO_COMPLETE) sd->achievement_data.achievements[i].complete = value ? true : false; else if (type == ACHIEVEINFO_COMPLETEDATE) sd->achievement_data.achievements[i].completeDate = value; else if (type == ACHIEVEINFO_GOTREWARD) sd->achievement_data.achievements[i].gotReward = value ? true : false; else { ShowWarning("buildin_achievementupdate: Unknown type '%d'.\n", type); return SCRIPT_CMD_FAILURE; } achievement_update_achievement(sd, achievement_id, false); return SCRIPT_CMD_SUCCESS; } Best of luck ~! 3 Link to comment Share on other sites More sharing options...
Zell Posted July 31, 2017 Group: Members Topic Count: 53 Topics Per Day: 0.01 Content Count: 412 Reputation: 266 Joined: 04/25/12 Last Seen: Saturday at 11:42 PM Share Posted July 31, 2017 Thanks tokei! Works like a charm. Link to comment Share on other sites More sharing options...
Litro Endemic Posted August 1, 2017 Group: Members Topic Count: 25 Topics Per Day: 0.01 Content Count: 283 Reputation: 79 Joined: 06/13/13 Last Seen: June 7, 2023 Share Posted August 1, 2017 On 7/28/2017 at 3:46 PM, Lemongrass said: Since aleos did not mention it explicitly: We require GCC 5 or newer from now on. Otherwise you will get a ton of warnings for yaml. can you help updating guide on get started docs i'm getting confused as how to install gcc5 and use it as default compiler https://github.com/rathena/rathena/wiki/Install-on-Centos Link to comment Share on other sites More sharing options...
Recommended Posts