MMExtension v2.2 + MMEditor v2.1 Level Editor [June 4, 2019]

The role-playing games (I-X) that started it all and the various spin-offs (including Dark Messiah).

Moderator: Moderators

Rodril
Demon
Demon
Posts: 313
Joined: 18 Nov 2016

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby Rodril » Dec 6 2016, 18:17

I know about these two projects:
http://mmgames.ru/index.php?option=com_ ... 88&lang=en
http://www.celestialheavens.com/forum/10/10974
(though they did use another ways to modify game, don't know how it now and if they are still active)

But often someone somewhere declaring intention to do it. I dont collect all links, there is last one (message by Kristal):
http://www.celestialheavens.com/forum/10/16219

Thanks for advices about QBits array and BeforeLoadMap(WasInGame). I've added it partially into script, but had some issues: Game.QBits - is it something from current version of MMExt, or from upcoming? Could not found it, but have found Party.QBits array, problem is Party.QBits indexes do not match with original sequence in quests.txt (see pic below). Attempt to change QBit using array leads to change in QBit with another index. Also, somewhat WasInGame is always nil in BeforeLoadMap, though in LoadMap(WasInGame) it works well, i've set it instead. Link in post above updated.

pic: https://www.dropbox.com/s/f5mhfhsmkzksx ... s.png?dl=0
Last edited by Rodril on Dec 6 2016, 18:20, edited 1 time in total.

User avatar
J. M. Sower
Scout
Scout
Posts: 170
Joined: 25 Jan 2016

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby J. M. Sower » Dec 6 2016, 19:12

I have another problem with blasters in MM8. I gave some NPC the topic number 321, responsible for appointment to expert in the field of blasters. When I click on this topic then I have this error message:
Image
I don't know how to do something with it. :/

mg979
Leprechaun
Leprechaun
Posts: 14
Joined: 05 Nov 2016

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby mg979 » Dec 6 2016, 20:45

Is it possible to edit spell costs? I tried to edit the spells.txt in Icons.lod, but the values there seem only for display, the real spell cost doesn't change even if it displays the different cost in the spell info. Thanks

User avatar
GrayFace
Dragon
Dragon
Posts: 1456
Joined: 29 Nov 2005

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby GrayFace » Dec 6 2016, 22:43

Rodril wrote:I know about these two projects:
http://mmgames.ru/index.php?option=com_ ... 88&lang=en
http://www.celestialheavens.com/forum/10/10974
(though they did use another ways to modify game, don't know how it now and if they are still active)

These are the same project :)

Rodril wrote:Thanks for advices about QBits array and BeforeLoadMap(WasInGame). I've added it partially into script, but had some issues: Game.QBits - is it something from current version of MMExt, or from upcoming? Could not found it, but have found Party.QBits array, problem is Party.QBits indexes do not match with original sequence in quests.txt (see pic below). Attempt to change QBit using array leads to change in QBit with another index. Also, somewhat WasInGame is always nil in BeforeLoadMap, though in LoadMap(WasInGame) it works well, i've set it instead. Link in post above updated.

pic: https://www.dropbox.com/s/f5mhfhsmkzksx ... s.png?dl=0

Yes, it's Party.QBits. Strange. Both QBits and WasInGame work fine for me. Are you using the intermediate version https://dl.dropboxusercontent.com/u/447 ... ionTmp.rar ?

mg979 wrote:Is it possible to edit spell costs? I tried to edit the spells.txt in Icons.lod, but the values there seem only for display, the real spell cost doesn't change even if it displays the different cost in the spell info. Thanks

Yes, see Data\Tables\Spells2.txt
Last edited by GrayFace on Dec 6 2016, 22:49, edited 1 time in total.
My patches: MM6 MM7 MM8. MMExtension. Tools. Also, I love Knytt Stories and Knytt Underground. I'm also known as sergroj.

mg979
Leprechaun
Leprechaun
Posts: 14
Joined: 05 Nov 2016

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby mg979 » Dec 6 2016, 23:23

GrayFace wrote:Yes, see Data\Tables\Spells2.txt


Thank you, but there I can only change recovery times not spell points cost, right? At least mine looks like

Code: Select all

Spell   DelayNormal   DelayExpert   DelayMaster
   0   0   0
Torch Light   60   60   60
...


Thanks anyway

User avatar
GrayFace
Dragon
Dragon
Posts: 1456
Joined: 29 Nov 2005

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby GrayFace » Dec 7 2016, 5:04

Yes, in MM6 spell points cost is spread across the spellcast function code.
My patches: MM6 MM7 MM8. MMExtension. Tools. Also, I love Knytt Stories and Knytt Underground. I'm also known as sergroj.

mg979
Leprechaun
Leprechaun
Posts: 14
Joined: 05 Nov 2016

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby mg979 » Dec 7 2016, 10:19

Ok thank you

User avatar
GrayFace
Dragon
Dragon
Posts: 1456
Joined: 29 Nov 2005

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby GrayFace » Dec 8 2016, 12:11

Rodril wrote:But often someone somewhere declaring intention to do it. I dont collect all links, there is last one (message by Kristal):
http://www.celestialheavens.com/forum/10/16219

That's actually the friend I told about :)

J. M. Sower wrote:I have another problem with blasters in MM8. I gave some NPC the topic number 321, responsible for appointment to expert in the field of blasters. When I click on this topic then I have this error message:

Use this code for now. It's included in next MMExt.

Code: Select all

   mem.asmpatch(0x4B0BE1, [[
      lea eax, [ecx - 300]
      mov ecx, 3
      xor edx, edx
      idiv ecx
      ret
   ]])
Last edited by GrayFace on Dec 8 2016, 12:12, edited 1 time in total.
My patches: MM6 MM7 MM8. MMExtension. Tools. Also, I love Knytt Stories and Knytt Underground. I'm also known as sergroj.

User avatar
J. M. Sower
Scout
Scout
Posts: 170
Joined: 25 Jan 2016

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby J. M. Sower » Dec 8 2016, 18:18

GrayFace wrote:Use this code for now. It's included in next MMExt.

Code: Select all

   mem.asmpatch(0x4B0BE1, [[
      lea eax, [ecx - 300]
      mov ecx, 3
      xor edx, edx
      idiv ecx
      ret
   ]])

It works, :D but I wonder Is it possible to change the cost of learning? For example, at this time the cost of Great Master of Blasters is 0.


Edit: I wanted to realize quest written by me someday in the past (code below) and I have an error. Is it possible that it happened because of the temporary version of MMExt that you sent? In the past, it worked correctly.

Code: Select all

Quest{"DaggerQuest",
   Slot = C,
   Quest = 135,
   Texts = {

      Topic = "Misja",
      Give = "W południowej strażnicy pracował mój ojciec. Cieszył się tam wysokim, dobrze opłacanym stanowiskiem. Ehhh... a ja teraz ledwie wiążę koniec z końcem. \n \n Nie proszę was o odnalezienie jego szczątków w celu pochówku, gdyż i tak mnie na to nie stać, a i cmentarz jest teraz przecież nawiedzony. Jednak jeśli odważylibyście się odwiedzić tamto miejsce to rozejrzyjcie się za pewnym świetnie wykonanym sztyletem. To była moja rodzinna pamiątka, jeszcze z czasów przed Ciszą! Rozpoznacie go bez problemu. Sztylet ten nigdy nie rdzewiał i nie tępiał!",

      GreetGiven = "Czy znaleźliście już mój sztylet?",
      -- TopicGiven can be set as well, but I keep it at "Quest!" here
      Undone = "Szukaj dalej! Powinien znajdować się gdzieś pod południową Strażnicą.",
      Done = "Znaleźliście mój rodzinny sztylet!  Proszę przyjmijcie tę nagrodę za waszą pomoc!",

      GreetDone = "Miło cię znowu widzieć. ",
      TopicDone = "Misja",
      After = "Ponowne dzięki!",
      
      Quest = "Odnajdź Sztylet rodzinny Toma White, który powinien znajdować się w Strażnicach Górniczego wybrzeża.",
   },
   QuestItem = 30,
   Gold = 500,
   Exp = 750,
   Awards = 2,
}

Image
Last edited by J. M. Sower on Dec 8 2016, 18:51, edited 4 times in total.

User avatar
GrayFace
Dragon
Dragon
Posts: 1456
Joined: 29 Nov 2005

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby GrayFace » Dec 9 2016, 0:46

J. M. Sower wrote:Edit: I wanted to realize quest written by me someday in the past (code below) and I have an error. Is it possible that it happened because of the temporary version of MMExt that you sent? In the past, it worked correctly.

Yes, it's a bug I introduced in it.
My patches: MM6 MM7 MM8. MMExtension. Tools. Also, I love Knytt Stories and Knytt Underground. I'm also known as sergroj.

Rodril
Demon
Demon
Posts: 313
Joined: 18 Nov 2016

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby Rodril » Dec 10 2016, 18:16

GrayFace wrote:Yes, it's Party.QBits. Strange. Both QBits and WasInGame work fine for me. Are you using the intermediate version https://dl.dropboxusercontent.com/u/447 ... ionTmp.rar ?


In new version both issues have gone.

TownPortalSwitch now supports 6th and 7th versions of MM as well (though with QBits modifying with evt. commands, i'll change it when official 2.2 MMExt will be released).
New link: https://www.dropbox.com/s/x79qgp42fjdj3 ... h.zip?dl=0 .
Last edited by Rodril on Dec 13 2016, 17:46, edited 2 times in total.

User avatar
theorclair
Peasant
Peasant
Posts: 55
Joined: 18 Jun 2013

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby theorclair » Dec 16 2016, 23:33

If I wrote a script for the quest to find Angela in New Sorpigal to give reputation as a reward, would this work?

evt.Global(329)
evt.Player = evt.Players.All if not evt.Cmp(evt.VarNum.Inventory, 449) then
return evt.SetMessage(350) -- You didn’t find poor Angela? Something horrible must have happened to her!"
end
evt.Subtract(vt.VarNum.Inventory, 449) --
return evt.SetMessage(37) -- "She’s alive! Thank you so much for finding Angela! If I weren’t so happy to see her, she’d be in a lot of trouble. Please take this as a reward for all you’ve done."
add (evt.Value.Food, 10)
add(evt.Value.ReputationIs, 200)
subtract(evt.NPC, 195)
add (evt.MoveNPC, 195, HouseID, 471)

evt.Player = evt.Players.All subtract(evt.qbit, 126)
Set.NPCTopic(1) evt.Index (1)
Set.NPCTopic(1) evt.Index (1)

end

User avatar
GrayFace
Dragon
Dragon
Posts: 1456
Joined: 29 Nov 2005

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby GrayFace » Dec 18 2016, 11:14

No, the syntax is invalid all over the script.
Last edited by GrayFace on Dec 18 2016, 11:14, edited 2 times in total.
My patches: MM6 MM7 MM8. MMExtension. Tools. Also, I love Knytt Stories and Knytt Underground. I'm also known as sergroj.

User avatar
theorclair
Peasant
Peasant
Posts: 55
Joined: 18 Jun 2013

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby theorclair » Dec 18 2016, 16:17

Okay. How would it look fixed?

User avatar
GrayFace
Dragon
Dragon
Posts: 1456
Joined: 29 Nov 2005

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby GrayFace » Dec 19 2016, 10:31

J. M. Sower wrote:It works, :D but I wonder Is it possible to change the cost of learning? For example, at this time the cost of Great Master of Blasters is 0.

The easiest way to make Blaster GM cost standard is

Code: Select all

mem.nop(0x4B0F6C, 2)
My patches: MM6 MM7 MM8. MMExtension. Tools. Also, I love Knytt Stories and Knytt Underground. I'm also known as sergroj.

User avatar
J. M. Sower
Scout
Scout
Posts: 170
Joined: 25 Jan 2016

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby J. M. Sower » Dec 19 2016, 18:53

GrayFace wrote:The easiest way to make Blaster GM cost standard is

Code: Select all

mem.nop(0x4B0F6C, 2)

Yep, it works. And what if I want to change the cost of the other skills? There are some possibilities? I ask only to spare. ;) I do not have anything specific in mind.
Last edited by J. M. Sower on Dec 19 2016, 21:33, edited 3 times in total.

User avatar
GrayFace
Dragon
Dragon
Posts: 1456
Joined: 29 Nov 2005

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby GrayFace » Dec 20 2016, 14:01

Yes, I could add a price hook, but there also are other requirements for some skills, like 50 Intellect ect.
My patches: MM6 MM7 MM8. MMExtension. Tools. Also, I love Knytt Stories and Knytt Underground. I'm also known as sergroj.

User avatar
J. M. Sower
Scout
Scout
Posts: 170
Joined: 25 Jan 2016

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby J. M. Sower » Dec 21 2016, 9:45

GrayFace wrote:Yes, I could add a price hook, but there also are other requirements for some skills, like 50 Intellect ect.

It would be cool. ;) Price hook will be sufficient.

User avatar
GrayFace
Dragon
Dragon
Posts: 1456
Joined: 29 Nov 2005

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby GrayFace » Dec 23 2016, 1:52

Anubis wrote:Does the MMExtension program have the capability of tweaking artifacts/relics like that? [e.g. giving Hareck's Leather an 'Of Earth Magic' enhancement]

Yes, with CalcStatBonusByItems event and player.EnumActiveItems, like this: (untested)

Code: Select all

function events.CalcStatBonusByItems(t)
  if t.Stat ~= const.Stats.EarthMagic or t.Player.Skills[const.Skills.EarthMagic] == 0 then
    return
  end
  for item, slot in t.Player:EnumActiveItems() do
    if item.Number == ??? then
      t.Result = SplitSkill(t.Player.Skills[const.Skill.EarthMagic]):div(2)
      return
    end
  end
end
My patches: MM6 MM7 MM8. MMExtension. Tools. Also, I love Knytt Stories and Knytt Underground. I'm also known as sergroj.

User avatar
theorclair
Peasant
Peasant
Posts: 55
Joined: 18 Jun 2013

Re: MMExtension v2.1 + MMEditor v2.1 Level Editor [Apr 22, 2016]

Postby theorclair » Dec 23 2016, 3:10

Two things - how do you modify the contents of a chest? And how would you change the properties of a fountain?


Return to “Might and Magic”

Who is online

Users browsing this forum: No registered users and 10 guests