-
Content Count
1677 -
Joined
-
Last visited
-
Days Won
246
Content Type
Profiles
Forums
Downloads
Staff Applications
Calendar
Everything posted by AnnieRuru
-
not yet, its been suggested but not yet implement http://herc.ws/board/topic/4412-map-zone-dbconf-allows-to-restrict-an-item-type/
-
it constantly getting updated when @reloadbattleconf, it sends (srcmapatcommand.c) chrif->ragsrvinfo(battle_config.base_exp_rate, battle_config.job_exp_rate, battle_config.item_rate_common);then map-server.exe send the value to char-server.exe via (srccharchar.c) if( SQL_ERROR == SQL->Query(sql_handle, "INSERT INTO `%s` SET `index`='%d',`name`='%s',`exp`='%d',`jexp`='%d',`drop`='%d'", ragsrvinfo_db, fd, esc_server_name, RFIFOL(fd,2), RFIFOL(fd,6), RFIFOL(fd,10)) ).. ok ... I don't understand why they need a sql table to send a server rate ... but for sure, whenever map-server change rate, it does send to the `ragsrvinfo` table 1 reason ... that I am just guessing ... is to support multi map-server so with just 1 login server, the player can select which server they like to play, and each map-server has different rates and that index indicate different map-server I'm just guessing though, maybe try ask Ind ok now I know why in case that map-server.exe crash, and char-server.exe still up it can retrieve the last value from SQL, because char-server.exe handles to rates (srcmapcharif.c) /*========================================== * timerFunction * Check the connection to char server, (if it down) *------------------------------------------*/.. . I'm quite sure that inserting a new row in a non-indexed table, will be the 1st rowjust do a select * from ragsrvinfo limit 1; would suffice
-
/*update item_db_re set script = 'doevent "item_soullink::OnSoulLink";' where id = 501;*/- script item_soullink -1,{OnSoulLink: if ( .@spirit = .spirit[BaseJob] ); else if ( Upper & 1 && BaseLevel < 70 ) .@spirit = 494; else end; sc_start4 SC_SOULLINK, -1, 1, .@spirit,0,0; skilleffect .@spirit, 1; end;OnInit: .spirit[Job_Alchemist] = 445; .spirit[Job_Monk] = 447; .spirit[Job_Star_Gladiator] = 448; .spirit[Job_Sage] = 449; .spirit[Job_Crusader] = 450; .spirit[Job_SuperNovice] = 451; .spirit[Job_Knight] = 452; .spirit[Job_Wizard] = 453; .spirit[Job_Priest] = 454; .spirit[Job_Bard] = .spirit[Job_Dancer] = 455; .spirit[Job_Rogue] = 456; .spirit[Job_Assassin] = 457; .spirit[Job_Blacksmith] = 458; .spirit[Job_Hunter] = 460; .spirit[Job_Soul_Linker] = 461; end;}
-
prontera,155,185,5 script abcde#1 100,{Onaaa: mes "testing ..."; next; mes "let's go !"; close2; getmapxy .@map$, .@x, .@y, 1; warpportal .@x+2, .@y+2, "yuno",157,51; end;}geffen,119,59,5 script abcde#2 100,{ doevent "abcde#1::Onaaa"; end;}change into- script abcde -1,{ mes "testing ..."; next; mes "let's go !"; close2; getmapxy .@map$, .@x, .@y, 1; warpportal .@x+2, .@y+2, "yuno",157,51; end;}prontera,155,185,5 duplicate(abcde) abcde#1 100geffen,119,59,5 duplicate(abcde) abcde#2 100.. I hope you get what I mean
-
1. correct by the way this script isn't mine my original script from eathena use OnTue20000: something-like labels asking members to put in the labels for start time and end time ( see my King of Emperium Hill script ) its Euphy that he improvise to make this script configurable in-game 2. in SQL, to remove a value is actually 'NULL', and '0' is a value in athena, '0' means both also means, if SQL doesn't list a value, it means 0 with athena script language your values are 1st session has woe on Sunday (0), starts from 12am (0) ~ 1am (1) with the castle ID 32 = 2^5 "payg_cas01" <- this 1 castle is on 2nd session has woe on Sunday (0), starts from 1am (1) ~ 2am (2) with the castle ID 4 = 2^2 "prtg_cas03" <-- this 1 castle is on 3rd session has woe on Thursday (4), starts from 10pm (22) ~ 11pm (23) with the castle ID 32 = 2^5 "payg_cas01" <-- this 1 castle is on 4th session has woe on Friday (5), starts from 10pm (22) ~ 11pm (23) with the castle ID 4 = 2^2 "prtg_cas03" <-- this 1 castle is on 3. prontera,156,184,5 script sdfhsdkfjs 100,{ .@nb = query_sql( "select `index`, `value` from mapreg where varname = '$WOE_CONTROL'", .@index, .@value ); for ( .@i = 0; .@i < .@nb; .@i++ ) .@woe[ .@index[.@i] ] = .@value[.@i]; dispbottom "There are currently "+ .@nb / 4 +" sessions configured"; for ( .@i = 0; .@i < .@nb; .@i += 4 ) { dispbottom " --- Session No."+( .@i/4 +1 )+" --- "; dispbottom "War on "+ .days$[ .@woe[.@i] ] +". Starts from "+ .@woe[.@i+1] +":00 until "+ .@woe[.@i+2] +":00"; .@c = 0; deletearray .@castle$; for ( .@j = 0; .@j < 30; .@j++ ) if ( .@woe[.@i+3] & 1 << .@j ) .@castle$[.@c++] = .castles$[.@j]; dispbottom "at these castles : "+ implode( .@castle$, "," ); } end;OnInit: setarray .days$[0],"Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"; setarray .castles$[0], "prtg_cas01","prtg_cas02","prtg_cas03","prtg_cas04","prtg_cas05", "payg_cas01","payg_cas02","payg_cas03","payg_cas04","payg_cas05", "gefg_cas01","gefg_cas02","gefg_cas03","gefg_cas04","gefg_cas05", "aldeg_cas01","aldeg_cas02","aldeg_cas03","aldeg_cas04","aldeg_cas05", "arug_cas01","arug_cas02","arug_cas03","arug_cas04","arug_cas05", "schg_cas01","schg_cas02","schg_cas03","schg_cas04","schg_cas05"; end;}
-
LOL ... you did well thoughI thought can let you handle ... oh well anyways, play around with this little script that I wrote during eathena period ... sh*t eathena forum down so I make a new one prontera,156,184,5 script ksdkfjhdkshfj 100,{ .@difficulty = 4; // change this from 1 to 30 ( athena script engine allows up to 2^32 -1 ) mes "Guess the total value of ^0000FF"+( .@value = rand( 1, 1 << .@difficulty ) )+"^000000 ?"; next; while (1) { .@menu$ = ""; for ( .@i = 0; .@i < .@difficulty; .@i++ ) .@menu$ = .@menu$ +( ( .@answer & 1 << .@i )? "^00FF00" : "^FF0000" )+"1 << "+ .@i +":"; .@s = select( .@menu$ ) -1; .@answer = .@answer ^ 1 << .@s; if ( .@answer == .@value ) break; } mes "Correct ! The answer is "; for ( .@i = 0; .@i < .@difficulty; .@i++ ) { if ( .@answer & 1 << .@i ) { .@ans$[.@c] = 1 << .@i; .@c++; } } mes implode( .@ans$, "+" ); close;}1 << 0 = 1 ( also means 20 -> 2 power of 0 -> you press the scientific calculator as 2^0 )1 << 1 = 2 ( also means 21 -> 2 power of 1 -> you press the scientific calculator as 2^1 ) 1 << 2 = 4 ( also means 22 -> 2 power of 2 -> you press the scientific calculator as 2^2 ) ... and so on so, if the script randoms a number of 14 the correct answer is 2+4+8 which means 1<<1 + 1<<2 + 1<<3 also means 21 + 22 + 23 also means 14 & 0 == false 14 & 1 == true 14 & 2 == true 14 & 4 == true in euphy script, which actually ... copy mine ... I wish I can show you the topic in eathena "prtg_cas01" uses 1<<0 ... "prtg_cas02" use 1<<1 and so on ( see setarray .Castles$[0] ) so if $WOE_CONTROL[0] = 0 $WOE_CONTROL[1] = 1 $WOE_CONTROL[2] = 2 $WOE_CONTROL[3] = 3 it means, the 1st session has woe on Sunday(0), starts from 1am(1) ~ 2am(2) with the castle ID 1+2 enable (3) 1+2 = prtg_cas01 + prtg_cas02 <-- these 2 castle on war at the time if you configure another session $WOE_CONTROL[4] = 3 $WOE_CONTROL[5] = 20 $WOE_CONTROL[6] = 22 $WOE_CONTROL[7] = 96 means 2nd session has woe on Wednesday (3), starts from 8pm (20) ~ 10pm(22) with the castle ID 96 = 32+64 = 25 + 26 1<<5 + 1<<6 = "payg_cas01" and "payg_cas02" <-- these 2 castles are enabled
-
I think that return 0; should be fix first https://github.com/HerculesWS/Hercules/commit/aa1461430c3d7c31bd03eca02c7b91a274351c19 the other bug report you mentioned, seems like a different issue, will be left to core developers
-
I'm very interested to know which script command 'return false;' if this really happens, that command really need some fixing prontera,157,180,5 script Healer#1 100,{ .@price = 0; // Zeny required for heal .@Buffs = 0; // Also buff players? (1: yes / 0: no) .@Delay = 0; // Heal delay, in seconds if (@HD > gettimetick(2)) end; if (.@price) { message strcharinfo(0),"Healing costs "+.@price+" Zeny."; if (Zeny < .@price) end; if(select("^0055FFHeal^000000:^777777Cancel^000000") == 2) close; Zeny -= .@price; } specialeffect2 EF_HEAL2; percentheal 100,100; if (.@Buffs) { specialeffect2 EF_INCAGILITY; sc_start SC_INC_AGI,240000,10; specialeffect2 EF_BLESSING; sc_start SC_BLESSING,240000,10; } if (.@Delay) @HD = gettimetick(2)+.@Delay; close;}prontera,154,180,5 script Healer#2 100,{ specialeffect2 EF_HEAL2; percentheal 100,100; specialeffect2 EF_INCAGILITY; sc_start SC_INC_AGI,240000,10; specialeffect2 EF_BLESSING; sc_start SC_BLESSING,240000,10; close;}actually I don't get any error
-
battle->bc->prevent_logout and battle_config.prevent_logout issit ? well ... I dunno how to really explain this either I only know that 'battle_config.xxxxx' cannot be read in the plugin, always return 0 but then I noticed this line https://github.com/HerculesWS/Hercules/blob/master/src/map/battle.c#L7107 battle->bc = &battle_config;'battle_config.xxxxx' cannot be used, so has to use 'battle->bc->xxxxx' hahaha ... sry I don't really know C stuffs either, I just try and error
-
ok I was wrong previously, screw up dispbottom "1. "+ getstrlen( Zeny ); debugmes "test1"; <-- error dispbottom "2. "+ getstrlen( Zeny +"" ); debugmes "test2"; <-- OK dispbottom "3. "+ getstrlen( .@z$ = Zeny ); debugmes "test3"; <-- OKso yeahgetstrlen(1234) will throw error ( I messed up ) getstrlen(1234 +""); <-- OK getstrlen( .@a$ = 1234 ); <-- OK
-
Are the list of enabled castle maps in db/castle_db.txt are in SQL?
AnnieRuru replied to Zirius's question in Script Support
nonono, you have to do the scripting part yourself I understand that you are expecting something like query_sql "select guild_id from guild_castle", .@gid;for ( .@i = 0; .@i <= 34; .@i++ )dispbottom "the castle "+ .castle$[.@i] +" has been conquered by "+ getguildname( .@gid[.@i] );setarray .castle$[0], "Neuschwanstein", "Hohenschwangau", "Nuernberg", .....which is wrongnot only some rows might be missing, but the rows are also not in order the correct way is prontera,156,184,5 script kjhsdkfjhs 100,{ .@nb = query_sql( "select castle_id, guild_id from guild_castle", .@castle_id, .@gid ); // --- build another array according to the castle ID for ( .@i = 0; .@i < .@nb; .@i++ ) .@castle[ .@castle_id[.@i] ] = .@gid[.@i]; // --- now you can list them safely for ( .@i = 0; .@i < 34; .@i++ ) { if ( .@castle[.@i] ) dispbottom "castle ID "+ .@i +" has been conquered by "+ getguildname( .@castle[.@i] ); else dispbottom "castle ID "+ .@i +" has not been conquer"; } end;}tested -
nonono ... lolgetstrlen( getarg(0) ) also wont show warning ... getstrlen(1234) or getstrlen("1234") also wont show warning ... --> wrong info -> read next post only dispbottom getstrlen(1234);will show warning mathematics if getarg(0) is 12345 -> .@i = getstrlen( .@str$ = getarg(0) ) -3; -> .@i = getstrlen( .@str$ = 12345 ) -3; -> .@i = getstrlen(12345) -3; .@str$ = 12345; // <-- perform 2 equations ... split them -> .@i = 5 -3; .@str$ = 12345; -> .@i = 2; .@str$ = 12345;
-
Are the list of enabled castle maps in db/castle_db.txt are in SQL?
AnnieRuru replied to Zirius's question in Script Support
huh ? by default, you should have 34 castles loaded what do you mean by "activate 6 castles" ? removed some of them ? those without entries in SQL, also means those castles are not conquered when my character AnnieRuru conquered Kriemhild (prtg_cas01) SQL will generate a row 15,2,0,0,0,0, .... where 15 is castle ID for Kriemhild 2 is my AnnieRuru's guild ID but map-server.exe will still be loading 34 castle as long as you don't comment any of them in castle_db.txt so even with just 1 line in sql table, the rest are being readed as 0 means those castle are not yet conquered -
dunno how many times I've said athena script engine will not throw error when assigning numbers or string prontera,156,184,5 script kjhsdkfjhs 100,{// input .@a, -1000000000, 2000000000;// dispbottom callfunc( "int__", .@a ); .@str$ = 12345; .@int = "12345"; dispbottom .@str$ +" "+ .@int; // <-- return 12345 12345 end;} they only throw error when comparing int and string if ( .@int == .@str$ ) or displaying an integer in a dialog dispbottom .@a; I've used this function for almost 2 years and never getting any error
-
Are the list of enabled castle maps in db/castle_db.txt are in SQL?
AnnieRuru replied to Zirius's question in Script Support
select * from guild_castle; -
*blush* sorry but I dunno how to answer your question
-
try this source http://herc.ws/board/topic/4570- function http://herc.ws/board/topic/4889- script http://upaste.me/6473ee
-
scripting ... easiest way - script kjdfkjdfkjsdf -1,{OnInit: bindatcmd "world", strnpcinfo(0)+"::Onaaa"; bindatcmd "sample", strnpcinfo(0)+"::Onbbb"; end;Onaaa: dispbottom "Hello World !"; end;Onbbb: dispbottom "This is a sample"; end;}. . atcommands . .patch src/map/atcommand.c | 13 +++++++++++++ 1 file changed, 13 insertions(+)diff --git a/src/map/atcommand.c b/src/map/atcommand.cindex b5e8fa7..9da02ac 100644--- a/src/map/atcommand.c+++ b/src/map/atcommand.c@@ -9374,6 +9374,17 @@ static inline void atcmd_channel_help(int fd, const char *command, bool can_crea clif->message(fd,atcmd_output); return true; }++ACMD(world) {+ clif->message( fd, "Hello World !" );+ return true;+}++ACMD(sample) {+ clif->message( fd, "this is a sample." );+ return true;+}+ /** * Fills the reference of available commands in atcommand DBMap **/@@ -9384,6 +9395,8 @@ void atcommand_basecommands(void) { * Command reference list, place the base of your commands here **/ AtCommandInfo atcommand_base[] = {+ ACMD_DEF(world),+ ACMD_DEF(sample), ACMD_DEF2("warp", mapmove), ACMD_DEF(where), ACMD_DEF(jumpto),.---- OR ---- . plugin #include <stdio.h>#include <stdlib.h>#include <string.h>#include "../map/clif.h"#include "../common/HPMi.h"#include "../common/HPMDataCheck.h" // should always be the last file included! (if you don't make it last, it'll intentionally break compile time)HPExport struct hplugin_info pinfo = { "world", // Plugin name SERVER_TYPE_MAP,// Which server types this plugin works with? "0.1", // Plugin version HPM_VERSION, // HPM Version (don't change, macro is automatically updated)};ACMD(world) { clif->message( fd, "Hello World !" ); return true;}ACMD(sample) { clif->message( fd, "this is a sample." ); return true;}HPExport void plugin_init (void) { clif = GET_SYMBOL("clif"); addAtcommand( "world", world ); addAtcommand( "sample", sample );}
-
I did asked you to make a request topic from the PM but isn't it a common sense that you should explain your request in detailed ? . . I've totally no idea what you mean this @bg ? it is like @joinbg ? http://herc.ws/board/topic/4438-about-our-bg-src/?p=28704
-
http://rathena.org/board/topic/78269-annieruru-lame-script-collection/function script int__ { .@i = getstrlen( .@str$ = getarg(0) ) -3; .@is_negative = charat( .@str$, 0 ) == "-"; while ( .@i > .@is_negative ) { .@str$ = insertchar( .@str$, ",", .@i ); .@i -= 3; } return .@str$;}you'll find this if you use my mvp ladder, mvp room or mission board
-
[Outdated] battleground system without waitingroom
AnnieRuru replied to AnnieRuru's topic in Plugin Releases
yes thanks to both of you its my source code that's bug let's say team Red has 2 players which is AnnieRuru and EnnyRuru1. AnnieRuru 2. EnnyRuru when AnnieRuru logs out it will be 1. 2. EnnyRuru it doesn't automatically shift the index so my getbgusers has to search the whole array and count them 1 by 1 -
sry for being sarcastic who cares about source code or atcommand.c and rathena developers are making it too complicated wahahahahahaha
-
[Outdated] battleground system without waitingroom
AnnieRuru replied to AnnieRuru's topic in Plugin Releases
apparently this is indeed a bug in the source which I have no idea how to fix'em http://upaste.me/6fb3d0 I multi 4 clients 2 players in team Red, 2 players in team Blue now try to log off one of them, let's say team Red the team Red will have bg_get_data as 1, which is correct, but $@arenamembersnum as 0 which is wrong don't tell me this is another bug produced from battleground queue system -
curious, where is the treasure room ?in guild_vs1, there is not enough room for a treasure room
-
gvg King of Emperium Hill
AnnieRuru replied to AnnieRuru's topic in PvP, WoE, GvG, & Battleground Releases
weird, its works fine with my tortoisegitthough, I see that battle.h does have an extra line ... try the new one