New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Initial release of the clan system #1511
Conversation
Fixed run-once mode Fixed packet version Renamed the initialize function to match the others
| INSERT INTO `clan` VALUES ('1', 'Swordman Clan', 'Raffam Oranpere', 'prontera', '500'); | ||
| INSERT INTO `clan` VALUES ('2', 'Arcwand Clan', 'Devon Aire', 'geffen', '500'); | ||
| INSERT INTO `clan` VALUES ('3', 'Golden Mace Clan', 'Berman Aire', 'prontera', '500'); | ||
| INSERT INTO `clan` VALUES ('4', 'Crossbow Clan', 'Shaam Rumi', 'payon', '500'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the clan_ids, not using the constants?
and I don't see u alter the char table for clan_id in upgrade file and add new column in main.sql
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks seems like I forgot to add that update... >.<
I did not use constants because because the char server does not have a constant resolving feature in it yet. Any suggestions?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
forgot, well. just leave it be.
|
Dear @Lemongrass3110 what minimal exe date and exe we should use to try the feature? |
| @@ -2330,6 +2330,9 @@ packet_keys: 0x631C511C,0x111C111C,0x111C111C // [Shakto] | |||
| 0x09D6,-1,npcmarketpurchase,2:4:6 | |||
| 0x09D7,-1 | |||
| 0x09D8,2,npcmarketclosed,0 | |||
| 0x098D,-1,clanchat,2:4 | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will the packets work with 2015-11-04aRagexe ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes.
@Anacondaqq everything from 2013-12-23 will work.
Forgot to add the new character table column and updated the sql scripts Added missing integrity check to character server Trimmed trailing whitespaces Added newlines to the end of the files where missing Added PACKETVER checks to the clif functions Dropped default charset for the new table
| }else{ | ||
| return SCRIPT_CMD_FAILURE; | ||
| } | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't the else part, just let it be end of function control?
(and for script above)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was thinking that it might be safer to terminate the script at this point, that is why I set it up like this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/ic
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might also be an option to make it return true/false to the caller so that they can check it.
What would you prefer/suggest?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Having a return value can be beneficial for clan_join and clan_leave to let the script know if the player was properly entered/removed from the clan.
| INSERT INTO `clan` VALUES ('4', 'Crossbow Clan', 'Shaam Rumi', 'payon', '500'); | ||
|
|
||
| ALTER TABLE `char` | ||
| ADD COLUMN `clan_id` INT(5) UNSIGNED NOT NULL DEFAULT '0' AFTER `hotkey_rowshift`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
must be INT(11)
|
Need the doc updates for |
Fixed a typo in field size of clan_id Thanks to @cydh
| int fd = sd->fd, offset, length; | ||
| struct clan* clan = sd->clan; | ||
| char mapname[MAP_NAME_LENGTH_EXT]; | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure doesn't want to check the sd first?
and also the fd (clif_session_isValid() wow, forgot about this actually)
just incase if player is autorade, they has no fd set.
Added some missing packet sizes into the packet_db and added the packet sizes to the hardcoded packet db Also added some sanity checks for valid sessions Exported the send type clan into the script engine Thanks again to @cydh.
* Fixed text that didn't make sense.
* Reverted a change from the previous dialogue change. * Added changelog line.
* Added return values for clan script commands. * Adjusted clan script to account for return values.
* Updated the script command documentation.
| struct clan* clan; | ||
| int length; | ||
|
|
||
| length = 4 + db_size(clan_db) * sizeof( struct clan ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make it
int clan_len = sizeof(struct clan);
Signed-off-by: Cydh Ramdh <cydh@pservero.com>
|
|
`@guild` will now block creation if you are in a clan. Thanks to @cydh for bringing this to my attention.
# Conflicts: # npc/re/scripts_athena.conf # src/map/script_constants.h # src/map/status.c
By the skills RL_BANISHING_BUSTER and AB_CLEARANCE
# Conflicts: # npc/re/scripts_athena.conf
|
In the topic NPCs show the emblem of the clan under each one, I may have applied the wrong patch, everything is working, less clan emblem that does not appear below the npc, see: Topic: https://rathena.org/board/topic/105463-clan-system/ Server: http://imgur.com/tZZFEzq |
|
@admkakaroto What is the date of the client you are using? |
|
@admkakaroto this is a known issue at the moment. I know how to get it working, but we did not implement it properly yet. |
|
@secretdataz 2015-11-04 @Lemongrass3110 i understand, but the system is working perfectly, congratulations. |
# Conflicts: # src/common/mmo.h
| @@ -54,6 +55,7 @@ int inter_recv_packet_length[] = { | |||
| -1,10, 6,-1, 0, 0, 0, 0, 0, 0, 0, 0, -1,10, 6,-1, // 3070- Mercenary packets [Zephyrus], Elemental packets [pakpil] | |||
| 48,14,-1, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 3080- | |||
| -1,10,-1, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 3090- Homunculus packets [albator] | |||
| 2,-1, 6, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 30A0- Clan packets | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder, maybe can we move the clan packets to empty packets there. We have lot unused packets
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah would not be a problem. I just though i'll create a new range because it seemed like that for all other things too.
|
My character's clan emblem disappears when I use Client: 2015-11-04. Also, I don't know how the official behavior is, but would be great if we have a conf like "display_party_name" to show the clan name. |
|
From looking into the code I think there are more things missing when you use refresh at the moment. All kind of visual status changes and hat effects. I will test it later today. About the display_party_name feature: |
|
@Lemongrass3110 Exactly. Thank you for your quick response and amazing work! |
|
When an apprentice enters a Clan after logout and login again, the HP of the character is reduced, is that correct? Before: http://imgur.com/XVHqI07 not yet applied the changes you made on the 10th, I will do it tomorrow and test. |
|
@admkakaroto just confirmed this and looking into it. Thanks for reporting. |
# Conflicts: # db/const.txt Closes #1709
# Conflicts: # src/common/mmo.h # src/map/intif.c
Refactored the new clif functions to use the new char pointer fifo macros
Thanks to @cydh, @RagnarokNova and @aleos89 for their help.
Thanks to @RagnarokNova for his help.
We have a few things that are not yet in there. I will open up some issues for it and try to solve them as soon as possible.
Fixes #1317