ID:158858
 
1. How do I center the main window on a screen, and how would I lock other windows on a certain spot on the screen?

2.Would it be possible to, for example, press a button, and that uses a macro that automatically clicks the input window? And if so, how might I do that?

3. Would it be possible to have it so that, when you click the input window, You can change what type of input you are putting in. Example of what I am saying would be... You are writing in the input window, and then you press alt or some other key, and it would change the input from your view, to the world?

4. I think this is the last question, Would it be possible to make a proc run, while a person is typing in the input window?
Like, they start typing there message, and a proc runs. They stop typing, the proc stops, something along those lines?

Thank you for reading these questions, and for any help you can give
Koriami wrote:
1. How do I center the main window on a screen, and how would I lock other windows on a certain spot on the screen?

I don't believe at present you can center a window on the screen, since we don't have anything to grab either screen size or the exterior size of the window. (The window.size parameter deals with interior size.) You would need both pieces of info to center a window on screen.

It is also not possible to keep a window locked in a certain position; I'm not even sure Windows would make that entirely feasible, since I can't really think of any particular programs that lock their window in one place. It would be possible to add a parameter to disable the ability to drag a window around by its content area, and so if that was in use you could in theory remove the window title and border and have an unmovable window. I'm not sure I see that as being very desirable, but it's something we could consider.

2.Would it be possible to, for example, press a button, and that uses a macro that automatically clicks the input window? And if so, how might I do that?

If you mean automatically acting as if Enter was typed, then no. This could conceivably represent a security hole, since it could be used to force commands to run that the user did not intend.

If you mean you want to move the keyboard focus to the input control, then yes. You can use the focus parameter for that.

3. Would it be possible to have it so that, when you click the input window, You can change what type of input you are putting in. Example of what I am saying would be... You are writing in the input window, and then you press alt or some other key, and it would change the input from your view, to the world?

If I interpret this right you're basically asking about a way of dynamically changing what objects a verb has access to. Since the objects accepted by a verb are defined by the verb itself, this is not possible. This would be more along the lines of a language feature than a skin feature.

As far as skins go though, you could have a specific command setup for an input window that changed by using a macro or button. So for example if you had an input control dedicated to chat, you could hit a button and change its command from "say" to "teamsay" to talk to your teammates only.

4. I think this is the last question, Would it be possible to make a proc run, while a person is typing in the input window?
Like, they start typing there message, and a proc runs. They stop typing, the proc stops, something along those lines?

At some point down the road we may implement an on-change parameter for input controls. This has not been done yet for one reason. Because the server can presently only process one command per tick, on-change would basically overrule any other input from the user. In the future this may come up again for consideration.

Lummox JR
Koriami wrote:
2.Would it be possible to, for example, press a button, and that uses a macro that automatically clicks the input window? And if so, how might I do that?

You just want to make the input control focused, right? You can give focus to any applicable control by setting its focus parameter to "true" with winset(). EDIT: And in things like buttons, if the button doesn't need to do something else (special), then you can do this better by using the .winset client command directly in the button's command.

[...] Example of what I am saying would be... You are writing in the input window, and then you press alt or some other key, and it would change the input from your view, to the world?

Provided I understand what you want, this is possible through multiple methods. You should be able to either modify the input's current command with the text parameter (to visibly change the sent command/arguments) or its base command with the command parameter (which is more invisible to the user and will send the arguments given with a different command, usually to a different verb - you can send it to world_say() instead of say()).

4. I think this is the last question, Would it be possible to make a proc run, while a person is typing in the input window?

Hmm, I dunno, I think not.

Thank you for reading these questions, and for any help you can give

No problem, happy to help. =)
In response to Lummox JR
Thanks for the help guys, but I have one more question that I know can happen.

How do I send output into specific output windows?

Again, thanks for reading and for any help you can give.

Edit: Oh, I checked the tutorial for making skins and I think i get it
In response to Koriami
Koriami wrote:
How do I send output into specific output windows?

http://www.byond.com/docs/ref/info.html#/proc/output