Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 9 10 [11] 12 13 ... 46

Author Topic: Dfterm2 0.16, server software for playing Dwarf Fortress remotely  (Read 250198 times)

Adeon

  • Bay Watcher
  • Obey.
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3b - 8/4/2010)
« Reply #150 on: April 11, 2010, 04:21:24 am »

Not really sure what I changed, if anything, but the F-keys seem to work.

Did some playing around, and it seems that Putty doesn't send some chordic special keys, e.g. shift+"left arrow" sends just "left arrow", so not sure what can be done about that. shift or ctrl + enter send just enter. alt+enter sends a null byte.

Yep. I've tried with various clients to see if there's a way to get them to send something different on shift+arrow keys. Currently dfterm doesn't handle ctrl or alt -key combinations but they can be made to work for many of the keys (earlier shift key had this problem with all keys! that was pretty bad). Perhaps bind ctrl+arrow keys to shift+arrow keys when I release a next version? (unless they are used for something else, can't remember myself).

Update: I'm not making a formal release out of this yet but a version with more ctrl/alt-key combinations working (notably alt+arrow keys for adventure mode) http://83.150.74.15/files/dfterm/dfterm-experimental.zip. The file can change abruptly and be broken at times...
For shift+arrow problem I suggest binding them from DF to ctrl+arrow keys instead, they work with that experimental dfterm version.

« Last Edit: April 11, 2010, 06:19:31 am by Adeon »
Logged
I make dead people. Dfterm3

ILikePie

  • Bay Watcher
  • Call me Ron
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3b - 8/4/2010)
« Reply #151 on: April 11, 2010, 07:05:50 am »

iirc if the byte for a key is say, 0x0.4, then ctrl + the key would be \x4 or \c4 or something.

About my problem, when using DFPATH dwarf fortress treats dfterm's folder as its root folder. So dwarf fortress starts looking for its libraries and the data and raw folders in c:\dfterm and c:\dwarfort. Is this any normal?

If you ever add support for other text based games, have you thought of replacing the df.launchdf(slot) command with something like launch(path,slot)?
Maybe allow adding and removing slots in real time too?
« Last Edit: April 11, 2010, 12:56:47 pm by ILikePie »
Logged

Adeon

  • Bay Watcher
  • Obey.
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3b - 8/4/2010)
« Reply #152 on: April 11, 2010, 10:37:58 am »

iirc if the byte for a key is say, 0x0.4, then ctrl + the key would be \x4 or \c4 or something.

About my problem, when using DFPATH dwarf fortress treats dfterm's folder as its root folder. So dwarf fortress starts looking for its libraries and the data and raw folders in c:\dfterm and c:\dwarfort. Is this any normal?

If ever add support for other text based games, have you thought of replacing the df.launchdf(slot) command with something launch(path,slot)?
Maybe allow adding and removing slots in real time too?

There's also a setting called DFWORK. You need to set both DFPATH and DFWORK to make DF find its files. Check the manual.

I won't allow non-admin users to decide what to launch in a slot. The number of slots should be thought as the maximum number of slots the server hoster wants to allow. An user allocates a slot for themselves by selecting an empty slot. I can add a feature to add and remove slots in real time but only for admins (and only if there's more demand for that).

I'm not trying to reinvent dgamelaunch. I really just wanted to play Dwarf Fortress remotely. It is called dfterm, right? I can add support for other games but they are not a priority.

Logged
I make dead people. Dfterm3

daoist

  • Bay Watcher
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3b - 8/4/2010)
« Reply #153 on: April 13, 2010, 12:25:28 am »

after experimenting with the interface file, here's some changes I think work well:

Code: [Select]
Find:

[DISPLAY_STRING:KEYC0:Key C0]
[DISPLAY_STRING:SHIFT+KEYC0:Shift + Key C0]

Replace with:

[DISPLAY_STRING:KEYC0:Tilde]
[DISPLAY_STRING:SHIFT+KEYC0:Shift + Tilde]

Find: (there should be a few of them)

[SEC_SELECT:SHIFT+ENTER]

Replace with:

[SEC_SELECT:SHIFT+KEYC0]

Find:

[SECONDSCROLL_UP:SUBTRACT]
[SECONDSCROLL_DOWN:ADD]
[SECONDSCROLL_PAGEUP:DIVIDE]
[SECONDSCROLL_PAGEDOWN:MULTIPLY]

Replace with:

[SECONDSCROLL_UP:KEYDB]
[SECONDSCROLL_DOWN:KEYDD]
[SECONDSCROLL_PAGEUP:MINUS]
[SECONDSCROLL_PAGEDOWN:PLUS]

Find:

[CURSOR_UP_FAST:SHIFT+8]
[CURSOR_DOWN_FAST:SHIFT+2]
[CURSOR_LEFT_FAST:SHIFT+4]
[CURSOR_RIGHT_FAST:SHIFT+6]

Replace with:

[CURSOR_UP_FAST:SHIFT+W]
[CURSOR_DOWN_FAST:SHIFT+S]
[CURSOR_LEFT_FAST:SHIFT+A]
[CURSOR_RIGHT_FAST:SHIFT+D]

Find:

[D_MILITARY_ALERTS_SET_RETAIN:SHIFT+ENTER]

Replace with:

[D_MILITARY_ALERTS_SET_RETAIN:SHIFT+KEYC0]


Instead of shift+enter, use shift+tilde (the ` and ~ key)
Instead of shift+arrows, use shift+WASD
Instead of numpad +/- etc use []-= (the ones by your backspace key)
Logged

Adeon

  • Bay Watcher
  • Obey.
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #154 on: April 13, 2010, 10:36:45 am »

Released dfterm v0.1.3c to work with DF v0.31.03. This also includes some keyboard fixes (aformentioned in earlier posts with ctrl/alt stuff).

Logged
I make dead people. Dfterm3

daoist

  • Bay Watcher
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #155 on: April 13, 2010, 12:53:58 pm »

You forgot to update the download link in the first post :)

http://83.150.74.15/files/dfterm/dfterm-0.1.3c.zip
Logged

PhoenicIan

  • Bay Watcher
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #156 on: April 14, 2010, 04:02:27 am »

So how do I get this to work if I just want to watch other servers? And is there a list of ones that are up pretty consistently/constantly? I've tried a couple addresses and ports and every time all I get is a blank screen, and typing anything just makes it show up as if I was in notepad.

I'm running Vista somethin-or-other, if that's any sorta issue, using PuTTY. I selected the Telnet connection style, UTF-8, and "vt100+" when I found them, and nothing changed...
Logged
With apostrophes,
Rastaan angers PhoenicIan.
To my amusement.

Adeon

  • Bay Watcher
  • Obey.
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #157 on: April 14, 2010, 05:17:32 am »

So how do I get this to work if I just want to watch other servers? And is there a list of ones that are up pretty consistently/constantly? I've tried a couple addresses and ports and every time all I get is a blank screen, and typing anything just makes it show up as if I was in notepad.

I'm running Vista somethin-or-other, if that's any sorta issue, using PuTTY. I selected the Telnet connection style, UTF-8, and "vt100+" when I found them, and nothing changed...

I am aware of some servers that are constantly running, but I have no idea if they want to be public, except k4os.dyndns.org, port 8000 (which is getting less use now because we are using a server with better hardware elsewhere but it's not in my control so...).

Your PuTTY settings seem totally correct. I'm guessing you are simply not connecting to an active server and can't get a connection.

It'd be great if there was a central server that I could use to link other servers to one place, but it can require a lot of bandwidth and I just don't think there are many people willing to spare that much. Alternatively I'd keep up a list of servers somewhere but there are not many I know of.


Logged
I make dead people. Dfterm3

PhoenicIan

  • Bay Watcher
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #158 on: April 14, 2010, 03:12:07 pm »

That kinda stinks, cause I really like the idea of being able to watch folks play and see what they're doing, especially if they can explain it to me at the same time.

As far as public servers, heck, someone had one listed in their forum signature. I imagine that's fairly public.
Logged
With apostrophes,
Rastaan angers PhoenicIan.
To my amusement.

Guvante

  • Escaped Lunatic
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #159 on: April 16, 2010, 09:28:46 pm »

A friend and I played around with this today for several hours and it worked great! However after stopping for a while I also ran into the can't control anything bug. It pestered me after enabling the VERBOSITY setting (I wanted a list of the keypad control codes)

After some testing here is what happened when I was having issues:
Spoiler (click to show/hide)

Seems the only way I could get it to load was by not doing anything until the main screen was up, which was odd since I loaded a few times via the console before. Additionally it did not help to have the second console follow the right rules if the first did not.

I will look into it more and see if I see any patterns. BTW here is the result of my looking into Numpad in Application Mode

Spoiler (click to show/hide)

The code is untested since it seems to be non-trivial to compile the program, especially on Windows. All the codes were taken via VERBOSITY: 1, although they may not be 100% accurate due to the continuous nature of the log.

Keep up the good work, although I will say a simple Dwarf Therapist style assignment mode would be the only thing it appears to lack, but of course that would require a CLII rewrite from what I can tell since no one makes CLIs anymore it seems :).
« Last Edit: April 19, 2010, 04:43:59 pm by Guvante »
Logged

SolarShado

  • Bay Watcher
  • Psi-Blade => Your Back
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #160 on: April 16, 2010, 09:54:16 pm »

the real trick isn't making a "text-based GUI", but making something like that work over a standard telnet connection.

One could always write a custom client/server and use a purpose-built communication protocol, but that would be quite a bit of work.

If I could utilize a memory-reading library (like DFHack maybe) in Java, I'd be tempted to try my hand at a project like that...
Logged
Avid (rabid?) Linux user. Preferred flavor: Arch

Guvante

  • Escaped Lunatic
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #161 on: April 16, 2010, 10:09:59 pm »

I have been looking at it more and it seems like outside of interfacing with DF this could be handled entirely on the LUA side by defining a new state of locking (and associated flags), and a full screen overlay.

Here is what I was thinking:

Code: [Select]
        M|C C W|M S A A H T S|
        i|a r o|a t n n u r m|
        n|r o o|s o i i n a a|
        i|p s d|o n m m t p l|
        n|e s C|n e a a i p l|
        g|n s u|o D l l n i A|
         |t s t|r e T C g n n|
         |r M t|y t r a   g i|
         |y a t|  a a r     m|
 Dorf1  0|0 0 0|* * * 0 0 0 0
 Dorf2  *|* * 0|0 0 0 0 0 * *
 Dorf3  0|* 0 *|* * 0 0 0 0 *
 Dorf4  *|0 0 0|0 0 0 0 0 0 0

With actual shortening of the names, you could probably fit nearly 20 dwarves, how many disciplines would depend on how much room is left for dwarf names, assuming 13 that leaves enough room for 33 per page, which fits into 2 pages worth I think.

A selection icon similar to used in the game with a semifamilar paging method (either umhk or shift, or whatever) would make is usable in my opinion, and still significantly faster for a lot of the simple tasks than the in game UI.

Obviously the binary would need to provide the data and consume updates for this to work, but it is by no means impossible.
Logged

corhen

  • Bay Watcher
    • View Profile
    • My Google Site (WIP)
Logged
Now I need to build a wooden ship with waterwheels at the side and an iron cannon, i mean screwpump, at the front...

Guvante

  • Escaped Lunatic
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #163 on: April 17, 2010, 02:17:31 am »

Well that was interesting, if involving, still have to look into getting the data, but here is a mock up I built

Spoiler (click to show/hide)

I don't know if it would be readable with a different font (I am using 16x16 Mayday here), but I didn't need to pad at this resolution, having 5 letters for names is pretty harsh though.

Also didn't figure out a good way to mark things yet, just didn't get to it and having difficulty finding good characters (Need to just play around with the command prompt or something)

Odd, mildly amused by playing the game then extremely intrigued with modifying it :P
Logged

immibis

  • Bay Watcher
    • View Profile
Re: Dfterm, Dwarf Fortress in a terminal (v0.1.3c - 13/4/2010)
« Reply #164 on: April 17, 2010, 05:16:04 am »

What format were the screen contents in for 40d?
Logged
If I wanted ramps I would've designated ramps, dammit!
Pages: 1 ... 9 10 [11] 12 13 ... 46