Jump to content
Sign in to follow this  
bWolfie

getalliance Script Command

Recommended Posts

Hello again!

This time I bring the getalliance(<Guild ID>) script command. It works similar to getpartymember() and getguildmember(). I'm still in the process of testing, but it seems to work okay so far. There is a sample script in the comments section at the top of the plugin. Try it out!

*getalliance(<Guild ID>)
This command will find all guilds in an alliance with the specified guild and
returns their names and guild ids into an array of temporary global variables.

Upon executing this,

$@guildallyname$[]        is a global temporary string array which contains all the
                          names of each allied guild.

$@guildoppositionname$[]  is a global temporary string array which contains all the
                          names of each opposition guild.

$@guildallygid[]          is a global temporary number array which contains the
                          guild id of each allied guild.

$@guildoppositiongid[]    is a global temporary number array which contains the
                          guild id of each opposition guild.

$@guildallycount          is the number of allied guilds found.

$@guildoppositioncount    is the number of opposition guilds found.

Note that the returned guilds come in no particular order.

Be sure to use $@guildallycount/$@guildoppositioncount to go through this array, and not
getarraysize(), because it is not cleared between runs of getalliance().

For usage examples, see getpartymember().

Download: https://pastebin.com/82DxKcUW

Edited by Myriad

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.