Jump to content

Recommended Posts

Posted

I would like to propose adding this to the svn as a quick alternative to /guildbreak, because guild names with spaces are not supported anymore on newer clients.

Index: atcommand.c
===================================================================
--- atcommand.c	(revision 16820)
+++ atcommand.c	(working copy)
@@ -8817,6 +8817,26 @@
 #undef MC_CART_MDFY
}

+/*==========================================
+ * works like /breakguild "<guild name>" (without the name though)
+ * This is needed for newer clients as an
+ * alternative to /guildbreak because support
+ * for " " in newer clients is dropped. [clydelion]
+ *------------------------------------------*/
+ACMD_FUNC(breakguild)
+{
+	struct guild *g;
+	nullpo_retr(-1, sd);
+
+	if (sd->status.guild_id == 0 || (g = guild_search(sd->status.guild_id)) == NULL || strcmp(g->master,sd->status.name)) {
+		clif_displaymessage(fd, "Only the guild leader can use this command.");
+		return -1;
+	}
+
+	guild_break(sd,g->name);
+	return 0;
+}
+
/**
 * Fills the reference of available commands in atcommand DBMap
 **/
@@ -8827,6 +8847,7 @@
  * Command reference list, place the base of your commands here
  **/
 AtCommandInfo atcommand_base[] = {
+		ACMD_DEF(breakguild),
	 ACMD_DEF2("warp", mapmove),
	 ACMD_DEF(where),
	 ACMD_DEF(jumpto),

breakguild.diff

  • Upvote 2
Posted (edited)

Agree!. :) I don't know if it is working or not, if working it would be nice to add it to the SVN. Keep it up Cheeeerrrss!

Edited by Rejected
Posted

if I recall correctly, you no longer need to use quotes when deleting/creating a guild when it got space :) (same for parties)

just tried creating a guild with a name having a space, failed.

I would like to propose adding this to the svn as a quick alternative to /guildbreak, because guild names with spaces are not supported anymore on newer clients.

Index: atcommand.c
===================================================================
--- atcommand.c	(revision 16820)
+++ atcommand.c	(working copy)
@@ -8817,6 +8817,26 @@
 #undef MC_CART_MDFY
}

+/*==========================================
+ * works like /breakguild "<guild name>" (without the name though)
+ * This is needed for newer clients as an
+ * alternative to /guildbreak because support
+ * for " " in newer clients is dropped. [clydelion]
+ *------------------------------------------*/
+ACMD_FUNC(breakguild)
+{
+	struct guild *g;
+	nullpo_retr(-1, sd);
+
+	if (sd->status.guild_id == 0 || (g = guild_search(sd->status.guild_id)) == NULL || strcmp(g->master,sd->status.name)) {
+		clif_displaymessage(fd, "Only the guild leader can use this command.");
+		return -1;
+	}
+
+	guild_break(sd,g->name);
+	return 0;
+}
+
/**
 * Fills the reference of available commands in atcommand DBMap
 **/
@@ -8827,6 +8847,7 @@
  * Command reference list, place the base of your commands here
  **/
 AtCommandInfo atcommand_base[] = {
+		ACMD_DEF(breakguild),
	 ACMD_DEF2("warp", mapmove),
	 ACMD_DEF(where),
	 ACMD_DEF(jumpto),

had a somewhat similar mod with this one from earlier this year in this post.

and I +1 to this too.

  • 3 weeks later...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...