Jump to content

Emistry

Forum Moderator
  • Posts

    9,779
  • Joined

  • Days Won

    322

Emistry last won the day on September 29

Emistry had the most liked content!

About Emistry

  • Birthday January 1

Profile Information

Recent Profile Visitors

60,668 profile views

Emistry's Achievements

  1. these are reserved for npc sprite or clones. the numbers in these range are usable for monsters
  2. actually, you can also consider another alternative like this .size = getarraysize(.itemid); for ([email protected] = 0; [email protected] < .size; [email protected]++) .total_chance += .itemchance[[email protected]]; [email protected] = rand(.total_chance); for ([email protected] = 0; [email protected] < .size; [email protected]++) { [email protected]_itemchance += .itemchance[[email protected]]; if ([email protected] < [email protected]_itemchance) { getitem .itemid[[email protected]], 1; end; } } this would greatly reduce your array size, and probably perform slightly better
  3. [email protected] = convertpcinfo(.players[[email protected]],CPC_ACCOUNT); getitem .item_win, .count_win, [email protected];
  4. summon monster, set hp to 10, skill invincible on or set immune to damage. the mob shall take only 1 damage afterwards
  5. Emistry

    Autopots

    start with readying the info inside the script. npc/custom/etc/autopot.txt#L25-L36 all the info is there.
  6. you could try something like this. initialize all the character as specific character, then search and replace them randomly. if (abcde$ == "") abcde$ = "____"; // initialize with a dummy character if (compare(abcde$, "_")) { [email protected] = getstrlen(abcde$); do { [email protected] = rand([email protected]); } while (charat(abcde$, [email protected]) != "_")); // search for it setchar(abcde$, .word$[[email protected]], [email protected]); // replace it } message strcharinfo(0), "Letter's Collected : "+ abcde$;
  7. OnPCAttackEvent: if (strcharinf(3) != "prontera") end; // <--- change to the punching bag map message strcharinfo(0), "You have dealt "+ @damage +" damage to Punching Bag"; end;
  8. may refer this post for guide to fix the account_id issue. https://rathena.org/board/topic/131467-need-help-sql-db-error-pls-thanks/#comment-407968
  9. may refer this post for guide to fix the account_id issue. https://rathena.org/board/topic/131467-need-help-sql-db-error-pls-thanks/#comment-407968
  10. conf\log_athena.conf // Enable Logs? (Note 3) ... ... // 0x00000010 - (S) Log NPC transactions (buy/sell) ... ... enable_logs: 0x00000010 load the NPC prontera,155,181,5 script Sample 757,{ [email protected]$ = "SELECT `nameid`, SUM(`amount`) AS `total` FROM `picklog` WHERE `type` = 'S' AND `amount` > 0 GROUP BY `nameid` ORDER BY `total` DESC LIMIT 10"; [email protected] = query_sql([email protected]$, [email protected], [email protected]); mes "Items:"; for ([email protected] = 0; [email protected] < [email protected]; [email protected]++) mes getitemname([email protected][.[email protected]])+" - "+F_InsertComma([email protected][[email protected]]); close; } however there is no way telling how much NPC have earned or lost from the transaction since it's not log.
  11. [email protected] = select( [email protected]$ ) - 1; setarray [email protected], LOOK_HEAD_TOP, LOOK_HEAD_MID, LOOK_HEAD_BOTTOM; if (getlook([email protected][[email protected]]) <= 0) { dispbottom [email protected]$[[email protected]] +" is already hidden"; end; }
  12. bonus bMatk,(getrefine() + 10); Magical attack power +10 per refine bonus bMatkRate,(getrefine() + 2); Magical attack power + 2% per refine
×
×
  • Create New...

Important Information

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