ittiphol

Members
  • Content Count

    54
  • Avg. Content Per Day

    0
  • Joined

  • Last visited

Community Reputation

0 Neutral

About ittiphol

  • Rank
    Santa Poring

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. This script it's works fine but not use Auto Potion on attack I must use this script please fix on this script please help .... //===== rAthena Script ======================================= //= Auto-Potion //===== By: ================================================== //= Euphy //===== Current Version: ===================================== //= 1.0 //===== Compatible With: ===================================== //= rAthena Project //===== Description: ========================================= //= Provides an @autopot command to automatically use potions //= when hit (i.e. 'autobonus2'). //===== Additional Comments: ================================= //= 1.0 First version. [Euphy] //============================================================ - script #autopot -1,{ OnInit: bindatcmd("autopot",strnpcinfo(0)+"::OnCommand"); end; L_Help: dispbottom "Available commands:"; dispbottom " @autopot <item id> {<min hp % [1..100]> {<delay [50..1000]>}}"; dispbottom " @autopot <on|off>"; dispbottom " @autopot list"; dispbottom " @autopot info"; dispbottom " @autopot help"; return; L_Info: dispbottom "------ Auto-Potion Information ------"; dispbottom "POTION: " + getitemname(@autopot_id) + " (" + @autopot_id + ")"; dispbottom "MIN HP: " + @autopot_min + " %"; dispbottom "DELAY: " + @autopot_delay + " ms"; dispbottom "---------------------------------------------"; return; L_Start: [email protected] = getarg(0); [email protected] = getarg(1); [email protected] = getarg(2); if ([email protected] < 1 || [email protected] > 100) [email protected] = 90; if ([email protected] < 50 || [email protected] > 1000) [email protected] = 50; // lower values will increase server strain switch ([email protected]) { case 501: case 507: case 545: case 569: [email protected] = EF_POTION1; break; case 502: [email protected] = EF_POTION2; break; case 503: case 508: case 546: case 579: case 11500: [email protected] = EF_POTION3; break; case 504: case 509: case 547: case 11501: case 11503: case 11548: [email protected] = EF_POTION4; break; case 512: case 513: case 515: case 516: case 548: case 549: case 550: case 582: case 607: [email protected] = EF_POTION7; break; default: [email protected] = EF_EXIT; break; } if (BaseLevel < getiteminfo([email protected],12)) { message strcharinfo(0), "Your base level is too low to use '" + getitemname([email protected]) + "'."; end; } @autopot_id = [email protected]; @autopot_min = [email protected]; @autopot_delay = [email protected]; @autopot_eff = [email protected]; @autopot_none = 0; bonus_script "{ callfunc \"start_autopot\"; }",86400,8,0,SI_INCHEALRATE; message strcharinfo(0), "Auto-Potion started."; callsub L_Info; return; OnCommand: if (!getarraysize([email protected]_parameters$)) { message strcharinfo(0), "Invalid syntax."; callsub L_Help; end; } [email protected]$ = strtolower([email protected]_parameters$[0]); if ([email protected]$ == "on") { if (@autopot_min) message strcharinfo(0), "Auto-Potion is already on."; else if (@autopot_min_) { @autopot_min = @autopot_min_; @autopot_min_ = 0; message strcharinfo(0), "Auto-Potion enabled."; callsub L_Info; } else { message strcharinfo(0), "Auto-Potion has not been set."; callsub L_Help; } end; } else if ([email protected]$ == "off") { if ([email protected]_min) message strcharinfo(0), "Auto-Potion is already off."; else { @autopot_min_ = @autopot_min; @autopot_min = 0; message strcharinfo(0), "Auto-Potion disabled."; } end; } else if ([email protected]$ == "list") { // credits to AnnieRuru getinventorylist; for (; [email protected] < @inventorylist_count; [email protected]++) { if (getiteminfo(@inventorylist_id[[email protected]],2) == IT_HEALING) { [email protected][[email protected]] = @inventorylist_id[[email protected]]; [email protected]$ = [email protected]$ + sprintf("~ ^0055FF%s^000000 (%dx):", getitemname(@inventorylist_id[[email protected]]), countitem(@inventorylist_id[[email protected]])); [email protected]++; } } if ([email protected]) { // 'mes' window needed if player is hit during selection mes "[ Auto-Potion ]"; mes "Select a healing item."; [email protected] = select([email protected]$ + " ^777777Cancel^000000") - 1; if ([email protected] != [email protected]) callsub L_Start, [email protected][[email protected]], 0, 0; close2; } else message strcharinfo(0), "There are no healing items in your inventory."; end; } else if ([email protected]$ == "info") { if (@autopot_min) { message strcharinfo(0), "Auto-Potion information is displayed below."; callsub L_Info; } else message strcharinfo(0), "Auto-Potion is not enabled."; end; } else if ([email protected]$ == "help") { message strcharinfo(0), "List of commands is displayed below."; callsub L_Help; end; } else { [email protected] = atoi([email protected]_parameters$[0]); if (getiteminfo([email protected],2) != IT_HEALING) { message strcharinfo(0), getitemname([email protected]) + " is not a healing item."; end; } callsub L_Start, [email protected], atoi([email protected]_parameters$[1]), atoi([email protected]_parameters$[2]); end; } } function script start_autopot { if (@autopot_active) end; @autopot_active = 1; while (Hp && Hp * 100 / MaxHp < @autopot_min) { if (!countitem(@autopot_id)) { if (@autopot_none <= gettimetick(2)) { @autopot_none = gettimetick(2) + 10; dispbottom "There are no '" + getitemname(@autopot_id) + "' in your inventory."; } break; } if (getstatus(SC_BERSERK) || getstatus(SC_SATURDAYNIGHTFEVER) || getstatus(SC_GRAVITATION) || getstatus(SC_TRICKDEAD) || getstatus(SC_HIDING) || getstatus(SC__SHADOWFORM) || getstatus(SC__INVISIBILITY) || getstatus(SC__MANHOLE) || getstatus(SC_KAGEHUMI) || getstatus(SC_HEAT_BARREL_AFTER)) break; if (getstatus(SC_STONE) || getstatus(SC_FREEZE) || getstatus(SC_STUN) || getstatus(SC_SLEEP)) ; else { delitem @autopot_id,1; consumeitem @autopot_id; specialeffect2 @autopot_eff; } sleep2 @autopot_delay; } @autopot_active = 0; autobonus2 "{}",10000,1,BF_WEAPON|BF_MAGIC; end; }
  2. how to use this script by callfunc not type in textbox chat thank you.
  3. autopot.txt it's works fine autopot.txt it's use only type text box but now i try apply to item to use it thank you
  4. Need help compile is error how to fixit
  5. ittiphol

    Autopots & RCX

    Need help compile is error how to fixit thankyou...
  6. Need help about Script auto storage how can i take item from the store i mean auto when item in inventory is empty please script advance..
  7. yes please wait i sent id to your pm.
  8. That's broblem how to do by manually please... i'm try to learn five days - -*
  9. yes i do but it's still error
  10. i dit't not i'm use to program in the picture 2 code is open it's selfe
  11. Thank you i'm try ... i still don't understand look at the pictures
  12. i'm try but i don't understand please you can to patch this file for me please.... @autoattack rAthena SVN 17726.patch @AutoAttack (1).patch @autopots_3.patch autoattack (1).diff
  13. i search everywhere i need someone to teach me step to step to compile 1... 2... 3..... i want to compile - @AutoAttack.patch - @Autopots_3.patch please help - -*