Jump to content

glemor123

Members
  • Content Count

    287
  • Joined

  • Last visited

Posts posted by glemor123


  1.  

    @Cydh, Please avoid quoting many quotes..

     

    Me Puts a Teaser :

     

    nice =D what about making a setting to "time out and disappear" and also make two parameters to the command: "@market <pub title>, <message>" where the 'message' will display a small text with dispbottom to the user who clicks =)

    this is a good idea sir. :)


  2. shop.png

     

    This is my prototype for now, still have to refactor some parts of the code.

    The command takes in a title, and a description. The description shows up on the chat message when a player clicks on the chat room

    the clone name also must be the same with the players name.

     

    please release a diff for rathena also thank you


  3. It doesn't look too bad to create. What are the requirements? Like how long does this clone stay up for and what not 

    the clone will stay up as long as the player is connected ingame. if the player got disconnected or logout then the clone will disappear


  4. I wan't that the hunting mission point be replaced by TCG CARD (7227). with a constant number of 3.

    //===== rAthena Script =======================================//= Hunting Missions//===== By: ==================================================//= Euphy//===== Current Version: =====================================//= 1.3b//===== Compatible With: =====================================//= rAthena Project//===== Description: =========================================//= Random hunting missions.//= Rewards are based on quest difficulty.//=//= NOTE: Requires SQL mob database.//===== Additional Comments: =================================//= 1.0 Initial script.//= 1.1 Small improvements and fixes.//= 1.2 Added party support and replaced blacklists with an//= SQL query, both thanks to AnnieRuru.//= 1.3 Re-added a blacklist adapted for the SQL query.//= 1.3a Added mission reset options.//= 1.3b Function updates.//============================================================prontera,152,187,6    script    Hunting Missions    951,{function Chk;    mes "[Hunting Missions]";    mes "Hello, "+strcharinfo(0)+"!";    if (!#Mission_Delay) {        next;        mes "[Hunting Missions]";        mes "I can't find any records...";        mes "You must be new here!";        emotion e_omg;        next;        callsub Mission_Info;        emotion e_go;        set #Mission_Delay,1;        close;    }    mes rand(2)?"Working hard, as always...":"Not slacking, I hope...";    mes "Is there anything I can help";    mes "you with?";    mes " ";    mes "^777777~ You've completed "+callfunc("F_InsertPlural",Mission_Total,"mission",0,"^0055FF%d^777777 %s")+". ~^000000";    next;    switch(select(((!Mission0)?" ~ New Mission::":": ~ Mission Status: ~ Abandon Mission")+": ~ Information: ~ Mission Shop: ~ View Top Hunters: ~ ^777777Cancel^000000")) {    case 1:        mes "[Hunting Missions]";        if (#Mission_Count) {            mes "You've started a mission";            mes "on another character.";            close;        }        if (#Mission_Delay > gettimetick(2) && .Delay) {            mes "I'm afraid you'll have to wait "+callfunc("Time2Str",#Mission_Delay)+" before taking another mission.";            close;        }        mes "You must hunt:";        query_sql("SELECT ID FROM `" + .mob_db$ + "` WHERE left(Sprite, 4) != 'meta' AND left(Sprite, 2) != 'E_' AND ~Mode & 32 AND EXP > 0 AND MVP1id = 0 AND DropCardid > 4000 AND DropCardid < 5000 AND ID < 2000 AND instr('"+.Blacklist$+"',ID) = 0 ORDER BY rand() LIMIT "+.Quests, .@mob);        for (set .@i,0; .@i<.Quests; set .@i,.@i+1) {            setd "Mission"+.@i, .@mob[.@i];            setd "Mission"+.@i +"_",0;        }        set #Mission_Count, rand(.Count[0],.Count[1]);        callsub Mission_Status;        next;        mes "[Hunting Missions]";        mes "Report back when";        mes "you've finished.";        mes "Good luck!";        close;    case 2:        mes "[Hunting Missions]";        mes "Mission status:";        callsub Mission_Status;        close;    case 3:        mes "[Hunting Missions]";        mes "Do you really want to";        mes "abandon your mission?";        if (.Reset < 0 && .Delay)            mes "Your delay time will not be reset.";        else if (.Reset > 0)            mes "It will cost "+callfunc("F_InsertComma",.Reset)+" Zeny.";        next;        switch(select(" ~ Abandon...: ~ ^777777Cancel^000000")) {        case 1:            if (.Reset > 0) {                if (Zeny < .Reset) {                    mes "[Hunting Missions]";                    mes "You don't have enough";                    mes "Zeny to drop this mission.";                    emotion e_sry;                    close;                }                set Zeny, Zeny-.Reset;                emotion e_cash;            }            mes "[Hunting Missions]";            mes "Alright, I've dropped";            mes "your current mission.";            specialeffect2 EF_STORMKICK4;            for(set .@i,0; .@i<.Quests; set .@i,.@i+1) {                setd "Mission"+.@i,0;                setd "Mission"+.@i+"_",0;            }            set #Mission_Count,0;            if (.Reset < 0 && .Delay) set #Mission_Delay, gettimetick(2)+(.Delay*3600);            close;        case 2:            mes "[Hunting Missions]";            mes "I knew you were kidding!";            mes "Keep up the good work.";            emotion e_heh;            close;        }    case 4:        callsub Mission_Info;        close;    case 5:        mes "[Hunting Missions]";        mes "You have ^0055FF"+#Mission_Points+"^000000 Mission Points.";        mes "Use them well!";        callshop "mission_shop",1;        npcshopattach "mission_shop";        end;    case 6:        mes "[Hunting Missions]";        mes "The top hunters are:";        query_sql("SELECT char_id AS id, (SELECT `name` FROM `char` WHERE char_id = id),`value` FROM `global_reg_value` WHERE str = 'Mission_Total' ORDER BY CAST(`value` AS SIGNED) DESC LIMIT 5",.@id,.@name$,.@val);        for(set .@i,0; .@i<5; set .@i,.@i+1)            mes " [Rank "+(.@i+1)+"] "+((.@name$[.@i] == "")?"^777777none":"^0055FF"+.@name$[.@i]+"^000000 : ^FF0000"+.@val[.@i]+" pt.")+"^000000";        close;    case 7:        mes "[Hunting Missions]";        mes "Nothing? Okay...";        emotion e_hmm;        close;    }Mission_Status:    set @f,0;    deletearray .@j[0], getarraysize(.@j);    for(set .@i,0; .@i<.Quests; set .@i,.@i+1) {        set .@j[.@i], getd("Mission"+.@i);        set .@j[.Quests], .@j[.Quests]+strmobinfo(3,.@j[.@i]);        set .@j[.Quests+1], .@j[.Quests+1]+(strmobinfo(6,.@j[.@i])/(getbattleflag("base_exp_rate")/100)*.Modifier[0]);        set .@j[.Quests+2], .@j[.Quests+2]+(strmobinfo(7,.@j[.@i])/(getbattleflag("job_exp_rate")/100)*.Modifier[1]);        mes " > "+Chk(getd("Mission"+.@i+"_"),#Mission_Count)+strmobinfo(1,.@j[.@i])+" ("+getd("Mission"+.@i+"_")+"/"+#Mission_Count+")^000000";    }    // Reward formulas:    set .@Mission_Points, 3+(.@j[.Quests]/.Quests/6);    set .@Base_Exp, #Mission_Count*.@j[.Quests+1]/5;    set .@Job_Exp, #Mission_Count*.@j[.Quests+2]/5;    set .@Zeny, #Mission_Count*.Quests*.@j[.@i]*.Modifier[2];    next;    mes "[Hunting Missions]";    mes "Mission rewards:";    mes " > Mission Points: ^0055FF"+.@Mission_Points+"^000000";    mes " > Base Experience: ^0055FF"+callfunc("F_InsertComma",.@Base_Exp)+"^000000";    mes " > Job Experience: ^0055FF"+callfunc("F_InsertComma",.@Job_Exp)+"^000000";    mes " > Zeny: ^0055FF"+callfunc("F_InsertComma",.@Zeny)+"^000000";    if (@f) { set @f,0; return; }    next;    mes "[Hunting Missions]";    mes "Oh, you're done!";    mes "Good work.";    mes "Here's your reward.";    emotion e_no1;    specialeffect2 EF_ANGEL;    specialeffect2 EF_TRUESIGHT;    set #Mission_Points, #Mission_Points+.@Mission_Points;    set BaseExp, BaseExp+.@Base_Exp;    set JobExp, JobExp+.@Job_Exp;    set Zeny, Zeny+.@Zeny;    for(set .@i,0; .@i<.Quests; set .@i,.@i+1) {        setd "Mission"+.@i,0;        setd "Mission"+.@i+"_",0;    }    set #Mission_Count,0;    if (.Delay) set #Mission_Delay, gettimetick(2)+(.Delay*3600);    set Mission_Total, Mission_Total+1;    if (Mission_Total == 1) query_sql("INSERT INTO `global_reg_value` (`char_id`,`str`,`value`,`type`,`account_id`) VALUES ("+getcharid(0)+",'Mission_Total','1',3,0)");    else query_sql("UPDATE `global_reg_value` SET `value` = "+Mission_Total+" WHERE char_id = "+getcharid(0)+" AND `str` = 'Mission_Total'");    close;Mission_Info:    mes "[Hunting Missions]";    mes "If you so choose, I can assign";    mes "you a random hunting quest.";    mes "Some are easier than others, but";    mes "the rewards increase with difficulty.";    next;    mes "[Hunting Missions]";    mes "Missions points are shared";    mes "amongst all your characters.";    if (.Delay) mes "Delay time is, too.";    mes "You can't take missions on";    mes "multiple characters at once.";    next;    mes "[Hunting Missions]";    mes "You can start a quest";    if (.Delay) mes "every "+((.Delay == 1)?"hour.":.Delay+" hours.");    else mes "whenever you want.";    mes "That's everything~";    return;function Chk {    if (getarg(0) < getarg(1)) { set @f,1; return "^FF0000"; }    else return "^00FF00"; }OnBuyItem:    set @cost,0;    for(set .@i,0; .@i<getarraysize(@bought_nameid); set .@i,.@i+1)        for(set .@j,0; .@j<getarraysize(.Shop); set .@j,.@j+2)            if (@bought_nameid[.@i] == .Shop[.@j]) {                set @cost, @cost+(.Shop[.@j+1]*@bought_quantity[.@i]);                break;            }    mes "[Hunting Missions]";    if (@cost > #Mission_Points) mes "You don't have enough Mission Points.";    else {        for(set .@i,0; .@i<getarraysize(@bought_nameid); set .@i,.@i+1) {            getitem @bought_nameid[.@i], @bought_quantity[.@i];            dispbottom "Purchased "+@bought_quantity[.@i]+"x "+getitemname(@bought_nameid[.@i])+".";        }        set #Mission_Points, #Mission_Points-@cost;        mes "Deal completed.";        emotion e_cash;    }    set @cost,0;    deletearray @bought_nameid[0], getarraysize(@bought_nameid);    deletearray @bought_quantity[0], getarraysize(@bought_quantity);    close;OnNPCKillEvent:    if (!getcharid(1) || !.Party) {        if (!#Mission_Count || !Mission0) end;        for (set .@i, 0; .@i<.Quests; set .@i,.@i+1) {            if (strmobinfo(1,killedrid) == strmobinfo(1,getd("Mission"+.@i))) {                if (getd("Mission"+.@i+"_") < #Mission_Count) {                    dispbottom "[Hunting Mission] Killed "+(set(getd("Mission"+.@i+"_"),getd("Mission"+.@i+"_")+1))+" of "+#Mission_Count+" "+strmobinfo(1,killedrid)+".";                    end;                }            }        }    } else if (.Party) {        set .@mob, killedrid;        getmapxy(.@map1$,.@x1,.@y1,0);        getpartymember getcharid(1),1;        getpartymember getcharid(1),2;        for(set .@i,0; .@i<$@partymembercount; set .@i,.@i+1) {            if (isloggedin($@partymemberaid[.@i], $@partymembercid[.@i])) {                attachrid $@partymemberaid[.@i];                if (#Mission_Count && Mission0 && HP > 0) {                    getmapxy(.@map2$,.@x2,.@y2,0);                    if ((.@map1$ == .@map2$ || .Party == 1) && (distance(.@x1,.@y1,.@x2,.@y2) <= 30 || .Party < 3)) {                        for(set .@j,0; .@j<.Quests; set .@j,.@j+1) {                            if (strmobinfo(1,.@mob) == strmobinfo(1,getd("Mission"+.@j))) {                                if (getd("Mission"+.@j+"_") < #Mission_Count) {                                    dispbottom "[Hunting Mission] Killed "+(set(getd("Mission"+.@j+"_"),getd("Mission"+.@j+"_")+1))+" of "+#Mission_Count+" "+strmobinfo(1,.@mob)+".";                                    break;                                }                            }                        }                    }                }            }        }    }    end;OnInit:    set .Delay,12;        // Quest delay, in hours (0 to disable).    set .Quests,4;        // Number of subquests per mission (increases rewards).    set .Party,3;        // Party options: 0 (exclude party kills), 1 (include party kills), 2 (same map only), 3 (screen area only)    set .Reset,-1;        // Reset options: -1 (abandoning mission sets delay time), 0 (no delay time), [Zeny] (cost to abandon mission, no delay time)    setarray .Count[0],    // Min and max monsters per subquest (increases rewards).        40,70;    setarray .Modifier[0],    // Multipliers for Base Exp, Job Exp, and Zeny rewards.        getbattleflag("base_exp_rate")/100,getbattleflag("job_exp_rate")/100,60;    set .mob_db$,        // Table name of SQL mob database        (checkre(0))?"mob_db_re":"mob_db";    setarray .Shop[0],    // Reward items: <ID>,<point cost> (about 10~20 points per hunt).        512,1,513,1,514,1,538,5,539,5,558,10,561,10;    set .Blacklist$,    // Blacklisted mob IDs.        "1062,1088,1183,1186,1200,1212,1220,1221,1234,1235,"+        "1244,1245,1250,1268,1290,1293,1294,1296,1298,1299,"+        "1300,1301,1303,1304,1305,1306,1308,1309,1311,1313,"+        "1515,1588,1618,1676,1677,1678,1679,1796,1797,1974,"+        "1975,1976,1977,1978,1979";    npcshopdelitem "mission_shop",512;    for(set .@i,0; .@i<getarraysize(.Shop); set .@i,.@i+2)        npcshopadditem "mission_shop", .Shop[.@i], .Shop[.@i+1];    end;}-    shop    mission_shop    -1,512:-1

     

     


  5.  

     

     

     

     

    This can be simulated using numerous NPCs and just summon them to your location. However, this is a resource heaven way of doing it.

     

    Right now I don't think there is a way of doing what you want. But I've been wrong before.

     

    There's a server who have it.. made by Cydh.

     

    is cydh selling it?

    no. xD

    then if no. it is free then .haha :). I'm hoping you will be releasing it for free

    people say "I'm not selling my life" means also they won't share their life. :P

    I'm not selling it nor sharing it.

     

    but, once upon a time. xD @Dastgir said want to make it

    T_T. well i'm looking forward to the source development sir @Dastgir :)


  6.  

     

     

    This can be simulated using numerous NPCs and just summon them to your location. However, this is a resource heaven way of doing it.

     

    Right now I don't think there is a way of doing what you want. But I've been wrong before.

     

    There's a server who have it.. made by Cydh.

     

    is cydh selling it?

    no. xD

    then if no. it is free then .haha :). I'm hoping you will be releasing it for free


  7.  

    This can be simulated using numerous NPCs and just summon them to your location. However, this is a resource heaven way of doing it.

     

    Right now I don't think there is a way of doing what you want. But I've been wrong before.

     

    There's a server who have it.. made by Cydh.

    is cydh selling it?


  8. a player types @market <message>. then a clone that have the same name as the player who typed @market will popup to your place with a chat room containing the message you typed in the @market. Then when another player clicks the pub of the clone. a message will pop up that she/he should pm the player because it is only a clone.


  9. how to set the time limit per account not per player? thank you

    function t;function s;	if ( cooldown_warp > gettimetick(2) ) {		mes "you must wait "+ t( cooldown_warp - gettimetick(2) );		close;	}	warp .map$,0,0;	cooldown_warp = gettimetick(2) + 3600;// 3600 secs = 1h	addtimer ( 3 *60 *1000 ), strnpcinfo(3) +"::OnEvent";// 3mins	end;OnEvent:	dispbottom "Gold Hunt is Over";	warp "invek",146,173;	end;function t {	if ( ( .@left = getarg(0) ) <= 0 ) return getarg(0);	.@week = .@left / ( 86400 * 7 );	.@day = .@left / 86400;	.@hour = .@left % 86400 / 3600;	.@min = .@left % 3600 / 60;	.@sec = .@left % 60;	return ( ( .@week ? .@week +" week"+ s( .@week ) : "" ) + ( .@day ? .@day +" day"+ s( .@day ) : "" ) + ( .@hour ? .@hour +" hour"+ s( .@hour ) : "" ) + ( .@min ? .@min +" min"+ s( .@min ) : "" ) + ( .@sec ? .@sec +" sec"+ s( .@sec,1 ) : "" ) );function s { return ( ( getarg(0) > 1 ? "s" : "" ) + ( getarg(1,0) ? "" : " " ) ); }}

  10.  

     

     

     

    you can edit it in mmo.

     

    trunksrccommonmmo

    Sir my client needs to be hexed

    Dude, what kind of hex do you want or you want to diff your client? I'm also using 20100730 with 9 char slot and i didn't hex my client only you need todo is apply diff to your client..

    I already diff my server 

    #define MAX_CHARS 9 

    and recompiled but this i can't create a new character in the other slots

    try to downlaod latest rev.

    I'm using the latest revision.


  11.  

     

    you can edit it in mmo.

     

    trunksrccommonmmo

    Sir my client needs to be hexed

    Dude, what kind of hex do you want or you want to diff your client? I'm also using 20100730 with 9 char slot and i didn't hex my client only you need todo is apply diff to your client..

    I already diff my server 

    #define MAX_CHARS 9 

    and recompiled but this i can't create a new character in the other slots


  12. Sorry sir.

    I didn't saw it 

     

    -	script	Sample	-1,{OnInit:	set .Delay,3600;	end;OnPCKillEvent:	if( .Delay < gettimetick(2) ){	getitem 7227,1;	announce strcharinfo(0) +"Killed " + rid2name(killedrid) + " At The PVP Room",bc_blue|bc_all;	if( .Delay ) set .Delay,gettimetick(2) + .Delay;}end;}}

    how about this sir?


  13.  

    1st) It's in seconds. You can convert them to minutes or hours yourself. Please see gettimetick script command documentation for it, either in our wiki or the scripting documentation:

     

     

     

    *gettimetick(<tick type>)

     

     

    This function will return the system time in UNIX epoch time (if tick type is 2) or the time since the start of the current day in seconds if tick type is 1.

    Passing 0 will make it return the server's tick, which is a measurement in milliseconds used by the server's timer system. The server's tick is an unsigned int which loops every ~50 days.

    Just in case you don't know, UNIX epoch time is the number of seconds elapsed since 1st of January 1970, and is useful to see, for example, for how long the character has been online with OnPCLoginEvent and OnPCLogoutEvent, which could allow you to make an 'online time counted for conviction only' jail script.

     


     

    2nd) You can use the killedrid var that is set as player value when running that OnPCKillEvent, and rid2name it .

     

    Documentation:

    OnPCKillEvent:

     
    This special label triggers when a player kills another player. The variable 'killedrid' is set to the ID of the player killed.
     
    * rid2name(<rid>)
     
    Converts rid to name. Note: The player/monster/NPC must be online/enabled. Good for PCKillEvent where you can convert 'killedrid' to the name of the player.
     
    Note: rid2name may not produce correct character names since rid means account id. It will return the current online character of the account only.
     
    Answer:
    	announce strcharinfo(0) +"Killed " + rid2name(killedrid) + " At The PVP Room",bc_blue|bc_all;

     


     

    3rd: Variables with an @ prefix are temporary char variables (documentation) that get reset/deleted when logging out. You could make your variables permanent to the characters if you put them without any prefix (documentation).

     

    Full documentation for this part:

     

    Extent can be:
    permanent - They still exist when the server resets.
    temporary - They cease to exist when the server resets.
     
    Prefix: scope and extent
    nothing - A permanent variable attached to the character, the default
     variable type.
    "@" - A temporary variable attached to the character.
     They disappear when the character logs out.

     

    Answer:

    Simply change all @Delay variable names to Delay without the @. This will force the var not to get deleted on log out.

     


     

    Hope it helped you.

    thank you sir

    is this correct?

     

    -	script	Sample	-1,{OnInit:	set .Delay,3600;	end;OnPCKillEvent:	if( .Delay < gettimetick(2) ){	getitem 7227,1;	announce strcharinfo(0) +"Killed " + rid2name(killedrid) + " At The PVP Room",bc_blue|bc_all;	if( .Delay ) set @Delay,gettimetick(2) + .Delay;}end;}}

  14. prontera,1,1,1	script	NoChatVendPront	-1,{OnWhisperGlobal:if (getgroupid()<90){OnInit:setcell "Hallow01",91,113,121,82,cell_nochat,1;setcell "Hallow01",91,113,121,82,cell_novending,1;setcell "Hallow01",99,61,112,49,cell_nochat,1;setcell "Hallow01",99,61,112,49,cell_novending,1;end;}end;} 

    what to do so that gm level greater than level 90 can still create a chatroom


  15. -	script	Sample	-1,{OnInit:	set .Delay,18000;	end;OnPCKillEvent:	if( @Delay < gettimetick(2) ){	getitem 7227,1;	announce strcharinfo(0) +"Killed Someone At The PVP Room",bc_blue|bc_all;	if( .Delay ) set @Delay,gettimetick(2) + .Delay;}end;}}

    how many minutes/hours is 18000 that is set??

     

    also about the announce i would like that the players killed name will pop up. like Killer 1 Killed Killer2

     

    lastly. how to prevent them from bypassing the delay. because they will just reconnect and the delay will be removed already

×
×
  • Create New...

Important Information

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