-
Content Count
618 -
Joined
-
Last visited
-
Days Won
15
Reputation Activity
-
Mumbles got a reaction from Zirius in "name of party" to party_id
Place this at the top of your script (below the header) and you'll be able to use getpartyid() to determine the party ID of the input party name. Alternatively, you could do something with getcharid(1), but it may require more writing than you'd like.
// getpartyid("Party Name")function getpartyid { // Determine party ID query_sql "SELECT `party_id` FROM `party` WHERE `name` ='"+ getarg(0) +"'", .@party_id; // Return false (0) if party not found if (!.@party_id) { return false; // Return party ID if found } else { return .@party_id; }}
Example:
// Determine party ID of party "Party Name".@party_id = getpartyid("Party Name"); -
Mumbles reacted to quesoph in Disabling 'Cash Shop' button in upper right corner
You need to hex your client..
Find this:
4E 43 5F 43 61 73 68 53 68 6F 70and replace with00 00 00 00 00 00 00 00 00 00 00This would disable cashshop.
* back up your client first just in case something goes wrong.
-
Mumbles got a reaction from Hadeszeus in About 1 Per Mac IP except vending or @AT
Here's my own version, using temporary global vars for to allow for other uses of these MAC addresses (assuming you know what to do with them).
- script dual_check -1,{ /*----------------------------------------------------- Determine MAC address [Harmony] -----------------------------------------------------*/ function getmacaddress { query_sql "SELECT `last_mac` FROM `login` WHERE `account_id` = '"+ getcharid(3) +"'", .@mac_address$; return .@mac_address$; } /*----------------------------------------------------- Log MAC address to array -----------------------------------------------------*/ OnPCLoginEvent: // Log MAC address .@user_mac$ = getmacaddress(); // Loop through all map exceptions (if enabled) for (.@i = 0; .@i < getarraysize(.allow_map$) && .map_exceptions; .@i++) { // Determine if player's map is excepted if (strcharinfo(3) == .allow_map$[.@i]) { // Bypass flag .@bypass = 1; break; } } // Loop through entire MAC address list if no bypass flag for (.@i = 0; .@i < getarraysize($@mac_list$) && !.@bypass; .@i++) { // Determine if user's MAC address is already logged if (.@user_mac$ == $@mac_list$[.@i]) { // Jail user for dual-clienting atcommand "@jailfor "+ .jail_time$ +" "+ strcharinfo(0); // Message delay sleep2 100; // Error message message strcharinfo(0), "Dual-clienting is not allowed."; break; } } // Add user's MAC address to log $@mac_list$[getarraysize($@mac_list$)] = .@user_mac$; end; /*----------------------------------------------------- Remove single MAC address entry -----------------------------------------------------*/ OnPCLogoutEvent: // Log MAC address .@user_mac$ = getmacaddress(); // Loop through entire MAC address list for (.@i = 0; .@i < getarraysize($@mac_list$); .@i++) { // Find matching MAC address if (.@user_mac$ == $@mac_list$[.@i]) { // Delete single entry deletearray $@mac_list$[.@i], 1; } } end; /*----------------------------------------------------- Configuration -----------------------------------------------------*/ OnInit: // Jail for 10 years .jail_time$ = "10y"; // Allow map exceptions? 1: yes, 0: no .map_exceptions = 1; // Map exceptions setarray .allow_map$[0], "poring_w01", "poring_w02"; end;} -
Mumbles got a reaction from Zirius in Remove some maps from @go & Remove MVP from @whodrops
Use this for @go (script-based)
http://herc.ws/board/topic/3045-utility-go-command/
-
Mumbles got a reaction from iZeal in storing npc name as variable need help
When storing string variables, you need to append them with the suffix $.
.@var = 123;.@var$ = "abc";
If these variables are going under an OnInit label, make sure they're permanent NPC variables instead of temporary ones.
.var = 123;.var$ = "abc";
These posts should help you get back into the basics of scripting:
Crash Course: Scripting 101-A Crash Course: Scripting 101-B
-
Mumbles got a reaction from Zirius in Choosing decent Server for hosting Hercules
Depends what type of lag you are experiencing. If it's a latency issue where you're consistently "skipping" across the screen, it may be due to your own connection to your server (which would be silly, consider it's locally-hosted?). If you're experiencing a lot of server-side lag, review any custom scripts you've got loaded; some of them may be extremely memory-intensive (i.e. Toasty's WoE Controller, loadevent/OnPCLoadMapevent mapflags/labels, etc.).
-
Mumbles got a reaction from Mhalicot in Permanant Group Changer
As it's currently written, this won't function completely for a couple of reasons.
.@p_name$ = .@atcmd_parameters$[1];
This only pulls the second position of the index. If you syntax is @adjgroup2 99 Player B, the script will only read it as @adjgroup2 99 Player. The biggest problem with this is that if there are two players online named Player A and Player B, the script might unintentionally change Player A's group; you won't immediately know for sure, since your variable .@p_name$ will only store "Player".
A proper way to determine the player's name would be to store additional values past index 1. When you type @adjgroup2 99 Player B, the following values are stored:
.@atcmd_command$ = "@adjgroup2";.@atcmd_parameters$[0] = "99";.@atcmd_parameters$[1] = "Player";.@atcmd_parameters$[2] = "B";.@atcmd_numparameters = 3;
Using this information, you can collect the additional player information by copying the array values and imploding them, separated by spaces:
for (.@i = 1; .@i < .@atcmd_numparameters; .@i++) { .@name_data$[.@j++] = .@atcmd_parameters$[.@i];}.@p_name$ = implode(.@name_data$, " ");
Now .@p_name$ will properly store the name Player B, or whatever name you send that has spaces in it.
.@account_id = getcharid(3, .@p_name$);
The problem here is that getcharid() will only return a value if the player is online and can be attached to the script (this would have been a problem with .@p_name$ anyway, since it was incorrectly storing player names); if Player B is offline, .@account_id will have a value of 0. Normally, this would be fine, since you added a check to determine whether or not a player exists on the map server; however, it seems you're trying to update the account regardless of whether or not a player is online. A more efficient way of collecting a player's account ID would be to query the database using their (now properly stored) player name.
.@account_id = query_sql("SELECT `account_id` FROM `char` WHERE `name` = '"+ .@p_name$ +"'");
Using the function query_sql() will return the value found; if the player truly does not exist at all, the function will return 0. In that case, you can replace this check with a simpler one:
.@exist = query_sql("SELECT `group_id` FROM `login` WHERE `account_id`="+.@account_id, .@g_id); if (!.@exist){ message strcharinfo(0), .@p_name$ +" Does not Exist."; end; } if (!.@account_id){ message strcharinfo(0), .@p_name$ +" does not exist."; end; } query_sql "SELECT `group_id` FROM `login` WHERE `account_id` = '"+ .@account_id +"'", .@g_id;
With these changes made, the rest of the script and checks will run just fine.
-
-
Mumbles got a reaction from iZeal in FluxCP paypal donation question
For the PayPalIpnUrl, use www.paypal.com to accept donations. Make sure you set your PayPalBusinessEmail to the PayPal email address you use to accept payments. This is typically your login email as well. If my email address to accept payments is [email protected], then I would set that as the value for my PayPalBusinessEmail. Leave the PayPalReceiverEmails array alone.
Also, don't forget to add Flux to your PayPal IPN settings. Your IPN URL should look something like this:
http://my.ragnarok.ws/?module=donate&action=notify -
Mumbles got a reaction from jaBote in Pedido Blue Ghost setup
Here's a ZIP archive containing the file you requested: http://www.mediafire.com/download/9yu5xgex7fqsk8p
-
Mumbles got a reaction from humble in Variant Mining
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
-
Mumbles got a reaction from Begin in @go command
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
-
Mumbles got a reaction from TioHugo in @go command
Is this bypass only for the Zeny cost? If so, edit line 70:
} else if (.charge && Zeny < getarg(5)) { } else if (.charge && Zeny < getarg(5) && getgroupid() < .bypass_id) {
Then, add this to line 46:
.bypass_id = 1; // Minimum group ID to bypass zeny cost -
Mumbles got a reaction from TioHugo in @go command
Edit this:
} else if (.delay && @go_delay > gettimetick(2)) { } else if (.delay && @go_delay > gettimetick(2) && getgroupid() < .bypass_id) { -
Mumbles got a reaction from kyeme in Didn't want to...
I personally love Hercules' HPM and libconfig-style format for the item databases. The mob database is a work-in-progress for a similar format, so I'm looking forward to that too. I prefer it over rAthena particularly because of my ability to stay up-to-date with the latest revisions by syncing with the Git repo - and most source changes I need can be hooked with HPM. Additionally, Hercules is less memory-intensive; you can run it on a Raspberry Pi if you really wanted to. In comparison, a clean Hercules uses up about 35-75 MB RAM, while rAthena uses 350+ MB RAM.
These are just a few things that I really like about Hercules, but I suppose it's just a matter of preference, I guess. We don't have as much official content (to my knowledge), but the content we do have is accurate and up-to-date.
-
Mumbles got a reaction from kyeme in Recommended Server Host?
If you know what you're doing™, check out Ubiquity Hosting. I've been with them for the past month now, and they've got great customer service, good deals, and (so far) 100% uptime; you get what you pay for. If it seems a bit out of your budget, BuyVM is a preferable alternative. I wouldn't recommend any of those RO-VPS deals; most of them are unreliable, like the one that disappeared without a word to its customers. You're much better off choosing an established host over some small start-up.
-
Mumbles reacted to KeyWorld in Lumina Social Ragnarok Panel - Soon
If I find time and motivation I'll maybe check for security exploits once it's done. Most of the panels out there got critical vulnerabilities.
In fact really depend if the project interest me.
-
Mumbles got a reaction from cJei in Coin Trader
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
-
Mumbles got a reaction from Angelmelody in Partyscript Debugger
Utility: Partyscript Debugger
Description:
Debug utility for Mhalicot's partyscript plugin. Accessible via '@modparty' or '@mp'.
Download:
https://github.com/datmumbles/Scripts/raw/master/sample/party.txt
-
Mumbles got a reaction from Helena in How to add join main in this script?
OnPCLoginEvent: if (main) { atcommand "@main on"; } end; Something more like this o.o
-
Mumbles got a reaction from Moonlight in How to add join main in this script?
OnPCLoginEvent: if (main) { atcommand "@main on"; } end; Something more like this o.o
-
Mumbles got a reaction from Mhalicot in Party Script Plugins
Here's the original debug utility used when we were working on this plugin: http://herc.ws/board/topic/5910-partyscript-debugger/
-
Mumbles reacted to jaBote in Hercules Radio
Find this line:
announce strnpcinfo(1) +": Now playing '"+ .song$[.@option] +"' by "+ .artist$[.@option] +".", bc_map;
and change to this:
announce strnpcinfo(1) +": Now playing '"+ .song$[.@option] +"' by "+ .artist$[.@option] +" as requested by "+ strcharinfo(0) +".", bc_map; -
Mumbles reacted to Dastgir in [Error] can't make sql
not yet experienced this yet, but search on internet shows that, if you have imported it from windows, then linebreaks are different(linux and windows handles it differently)So do these commands
dos2unix sysinfogen.shchmod +x sysinfogen.shThen , make all -
Mumbles reacted to karazu in IP checker. kick 5 accounts with same IP in same MAP
So how to add new map?
set .Map$,"payon"; this is how I add.
set .Map$,"payon"prontera";