Jump to content

IndieRO

Members
  • Content Count

    286
  • Joined

  • Last visited

  • Days Won

    13

Reputation Activity

  1. Upvote
    IndieRO reacted to quesoph in how can i add soul link buffs on this script?   
    -  script  Healer  -1,{    set .@Price,0;  // Zeny required for heal  set .@Buffs,1;  // Also buff players? (1: yes / 0: no)  set .@Delay,0;  // Heal delay, in seconds  callfunc "F_ClearGarbage",0;  switch ( BaseJob ) {    case 18:  .@spirit = 445; break;    case 20:    case 15:  .@spirit = 447; break;    case 19:  .@spirit = 455; break;    case 4047: .@spirit = 448; break;    case 17:  .@spirit = 456; break;    case 16:  .@spirit = 449; break;    case 12:  .@spirit = 457; break;    case 14:  .@spirit = 450; break;    case 10:  .@spirit = 458; break;    case 23:  .@spirit = 451; break;    case 11:  .@spirit = 460; break;    case 7: .@spirit = 452; break;    case 4049:  .@spirit = 461; break;    case 8: .@spirit = 454; break;    case 9: .@spirit = 453; break;  }  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;    set Zeny, Zeny-.@Price;  }  specialeffect2 EF_HEAL2; percentheal 100,100;      if (.@Buffs) {    for( .@i = 0; .@i < getarraysize( .Buffs$ ); .@i++ ) {      .@sum = atoi(.@b$[.@i]) + .min_Levels[.@i];      .@j = .Buffs$[.@i];      stand (strcharinfo(0)); // <- Added this so characters dont get stuck when soul link is casting.      if( .@sum )        sc_start4 .@j, 240000, 5,  .@spirit,0,0;      if ( .min_Levels[3] )        skilleffect .@spirit, 5;   // Start Soul Link Effect.    }  }  if (.@Delay) set @HD, gettimetick(2)+.@Delay;  close;OnInit:  setarray .Buffs$, SC_INC_AGI, SC_BLESSING, SC_KYRIE, SC_SOULLINK;  setarray .min_Levels,    5,   5, 1, 5;  end;  }prontera,163,185,6  duplicate(Healer)  Healer1#alb  909
  2. Upvote
    IndieRO reacted to Dastgir in Mob Avail copy of mob ID   
    not ok to ignore, its constants used for scripts(if there's any script, like disguise), you see the 2 mob id's 1120 and 3188, having same name GHOSTRING, just change it. add a _, to avoid any more warnings.
  3. Upvote
    IndieRO reacted to GmOcean in Scripting Tutorials & Guides   
    Scripting Tutorials and Guides
    I'm going to attempt to help everyone here with their scripts while not being directly involved in helping you with them xD.
    This will also help future/current scripters get some fresh info and maybe inspire innovative ideas towards scripting.
    So that we can prove that us " Scripters " are the superior ragnarok emulation race! Take that Source Code writers!! Jk lol, we need you too .

    What I'm going to do, is write detailed tutorials on how to write a few scripts. Starting from the basics to more advanced scripts.
    This way everyone can follow along. And hopefully this will help everyone understand how to write a few scripts and even troubleshoot their own scripts.
     
    Also please read: Scripting Standards.
    It will help you understand how to read some of the syntax and way people script things.
    // A list of <sprite id>s can be found here: Sprite_IDs Credits: Ai4rei
    Scripting Tutorials & Guides
    In this section you will learn how to write scripts ranging from Complete Begginer Level Scripts ( Me and Some of you ) -> Expert Level Scripts ( Think, Developer Status O.o; )
    - Beginner Scripts -
    Scripts for complete beginners and novice scripters.
     
     
    - Intermediate Scripts -
    Scripts for intermediate level scripters. If you completed my beginner script series, then you are ready for this section.
     
     
    - Advanced Scripts -
    Scripts for advanced level scripters. If you completed my intermediate script series and have made a few of your own intermediate scripts, then you are ready for this section.
     
     
    The idea behind this topic, is for new users, and current ones, to have a (second)place they can go to for reference when trying to write a script if they can't figure it out with script_commands.txt file. It will also help people learn how to write scripts. While hopefully, keeping script writing techniques to a ' very ' similar structure!
     
    *Read Me* - I have updated the links on this post to link to the oldboard so these guides can be viewed. However, do note that the script_commands.txt links within those guides are no longer accurate. Enjoy your scripting.
  4. Upvote
    IndieRO reacted to Haru in Scripting Tutorials & Guides   
    Mumbles: see my reply in the pull request. It actually becomes easier with .@select, as you don't even need to use the @menu variable.
     
    Garr: but using labels is even worse than using a switch, and makes the script less readable. If several options lead to the same result, their case labels in the switch can be grouped together without break in between, if you don't wish to use select. Or, nobody forces you to use a switch, and you can use if/else conditions if you prefer.
     

    switch (select("a:b:c:d:e")) {case 1:case 2:case 4: mes "a, b and d lead here."; break;case 3: mes "this is c."; break;}// and e does nothing Or
     

    .@choice = select("a:b:c:d:e"));if (.@choice == 3) { mes "this is c.";} else if (.@choice < 5) { mes "a, b and d lead here.";}// and e does nothing
  5. Upvote
    IndieRO reacted to Lamex in DailyRewards like this one so cool!   
    I got a code from Stolao's "Daily login reward 1.59" for this sample.
     
    //===== EinherjarRO Scripts ================================== //= Daily Prize, OnPCLoginEvent //===== By: ================================================== //= Stolao //===== Current Version: ===================================== //= 1.59 //===== Compatible With: ===================================== //= rAthena SVN //===== Description: ========================================= //= A reward system for players who play more frequently //===== Comments: ============================================ //= Maybe Make .MinWait an array mins,days,weeks,months,years; //===== Additional Comments: ================================= //= For Older See Forums //= 1.51 Changed set .@g formula and move lower into script //= 1.52 Replace all disbottom -> message //= 1.53 Changed Format to Include minuets instead of just hours //= 1.54 Made Time till next rewards display dynamic //= 1.55 Changed a forgotten .PointType$ -> getd(.@TT[1]) //= 1.56 changed .@XT -> .@XT$ //= 1.57 Added Atoi where nessisary //= 1.58 Fixed a swapped .@x and .@x+1 //= 1.59 Serveral Edit Undocumented to fix //===== Contact Info: ======================================== //= [Stolao] //= Email: [email protected] //============================================================ - script LOGIN -1,{ OnWhisperGlobal: OnLoginCmnd: OnPCLoginEvent: sleep2 1000 + .Rest * 60000; set .@i, (gettime(7) * 365 * 24 * 60) + (gettime(8) * 24 * 60) + (gettime(3) * 60) +gettime(2); if(.@i >= (#LastDailyReward + .MinWait)){ if(.@i < #LastDailyReward + .MaxWait){ set #DRewardCon, #DRewardCon + 1; } else { set #DRewardCon, 1; } set .@g, (#DRewardCon > getarraysize(.Rewards$)) ? (getarraysize(.Rewards$)-1) : #DRewardCon; explode(.@XT$,.Rewards$[.@g],"|"); for(set .@x,0; .@x < getarraysize(.@XT$); set .@x,.@x + 1){ set .@TT[.@x], atoi(.@XT$[.@x]); } if(.Mode & 1 && .@TT[4]){ //[Note]: I need to figure out a checkweight for all items tired atm lol, for now ill leave it missing for(set .@x,4; .@x < getarraysize(.@TT); set .@x,.@x + 2){ getitem .@TT[.@x], .@TT[.@x+1]; message strcharinfo(0),"Recived "+ .@TT[.@x+1] +" "+ getitemname(.@TT[.@x]); } } if(.Mode & 2){ if(.@TT[0]){ set zeny,zeny + .@TT[0]; message strcharinfo(0),"Recived "+ .@TT[0] +"z"; } if(.@TT[1]){ setd getd(.Points$[0]),getd(.Points$[0]) + .@TT[1]; message strcharinfo(0),"Recived "+ .@TT[1] +" "+.Points$[1]; } } if(.Mode & 4 && (.@TT[3] || .@TT[4])) getexp .@TT[3], .@TT[4]; if(.Mode & 8){ for(set .@x,0; .@x < getarraysize(.BuffInfo); set .@x,.@x + 4){ if(#DRewardCon % .BuffInfo[.@x + 1] == 0) sc_start .BuffInfo[.@x], .BuffInfo[.@x + 2] * 60000, .BuffInfo[.@x + 3]; } } message strcharinfo(0),"You have collected your daily reward, for "+#DRewardCon+" day"+((#DRewardCon > 1)?"s":"")+" in a row."; //===============Display of pic's with day highlighted.======================= cutin .Pic$[.@g],4; //============================================================================ set #LastDailyReward, .@i; } else { set .@days,(#LastDailyReward + .MinWait - .@i)/60/24; set .@hours,((#LastDailyReward + .MinWait - .@i)/60)%24; set .@mins,(#LastDailyReward + .MinWait - .@i)%60; message strcharinfo(0),"You have "+ ((.@days) ? .@days +":Days " : "") +""+ ((.@hours) ? .@hours +":Hours " : "") +""+ ((.@mins) ? .@mins +":Minutes " : "") +"till your next reward"; } end; OnInit: //Basic Settings // 1: Item | 2: Points | 4: Exp // 8: Gain Buffs Every X Consecutive Days logged in // (a bit value, e.g. 3 = Items & Points from Multi) set .Mode,1; //To Enable @ Command '@loginreward' unslash next lines // * Needs extra commands for typos bindatcmd("relog" ,"LOGIN::OnLoginCmnd",0,99); //Minimum Minuets Between Collecting Daily Reward // Day: 22*60 - 24*60 // Week: 10080 set .MinWait,1; //Minuets Before Lose Consecutive Daily Reward // Day: 48*60 - 50*60 // Week: 20160 set .MaxWait,3000; //Number of mins after logging before collecting prize set .Rest,0; //Point Type // [0] Points earned // [1] Point name in mes setarray .Points$,"#KAFRAPOINTS","K-Points"; // Consecutive Days Buff // Each buff contains 4 variables (32 Total Max) // <Type>,<Days>,<Duration>,<Rate>, // Buff 1 // <Type>,<Days>,<Duration>,<Rate>, // Buff 2 // ...; // // Example: 188,7,45,3 // -Every 7th consecutive day logged in Player gains +3 Str for 45 mins // // Type is 188, which references which SC_ to use, SC_INCSTR in this example // -For a full list of SC_ visit the db/const.txt // Days is days buff is applied, in this example 7, so every 7th day, 14,21,28.... // Duration is buff duration is Minuits, in this example 45 mins // Rate is buff strength, in this example player gains 3 Str setarray .BuffInfo ,260,2,360,1 // Life Insurance for 360 Mins Every 2nd Day ,198,3,120,10 // +10% Hp for 120 Mins Every 3th Day ,196,5,120,25 // +25 Flee for 120 Mins Every 5th Day ,257,7,240,50; // +50% Exp for 240 Mins Every 7th Day // Daily Prize items (max 128 days): // "<Zeny>|<Points>|<BaseExp>|<JobExp>|<itemID-1>|<amount-1>|<itemID-2>|<amount-2>...etc", // Day 1 // "<Zeny>|<Points>|<BaseExp>|<JobExp>|<itemID-1>|<amount-1>|<itemID-2>|<amount-2>...etc" // Day 2 // ...; // Total length of any days string must be 255 or shorter // * If players login longer than the last set // day, they will keep getting the last prize. setarray .Rewards$, "100", // Day 1: 100 Zeny "0|0|0|0|501|5", // Day 2: 5 Red Potion "0|0|0|0|503|5|506|5"; // Day 3: 5 White Potion + 5 Green Potion setarray .Pic$, "tutorial01", //pic with day1 highlighted "tutorial02", //pic with day2 highlighted "tutorial03"; //pic with day3 highlighted end; }  
    So that's what i added:
     
    1) Way to setup pictures.
    setarray .Pic$, "tutorial01", //pic with day1 highlighted "tutorial02", //pic with day2 highlighted "tutorial03"; //pic with day3 highlighted 2) Way to show em up.
    //===============Display of pic's with day highlighted.======================= cutin .Pic$[.@g],4; //============================================================================  
    Like i said its kinda easy. 
     
    P.S. Script skips one day due 1.59 version bug. So you might want to get a 1.5D and change it if you want to use it at ur server and I set 1min timer to get a reward for testing purposes.
  6. Upvote
    IndieRO reacted to quesoph in [REQUEST] Card Remover (Lazy Edition)   
    prontera,165,185,4  script  Card Remover  100,{  disable_items;  mes "["+strnpcinfo(1)+"]";  mes "Do u want to remove some cards?";  if(select("Remove Card","Close") == 2 ) close;    mes " ","Choose an item.";    setarray .@position$[1], "Head","Body","Left hand","Right hand","Robe","Shoes","Accessory 1","Accessory 2","Head 2","Head 3";    set .@menu$,"";    for( set .@i,1; .@i <= 10; set .@i,.@i+1 ) {      if( getequipisequiped(.@i) )        set .@menu$, .@menu$ + .@position$[.@i] + "-" + "[" + getequipname(.@i) + "]";        set .@menu$, .@menu$ + ":";    }    set .@part, select(.@menu$);    if( !getequipisequiped(.@part) ) {      mes " ","Check Equip.";      close;    }    if(getequipcardcnt(.@part) == 0) {      mes " ","No cards compounded.";      close;    }    successremovecards .@part;    close;}
  7. Upvote
    IndieRO reacted to Dastgir in How to support packet encryption in 2013-08-07a Ragexe   
    Packet First Key Encryption [58AA359A]
    Packet Second Key Encryption [55F86C1E]
    Packet Third Key Encryption [3F094C49]
    Make sure you change those keys in SRC/map/packets.h and recompile
    (Show packets.h if you have done it already)
  8. Upvote
    IndieRO reacted to Dastgir in How to support packet encryption in 2013-08-07a Ragexe   
    You should not use those 3 patches unless you want to modify the packet keys to some custom.Just diff without those and it will work fine(I just saw those are default 20141022 packet keys)
    Those Patches are for custom packet keys...
  9. Upvote
    IndieRO reacted to Ind in Mapflag for Cash Shop   
    added in https://github.com/HerculesWS/Hercules/commit/8629562655cfcbd6aef97307e3e0c078235619ff
  10. Upvote
    IndieRO reacted to Dastgir in How to change Client version in Linux Centos 7   
    It's same method?
    Change from src/common/mmo.h
  11. Upvote
    IndieRO reacted to Angelmelody in Spider Web Limit   
    this?
    skill_db.txt
    405,7,6,1,0,0x1,0,1,1,no,0,0,3,magic,0, PF_SPIDERWEB,Fiber Lock
  12. Upvote
    IndieRO reacted to themon in Bank System English Texture   
    File Name: Bank System English Texture
    File Submitter: themon
    File Submitted: 14 Nov 2013
    File Category: Maps & Textures
     
    I hope you like what I did with this Bank System English Texture
    I replace all the Korean text with English Text
     
    Click here to download this file
  13. Upvote
    IndieRO reacted to Vanquiser in Simple Avast Thor Patcher   
    File Name: Simple Avast Thor Patcher
    File Submitter: Vanquiser
    File Submitted: 09 Jul 2014
    File Category: Other Graphics
     
    Thor Patcher,,, Avast 2014 Based
     
     
    Features
     
     
    Website Button
    Facebook Page Button
    Facebook Group Button
    Donate Button
    Help Button
    Register Button
    Setup Button (Open Setup.exe)
     
     
    BTW Im using MS Paint Only XD...
     
     
    Please Dont Remove Credits, Thx
     
    Click here to download this file
×
×
  • Create New...

Important Information

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