A simple dialogue editor

The place to discuss all things Lugaru.
Silb
Master cartographer
Posts: 558
Joined: Sat Dec 10, 2005 10:03 am
Location: Map Guild

A simple dialogue editor

Post by Silb » Sun Apr 16, 2006 2:46 am

Very simple, but it does its job.

Image

This program can read information from Lugaru dialogue files. There are plenty of examples in the Lugaru/Data/Dialogues folder.
Then it writes it at the appropriate places in a map file. You can just edit dialogues in a text editor, following the Lugaru dialogue file pattern, and MapEdit will take care of the rest.

It also lets you swap camera views, or import them from some other map (usually a backup).

(Quoting a post from below)
You can run it by double-clicking. I made it as simple to use as possible so there's no flag or parameters. You don't have to know about command-lines.

Download.

Important Warnings:
-The app is compiled for OS X. However, the source in ANSI-C is included, and should almost spontaneously compile on any platform.
- This is a very simple program that was created fast, and won't have intelligent reactions if you try to give him stupid orders.
-You still can't add dialogue to a map that doesn't have any.
-If all else fails, there are instructions in the ReadMe.

It's up to you to undertake a campaign now. :)

EDIT: updated to fix a bug.
Last edited by Silb on Thu May 11, 2006 10:59 pm, edited 3 times in total.

Zantalos
The Postman
Posts: 1589
Joined: Thu Feb 23, 2006 10:43 pm
Location: Santa Clara,CA

Post by Zantalos » Sun Apr 16, 2006 3:54 am

Oh balls. :?

It seems like it will only work for the OS X, this just doesn't seem windows friendly. Maybe in part due to the lack of file extensions needed for the microsoft OS (adding .exe doesn't seem to fix the problem, may just be my computer). Oh well, looks like I'm gonna have to learn how to do this the hard way. :twisted:

Jeff
Evil Twin
Posts: 2892
Joined: Wed Nov 19, 2003 10:48 pm
Location: San Francisco, CA
Contact:

Post by Jeff » Sun Apr 16, 2006 4:14 am

I'm going to have a Cocoa GUI for this pretty soon.

Nuky
Plutonium Handler
Posts: 732
Joined: Mon Aug 15, 2005 5:34 am

Post by Nuky » Sun Apr 16, 2006 6:58 am

Zanta, you ARE using the cmd, right?
I don't think this is an executable like you are used to (click-n-run).

Jeff, awesome.

User avatar
rudel_ic
official Wolfire heckler
Posts: 2193
Joined: Sun Aug 28, 2005 11:19 pm
Location: Hamburg City
Contact:

Post by rudel_ic » Sun Apr 16, 2006 7:21 am

Zantalos, you'll have to compile it or wait for someone who compiles it for you. Just changing the file extensions won't do.
Then, you should run the resulting executable in a cmd window. Good luck.

Silb
Master cartographer
Posts: 558
Joined: Sat Dec 10, 2005 10:03 am
Location: Map Guild

Post by Silb » Sun Apr 16, 2006 7:53 am

You can run it by double-clicking. I made it as simple to use as possible so there's no flag or parameters. You don't have to know about command-lines.

Zantalos, I'm afraid Rudel_ic's right. Ask around for someone to compile it on Windows.

Zantalos
The Postman
Posts: 1589
Joined: Thu Feb 23, 2006 10:43 pm
Location: Santa Clara,CA

Post by Zantalos » Sun Apr 16, 2006 5:28 pm

Dang I have no idea how to compile yet, I'll have to find someone, but there's not that many people I know that can program with computers (I actually don't know any). So, I'll have to hold this one off, at least until I know more about this. Is there some kind of book or webpage you guys learn this from, or is this taught in college classes or some kind of advanced highschool program? I'll learn sooner or later.

User avatar
rudel_ic
official Wolfire heckler
Posts: 2193
Joined: Sun Aug 28, 2005 11:19 pm
Location: Hamburg City
Contact:

Post by rudel_ic » Sun Apr 16, 2006 7:16 pm

I learned C with books. You could look up stuff on Wikipedia though, like compiler and C.

Under Windows, a commonly used compiler (and overall useful collection) is MinGW.

To fully understand this whole mumbojumbo, you'd better learn programming in C. A random starting point for this is this place. A random Windows-centered perspective is accessible here.

(c) Google Entertainment Factory

Nuky
Plutonium Handler
Posts: 732
Joined: Mon Aug 15, 2005 5:34 am

Post by Nuky » Sun Apr 16, 2006 8:58 pm

Can't you just ./configure and make ? >_>

Or open the stuff in dev++ and click "compile"? -_-

Silb
Master cartographer
Posts: 558
Joined: Sat Dec 10, 2005 10:03 am
Location: Map Guild

Post by Silb » Sun Apr 16, 2006 11:48 pm

You can't ./configure and make. I don't know "dev++", but if it can compile any form of C, it can compile this.

I learned C by reading examples. Everyone's favourite learning method. :wink:

User avatar
rudel_ic
official Wolfire heckler
Posts: 2193
Joined: Sun Aug 28, 2005 11:19 pm
Location: Hamburg City
Contact:

Post by rudel_ic » Mon Apr 17, 2006 12:09 am

Nuky wrote:Can't you just ./configure and make ?
To call ./configure, you'd need a configuration script. That would generate a Makefile which you would then be able to call with make.
This compilation cycle is thought for strict system-dependent compilation and needs various standard project files and GNU tools.
At least the GNU tools can be installed under Windows with MinGW.
Or open the stuff in dev++ and click "compile"? -_-
Sounds likely. You could as well get gcc (via a properly installed MinGW again), go into the folder to which you extracted the source and type something like

Code: Select all

gcc mapedit.c -o mapedit.exe
at a cmd prompt.

It works fine under Linux with an installed gcc. Of course I've compiled without the .exe extension there :)

User avatar
»StaffShock«
Posts: 173
Joined: Sat Mar 18, 2006 11:13 am
Contact:

Post by »StaffShock« » Mon Apr 17, 2006 12:37 pm

Cool, this'll be great for my campaign, but whenever I try to import an edited dialogue file to replace Skipper's on the first level, it says that the original dialogue has 7 panes, and the target has 0. Then, when I import and try to play the map, whenever I go to Skipper and click, the up-and-down looping animations start over and the camera angle changes, but there's no dialogue.
Dialogue boxes: 7

Box 1:
Location: 2
Color: 0.0 0.0 0.0
Name: Jake
Text: Turner!
Sound: 4

Box 2:
Location: 1
Color: 0.0 0.0 0.0
Name: Turner
Text: What?
Sound: 7

Box 3:
Location: 2
Color: 0.0 0.0 0.0
Name: Jake
Text: Remember the desert outpost that we passed on our\way here?
Sound: 1

Box 4:
Location: 2
Color: 0.0 0.0 0.0
Name: Jake
Text: And how we thought it was deserted?
Sound: 4

Box 5:
Location: 1
Color: 0.0 0.0 0.0
Name: Turner
Text: Yes... What does this have to do with anything?
Sound: 1

Box 6:
Location: 2
Color: 0.0 0.0 0.0
Name: Jake
Text: It turns out it wasn't. One of their dead turned up\last night. Anne is examining him. Maybe you\should ask what happened. She didn't seem to want to\talk to me.
Sound: 6

Box 7:
Location: 1
Color: 0.0 0.0 0.0
Name: Turner
Text: I guess that explains the body armor. I wonder how\a raider ended up here!
Sound: 4
That's my dialogue file. Maybe I typed something wrong?

Silb
Master cartographer
Posts: 558
Joined: Sat Dec 10, 2005 10:03 am
Location: Map Guild

Post by Silb » Mon Apr 17, 2006 1:12 pm

Original dialogue in this case is Skipper's, and it does have 7 panes. Target dialogue is your dialogue (btw, it can have any number of panes, not a problem), it has 7 panes and not 0.

However the dialogue format you posted is perfectly ok. I just copy-pasted it right from your post into a text file and did what you tried. I didn't get this 0 pane bug. MapEdit just told me dialogue box 5's "Text" is too long (should be box 6, I corrected that and updated the link in my intro post), which is correct. I shortened it and it worked fine. But this length issue is not the problem right now.

Are you absolutely certain you didn't load the wrong file when MapEdit asked for the dialogue file?

If so, do you have the same problem if you try to load some dialogue file from the Data/Dialogues folder instead?

User avatar
»StaffShock«
Posts: 173
Joined: Sat Mar 18, 2006 11:13 am
Contact:

Post by »StaffShock« » Mon Apr 17, 2006 3:15 pm

Well, when I loaded one of the original campaign's dialogues, it worked fine. I'm trying to do a new dialogue for a level based on the raider camp. I also get the 0 pane bug. Here's what I have
Dialogue boxes: 2

Box 1:
Location: 1
Color: 0.0 0.0 0.0
Name: Turner
Text: Those are some nice robes they're wearing.\I'll have to take a couple before I leave.
Sound: 1

Box 2:
Location: 1
Color: 0.0 0.0 0.0
Name: Turner
Text: I wonder why anyone would build such a sturdy camp\in the middle of nowhere.
Sound: 8
Again, it looks fine to me.

Silb
Master cartographer
Posts: 558
Joined: Sat Dec 10, 2005 10:03 am
Location: Map Guild

Post by Silb » Mon Apr 17, 2006 7:45 pm

Again, I copy-pasted what you posted into a text file, and it worked at once.

Here's what I propose:

1- Perhaps some invisible character like line break is at fault. Hence, I'm sending you right here your own dialogue file as I used it. If it works, it will be a very good clue. Conversely, could you send me the exact file you used so I can look into it? You can use www.rapidshare.de, it's easier to post a file there than to download.

2- Speaking of which, you may also send me in a pack all your levels along with the dialogues. Since MapEdit works fine for me, it'll be a matter of 5 minutes to apply the latters to the formers and send back the result.

3- If number 1 doesn't work, it would be a huge help if you could edit the original raidercamp dialogue step by step into your own dialogue and locate at what point exactly you get the 0 pane bug.

Last thing, your dialogue doesn't have to have the same number of panes as the one you're replacing. It can have any number of panes between 1 and 100 :roll:

If anyone else has used MapEdit, it would help to know whether you get the same bug :)

Post Reply