Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: What do you think of this option of making an Online version of adventure mode?  (Read 2050 times)

Lioneez

  • Bay Watcher
  • Challenged.
    • View Profile

I was thinking a bit about DF while I was learning full stack, it is kind of irrelevant what I learned exactly since im on my way to being a junior so its all hypothetical from here on:

Essentially, I had an idea of how maybe one could possibly make an online version of adventure mode, essentially you would have 2 separate programs.
on the main server, you have the generated DF world which runs constantly, the world information is handled by the server, aka the world instance on the server.
the player communicates to the server by taking control of an entity they created using DF hack, now because DF works on tics and you cant take control of more than one entity, I thought that maybe if DFHack had a prescript option to control entities, it could be possible to have more than one player to take control and play on the same world.

now the second program from which you communicate to the server, well it just communicates to the server and also renders the images, making a 2D grid map to have the players move on isnt all that hard, with DF hack you can make the program communicate to DF on that server what will happen in the world.

I kinda suck at explaining but thats the gist of it, 2 programs, on the server you have a DF world with DF hack, the other program just communicates via json or something, any thoughts?
Logged

Thisfox

  • Bay Watcher
  • Vixen.
    • View Profile

I've heard of people doing this before somewhere. Making the game multiplayer would definitely be an amazing idea.
Logged
Mules gotta spleen. Dwarfs gotta eat.
Thisfox likes aquifers, olivine, Forgotten Beasts for their imagination, & dorfs for their stupidity. She prefers to consume gin & tonic. She absolutely detests Facebook.
"Urist McMason died out of pure spite to make you wonder why he was suddenly dead"
Oh god... Plump Helmet Man Mimes!

Asra

  • Bay Watcher
    • View Profile

Hmm... how would you handle the complicatedness of wrestling in real time?
Logged

Lioneez

  • Bay Watcher
  • Challenged.
    • View Profile

Hmm... how would you handle the complicatedness of wrestling in real time?

hmm... well all the units are capable of that, if dfHack had a way as I said to pre define entities actions you could communicate to that same script that the NPC in question does certain wrestling moves on a target.

hotkeys for real time should come in handy for implementation of that, if I imagine the numLock keys to be a representation of the enemy you are facing we can imagine those keys to be as follow:

7(Extra appendage*)8(Head)9(Extra appendage*)
4(Left arm)5(upper Torso)6(Right arm)
1(Left Leg)2(Lower Torso)3(Right leg)
0(Extra appendage*)

or something like that, now upon pressing lets say the head[8] you enter to the features of the head

7(Left ear)8(Hair(?))9(Right ear)
4(Left Eye)5(Nose)6(Right Eye)
1(Extra appendage*)2(Mouth)3(Extra appendage*)
0(Neck)

Now that you entered that array we can have you enter another or another one until we reach the end of this array of arrays or alternatively you clicked another hot key which will bring you to the action hotKeys like lets say [numKey +] in which you will again enter into an array of possible actions.

its not perfect work around and you will need to press something like "80+9" and lets say to let go we will have the hotKey [numKey -] which will undo the grab feature after it, but if you are already holding it you can press "+9" again and again to repeat the action cause of condition "if(hold)" lets say.

does it answer the concern? also im aware it wont be able to replicate all the action and visualizing this sort of targeting system on a 3x3 grid plus one would be a challenge in itself and some moves will be impossible, but in wrestling lets say its kind of unrealistic to grab someone by the eye lashes and pluck them one by one to begin with lol


Edit: Oh i forgot you must first choose with which appendage to attack with, so lets say the first combination of keys you press on the numPad are what appendage you intend to use, so it will be like:

Choose what appendage to use:
45+80+9 (lets say that 5 in this case is upper arm like:
4(hand)5(middle arm)6(upper arm)
)
« Last Edit: November 22, 2021, 01:22:05 pm by Lioneez »
Logged

Schmaven

  • Bay Watcher
  • Abiding
    • View Profile

Pausing would have to either be completely removed, or if any 1 player pauses, it's paused for all.  Otherwise you'd get time synchronization issues.  Combat would be much more dangerous with no pause given how quick the AI is.
Logged

Lioneez

  • Bay Watcher
  • Challenged.
    • View Profile

Pausing would have to either be completely removed, or if any 1 player pauses, it's paused for all.  Otherwise you'd get time synchronization issues.  Combat would be much more dangerous with no pause given how quick the AI is.

ehh.. not exactly, you as a player if and only if we can somehow pre Script actions of a given entity join an already running instance of a DF world, we communicate to that pre Script the actions of your players through a second program which renders you the graphics, reads from the server the state of your surroundings in the DF world, and lastly communicates to that script so you as a player can actually control it.

there wont be a pause option if its online, you will need to relay on muscle memory essentially in that case or simply ignore Wrestling as an option by just pressing [numKey -] (essentially remove his grab automatically instead) each time an NPC attacks you with a grab or something, I also think that maybe I should delay the speed of wrestling moves for NPCs on players because those are quite fast without a pause option.

I need to think more about the timing though if I take the delaying approach
Logged

Shonai_Dweller

  • Bay Watcher
    • View Profile

So is your plan is to remove Fast travel and building altogether in this version? I can't see how that could possibly work in a multiplayer game. Unless it's "set fast travel - log off for the night".

And wandering around manually is tremendously boring.
Logged

Lioneez

  • Bay Watcher
  • Challenged.
    • View Profile

So is your plan is to remove Fast travel and building altogether in this version? I can't see how that could possibly work in a multiplayer game. Unless it's "set fast travel - log off for the night".

And wandering around manually is tremendously boring.

I dont really know how Fast travel works, but I think it should be possible to use the DFhack Teleport() function for that but I think it should be reserved to certain places personally rather than being able to sonic speed run across the world while the rest of the players and entities didnt even get their pants on(in theory, dont quote me on that), dfHack has a lot of tools I didnt see being used.

also.. because we create an entitiy we create it somewhere, meaning that you can probably extend that function to other points or just rewrite your character stats and condition and have DFhack create that char and create it anew(will probably be buggy as all hell)
Logged

Rumrusher

  • Bay Watcher
  • current project : searching...
    • View Profile

So is your plan is to remove Fast travel and building altogether in this version? I can't see how that could possibly work in a multiplayer game. Unless it's "set fast travel - log off for the night".

And wandering around manually is tremendously boring.

I dont really know how Fast travel works, -snip-
fast travel is pretty much unloads the map and sends the player to what I gather the embark screen you can't really use dfhack teleport to warp folks across the world map since adventure mode main field is similar to fort mode but you don't see the edges of the field, and if the adventurer gets too close to the field edge the game will unload a chunk of the map and load in a new chunk and anything stuck in the unloaded section of the map gets remove from play and possibly become a historical figure in an army or culled if it wasn't important.

I would say warmist did do something similar to this in the multiplayer online DF mods that were made where you just took control over some unit on an active field.
Logged
I thought I would I had never hear my daughter's escapades from some boy...
DAMN YOU RUMRUSHER!!!!!!!!
"body swapping and YOU!"
Adventure in baby making!Adv Homes

Nopenope

  • Bay Watcher
    • View Profile

Yeah warmist made some dfhack magic such that one instance runs fort mode and other players control units in an adventurer-like fashion. It's not adventurer mode, though, and in combat the AI behind every unit takes over just like fort mode.

http://www.bay12forums.com/smf/index.php?topic=165168.0
Logged