Scripting Programs

User avatar
syntax
Site Admin
Posts: 426
Joined: Tue Jun 02, 2009 10:02 am

Scripting Programs

Postby syntax » Tue Jul 14, 2009 12:09 pm



User avatar
MiOw
Posts: 89
Joined: Tue Nov 15, 2016 7:40 pm

Opening a specific character .ini w/ shortcut

Postby MiOw » Mon May 22, 2017 1:16 pm

The following mod/add will direct a MegaMUD shortcut to launch the program with a specific character.ini file loaded.

"C:\Program Files (x86)\Megamud\megamud.exe" -i "C:\Program Files (x86)\Megamud\Chars\character.ini"

Modify the path based on your installation and specific .ini filename and you are good to go!


ClassicMUD... nothing fancy, just MUD the way your daddy played it @ bbs.ClassicMUD.com (port 2323)
One character per verified player, per realm, with two realms offered; (PVP) and (NO PVP)
Realm Details - viewtopic.php?f=64&t=2357
rytz
Posts: 47
Joined: Tue Sep 17, 2013 12:53 pm

Re: Scripting Programs

Postby rytz » Sat Jun 24, 2017 6:54 am

I've created a MegaMud hack that displays the hash code for the current room on the status bar. I've never seen this displayed anywhere in the program, but is important to know because it is used in all the MegaMud paths. It's nice to know the current room hash when manually editing paths. Ignore the trailing colon on the code.

The status bar sizing and placement is tweaked. The room code is placed where the exp rate was, the exp rate is placed where the mana/kai regen was, and the mana/kai regen is placed over the clock. I increased the size of the status bar parts. I use a slightly larger font on my computer and the text on the status bar was being truncated. The Mana/Kai regen section is always displayed now, even when not being used by a class (would be hidden before). All edits are done on the MegaMud.exe:

Code: Select all

--------------------------------------------
Replace Status Bar Clock with Mega Room Code
--------------------------------------------
[Replace Dynamic Values]
84940-84954:
   Old: 85 ED B9 28 92 4B 00 75 05 B9 24 92 4B 00 8B 54 24 2C 51 52 50
   New: 90 90 90 90 90 90 90 90 90 90 90 51 50 8B 15 D8 16 4D 00 52 90

[Replace Formatting Text]
84959-8495D:
   Old: 68 74 33 4C 00
   New: 68 94 23 4C 00

--------------------------------------------
Re-Order Status Bar for Room Code
--------------------------------------------
[New Forced Status Bar Part Sizing]
8455F-8456F:
   Old: 75 1B 8B 74 24 2C B8 23 00 00 00 03 F0 03 D0 03 C8
   New: 8B 74 24 2C B8 50 00 00 00 90 83 EE 70 2B D0 2B C8

[Room Code / Time in Exp. Rate Status Box]
849E0:
   Old: 6A 07
   New: 6A 05

[Exp. Rate in Mana/Kai Box]
84B96:
   Old: 6A 05
   New: 6A 06
84C06:
   Old: 6A 05
   New: 6A 06

[Mana/Kai in Clock Section]
84C72:
   Old: 6A 06
   New: 6A 07
84CC1:
   Old: 6A 06
   New: 6A 07

--------------------------
Update ToolTips
--------------------------
C3C60-C3C9F:
   Old: 43 75 72 72 65 6E 74 20 54 69 6D 65 00 00 00 00 43 75 72 72 65 6E 74 20 4D 61 6E 61 2F 4B 61 69 20 52 65 67 65 6E 00 00 43 75 72 72 65 6E 74 20 45 78 70 65 72 69 65 6E 63 65 20 52 61 74 65 00
   New: 4D 61 6E 61 2F 4B 61 69 20 52 65 67 65 6E 00 00 45 78 70 65 72 69 65 6E 63 65 20 52 61 74 65 00 00 00 00 00 00 00 00 00 43 75 72 72 65 6E 74 20 52 6F 6F 6D 20 4D 65 67 61 2D 43 6F 64 65 00 00

ss.png


User avatar
BearFather
Posts: 375
Joined: Sun Feb 09, 2014 6:27 pm
Contact:

Re: Scripting Programs

Postby BearFather » Sat Jun 24, 2017 11:07 am

Nice our first hexedit for megamud. And an interesting one. I'm not sure if I need it but I can see the need for some of my users who love making mega paths.

May I request a hex that would disable the scroll wheel in the chat window's input? The biggest most annoying bug ever!


rytz
Posts: 47
Joined: Tue Sep 17, 2013 12:53 pm

Re: Scripting Programs

Postby rytz » Sat Jun 24, 2017 8:40 pm

BearFather wrote:Nice our first hexedit for megamud. And an interesting one. I'm not sure if I need it but I can see the need for some of my users who love making mega paths.

May I request a hex that would disable the scroll wheel in the chat window's input? The biggest most annoying bug ever!

That's a good request, actually. I'll take a peek later tonight. Should be easy enough.


rytz
Posts: 47
Joined: Tue Sep 17, 2013 12:53 pm

Re: Scripting Programs

Postby rytz » Mon Jun 26, 2017 7:55 am

Well that was an adventure. Below is a fix for the conversation bar and scroll wheel issue. I wanted to just have the scroll wheel events ignored, but couldn't due to the ComboBox and its Edit control having their events tied together within the framework. The code looks for CBN_SELENDOK (9) @ 883E4. There is no simple way to say "ignore the scroll wheel". A programmer would have to make a custom class to override the ComboBox event handler, which wasn't done here, obviously.

As a compromise, the ComboBox will hold the single last command/item. The scroll wheel will not raise events on a ComboBox with a single item. If you use the scroll wheel and do populate the ComboBox, or use the drop down, you will get a single room re-display. It won't spam, though.

Let me know if anyone encounters issues:

Code: Select all

[Save String Length for Future Compare (8B F8)]
[Compare Against Empty String (83 FF 00)]
[Jump (74 3E)]
8843C-8846A:
  Old: 8B 35 4C 14 4B 00 8D 8C 24 D0 00 00 00 51 6A FF 68 58 01 00 00 53 FF D6 83 F8 FF 75 3F 0B C8 8D BC 24 D0 00 00 00 33 C0 F2 AE F7 D1 49 74 2D
  New: 8B F8 8B 35 4C 14 4B 00 8D 8C 24 D0 00 00 00 51 6A FF 68 58 01 00 00 53 FF D6 83 F8 FF 75 3D 83 FF 00 74 3E 90 90 90 90 90 90 90 90 90 90 90

[Omit / NOP (Gets String Count)]
8846B-88479:
   Old: 50 50 68 46 01 00 00 53 FF D6 83 F8 64 7C 0C
   New: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90

[Delete All instead of Delete Single (CB_RESETCONTENT / CB_DELETESTRING)]
8847E:
   Old: 68 44 01 00 00
   New: 68 4B 01 00 00


User avatar
BearFather
Posts: 375
Joined: Sun Feb 09, 2014 6:27 pm
Contact:

Re: Scripting Programs

Postby BearFather » Mon Jun 26, 2017 9:55 am

Sweet I will have to give this a try when I get home tonight. I bow down to your mad skilllz!


rytz
Posts: 47
Joined: Tue Sep 17, 2013 12:53 pm

Re: Scripting Programs

Postby rytz » Fri Jun 30, 2017 5:27 am

Hey BearFather - did you get the edits working?


User avatar
BearFather
Posts: 375
Joined: Sun Feb 09, 2014 6:27 pm
Contact:

Re: Scripting Programs

Postby BearFather » Fri Jun 30, 2017 9:58 am

Yes I did. I have attached both versions to this post.

scr-room-megamud.exe:
This has the Convo box scroll wheel edit and the room hash in the status bat edit.

noscroll-megamud.exe:
This is just the no Convo box scroll edit.
Attachments
MegaMUDedits.zip
(712.53 KiB) Downloaded 278 times


rytz
Posts: 47
Joined: Tue Sep 17, 2013 12:53 pm

Re: Scripting Programs

Postby rytz » Fri Jun 30, 2017 10:05 am

Cool - glad to hear.



Return to “Downloads”

Who is online

Users browsing this forum: No registered users and 1 guest