Jump to content

Patskie

Forum Moderator
  • Content Count

    1,648
  • Avg. Content Per Day

    1
  • Joined

  • Last visited

  • Days Won

    9

Patskie last won the day on July 5

Patskie had the most liked content!

Community Reputation

199 Excellent

About Patskie

  • Rank
    superpatskie
  • Birthday 09/22/1993

Profile Information

  • Gender
    Male
  • Location
    Philippines

Contact Methods

  • Discord
    superpatskie#0110

Recent Profile Visitors

107,860 profile views
  1. @Capuche Yeah right i always remember setunitdata and getunitdata for their main attributes only and tend to forget the UMOB_X and UMOB_Y constants as part of it
  2. There should be no issues if you are using latest rAthena (C++ version)
  3. getitem will give the item directly to your inventory, if you want the monster to drop an item "on top" of their natural drops then you can do like below // 1. Go to your src/map/script.cpp // 2. Add below code before "case BL_PC: //Get Character Position" // case BL_MOB: // if (script_hasdata(st,6)) // bl = map_id2bl(script_getnum(st,6)); // break; // 3. Recompile your server // 4. Add below script - script CustomDrop FAKE_NPC,{ OnNPCKillEvent: for ([email protected] = 0; [email protected] < .size; [email protected] += 4) { if (killedrid == .data[[email protected]]) { if (rand(10000) < .data[[email protected] + 3]) { getmapxy [email protected]$, [email protected], [email protected], BL_MOB, killedgid; [email protected] = .data[[email protected] + 2]; while ([email protected]) { makeitem .data[[email protected] + 1], 1, [email protected]$, [email protected], [email protected]; [email protected]; } } } } end; OnInit: // <mob_id>, <item_id>, <item_amount>, <chance> // Chance ======================== // 10000 = 100% // 1000 = 10% // 100 = 1% // 99 = 0.99% // 50 = 0.50% // 1 = 0.01% // =============================== setarray .data[0], 1002, 607, 2, 10000, // poring will drop 2 ygg berries on the floor with 100% chance 1002, 608, 3, 10000; // poring will drop 3 ygg seeds on the floor with 100% chance .size = getarraysize(.data); end; }
  4. You can try below and let me know if it works for you prontera,130,215,5 script Lottery 76,{ function ShowNumbers; function GenerateNumbers; function MatchCount; function GenerateID; function GenerateID { $LWID = $LID; $LID = rand(100000, 999999); return; } function MatchCount { [email protected] = 0; for ([email protected] = 0; [email protected] < .combinations; [email protected]++) { if (inarray($LW, #LW[[email protected]]) != -1) [email protected]++; } return [email protected]; } function ShowNumbers { switch (getarg(0)) { default: case 0: [email protected]$ = "^FF0000"; [email protected]$ = "#LW"; break; case 1: [email protected]$ = "^0000FF"; [email protected]$ = "$LW"; break; case 2: [email protected]$ = "^006600"; [email protected]$ = "$LR"; break; } if (getarg(1, 0)) [email protected]$ = ""; [email protected]$ = [email protected]$; for ([email protected] = 0; [email protected] < .combinations; [email protected]++) [email protected]$ = [email protected]$ + "[" + getd([email protected]$+"["[email protected]+"]") + "] "; if (!getarg(1, 0)) [email protected]$ = [email protected]$ + "^000000"; return [email protected]$; } function GenerateNumbers { [email protected] = 0; deletearray getarg(0); while ([email protected] < .combinations) { do { [email protected] = rand(1, 40); } while (inarray(getarg(0), [email protected]) != -1); set getelementofarray(getarg(0), [email protected]), [email protected]; [email protected]++; } return; } mes .npc$; mes "Winning Lotto Numbers ("+$LWID+"):"; mes ShowNumbers(1, 0); mes "Your Ticket ("+#LID+"):"; mes ShowNumbers(0, 0); mes "Next Draw-ID: ^FF0000" + $LID + "^000000."; next; switch(select((#LID == $LWID ? "Claim Prize" : ""), "Buy New Ticket", (getgmlevel() < .gm_level ? "" : "^FF0000[GM]^000000 Do Draw Now"), (getgmlevel() < .gm_level ? "" : "^FF0000[GM]^000000 Rig the Lottery"), "Cancel")) { default: break; // Claim Prize case 1: [email protected]_count = MatchCount(); if ([email protected]_count != .combinations) { mes .npc$; mes "Bad luck, it appears you do not hold a winning ticket."; next; mes .npc$; mes "Better luck next time!."; close; } mes .npc$; mes "You have matched all " + .combinations + " numbers!"; mes "Jackpot!"; mes "You've won ^0000FF" + F_InsertComma(.jackpot_zeny) + "^000000z & " + .jackpot_items[1] + " " + getitemname(.jackpot_items[0]) + "!"; Zeny = (Zeny + .jackpot_zeny) > 2147483647 ? 2147483647 : (Zeny + .jackpot_zeny); getitem .jackpot_items[0], .jackpot_items[1]; announce "Lottery: " + strcharinfo(0) + " has won the JACKPOT of " + F_InsertComma(.jackpot_zeny) + "z & " + .jackpot_items[1] + " " + getitemname(.jackpot_items[0]) + "!", 0; #LID = 0; break; // Buy New Ticket case 2: if (#LW && #LID == $LID) { mes .npc$; mes "It appears that you already have a ticket for today."; mes "You may only purchase one ticket per draw."; close; } mes .npc$; mes "Tickets cost ^0000FF" + F_InsertComma(.ticket_price) + "^000000z."; mes "The Jackpot is ^FF0000" + F_InsertComma(.jackpot_zeny) + "^000000z & " + .jackpot_items[1] + " " + getitemname(.jackpot_items[0]) + "!"; next; if (Zeny < .ticket_price) { mes .npc$; mes "You can't afford a lottery ticket."; close; } mes .npc$; mes "Would you like your numbers hand picked or computer generated?"; next; switch(select("Computer Generated", "Hand Picked")) { case 1: while (true) { mes .npc$; mes "The computer has selected the following numbers:"; GenerateNumbers(#LW); mes ShowNumbers(0, 0); next; if (select("Re-Generate", "Confirm") & 2) break; } break; case 2: while (true) { mes .npc$; mes "Please pick your numbers (1-40):"; [email protected] = 0; [email protected] = 0; deletearray #LW; while ([email protected] < .combinations) { if (getarraysize(#LW)) { mes "PICK " + [email protected] + ": ^0000FF" + #LW[[email protected]] + "^000000"; [email protected]++; } do { input @pick; } while (@pick < 1 || @pick > 40 || inarray(#LW, @pick) != -1); #LW[getarraysize(#LW)] = @pick; [email protected]++; } mes "PICK " + [email protected] + ": ^0000FF" + #LW[[email protected]] + "^000000"; next; mes .npc$; mes "Your numbers are:"; mes ShowNumbers(0, 0); next; if (select("Confirm", "Re-Pick") == 1) break; } break; } Zeny -= .ticket_price; #LID = $LID; mes .npc$; mes "The live broadcasted draw is at 9pm."; mes "You can claim your ticket between then and the next draw."; next; mes .npc$; mes "Good luck!"; break; // Do Draw Now case 3: deletearray $LW; if (!$LR) GenerateNumbers($LW); else copyarray $LW, $LR, getarraysize($LR); close2; announce "Lottery: Welcome to the special GM's lotto draw!", 0; sleep 3000; announce "The numbers are as follows: " + ShowNumbers(1, 1), 0; sleep 3000; announce "Congratulations to the winners!", 0; GenerateID(); deletearray $LR; end; // Rig the Lottery case 4: while (true) { mes .npc$; mes "Please pick your numbers (1-40):"; [email protected] = 0; [email protected] = 0; deletearray $LR; while ([email protected] < .combinations) { if (getarraysize($LR)) { mes "PICK " + [email protected] + ": ^0000FF" + $LR[[email protected]] + "^000000"; [email protected]++; } do { input @pick; } while (@pick < 1 || @pick > 40 || inarray($LR, @pick) != -1); $LR[getarraysize($LR)] = @pick; [email protected]++; } mes "PICK " + [email protected] + ": ^0000FF" + $LR[[email protected]] + "^000000"; next; mes .npc$; mes "Your rigged numbers are:"; mes ShowNumbers(2, 0); next; if (select("Confirm", "Re-Pick") == 1) break; } mes .npc$; mes "Lottery rigged for next draw."; break; } close; // Automatic Draw OnClock0200: OnClock0400: OnClock0600: OnClock0800: OnClock1000: OnClock1200: OnClock1600: OnClock1800: OnClock2000: OnClock2006: OnClock2007: OnClock2200: deletearray $LW; if (!$LR) GenerateNumbers($LW); else copyarray $LW, $LR, getarraysize($LR); announce "Lottery: This hour's draw is worth " + F_InsertComma(.jackpot_zeny) + " Zeny and " + .jackpot_items[1] + " " + getitemname(.jackpot_items[0]) + "!!", 0; sleep 3000; announce "The numbers are as follows: " + ShowNumbers(1, 1), 0; sleep 3000; announce "Congratulations to the winners of tonight!", 0; GenerateID(); deletearray $LR; end; OnInit: .npc$ = "[Lottery]"; .gm_level = 99; .combinations = 3; .ticket_price = 100000; .jackpot_zeny = 2000000000; setarray .jackpot_items[0], 501, 20; if (!$LID) GenerateID(); waitingroom "Hourly Lottery",0; end; } You can set below configs as per your desire .gm_level .combinations .ticket_price .jackpot_zeny .jackpot_items
  5. Perhaps along with your code you can tell us how you want it to be implemented?
  6. Since this is a paid script i suggest you message @Daegaladh for help
  7. query_sql("INSERT INTO table VALUES (20000046, 23456, 100, 0, DATE_ADD(NOW(), INTERVAL 7 DAY))");
  8. Try below // if you want to use card trader where you can put multiple cards if u have them in inventory then use below prontera,150,150,6 script Sample 100,{ getinventorylist; for ([email protected] = 0; [email protected] < @inventorylist_count; [email protected]++) { if (getiteminfo(@inventorylist_id[[email protected]], 2) == 6) { [email protected]$ = [email protected]$ + getitemname(@inventorylist_id[[email protected]]) + ":"; [email protected][getarraysize([email protected])] = @inventorylist_id[[email protected]]; [email protected][getarraysize([email protected])] = @inventorylist_amount[[email protected]]; } } [email protected] = 0; mes "Please select 3 cards..."; while ([email protected] < 3) { if (getarraysize([email protected])) { mes "> 1x " + getitemname([email protected][[email protected]]); [email protected]++; } [email protected] = select([email protected]$) - 1; [email protected][getarraysize([email protected])] = [email protected][[email protected]]; cleararray [email protected][[email protected]], ([email protected][[email protected]] < 1 ? 0 : ([email protected][[email protected]]-1)), 1; if ([email protected][[email protected]]) [email protected]$ = replacestr([email protected]$, getitemname([email protected][[email protected]]), ""); [email protected]++; } [email protected] = getarraysize([email protected]); mes "> 1x " + getitemname([email protected][[email protected]]); next; mes "Are you sure you want to trade these cards?"; if (select("~ Yes:~ No") & 2) end; for ([email protected] = 0; [email protected] < [email protected]; [email protected]++) delitem [email protected][[email protected]], 1; getitem rand(4001,4699), 1; close; } // if you want to use distinct card trader, means even if u have 2x poring card you can only trade 1 of them use below prontera,153,153,6 script Sample1 100,{ getinventorylist; for ([email protected] = 0; [email protected] < @inventorylist_count; [email protected]++) { if (getiteminfo(@inventorylist_id[[email protected]], 2) == 6) { [email protected][getarraysize([email protected])] = @inventorylist_id[[email protected]]; [email protected]$ = [email protected]$ + getitemname(@inventorylist_id[[email protected]]) + ":"; } } [email protected] = 0; mes "Please select 3 cards..."; while ([email protected] < 3) { if (getarraysize([email protected])) { mes "> 1x " + getitemname([email protected][[email protected]]); [email protected]++; } [email protected] = select([email protected]$) - 1; [email protected][getarraysize([email protected])] = [email protected][[email protected]]; [email protected]$ = replacestr([email protected]$, getitemname([email protected][[email protected]]), ""); [email protected]++; } [email protected] = getarraysize([email protected]); mes "> 1x " + getitemname([email protected][[email protected]]); next; mes "Are you sure you want to trade these cards?"; for ([email protected] = 0; [email protected] < [email protected]; [email protected]++) mes "> " + getitemname([email protected][[email protected]]); if (select("~ Yes:~ No") & 2) end; for ([email protected] = 0; [email protected] < [email protected]; [email protected]++) delitem [email protected][[email protected]], 1; getitem rand(4001,4699), 1; close; }
  9. Change shop to cashshop - shop card_mob#A -1,501:1000 - shop card_mob#B -1,501:1000 - shop card_mob#C -1,501:1000 - shop card_mob#D -1,501:1000 - shop card_mob#E -1,501:1000 - shop card_mob#F -1,501:1000 - shop card_mob#G -1,501:1000 - shop card_mob#H -1,501:1000 - shop card_mob#I -1,501:1000 - shop card_mob#J -1,501:1000 - shop card_mob#K -1,501:1000 - shop card_mob#L -1,501:1000 - shop card_mob#M -1,501:1000 - shop card_mob#N -1,501:1000 - shop card_mob#O -1,501:1000 - shop card_mob#P -1,501:1000 - shop card_mob#Q -1,501:1000 - shop card_mob#R -1,501:1000 - shop card_mob#S -1,501:1000 - shop card_mob#T -1,501:1000 - shop card_mob#U -1,501:1000 - shop card_mob#V -1,501:1000 - shop card_mob#W -1,501:1000 - shop card_mob#X -1,501:1000 - shop card_mob#Y -1,501:1000 - shop card_mob#Z -1,501:1000
  10. Then you have to check first if the person who will wear the item is a VIP or not before adjusting their group *vip_status(<type>,{"<character name>"}) Returns various information about a player's VIP status. Valid types: VIP_STATUS_ACTIVE - VIP status: true if the player is a VIP or false if not VIP_STATUS_EXPIRE - VIP expire timestamp if the player is VIP or 0 if not VIP_STATUS_REMAINING - VIP time remaining in seconds NOTE: This command is only available if the VIP System is enabled.
  11. If you are using latest rAthena then you can configure it in skill_db.yml. Storm Gust : https://github.com/rathena/rathena/blob/5112f8e2d8a6eca1df88d1700de61f07e93de6f2/db/re/skill_db.yml#L3715 LOV : https://github.com/rathena/rathena/blob/5112f8e2d8a6eca1df88d1700de61f07e93de6f2/db/re/skill_db.yml#L3381 Meteor Storm : https://github.com/rathena/rathena/blob/5112f8e2d8a6eca1df88d1700de61f07e93de6f2/db/re/skill_db.yml#L3167
  12. Ano ba considered "malupit" sayo? HAHAHA
  13. Thanks sa mga sumagot at sa mga sasagot pa!
  14. By default the time limit for ET is 4 hours and if you are idle for 5 minutes you will be kicked out of the instance # - Id Instance ID. # Name Instance Name. # TimeLimit Total lifetime of instance in seconds. (Default: 3600) # IdleTimeOut Time before an idle instance is destroyed in seconds. (Default: 300) # Enter: Instance entrance coordinates. # Map Map Name where players start. # X X Coordinate where players start. # Y Y Coordinate where players start. # AdditionalMaps: List of maps that are part of an instance. (Optional)
×
×
  • Create New...

Important Information

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