Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2 3 ... 9

Author Topic: Dwarf fortress multiplayer  (Read 65817 times)

Warmist

  • Bay Watcher
  • Master of unfinished jobs
    • View Profile
Dwarf fortress multiplayer
« on: August 09, 2017, 01:47:49 pm »

Hi,

So this is a dfhack script that does web page based df multiplayer. As with all things in life there are some caveats:
  • arena only (for now?)
  • control is *indirect*. There is no good way to directly control a unit AFAIK. And there is an issue of "multiplayer turn based control" on top of it. So you guide the unit you control. Though you can arm it, haul items, etc...
  • done by a madman. A normal person would have used a web server with https support, i've implemented http server on top of tcp/ip...

Server running on: Offline (should really automate this indicator somehow...)
Source code on: github

How to host yourself:
  • Get win64 version of df. Install it.
  • Get the scripts from: here
(green button: clone or download, then download zip)
  • Extract files so that all of them are in df/hack/scripts/http (e.g. core.lua would be df/hack/scripts/http/core.lua)
  • Optional: modify hack/scripts/http/core.lua to change port etc...
  • Optional: modify equipment.txt, unit_list.txt, etc... For your own balance and choices
  • Start DF arena mode (the fort mode is still not very developed
  • type "http/burrows"
  • Designate a burrow and name it "SPAWN_MOBS"
  • type "http/server2" to start the server
  • Enjoy!

Features:
  • User management: users have username, password and unit
  • Unit control: click on map to move unit. Loose control as the unit goes into a rage and fights other units
  • New unit button!
  • Tilebased display (sorry no graphics yet)
  • Newest AJAX technolgy evah
  • Server autopauses if there is no players
  • Awesome arena action
  • Unit creation
  • Unit naming
  • Combat reports
  • Item buying. Kills give 5 money!
  • Numpad controls (thanks for idea KittyTac)
  • Highscore
  • Spectator mode
  • Chat , maybe with immersive distance to hear etc.. too lazy for the rest of it
  • Equip and haul items
  • Save your char builds using NEXTGEN localstorage HTML5 TECH

TODO:
Spoiler (click to show/hide)
Bugs and other lack of features:
  • No encryption or https: use non-main passwords
  • Up ramps wonky
  • Slow startup: the game is on my HDD so please wait until it spins up if for some time it was idle
Roadmap:
  • Tactical mode: As spectator but also place units. This mostly needs clientside work
  • Co-op mode: Defend fort from waves of enemies
  • Fort mode: Play as existing or "visiting" units. Do (or not) jobs. Start (or not) jobs. Drink all the beer and pass out. Fun for community forts
  • Sometime in the future: adventure mode - not sure what to do with fog of war

Suggestions are welcome. Also i'm not a web dev so this should look awful for them :P
« Last Edit: February 04, 2021, 06:33:54 am by Warmist »
Logged

assasinwar9

  • Bay Watcher
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #1 on: August 09, 2017, 05:51:24 pm »

your links seem to have a extra http thing going on lol.

just thought id tell you


EDIT: my god ... its actually rather amazing, even if i don't get to use a interface lol, i may have killed a unit without even knowing it till recently :)

also the fps seems to be .... too high or too low.... and i cant get my guy to go stay a z level lower becuse of it lol... but must say so far great work ... if i can help just tell me,
might want to get me to add you on discord or something tho... im not on here very often
« Last Edit: August 09, 2017, 05:59:35 pm by assasinwar9 »
Logged
immortal is never dieing so that sucks lol

Warmist

  • Bay Watcher
  • Master of unfinished jobs
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #2 on: August 09, 2017, 11:23:53 pm »

your links seem to have a extra http thing going on lol.

just thought id tell you


EDIT: my god ... its actually rather amazing, even if i don't get to use a interface lol, i may have killed a unit without even knowing it till recently :)

also the fps seems to be .... too high or too low.... and i cant get my guy to go stay a z level lower becuse of it lol... but must say so far great work ... if i can help just tell me,
might want to get me to add you on discord or something tho... im not on here very often

Thanks :). The fps is around 100 so it should be not too high. It might be too fast because there is no pause and it's making turns even if you are not doing anything. And yeah the z level navigation is strange, hopefully i'll think of something...

Sadly i don't use discord. I use irc though and am on #dfhack and #dwarffortress on freenode.

Warmist

  • Bay Watcher
  • Master of unfinished jobs
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #3 on: August 10, 2017, 02:45:28 pm »

So yeah. Added creature creation and ramp walking (though walking up ramps is a little... strange)

Also suggest races and cost if you want them added.

funkydwarf

  • Bay Watcher
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #4 on: August 11, 2017, 10:42:01 pm »

How do I get an account to try this thing? Do I just ask you like below?


Hey Warmist, will you make an account for me to see what this is and check it out?
Logged

Warmist

  • Bay Watcher
  • Master of unfinished jobs
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #5 on: August 12, 2017, 12:46:06 am »

How do I get an account to try this thing? Do I just ask you like below?


Hey Warmist, will you make an account for me to see what this is and check it out?
Oh just try logging in. If that account does not exist, it just creates a new one.

Warmist

  • Bay Watcher
  • Master of unfinished jobs
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #6 on: August 12, 2017, 06:38:49 am »

New version. Changes:
  • Added unit names
  • Combat report!!
  • Lowered fps to 20

KittyTac

  • Bay Watcher
  • Impending Catsplosion. [PREFSTRING:aloofness]
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #7 on: August 12, 2017, 10:24:26 am »

Good but laggy. Maybe someday we will get something like this but with a pocket world. Even mid-grade computers will slow down to a crawl with that though, probably.
« Last Edit: August 12, 2017, 10:27:26 am by KittyTac »
Logged
Don't trust this toaster that much, it could be a villain in disguise.
Mostly phone-posting, sorry for any typos or autocorrect hijinks.

Warmist

  • Bay Watcher
  • Master of unfinished jobs
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #8 on: August 12, 2017, 10:53:32 am »

Good but laggy. Maybe someday we will get something like this but with a pocket world. Even mid-grade computers will slow down to a crawl with that though, probably.
Actually i lowered fps so you could see what is happening. The other thing why it might look laggy is that the way i control creatures does not always work...

In other news: i've done items. Now you can add weapons to your creatures.

Edit: and armor and shields. Also increased fps to 50. Fights will be very chaotic. But maybe it's okay...
Edit2: probably need better arena...
« Last Edit: August 12, 2017, 11:13:07 am by Warmist »
Logged

assasinwar9

  • Bay Watcher
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #9 on: August 12, 2017, 12:31:17 pm »

talk about fast progress lol :)

keep up the good work and godspeed

shame you dont use discord tho >.<

EDIT : i just played for about 2 min or so ... then it seems it froze or my unit stopped responding to my mouse clicks :/
« Last Edit: August 12, 2017, 12:38:22 pm by assasinwar9 »
Logged
immortal is never dieing so that sucks lol

Warmist

  • Bay Watcher
  • Master of unfinished jobs
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #10 on: August 12, 2017, 03:00:59 pm »

talk about fast progress lol :)

keep up the good work and godspeed

shame you dont use discord tho >.<

EDIT : i just played for about 2 min or so ... then it seems it froze or my unit stopped responding to my mouse clicks :/
Yeah it crashed. Not sure why though. Will need to investigate

lethosor

  • Bay Watcher
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #11 on: August 12, 2017, 05:03:10 pm »

I've also had some issues with requests to /map failing and requiring the page to be reloaded before the map updates again (although that could just be due to general internet connection issues on your/my end).
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

funkydwarf

  • Bay Watcher
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #12 on: August 13, 2017, 02:27:53 am »

whoa thanks-i could see myself fooling around with this alot on mobile. I took a bronze axe, slayed a couple kobolds and a bob, then vomited all over.  It was glorious. Now I just tried and it works pretty good from my phone browser even, and the size is almost better for the small screen...

Very Cool!
Logged

KittyTac

  • Bay Watcher
  • Impending Catsplosion. [PREFSTRING:aloofness]
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #13 on: August 13, 2017, 06:17:18 am »

I'm able to move a single tile using mouse clicks, then it's unresponsive. Help.
Logged
Don't trust this toaster that much, it could be a villain in disguise.
Mostly phone-posting, sorry for any typos or autocorrect hijinks.

Warmist

  • Bay Watcher
  • Master of unfinished jobs
    • View Profile
Re: Dwarf fortress multiplayer
« Reply #14 on: August 13, 2017, 06:21:50 am »

I'm able to move a single tile using mouse clicks, then it's unresponsive. Help.
Just crashed :) but now it should be back up and hopefully fixed that bug.

I need to investigate a better control scheme. Maybe indicate more of what is happening (e.g. why your char is stuck?)

New version:
  • Added view up/down/reset
  • Added missle weapons (bow/crossbow). Currently it gives you 20 arrows/bolts if you select them
« Last Edit: August 13, 2017, 07:43:58 am by Warmist »
Logged
Pages: [1] 2 3 ... 9