Mumbles

Community Contributors
  • Content count

    610
  • Joined

  • Last visited

  • Days Won

    12

Everything posted by Mumbles

  1. Utility

    Utility: @go command Original concept by : http://herc.ws/board/topic/14-utility-added-feature-jtynnes-go-command-alternative-txt-format/ Description: Alternative @go command. Allows for unlimited aliasing, as well as level and group restrictions for each destination. Additional options to add a delay, prevent use when dead, and charge per use are available; default cost is defined with '.cost', but this parameter can be set manually with 'go()'. These extra features are disabled by default. Be mindful that the delay uses a temporary player variable, '@go_delay'; if the player logs out, this variable will be cleared. If you would like for a more secure delay, replace all instances of '@go_delay' with 'go_delay'. Download: https://github.com/datmumbles/Scripts/raw/master/cmd/go.txt
  2. Utility: Points to Item Exchanger As per @koji42's request: http://herc.ws/board/topic/4048-pods-cashpoints-convertion/ Description: Exchanges items for points and vice-versa at a fixed rate. Preview: Download: https://github.com/datmumbles/Scripts/raw/master/util/points2item.txt
  3. Change the value of .rate under Config
  4. Games

    Utility: Variant Mining As per xienne15's request: http://herc.ws/board/topic/1886-simple-mining/ Description: A simple mining system; allows for interacting players to excavate minerals by "mining" them with special equipment and tools. Minerals disappear and respawn randomly; chance is determined by configuration. Configuration is mostly done in arrays so that settings may be changed with no modifications to the script. Duplicate in additional locations as needed; update the value of '.var_amount' correspondingly. Download: https://github.com/datmumbles/Scripts/raw/master/util/mining.txt
  5. Here's an updated version without global variables and a simplified flow: - script vaporize -1,{ OnPCLoginEvent: // Set AFK check on login addtimer 60000, strnpcinfo(0) + "::On1min"; end; On1min: // Check if player has Homunculus and if AFK longer than allowed if(gethominfo(2) != "null" && checkidle() >= .vaporize) { atcommand "@useskill 244 1 " + strcharinfo(0); dispbottom "You are not allowed to farm with Homunculus while AFK."; } // Reset AFK check addtimer 60000, strnpcinfo(0) + "::On1min"; end; OnInit: // Time (in seconds) before vaporizing .vaporize = 120; end; }
  6. Does Chemi still work with you guys?
  7. Utility

    Utility: Hercules Radio As per youtube's request: http://herc.ws/board/topic/1676-rhelp/ Description: A radio NPC that plays preset selection of client-side songs (these songs are to be placed in the 'BGM' folder). The command '@radio' was added as a convenience, to allow songs to be played wherever the invoking player may be. Songs are played on the map in which the NPC was invoked, meaning that if a player is in pay_gld and types '@radio', (s)he and everyone on the map will hear the selected song. Each time a song is played, a lock is set for the preset minutes; this lock prevents the NPC from being accessed. A countdown in minutes and seconds is be displayed to reflect the remaining time until the next song can be played. Download: https://github.com/datmumbles/Scripts/raw/master/util/radio.txt
  8. Utility

    This code might be deprecated. If it does still work, it should overwrite the existing functionality of @go. When this was written, you did not need to make any src changes, as bindatcmd binded @go to the specified label within the script.
  9. Utility: Coin Trader As per @karazu's request: http://herc.ws/board/topic/4157-mithrill-to-gold-to-silver-coins-vice-versa-trader/ Description: Allows players to purchase coins with zeny, exchange coins for zeny, and convert coins to more valuable or lesser coins. See configuration to customise coin values. Download: https://github.com/datmumbles/Scripts/raw/master/util/cointrader.txt
  10. Currently, we have three different autoloot commands: autoloot alootid autoloottype My only question is, Why aren't these three features merged into one command with various syntaxes?, like so: autoloot autoloot rate <number %> autoloot item <name or ID> autoloot type <type> autoloot settings autoloot reset ...and aloot variations for those who like to shorthand, of course. It'd also be interesting to see rate and type combined; for example, autolooting any equipment items that drop at a rate of 12% or less.
  11. Utility: Instant Third-Class Jobs As per spectator's request: http://herc.ws/board/topic/882-rinstant-job-changer/ Description: Allows player to choose a third-class job upon initial login; if the player fails to choose a class for any reason, (s)he will be prompted again upon next login. Download: https://github.com/datmumbles/Scripts/raw/master/util/thirds.txt
  12. Utility: Points to Zeny Exchanger As per themon's request: http://herc.ws/board/topic/2774-zeny-to-cash-point/ Description: Allows players to exchange points for zeny and vice-versa. Point variable, exchange rate, and minimum exchange can be configured easily below the 'OnInit' label. Optimised for Hercules emulators. Download: https://github.com/datmumbles/Scripts/raw/master/util/points2zeny.txt
  13. In previous versions (not sure if still possible), you could pre-load a script in npc/scripts_custom.conf and it could potentially affect the next script in line if it wasn't closed properly. Example: npc: npc/custom/npc1.txtnpc: npc/custom/npc2.txt If npc/custom/npc1.txt was missing a right curly at the end of the file, it would still load, but the next file in line (in this example, npc/custom/npc2.txt) would throw an error at line 1. Just throwing that idea out there; it very well might not be the solution to your problem, but there's nothing wrong with making sure all of your custom scripts have no errors. d:
  14. What's the file above it, in npc/vroevents/ ? Might be missing a right curly at the end of that file.
  15. Or you could just not @reloadscript lol But anyway, here you go: http://upaste.me/2f9618109227d4fcd
  16. Did you read the second part? o.O
  17. You're over-thinking your implementation. On a smaller scale, you could write something like: - script summon_mvp -1,{ OnInit: monster "prt_fild08", 0, 0, "Baphomet", BAPHOMET, 1, strnpcinfo(0) +"::OnKilledBapho"; end; OnKilledBapho: announce strcharinfo(0) +" has killed "+ getmonsterinfo(BAPHOMET, MOB_NAME) +"!", bc_all; end;} ...but since you've already specified a very particular event (OnKilledBapho) for your Baphomet mob, you don't really need to pull the RID to display the name, nor do you even need to use getmonsterinfo(). Since you told the script to run OnKilledBapho when the event Baphomet is killed, you could just simply write your announcement like this: announce strcharinfo(0) +" has killed Baphomet!", bc_all; If you were randomizing MVP summons, however, you could do something like this: - script summon_mvp -1,{ OnInit: // Set MVP IDs setarray .mvp_id[0], BAPHOMET, GOLDEN_BUG, KNIGHT_OF_WINDSTORM, GARM, ORK_HERO; OnSetID: // Randomly select MVP to summon .summon_id = .mvp_id[rand(getarraysize(.mvp_id))]; // Summon Random MVP monster "prt_fild08", 0, 0, getmonsterinfo(.summon_id, MOB_NAME), .summon_id, 1, strnpcinfo(0) +"::OnKilledMVP"; end; OnKilledMVP: // Announce MVP death announce strcharinfo(0) +" has killed "+ getmonsterinfo(.summon_id, MOB_NAME) +"!", bc_all; // Respawn new MVP donpcevent strnpcinfo(3) +"::OnSetID"; end; }
  18. Utility

    So the documentation for nowarpto is correct, then; lost track of what the original issue was for a sec lol. In your last reply, you mentioned replacing mf_nowarp with mf_nowarpto: } else if (getgroupid() < getarg(4) || getmapflag(getarg(0), mf_nowarp)) { However, the intent of this line is to prevent warping if the player's Group ID isn't high enough OR if the destination has a nowarp flag, regardless of Group ID. You can bypass this for GMs by changing the expression a little (I'm sure there's a prettier way to do it, but I'm not feeling up to it): } else if (getgroupid() < getarg(4) || getmapflag(getarg(0), mf_nowarp) && getgroupid() < getarg(4)) { In regard to your original inquiry, the behaviour of nowarp is to prevent the use of @go to a destination; to prevent the use of @go from a map flagged with nowarp (despite this not being the intent of the nowarp flag), you can still prevent warping by adding an expression similar to my original suggestion: } else if (getmapflag(strcharinfo(3), mf_nowarp)) { message strcharinfo(0), "You are not authorised to warp from this map."; If you would like to prevent warping from specific maps, I would recommend moving forward with the filter/blacklist route — hell, you could even prevent both nowarp-flagged and specific maps from being warped to if you wanted to.
  19. Utility

    Can you please confirm (via in-game test) that nowarpto prevents this version of @go from warping to a map flagged with nowarpto, and that nowarp prevents warping from a map flagged with nowarp? I am unable to test any in-game behaviours at this time.
  20. Utility

    You could probably do without getmapxy() since the script is attached to a player when run; strcharinfo(3) will return the attached player's map name. I'd say you were correct in changing mf_nowarp to mf_nowarpto, should the function of nowarpto be that players cannot warp to the map (duh; though sometimes the documentation isn't tell-all). Someone should really update the documentation for both mapflags, as they are either lacking in information or documented incorrectly. /swt
  21. Utility

    Hi Kong, Per mf_nowarp's documentation (see nowarp.txt), mf_nowarp prevents the use of @go to a map, not from it. There is currently no mapflag (that I'm aware of) that prevents warping from the map, but you can circumvent this by either adding your own blacklist/filter of disabled maps. This is an example of a blacklist injection (though I wouldn't recommend punching this into this script exactly as it is written): setarray [email protected]$[0], "payon", "prontera", "izlude";for ([email protected] = 0; [email protected] < getarraysize([email protected]$); [email protected]++) { if (strcharinfo(3) == [email protected]$[[email protected]])) { message strcharinfo(0), "You may not warp from this map."; end; }}
  22. Utility

    Hi Kong, Thanks for the feedback. I'll push an update when I get back to my desk; for now, you can add this block of code at line 62 to accommodate your needs: } else if (getmapflag(getarg(0), mf_nowarp)) { message strcharinfo(0), "You are not authorised to warp to this map.";
  23. Games

    You can use the monster command after the line containing the progressbar command.