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

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

Moderator: Moderators

User avatar
DaveHer
Peasant
Peasant
Posts: 54
Joined: 13 Mar 2019

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

Postby DaveHer » Apr 15 2019, 17:34

Decompiling Evt files with the script you have at that site seems to work only for MM8. I get an error messages when I try it with the others, MM6 & MM7. :(

——————————————————————————————————————————————————————————————————————————————————
Debug Mode Started. Press Ctrl+Enter to execute commands.
----------------------------------------------------------------------------------
> local dir = "Decompile/"
for f in path.find(dir.."*.evt") do
evt.Decompile(f, 0, dir.."Scripts/"..path.setext(path.name(f), ".lua"))
evt.Decompile(f, 0, dir.."Scripts/txt/"..path.setext(path.name(f), ".txt"), true)
end
J:\3DO\Might and Magic VI/Scripts/Core/evt.lua:682: attempt to concatenate a boolean value

stack traceback:
J:\3DO\Might and Magic VI/Scripts/Core/evt.lua:682: in function 'CmdComment'
J:\3DO\Might and Magic VI/Scripts/Core/evt.lua:709: in function 'CmdParams'
J:\3DO\Might and Magic VI/Scripts/Core/evt.lua:1275: in function 'EmitCmd'
J:\3DO\Might and Magic VI/Scripts/Core/evt.lua:1322: in function 'DecompileEvt'
J:\3DO\Might and Magic VI/Scripts/Core/evt.lua:1389: in function 'DecompileCmdLua'
J:\3DO\Might and Magic VI/Scripts/Core/evt.lua:1439: in function 'DecompileBuffer'
J:\3DO\Might and Magic VI/Scripts/Core/evt.lua:1462: in function 'Decompile'
[string ""]:3: in main chunk
[C]: in function 'pcall'
J:\3DO\Might and Magic VI/Scripts/Core/Debug.lua:89: in function 'DoDebug'
J:\3DO\Might and Magic VI/Scripts/Core/Debug.lua:131: in function 'debug'
...O\Might and Magic VI\Scripts\General\DebugConsoleKey.lua:6: in function 'v'
Scripts/Core/EventsList.lua:68: in function <Scripts/Core/EventsList.lua:63>

arguments of 'CmdComment':
num = 26
struct = (table: 0x0c7b5180)

local variables of 'CmdComment':
comment = nil
(*temporary) = "("
(*temporary) = false
(*temporary) = ")"
(*temporary) = false
(*temporary) = ", "
(*temporary) = false
(*temporary) = "attempt to concatenate a boolean value"

upvalues of 'CmdComment':
mmver = 6
GetFromArray = (function: 0x0369bee8)
GetStr = (function: 0x0369bf48)
JoinStr = (function: 0x02f53918)
GetFromFile = (function: 0x03a4ea08)
>
The reason I wanted to decompile the evt files is because the version of "Chaos Conspiracy" that I have has more evt files (84) than the one, decompiled, that I download at the site.
Last edited by DaveHer on Apr 16 2019, 14:09, edited 2 times in total.

User avatar
DaveHer
Peasant
Peasant
Posts: 54
Joined: 13 Mar 2019

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

Postby DaveHer » Apr 16 2019, 14:47

I am also a big fan of Morrowind and created a mod for it with two quest and over 100 new meshes (made with blender). I have learned a lot about modding MM6-8 with the tools provided. I Have made many changes to them. There were three things I did not like about the games and it was stable, boats, and Reagents. Now I have transportation everyday of the week and the Reagents are more powerful for MM7 & 8. But I still need to learn more. Where are the obj files that you import into the editor? I checked all the Lod files. All they have is bmp files when you try to extract them with MMArchive. I would like to put more thing in the maps( unless they have limitations). In the original MM6 there has to be a script to change the amount of hp and sp for the red and blue bottles give. If there is. Where is it. Other wise the bottles are useless. I did not bother collecting them. If I learn more maybe I can help with the merge in some way. I am retired and this keeps me busy. I will start work on making echo's monstrosity mod compatible with the merge. Rodril told what I need it to do. There are over three hundred pal file in the monstrosity but only 70 have the some name as in the merge. So only 70 file names will be change. He also told me what I need it to do with the SFT file.
Last edited by DaveHer on May 10 2019, 23:16, edited 2 times in total.

User avatar
BTB
Peasant
Peasant
Posts: 93
Joined: 21 Aug 2011
Location: Houston, TX
Contact:

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

Postby BTB » Apr 17 2019, 0:38

Quick question... will the following check a character's base skill or will it factor in NPC/equipment bonuses:

if evt.Cmp("RepairSkill", 1)
"You don't have to be a vampire to die like one... *****." -Simon Belmont

killeroid356
Leprechaun
Leprechaun
Posts: 6
Joined: 17 Apr 2019

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

Postby killeroid356 » Apr 21 2019, 9:43

hello! i am new to modding and was told to come here to ask for help, if there are any tutorials on how to use this i would appreciate them greatly

my idea is a mm6 randomizer of sorts, where on a new save you could pick several options on what you want randomized (eg, dungeons, buildings, shops & guilds, overworld monsters) and then have it swap those things around. i want to know if something like this is possible and how hard it would be (the basic version would just be dungeons so if everything else is impossible / uber hard thats fine).

User avatar
kristal
Leprechaun
Leprechaun
Posts: 44
Joined: 23 Nov 2016
Location: Russian

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

Postby kristal » Apr 24 2019, 20:02

DaveHer wrote:Hi Garyface and Rodril,
I just want to thank you for the thing you are doing for us fans of might and magic. I know it is a lot of work. I know because I have been making changes to all three games. But I still need to learn more.
@Garyface
The example quests you have at your site need one more thing (awards). I have done six quests using your examples. But when you finish a quest there are no awards. There needs to be some kind of command add to the list:
Quest{
"SimpleExampleQuest",
QuestItem = 1, -- quest item index (Longsword)
Gold = 1000, -- reward: gold
Exp = 1000, -- reward: experience
RewardItem = 536, -- reward: Lucky Hat
Something that will place text in the awards page.
}


Better to write here so (Put the script in the Scripts\Global folder):

local A, B, C, D, E, F = 0, 1, 2, 3, 4, 5

local function QCheck(name, state, b)
b = (b == nil) or b
return function(t)
return (vars.Quests[name or t.Name] == state) == b
end
end

QuestNPC = 1 -- The lizard in the tavern

-- a simple quest: require item #1 (Longsword), give 1000 exp, 1000 gold and an artifact hat
Quest{
"ExampleQuest", -- Same as: Name = "ExampleQuest",
Slot = A,
Quest = 498,
Texts = {
FirstGreet = "Hello, world!",
Greet = "Hi.",

Topic = "Quest!",
Give = "I need a Longsword!",

GreetGiven = "How's it going?",
-- TopicGiven can be set as well, but I keep it at "Quest!" here
Done = "That's the sword I was looking for! Thank you! I have this hat and some gold coins for you!",
Undone = "You don't have the sword yet?",

GreetDone = "Greetings to you, The Man Who Gave The Sword!",
TopicDone = "Thanks!",
After = "Thank you for the sword!",

Quest = "Bring a Longsword (the most basic of swords) to that lizard in the tavern of Dagger Wound Islands.",
}
CheckDone = function()
evt.Player = evt.Players.All
if not evt.Cmp{"Inventory", Value = 729} then
return false
end
evt.Subtract {"Inventory", Value = 729}
evt.Add {"Experience", Value = 5000}
evt.Add {"ReputationIs", Value = 50}
evt.Player = evt.Players.Current
evt.Add {"Gold", Value = 5000}
return true
end
}



The code below can be modified with examples from the original MM. It gives a great opportunity. You can get examples of this code from the GrayFace website (Download decompiled scripts of all games):
https://grayface.github.io/mm/ext/

CheckDone = function()
evt.Player = evt.Players.All
if not evt.Cmp{"Inventory", Value = 729} then
return false
end
evt.Subtract {"Inventory", Value = 729}
evt.Add {"Experience", Value = 5000}
evt.Add {"ReputationIs", Value = 50}
evt.Player = evt.Players.Current
evt.Add {"Gold", Value = 5000}
return true
end

User avatar
DaveHer
Peasant
Peasant
Posts: 54
Joined: 13 Mar 2019

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

Postby DaveHer » Apr 24 2019, 23:00

kristal wrote:
DaveHer wrote:Hi Garyface and Rodril,
I just want to thank you for the thing you are doing for us fans of might and magic. I know it is a lot of work. I know because I have been making changes to all three games. But I still need to learn more.
@Garyface
The example quests you have at your site need one more thing (awards). I have done six quests using your examples. But when you finish a quest there are no awards. There needs to be some kind of command add to the list:
Quest{
"SimpleExampleQuest",
QuestItem = 1, -- quest item index (Longsword)
Gold = 1000, -- reward: gold
Exp = 1000, -- reward: experience
RewardItem = 536, -- reward: Lucky Hat
Something that will place text in the awards page.
}


Better to write here so (Put the script in the Scripts\Global folder):

local A, B, C, D, E, F = 0, 1, 2, 3, 4, 5

local function QCheck(name, state, b)
b = (b == nil) or b
return function(t)
return (vars.Quests[name or t.Name] == state) == b
end
end

QuestNPC = 1 -- The lizard in the tavern

-- a simple quest: require item #1 (Longsword), give 1000 exp, 1000 gold and an artifact hat
Quest{
"ExampleQuest", -- Same as: Name = "ExampleQuest",
Slot = A,
Quest = 498,
Texts = {
FirstGreet = "Hello, world!",
Greet = "Hi.",

Topic = "Quest!",
Give = "I need a Longsword!",

GreetGiven = "How's it going?",
-- TopicGiven can be set as well, but I keep it at "Quest!" here
Done = "That's the sword I was looking for! Thank you! I have this hat and some gold coins for you!",
Undone = "You don't have the sword yet?",

GreetDone = "Greetings to you, The Man Who Gave The Sword!",
TopicDone = "Thanks!",
After = "Thank you for the sword!",

Quest = "Bring a Longsword (the most basic of swords) to that lizard in the tavern of Dagger Wound Islands.",
}
CheckDone = function()
evt.Player = evt.Players.All
if not evt.Cmp{"Inventory", Value = 729} then
return false
end
evt.Subtract {"Inventory", Value = 729}
evt.Add {"Experience", Value = 5000}
evt.Add {"ReputationIs", Value = 50}
evt.Player = evt.Players.Current
evt.Add {"Gold", Value = 5000}
return true
end
}



The code below can be modified with examples from the original MM. It gives a great opportunity. You can get examples of this code from the GrayFace website (Download decompiled scripts of all games):
https://grayface.github.io/mm/ext/

CheckDone = function()
evt.Player = evt.Players.All
if not evt.Cmp{"Inventory", Value = 729} then
return false
end
evt.Subtract {"Inventory", Value = 729}
evt.Add {"Experience", Value = 5000}
evt.Add {"ReputationIs", Value = 50}
evt.Player = evt.Players.Current
evt.Add {"Gold", Value = 5000}
return true
end


First of all thank you for the code. So with that code I can add the following line to the code above? " evt.Add("Awards", 90)". I have text in the Awards.txt at lines 90, 91, and 92. They were the next available. Also It looks like I am to replace this:

Quest{
"SimpleExampleQuest",
QuestItem = 1, -- quest item index (Longsword)
Gold = 1000, -- reward: gold
Exp = 1000, -- reward: experience
RewardItem = 536, -- reward: Lucky Hat

with the code above. Yes or No.
Thanks again. Ignore the following post. I made a mistake.
Last edited by DaveHer on Apr 24 2019, 23:07, edited 2 times in total.

User avatar
DaveHer
Peasant
Peasant
Posts: 54
Joined: 13 Mar 2019

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

Postby DaveHer » Apr 24 2019, 23:01

DaveHer wrote:
kristal wrote:
DaveHer wrote:Hi Garyface and Rodril,
I just want to thank you for the thing you are doing for us fans of might and magic. I know it is a lot of work. I know because I have been making changes to all three games. But I still need to learn more.
@Garyface
The example quests you have at your site need one more thing (awards). I have done six quests using your examples. But when you finish a quest there are no awards. There needs to be some kind of command add to the list:
Quest{
"SimpleExampleQuest",
QuestItem = 1, -- quest item index (Longsword)
Gold = 1000, -- reward: gold
Exp = 1000, -- reward: experience
RewardItem = 536, -- reward: Lucky Hat
Something that will place text in the awards page.
}


Better to write here so (Put the script in the Scripts\Global folder):

local A, B, C, D, E, F = 0, 1, 2, 3, 4, 5

local function QCheck(name, state, b)
b = (b == nil) or b
return function(t)
return (vars.Quests[name or t.Name] == state) == b
end
end

QuestNPC = 1 -- The lizard in the tavern

-- a simple quest: require item #1 (Longsword), give 1000 exp, 1000 gold and an artifact hat
Quest{
"ExampleQuest", -- Same as: Name = "ExampleQuest",
Slot = A,
Quest = 498,
Texts = {
FirstGreet = "Hello, world!",
Greet = "Hi.",

Topic = "Quest!",
Give = "I need a Longsword!",

GreetGiven = "How's it going?",
-- TopicGiven can be set as well, but I keep it at "Quest!" here
Done = "That's the sword I was looking for! Thank you! I have this hat and some gold coins for you!",
Undone = "You don't have the sword yet?",

GreetDone = "Greetings to you, The Man Who Gave The Sword!",
TopicDone = "Thanks!",
After = "Thank you for the sword!",

Quest = "Bring a Longsword (the most basic of swords) to that lizard in the tavern of Dagger Wound Islands.",
}
CheckDone = function()
evt.Player = evt.Players.All
if not evt.Cmp{"Inventory", Value = 729} then
return false
end
evt.Subtract {"Inventory", Value = 729}
evt.Add {"Experience", Value = 5000}
evt.Add {"ReputationIs", Value = 50}
evt.Player = evt.Players.Current
evt.Add {"Gold", Value = 5000}
return true
end
}



The code below can be modified with examples from the original MM. It gives a great opportunity. You can get examples of this code from the GrayFace website (Download decompiled scripts of all games):
https://grayface.github.io/mm/ext/

CheckDone = function()
evt.Player = evt.Players.All
if not evt.Cmp{"Inventory", Value = 729} then
return false
end
evt.Subtract {"Inventory", Value = 729}
evt.Add {"Experience", Value = 5000}
evt.Add {"ReputationIs", Value = 50}
evt.Player = evt.Players.Current
evt.Add {"Gold", Value = 5000}
return true
end


First of all thank you for the code. So with that code I can add the following line to the code above? " evt.Add("Awards", 90)". I have text in the Awards.txt at lines 90, 91, and 92. They were the next available. Also It looks like I am to replace this:

Quest{
"SimpleExampleQuest",
QuestItem = 1, -- quest item index (Longsword)
Gold = 1000, -- reward: gold
Exp = 1000, -- reward: experience
RewardItem = 536, -- reward: Lucky Hat

with the code above. Yes or No.
Thanks again.

User avatar
kristal
Leprechaun
Leprechaun
Posts: 44
Joined: 23 Nov 2016
Location: Russian

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

Postby kristal » Apr 25 2019, 8:19

DaveHer wrote:First of all thank you for the code. So with that code I can add the following line to the code above? " evt.Add("Awards", 90)". I have text in the Awards.txt at lines 90, 91, and 92. They were the next available. Also It looks like I am to replace this:

Quest{
"SimpleExampleQuest",
QuestItem = 1, -- quest item index (Longsword)
Gold = 1000, -- reward: gold
Exp = 1000, -- reward: experience
RewardItem = 536, -- reward: Lucky Hat

with the code above. Yes or No.
Thanks again. Ignore the following post. I made a mistake.


Add entry to Awards.txt - evt.Ad("Awards", 92)
Yes. You can replace, but quests different. Much to look for and experience.
I can't explain much - my English is bad.

User avatar
DaveHer
Peasant
Peasant
Posts: 54
Joined: 13 Mar 2019

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

Postby DaveHer » Apr 25 2019, 9:06

kristal wrote:
DaveHer wrote:First of all thank you for the code. So with that code I can add the following line to the code above? " evt.Add("Awards", 90)". I have text in the Awards.txt at lines 90, 91, and 92. They were the next available. Also It looks like I am to replace this:

Quest{
"SimpleExampleQuest",
QuestItem = 1, -- quest item index (Longsword)
Gold = 1000, -- reward: gold
Exp = 1000, -- reward: experience
RewardItem = 536, -- reward: Lucky Hat

with the code above. Yes or No.
Thanks again. Ignore the following post. I made a mistake.


Add entry to Awards.txt - evt.Ad("Awards", 92)
Yes. You can replace, but quests different. Much to look for and experience.
I can't explain much - my English is bad.

Thanks again. Do not worry about your English. Your doing fine. :tsup:

Rodril
Assassin
Assassin
Posts: 264
Joined: 18 Nov 2016

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

Postby Rodril » May 5 2019, 10:10


Found few issues in this version:
- List of monsters (when you select monster and click "Type"), shows names of monsters starting from zero indexed monster, so pictures are correct, but names are shifted.
- "Select similar" button does not work - just clears current selection.

List of maps which includes ones from extra lods is very convenient - not necessary to rename them and relaunch game anymore.

User avatar
DaveHer
Peasant
Peasant
Posts: 54
Joined: 13 Mar 2019

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

Postby DaveHer » May 10 2019, 23:31

@ GrayFace or Rodril
I am having problems with map editing. This is the procedure I used. First, activated the editor, then pressed the wheel button to get access to the buttons on the left. second, export the map, then clicked continue, third, Placed some models, trees and plants to Sutter's Bay. Saved it. Compiled it. Place the files created into the Game.Lod. Started a new game. After finished creating party, I clicked on the OK button and went to Sutter's Bay. Every thing I placed was there. However, the horse shoes and the barrels you sell for 200 gold were gone. Also, I am unable to start a new game( Crash to desk top). :( But I am able to load a saved game and all the new sprites and models are there I placed with the editor.Please advice. Thanks
David
Last edited by DaveHer on May 17 2019, 17:43, edited 5 times in total.


Return to “Might and Magic”

Who is online

Users browsing this forum: Bing [Bot] and 6 guests