Jump to content

Angelmelody

Members
  • Content Count

    772
  • Joined

  • Last visited

  • Days Won

    23

Posts posted by Angelmelody


  1. replace this

        if(.game_player_name$[0] == "") {        .game_player_num = 1;        .game_player_name$[0] = strcharinfo(0);        query_sql "SELECT DATE_FORMAT(TIMESTAMPADD(SQL_TSI_SECOND, "+.time_joining+", NOW( )), '%T'), CURTIME( )", .@time_fstr$, .@time_nstr$;        announce "[Devil Square]: Game will start at "+.@time_fstr$+" (Now: "+.@time_nstr$+")", bc_all, 0x00FF00, 400, 18;        .time_delay = gettimetick(2) + .time_joining;        .game_status = 2;        initnpctimer;    } else {        .game_player_name$[.game_player_num] = strcharinfo(0);        .game_player_num++;    }

      with

    		.game_player_name$[.game_player_num] = strcharinfo(0);		.game_player_num++;		if(.game_status < 2) {			query_sql "SELECT DATE_FORMAT(TIMESTAMPADD(SQL_TSI_SECOND, "+.time_joining+", NOW( )), '%T'), CURTIME( )", .@time_fstr$, .@time_nstr$;			announce "[Devil Square]: Game will start at "+.@time_fstr$+" (Now: "+.@time_nstr$+")", bc_all, 0x00FF00, 400, 18;			.time_delay = gettimetick(2) + .time_joining;			.game_status = 2;			initnpctimer;		}

    then add this

    OnClock<hour><minute>:	if(.game_status) end;	query_sql "SELECT DATE_FORMAT(TIMESTAMPADD(SQL_TSI_SECOND, "+.time_joining+", NOW( )), '%T'), CURTIME( )", .@time_fstr$, .@time_nstr$;	announce "[Devil Square]: Game will start at "+.@time_fstr$+" (Now: "+.@time_nstr$+")", bc_all, 0x00FF00, 400, 18;	.time_delay = gettimetick(2) + .time_joining;	.game_status = 2;	initnpctimer;	end;

     



    the 'OnClock<hour><minute>:' is your automated event starting time


  2.  

     

    any update please?.. im having error when recompiling .... im using the latest revision

    I m using fresh emulator and don't have this mod so can't maintain it now

     

    I Have problems With rAmod

    im tryed your mod to -1 fix) but i have problems 

    If you dont Understand Say me pls I give you links with my elulator) try pls but this mod is very very important for me

    Ошибка	7	error C2065: timer: необъявленный идентификатор (..srcmapscript.c)	C:UsersСерыйDesktopTiamat 9970srcmapscript.c	21270	1	map-serverОшибка	8	error C2223: выражение слева от "->gettick" должно указывать на структуру или объединение (..srcmapscript.c)	C:UsersСерыйDesktopTiamat 9970srcmapscript.c	21270	1	map-serverОшибка	9	error C1903: не удается восстановить после предыдущих ошибок; остановка компиляции (..srcmapscript.c)	C:UsersСерыйDesktopTiamat 9970srcmapscript.c	21270	1	map-serverПредупреждение	10	warning C4244: функция: преобразование "int64" в "unsigned int", возможна потеря данных (..srcmapstatus.c)	C:UsersСерыйDesktopTiamat 9970srcmapstatus.c	3235	1	map-serverОшибка	4	error C2065: timerdata: необъявленный идентификатор (..srcmapchrif.c)	C:UsersСерыйDesktopTiamat 9970srcmapchrif.c	1974	1	map-serverОшибка	5	error C2223: выражение слева от "->tick" должно указывать на структуру или объединение (..srcmapchrif.c)	C:UsersСерыйDesktopTiamat 9970srcmapchrif.c	1974	1	map-serverОшибка	6	error C1903: не удается восстановить после предыдущих ошибок; остановка компиляции (..srcmapchrif.c)	C:UsersСерыйDesktopTiamat 9970srcmapchrif.c	1974	1	map-serverОшибка	1	error C2065: timerdata: необъявленный идентификатор (..srcmapchrif.c)	C:UsersСерыйDesktopTiamat 9970srcmapchrif.c	1970	1	map-serverПредупреждение	2	warning C4047: ==: "int" отличается по уровням косвенного обращения от "void *" (..srcmapchrif.c)	C:UsersСерыйDesktopTiamat 9970srcmapchrif.c	1970	1	map-serverОшибка	3	error C2223: выражение слева от "->tick" должно указывать на структуру или объединение (..srcmapchrif.c)	C:UsersСерыйDesktopTiamat 9970srcmapchrif.c	1970	1	map-server

      this symbol  '->' is the feature of hooking function  on Herc  and not compatible with rathena , you have  to manually covert 

      into the corresponding function on rathena


  3. will i received some lag/error issues if i showered it to 100~200 players?

    It won't lag if players are over 200 , becoz the freeloop command can prevent the lagging of huge loop

     

     

    @@Aurora yeah it has restriction 

     

    bindatcmd "shower",strnpcinfo(3)+"::OnShowerCommand",80,80;

    Can you translate this line in english? :D

      you can read  doc/script_commands.txt

     


  4. yeah thank u so much its working now..

    do you recommend this instead of plug in?

    because @@Oxxy said --tho that's madness, imagine server with 200 online. Query'll load server a lot.--

     

    btw can u make it like on the plug in?

    @shower (itemid) (quantity)

    example

    @shower 501 100

     

    sorry for asking too much.

     

    frequently query problem wasn't exist on new one , and here you go!  @shower <Item ID> <amount>

    -	script	asdfgadhjkl	-1,{  end;OnInit:	bindatcmd "shower",strnpcinfo(3)+"::OnShowerCommand",80,80;	end;OnShowerCommand:	.@showeritemid = atoi(.@atcmd_parameters$[0]);    	.@showeritamount = atoi(.@atcmd_parameters$[1]);	if ( !.@showeritemid ) {		message strcharinfo(0), "@shower <Item ID> <amount>";        	end;	}    	if ( getiteminfo(.@showeritemid,2) == -1 ) {        	message strcharinfo(0), "Invalid Item ID";		message strcharinfo(0), "@shower <Item ID> <amount>";        	end;    	}	if(.@showeritamount <= 0) {        	message strcharinfo(0), "Invalid Item Amount";		message strcharinfo(0), "@shower <Item ID> <amount>";        	end;    	}	query_sql("SELECT `account_id` FROM `login` WHERE `sex`!='S' ORDER BY `account_id` ASC LIMIT 1", .@minaid);	query_sql("SELECT `account_id` FROM `login` WHERE `sex`!='S' ORDER BY `account_id` DESC LIMIT 1", .@maxid);	.@showermap$ = strcharinfo(3);	freeloop(1);	while ( .@minaid <= .@maxid ) {		if(!attachrid(.@minaid++)) continue;		if(strcharinfo(3) !=.@showermap$ ) continue;		if(checkvending()) continue;		getitem .@showeritemid,.@showeritamount;		announce "Something has been drop from the sky!",bc_self,0xFFC0CB;	}	freeloop(0);end;}

  5. now i type .@shower no more lag but I received nothing

    updated, try again...

     

    -	script	asdfgadhjkl	-1,{  end;OnInit:	bindatcmd "shower",strnpcinfo(3)+"::OnShowerCommand",80,80;	end;OnShowerCommand:	query_sql("SELECT `account_id` FROM `login` WHERE `sex`!='S' ORDER BY `account_id` ASC LIMIT 1", .@minaid);	query_sql("SELECT `account_id` FROM `login` WHERE `sex`!='S' ORDER BY `account_id` DESC LIMIT 1", .@maxid);	.@showermap$ = strcharinfo(3);	freeloop(1);	while ( .@minaid <= .@maxid ) {		if(!attachrid(.@minaid++)) continue;		if(strcharinfo(3) !=.@showermap$ ) continue;		if(checkvending()) continue;		getitem 501,100;		announce "Something has been drop from the sky!",bc_self,0xFFC0CB;	}	freeloop(0);end;}

  6.  

     

     try this new one , it's no need to modify map_zone_db.conf now :)

     

    -	script	asdfgadhjkl	-1,{  end;OnInit:	bindatcmd "shower",strnpcinfo(3)+"::OnShowerCommand",80,80;	end;OnShowerCommand:	query_sql("SELECT `account_id` FROM `login` WHERE `sex`!='S' ORDER BY `account_id` ASC LIMIT 1", .@minaid);	query_sql("SELECT `account_id` FROM `login` WHERE `sex`!='S' ORDER BY `account_id` DESC LIMIT 1", .@maxid);	.@showermap$ = strcharinfo(3);	freeloop(1);	while ( .@minaid <= .@maxid ) {		if(!attachrid(.@minaid++)) continue;		if(strcharinfo(3) !=.@showermap$ ) continue;		if(checkvending()) continue;		getitem 501,100;		announce "Something has been drop from the sky!",bc_self,0xFFC0CB;	}	freeloop(0);end;}

  7. db/re/map_zone_db.conf
    insert the "loadevent" into the mapflags brackets of the zone named "All".

    mapflags: (
    "loadevent",
    )

    -	script	asdfghjkl	-1,{  end;OnInit:	bindatcmd "shower",strnpcinfo(3)+"::OnShowerCommand",80,80;	end;OnShowerCommand:	.@size = query_sql("select account_id from `char` where online = 1 and last_map ='"+strcharinfo(3)+"'",.@aid);	for ( .@i = 0; .@i < .@size; .@i++ ) {		if(!attachrid(.@aid[.@i])) continue;		if(CheckVending()) continue;		getitem 501,100;		announce "Something has been drop from the sky!",bc_self,0xFFC0CB;				}	end;OnPCLoadMapEvent:	query_sql("UPDATE `char` SET last_map='"+strcharinfo(3)+"'");end;}

  8. I wanna say, that's amazing~,jack! :D

    你的道具編碼太神奇了 ,錯誤之後竟可以變成唯一的一個編號

    因為 getuniqueid 變數存不了吧 ,變數只正負21億範圍 ,

    你看你的資料庫 道具編碼是超過 21億, 所以會溢位出一個數 ,

    而這個數竟然剛好就是唯一所以 太神奇了~ 傑克!


  9. 	for(.@i=1;.@i<=6;.@i++) .@c += getmapusers(has_instance(.@i+"@tower"));	if (.@c >4) {		mes "maximum challengers are 5, so now you can't enter the endless tower";		colse;	}

    try to add the above script snippets  before  the line:

     

    warp "1@tower",52,354;

  10. try this , hope it work :)

     

    {
      Id: 501
      AegisName: "Red_Potion"
      Name: "Red Potion"
      Type: 0
      Buy: 10

      KeepAfterUse: true
      Trade: {
      override: 60
      nodrop: true
      notrade: true
      noselltonpc: true
      nomail: true
      noauction: true
      }
      Script: <" itemheal rand(1000,200),0; ">
    },

×
×
  • Create New...

Important Information

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