Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - blackreaper666

Pages: [1]
1
I keep overscoping my projects like a scrub. Currently I should be spending lots of time working.

I lose focus somewhat, and I'm not sure why. Need to get that particle effect for the flamethrower done...

I don't think people actually go through the 100 options for making a particle effect in unity, by hand.

I feel like overscoping is one of the most common problems with game dev. It's just so easy to fall into the trap of "thinking big" and envisioning a million cool systems and gameplay ideas :D

My main problem at the moment is that I finally kept the scope well manageable and in theory could finally start creating actual content based on my "engine", but I'm kinda in a "art-block" where I further keep polishing systems instead of building actual game content for people to play... I'm currently building a open source "Slay The Spire"-like deck builder that can actually be run in the terminal (but there is also a windowed version) and the engine is working really well so far but it lacks content (︶︹︶) I hope I can get my lazy ass to finally create some more game content soon

2
Utilities and 3rd Party Applications / Re: DFHack 0.44.12-r2
« on: March 05, 2019, 10:33:23 am »
You sure it isn't just returning two values? x, y = dfhack.screen.getWindowSize()

 :o You are right! Thanks. Now I feel dumb... I didn't knew multiple returns where possible in lua and the error didn't really help. I would have expected a different kind of error that somehow indicates that there are multiple values returned and not just taking the first one and working with that. That's what I'm used to from other languages. Thanks again for your help!

3
Utilities and 3rd Party Applications / Re: DFHack 0.44.12-r2
« on: March 05, 2019, 06:41:41 am »
Could it be that
Code: [Select]
dfhack.screen.getWindowSize() is broken in the lua api?

As per Screen.cpp Screen::getWindowSize() returns a coord2d, so it has a x and a y field. Reference:
Code: [Select]
df::coord2d Screen::getWindowSize()
{
    if (!gps) return df::coord2d(80, 25);

    return df::coord2d(gps->dimx, gps->dimy);
}

but lua treats it as a single number.
Code: [Select]
dfhack.screen.getWindowSize() will just return the x value (width), but if you print it it will show x and y in the console but there is no way to select either x or y.

Code: [Select]
dfhack.screen.getWindowSize().x
dfhack.screen.getWindowSize().y
dfhack.screen.getWindowSize().X
dfhack.screen.getWindowSize().Y
dfhack.screen.getWindowSize()[0]
dfhack.screen.getWindowSize()[1]
...

all fail because of "attempt to index a number value" which makes sense because lua thinks getWindowSize returns a single number.

4
Since a while I played around with a certain idea. I really enjoy watching other people play dwarf fortress and older roguelikes like nethack had the possibility to watch live sessions of people playing it via telnet / ssh. I wanted to bring this kind of feature to dwarf fortress as lightweight alternative to live-streaming services like twitch where you need a recording tool, mic etc. My current approach is to have a simple DFhack lua script plugin that syncs the df screen with a main-server and makes all active sessions view-able via a website.

Video demonstrations:
- Old one with a lua script: https://streamable.com/lbz60 (laggy but syncing works + showing different tilesets)
- New one with a plugin: https://streamable.com/1j4vb (greatly improved fps)
- Website / Streaming Process: https://streamable.com/cw6ns

My goal is to have a nice looking website where you can browse all the current sessions of people playing and you can join whichever session you want. I think it would be great to also implement a chat so people can interact with the person playing. You could imagine it as a really lightweight version of twitch just targeted at df with minimal setup required. All you need to do is copy the syncing script plugin into the correct dfhack folder and starting it.

My question is if there is interest in this kind of project?



Finished:

  • Sync screen with server (plugin -> server)
  • Sync screen with browser (server -> browser)
  • Only sync parts of the screen that changed to improve speed
  • Support Dwarf Fortress tilesets in frontend
  • Creation of user accounts
  • Setting stream title and description
  • Show list of current sessions on the website
  • Show info about game

Planned:
  • Show description of the stream in a nice way
  • Add chat to each session
  • ...

Limitations:
  • Width or Height of the window can't be more than 254 cells
  • TWBT not supported

Plugin Working:
  • Windows (x32 DF): Yes
  • Windows (x64 DF): Current Goal. Not working yet duo compiling problems...
  • MacOSX: Yes
  • Linux: Planned

I'm also interested in suggestions about what kind of features could be interesting or useful!

UPDATE:

I wanted to push the possible fps of the stream further for a smoother experience, which wasn't possible with just a lua script. The obvious solution was writing a plugin for dfhack instead of just a script, so I just did that. It's working awesome so far! Feel free to take a look at the newer video 8)

5
Utilities and 3rd Party Applications / Re: DFHack 0.44.12-r2
« on: March 02, 2019, 02:47:10 pm »
Just a little question about the lua api. Is there a straightforward way to get the character, foreground and background color of a tile that is on the screen?

EDIT: Found the screen.readTile function. Unfortunately a lot of tiles return 0 as char code and color. Menus and Borders work but not the "game-view" where my little dwarfs run around. Is there something I'm missing?

EDIT2: So this was the result of using TWBT. So I solved all my problems :)

6
I tired to use the 12x12 version with Wanderlust 12x12, but the sprites keep having a black background... Is there anything I could have done wrong? (DF Version: 44.05)

7
Utilities and 3rd Party Applications / Re: DFHack 0.44.09-r1
« on: April 29, 2018, 03:46:24 am »
I'm having some smaller questions about scripting.

1. Is there a way to get the year of embark? You can get the current year, but I didn't find a way to check how many years the fort already exist

2. How can I get the 'name' of a creature that doesn't have a normal name?

3. How can I get the name of my fort?

Thanks in advance! :D

Pages: [1]