Please login or register.

Login with username, password and session length
Advanced search  

News:

For WME related articles and tutorials visit WME Resource Center.

Pages: [1] 2  All

Author Topic: How Add Window  (Read 11020 times)

0 Members and 1 Guest are viewing this topic.

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
How Add Window
« on: November 15, 2008, 02:55:14 AM »

I need basic instructions for adding a static image using the Window Editor and having it work in the game.

I read through as many forum posts and the docs online but can't find all the pieces or I'm missing something.  :  )
« Last Edit: November 15, 2008, 07:16:31 PM by Catacomber »
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: How Add Window
« Reply #1 on: November 15, 2008, 10:19:14 PM »

Create a window, set its dimensions so that it covers the entire screen (e.g. 800x600). Set its "Transparent" property to true. Then add buttons or static controls to it where you want your on-screen icons displayed.
Finally, in some script (e.g. in game.script, if you want it to be visible all the time) call something like:

var WinHUD = Game.LoadWindow("path\name.window");
WinHUD.Visible = true;
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #2 on: November 15, 2008, 11:43:24 PM »

Thank you, Mnemonic, I will try it.  :D
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #3 on: November 16, 2008, 12:28:44 AM »

It works beautifully.  Am surprised how simple it is!  That doesn't mean I can add a more complicated window as easily but it's a start.   :o
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #4 on: November 16, 2008, 04:05:24 AM »

Am playing Deathgate and would like to add some Deathgate type things to my file.  Will be back as soon as I've searched the forum to see if there are already instructions on what I'd like to do and whether I can do said stuff based on search results.  :  ) I think everything that's done in Deathgate that I would like to do can be done in a Window. 
« Last Edit: November 16, 2008, 04:32:19 AM by Catacomber »
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

metamorphium

  • Global Moderator
  • Addicted to WME forum
  • *
  • Karma: 12
  • Offline Offline
  • Gender: Male
  • Posts: 1511
  • Vampires!
    • View Profile
    • CBE  software s.r.o.
Re: How Add Window
« Reply #5 on: November 16, 2008, 02:36:16 PM »

let me know if you need something more specific. Death gate is excellent game and it's an example of game which can be made totally in WME. :)
Logged
J.U.L.I.A. Enhanced Edition, Vampires!, J.U.L.I.A., J.U.L.I.A. Untold, Ghost in the Sheet

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #6 on: November 16, 2008, 05:30:06 PM »

Thank you, Metamorphium, I'm sure I'll need some help. Am playing both Ghost in the Sheets and DeathGate while making a simple demo game to make sure that I can do the usual things I like to do in a game.  I found DeathGate by browsing this forum -- there was a discussion of adventure games.  It runs pretty well in Dosbox and I agree it seems very suited to WME.   

By the way, I really liked your music in the WME book exercises--it's my favorite type of music--. 
« Last Edit: November 16, 2008, 05:44:07 PM by Catacomber »
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #7 on: November 17, 2008, 04:12:40 AM »

I now have a question about following a Deathgate style.  What is the most efficient way of displaying talk topics at the bottom of the scene and the answers for each in a box up top right next to the picture of the speaker.

As here:


Would it be a window? As you click on the talk topic at the bottom, the response of the person in the picture appears up top in the box to the right of the picture.  I like this a lot. The screen seems to be broken into 3 parts: the picture of the speaker on the left, the response to each talk topic on the right and the talk topics on the bottom. It's nice that the talk topic that's selected appears yellow when you click on it but that's not absolutely necessary.

I'm trying to chase this down reading through old threads.  I found this old quote from Mnemonic:

"basically you can create "windows", those can have a backround image, title bar etc., plus the windows can contain other windows and "widgets", such as buttons, single line editors and static texts or images. Using these simple elements you can build up rather complex interfaces."

 
« Last Edit: November 17, 2008, 05:45:02 PM by Catacomber »
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #8 on: November 17, 2008, 08:44:50 PM »

Trying to figure out at least one way if not the best way to do this:
Looking at the particle emitter demo
I could create a window for each scene where I wanted this type of interface to take place could have 3 regions designed into the background (They are just there--drawn there).
Then could create the talk topics on the bottom square in a window via buttons.
Pressing a talk topic button, would trigger dialogue in the right hand box--just as in the particle emitter demo if you press the sentence for "Make snow"-it snows.  And when you press the sentence "Make rain" it makes rain. 

There has to be a better way.
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

metamorphium

  • Global Moderator
  • Addicted to WME forum
  • *
  • Karma: 12
  • Offline Offline
  • Gender: Male
  • Posts: 1511
  • Vampires!
    • View Profile
    • CBE  software s.r.o.
Re: How Add Window
« Reply #9 on: November 17, 2008, 09:54:26 PM »

Cat, for this you need exactly one window. You can even use the stock responses.def to boot. Simply put another static component to the right (the huge flowing text) and one static (or entity container) for the person's face. The rest is just background imagery. :)
Logged
J.U.L.I.A. Enhanced Edition, Vampires!, J.U.L.I.A., J.U.L.I.A. Untold, Ghost in the Sheet

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #10 on: November 17, 2008, 11:16:31 PM »

Let me see if I understand the steps correctly:
1. Create window and script to load window.
2. Create buttons in the bottom that are the talk topics that the player depresses.
3. Create static component to the right of big face which is just a static component itself. 
4. Use stock responses.def somehow.

Only 2 things I'm vague on but maybe I just have to try it---
1. How do I use the stock responses.def?
2. How do I fill the static component on the right with the text that answers each talk topic?

Thank you for your help!

Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

metamorphium

  • Global Moderator
  • Addicted to WME forum
  • *
  • Karma: 12
  • Offline Offline
  • Gender: Male
  • Posts: 1511
  • Vampires!
    • View Profile
    • CBE  software s.r.o.
Re: How Add Window
« Reply #11 on: November 17, 2008, 11:27:50 PM »

Cat,

you might want to backtrack to the chapter about dialogues. :)

http://res.dead-code.org/doku.php/wmebook:ch7

You can newly open the responses.def file in the window editor and add there a few more components. When the response is triggered, you simply update the Text property of the upper static control.

Hope this helps.
Logged
J.U.L.I.A. Enhanced Edition, Vampires!, J.U.L.I.A., J.U.L.I.A. Untold, Ghost in the Sheet

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #12 on: November 18, 2008, 01:56:26 AM »

There's so much knowledge stuffed into that WME book that I totally forgot Chapter 7!  Thanks. I will try it. Am not sure yet I know how to make it work in a window but will see how it goes.  :  )
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #13 on: November 18, 2008, 04:17:08 AM »

I reread Chapter 7--I had no problem implementing the dialogues in the game I made following the WME book.

But I'm lost. I don't have an actor at all in this little demo game that I'm making.  I do have a "phantom entity" that is nothing but a 2 pixel image.

I have my window "Box" all set up and it shows up when I play the scene.

I have the picture in as a static control.  I have a black background in on the right as a static control to hold the response text that should show up when the player left clicks on a talk topic.

I have two talk topics at the bottom as buttons.

I can open the responses def file in the window editor but what to do next escapes me.

I don't know what components to put in the responses def file or where to put them to trigger or create the response for each button.

Thanks for any help.  Everything is working fine except I'm stuck right here. 

Talking with an actor I can handle.  Talking split between a button and a static control is beyond me right now.

By the way, I'm really glad I printed your WME book out because right now I can't get into that area of the website.  :  )   
« Last Edit: November 18, 2008, 06:31:05 AM by Catacomber »
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  

Catacomber

  • Supporter
  • Frequent poster
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Female
  • Posts: 443
  • I love mice.
    • View Profile
    • Catacomber.com
Re: How Add Window
« Reply #14 on: November 18, 2008, 06:01:58 AM »

To simplify where do I store the response for each button that represents a talk topic? I don't have an actor--no molly or sally.

How and where do I call that response?  How do I pass it to the static component that receives and displays the text for response to the button.

I would guess it's called on left click in script on the button that has the talk topic but I don't know what to put there.
« Last Edit: November 18, 2008, 06:47:07 AM by Catacomber »
Logged
http://www.catacomber.com/
Code: WME Script
  1. Mnemonic is wonderful.
  2.  
Pages: [1] 2  All
 

Page created in 0.042 seconds with 20 queries.