Bert Posted March 23, 2013 Group: Members Topic Count: 16 Topics Per Day: 0.00 Content Count: 36 Reputation: 0 Joined: 02/03/12 Last Seen: June 12, 2013 Share Posted March 23, 2013 AS the title mentioned, is it possible to enable password on guild storage? If it's not possible, what are the modifications that I must do? Thanks in advance~ Quote Link to comment Share on other sites More sharing options...
Skorm Posted March 23, 2013 Group: Forum Moderator Topic Count: 33 Topics Per Day: 0.01 Content Count: 1268 Reputation: 382 Joined: 02/03/12 Last Seen: Sunday at 06:24 PM Share Posted March 23, 2013 (edited) Well it is and it isn't. Disable the guild storage command, and instead use an npc like this. prontera,165,188,4 script Guild Warehouse 112,{ cutin "kafra_06",2; mes "[Guild Warehouse Coupler]"; mes "This is the guild warehouse coupler service."; next; menu "Access Guild Warehouse", GS_OPEN, "Set Guild Warehouse Password", GS_PASS, "Exit", GS_EXIT3; GS_OPEN: if(getd("$gspass"+getcharid(2)+"$")!=""){ mes "Please input your guilds password."; input(.@gspass$); if(.@gspass$==getd("$gspass"+getcharid(2)+"$")){ mes "Welcome!"; } else { mes "I'm sorry but that's incorrect, please try again later."; goto GS_EXIT4; } } set @flag,guildopenstorage; if(@flag == 1) goto GS_EXIT1; if(@flag == 2) goto GS_EXIT2; goto GS_EXIT4; GS_PASS: if(!getcharid(2)) { mes "I'm sorry but you don't have a guild."; goto GS_EXIT4; } query_sql("SELECT `master` FROM `guild` WHERE `guild_id` = '"+ getcharid(2) +"';",.@b$); if(.@b$!=strcharinfo(0)){ mes "I'm sorry but you're not the leader of "+strcharinfo(2)+"."; goto GS_EXIT4; } if(getd("$gspass"+getcharid(2)+"$")!=""){ mes "Did you forget, your guild password is "+getd("$gspass"+getcharid(2)+"$")+". Do you still want to change it?"; if(select("Yes:No")-1) goto GS_EXIT4; } mes "Please Input your new guild password."; input(.@gspass1$); mes "Again."; input(.@gspass2$); if(.@gspass1$==.@gspass2$){ setd "$gspass"+getcharid(2)+"$",.@gspass1$; } else { mes "I'm sorry, but your passwords didn't match, please try again."; goto GS_PASS; } mes getd("$gspass"+getcharid(2)+"$")+" has been set as your password."; goto GS_EXIT4; GS_EXIT1: mes "[Guild Warehouse]"; mes "The guild warehouse is being used right now."; mes "Please wait a while, then come back."; goto GS_EXIT4; GS_EXIT2: mes "[Guild Warehouse]"; mes "You can't use this service if you're not in a guild!"; goto GS_EXIT4; GS_EXIT3: mes "[Guild Warehouser]"; mes "Come back whenever you want."; GS_EXIT4: cutin "kafra_06",255; close; }Warning if the guild is broken this script will leave unused global variables in your global_reg_value table.This script hasn't been tested yet. If you want the npc to be mobile... change the top line. - script gstorage -1,{ OnWhisperGlobal:Will be accessed from whisper menu with npc:gstorage.Also remember to modifiy the Kafra's inside of the guild bases because I think they allow guild storage access. Edited March 24, 2013 by Skorm 1 Quote Link to comment Share on other sites More sharing options...
Bert Posted March 24, 2013 Group: Members Topic Count: 16 Topics Per Day: 0.00 Content Count: 36 Reputation: 0 Joined: 02/03/12 Last Seen: June 12, 2013 Author Share Posted March 24, 2013 Thank you! How do I modify the Guild Kafra for the password system? Quote Link to comment Share on other sites More sharing options...
Skorm Posted March 24, 2013 Group: Forum Moderator Topic Count: 33 Topics Per Day: 0.01 Content Count: 1268 Reputation: 382 Joined: 02/03/12 Last Seen: Sunday at 06:24 PM Share Posted March 24, 2013 (edited) In "Ragnarok Server\trunk\npc\kafras\functions_kafras.txt" Find: function script F_KafStor { // Unable to access Guild Storage (Busy) if(getarg(0) == 1){ Add After: if(getd("$gspass"+getcharid(2)+"$")!=""){mes "Please input your guilds password."; input(.@gspass$);if(.@gspass$==getd("$gspass"+getcharid(2)+"$")){ mes "Welcome!"; } else { mes "I'm sorry but that's incorrect, please try again later."; cutin "", 255; close; }} If it helps at all you add this after line 198. This is optional if you're using the custom warper or not. In "Ragnarok Server\trunk\npc\custom\etc\quest_warper.txt" Find: if ($QW_KPoint == 1) set RESRVPTS, RESRVPTS + ($QW_GS_PRICE/5);Add After: if(getd("$gspass"+getcharid(2)+"$")!=""){mes "Please input your guilds password."; input(.@gspass$);if(.@gspass$==getd("$gspass"+getcharid(2)+"$")){ mes "Welcome!"; } else { mes "I'm sorry but that's incorrect, please try again later."; cutin "", 255; close; }} If it helps at all you add this after line 497. Edited March 24, 2013 by Skorm Quote Link to comment Share on other sites More sharing options...
Question
Bert
AS the title mentioned, is it possible to enable password on guild storage? If it's not possible, what are the modifications that I must do?
Thanks in advance~
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.