meko

Core Developers
  • Content count

    223
  • Joined

  • Last visited

  • Days Won

    17

meko last won the day on October 28

meko had the most liked content!

4 Followers

About meko

  • Rank
    Advanced Member

Contact Methods

  • IRC Nickname
    meko

Profile Information

  • Gender
    Not Telling
  1. To check on which map a player is: [email protected]$ = strcharinfo(PC_MAP, "%", [email protected]_id); if ([email protected]$ == "%") { // player is not on a map } else { // player is on a map // << add further checks here >> }
  2. in the Script<> section, you could do something like: if (gettimetick(2) <= @ITEM_LOCK[0]) end; @ITEM_LOCK[0] = gettimetick(2) + 1; percentheal(100, 100);
  3. you can find the documentation in the /doc folder, and some more on the wiki: https://github.com/HerculesWS/Hercules/wiki
  4. well, it's quite easy, you are supposed to replace <tab> by an actual tab, and you should also change the location/name boilerplate with the actual info
  5. attach the file, please
  6. By default, all servers use the same SQL configuration. To have a different SQL configuration for login/char/map, you can make more sql_connection.conf files and change the file paths in the @import directives. To configure the log system, you need to edit conf/map/logs.conf
  7. The SQL configuration is now in conf/global/sql_connection.conf
  8. However you can have 1 login server with many char+map pairs https://github.com/HerculesWS/Hercules/wiki/Multi-Realm
  9. multi-zone support was deprecated in 2016 and will be completely removed very soon
  10. Hercules now has a proper changelog, so I am locking this. You can always find the latest release here: https://github.com/HerculesWS/Hercules/releases/latest The full changelog is in CHANGELOG.md
  11. Sorry, Hercules does not offer pre-built binaries. However, surely someone can hook you up if you ask nicely: https://discord.gg/ZUzbRSp
  12. Offline as in only available on the computer you are currently using? Hercules, by default, already binds to localhost (127.0.0.1) so there's no extra configuration required: no need to open ports anywhere, no need to register a domain name, no need to get a VPS. Just follow the official instructions: README.md BTW, since you are on Windows 10, you don't have to install that oh-so-bulky Visual Studio, you can just enable the Windows Subsystem for Linux (WSL) and follow the Linux installation instructions instead of the Windows ones.
  13. The rAthena documentation does NOT apply to Hercules. Please refer to the Hercules documentation when using Hercules. If you seek support for rAthena instead, please use the rAthena forums. Hercules currently does not support this script command, and there is no Pull Request implementing it. Also, your syntax in Script<> is wrong
  14. @nuna see also item_packages.conf
  15. Try this: function script loot_crate { [email protected] = getarrayindex(getarg(0)); [email protected] = getarraysize(getarg(0)); for ([email protected] = [email protected]; [email protected] < [email protected] - [email protected]; [email protected] += 3) { for ([email protected] = 0; [email protected] < getelementofarray(getarg(0), [email protected] + 2); [email protected]) { [email protected][[email protected]++] = [email protected]; } } [email protected] = [email protected][rand([email protected])]; getitem(getelementofarray(getarg(0), [email protected]), getelementofarray(getarg(0), [email protected] + 1)); announce(sprintf("Player %s obtained %ix %s from a loot crate!" strcharinfo(PC_NAME), getelementofarray(getarg(0), [email protected] + 1), getitemname(getelementofarray(getarg(0), [email protected]))), getarg(1, bc_all)); return true; } And in your NPC do something like this: MAP,X,Y,DIR script NAME SPRITE,{ mes("Hello"); next(); loot_crate(.rewards, bc_all); mes("Goodbye!"); close; OnInit: setarray(.rewards, // Item, Amount, Chance Yggdrasilberry, 1, 60, Portable_Furnace, 1, 10, Spectacles, 1, 10, Seed_Of_Yggdrasil, 1, 10, Poison_Bottle, 1, 5, Silver_Coin, 1, 5); }