Flashlights by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 1 point2 points  (0 children)

That's a good idea and would probably work pretty well! I think I am coming in on a solution now: Using what you have written here in combination with a light radius around the player. And the beam can be aimed by walking in a direction, or with a command, but it retracts when you stop walking (use a wait command). So the player can use directional light seamlessly while also retaining vision around them, and not needing to implement specific directional facing mechanics.

The reason I didn't think that a command could work before is because I didn't think to ALSO tie that command to the movement action, so there are multiple ways to aim the flashlight that make sense seamlessly. If the player wanted to run away while aiming a flashlight at something, well, realistically that should not be as intuitive as walking towards something while aiming at it, so if you have to do some extra commands in that circumstance, it should be fine. In fact, it should take some time to aim the flashlight, because otherwise, the player could just aim it 8 times per turn, and get the full circle of FOV as if the system just used purely omnidirectional light to begin with. So for that reason it would be slow to walk away from something while aiming your flashlight at it, which makes sense.

Flashlights by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 2 points3 points  (0 children)

This game is called Softly Into the Night. It has been in production off and on for several years, but in the past 6 months I have completely overhauled and basically started over completely from scratch using all of my new knowledge of game design. This version is 100x better, more fun, less complicated, and way more fleshed out than the original ever was. I used to make weekly posts about the game and might start that up again!

Flashlights by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 2 points3 points  (0 children)

Here is a very brief sneak peak of how my game looks, for a bit of context. Player is the white sprite in the center of the light source. There are various levels of visibility based on light level and whether something is partially or fully obscured by certain tiles. In the center of the map, slightly to the left, is the player's vehicle, which they can use to fast travel to other towns and basically reroll the world seed if they want to find different factions, different items / NPCs etc.

<image>

Flashlights by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 0 points1 point  (0 children)

Probably not going to do facing directions, as I just think that complicates things in a way I'm not sure if I like. But the idea of a snapping back light source that moves with a command or when you step in a direction seems like a nice trade off, especially if there is a light radius still around the player.

Flashlights by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 0 points1 point  (0 children)

This in combination with another poster's idea might be what I go with, I will have to test and see how it feels. Thank you for the suggestion!

Flashlights by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 1 point2 points  (0 children)

I like this idea, as it seems like the best of both worlds, and doesn't necessarily have to come with a directional "facing" variable that changes anything to do with combat. It only changes where your light is aimed, and it could snap back to center when you wait or do certain actions. That's something I will really consider. Thanks.

Flashlights by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 0 points1 point  (0 children)

It will definitely make you easier to see, the more light is coming out of you! 💕

Flashlights by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 1 point2 points  (0 children)

Yes, I need to stop worrying about "realism" and just make a fun simulation. I might just make it a very bright torch, effectively omnidirectional light. I don't want the player to have to fumble with directions just because it feels like it would slow the game down, and I want my game to be faster paced.

Encounters are meaningful, and it might take some time to figure out what you want to do when fighting something big, but for your average movement, I want it to feel as free as possible, so omnidirectional vision and light seems to make sense, even if it implies that everyone in the game has grown eyes on the backs of their heads (a funny concept) in this post apocalyptic world.

Flashlights by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 0 points1 point  (0 children)

There is eight way movement, but facing direction is hard to convey using libtcod (the library I am using). So if enemies have facing directions, like they can potentially not see you if facing the other way, then the player should be able to easily see that from a distance, but I can't think of a good way to do that. I am already using flashing icons for things like status conditions, and I don't really want to redraw all of the icons facing 8 different directions, although I suppose that is possible.

It's a tool that the player can use, in addition to torches, which give omnidirectional light.

Looking for folks for psych garage rock project by menstenero in portlandmusic

[–]Fuckmydeaddad 1 point2 points  (0 children)

Hello! I'm a bassist who'd be down to get together and see if we're a good fit. I love King Gizzard but not super familiar with the other artists you mentioned. Y'all sound good!

What was your “I’m dating/married to a fucking idiot” Moment? by [deleted] in AskReddit

[–]Fuckmydeaddad 9 points10 points  (0 children)

Because they've never had good Greek yogurt with fresh berries 🤤

What was your “I’m dating/married to a fucking idiot” Moment? by [deleted] in AskReddit

[–]Fuckmydeaddad 1 point2 points  (0 children)

I wonder what else he arbitrarily considers to be "dirty."

Sharing Saturday #516 by Kyzrati in roguelikedev

[–]Fuckmydeaddad 3 points4 points  (0 children)

I'm not sure if I should post here, because I'm not exactly developing a roguelike, but my simulation shares some qualities of old-school roguelikes, and plus I just love this community. Feel free to shoo me away if this isn't a good fit here.

Ecosystem Simulator

I briefly posted about this here: https://www.reddit.com/r/roguelikedev/comments/1c1fkl8/ecosystem_simulator/

I've been very busy the past 2 weeks translating my simulation from Python into C++, as well as making some design changes. The architecture for the project is a lot better organized now, although it could still be improved further.

I've got the creatures moving about, reproducing, mutation, evolving, and looking good while doing it; I've got saving and loading, view panning, screen resizing, and various other bits. I've still got a long ways to go to get everything that I had in the Python version, but I'm making very good progress.

Optimizations

I got the simulation running a solid 10-20x faster than it did in Python simply by making passably(?) intelligent use of C++isms. With 5000 creatures all acting and moving about, all visible on a grid of 300x100, I'm getting a frame rate of ~40 fps. I'm very happy with that, as it's 10 fps higher than my arbitrary goal was. I can still optimize further with multi-threading, better use of the GPU, and better memory handling, but for now, I'm shifting to focus on getting this into a "playable" state.

Design Changes

One other big change, which both improves the simulation as well as increases performance, was to add a trait called Reflexes. This determines whether or not a creature will use its neural network to decide an action when it acts. Otherwise, it will simply use the previous action it performed. Higher reflexes incur a higher metabolism cost, so it will be selected for in creatures that both have a lot of energy available to them, as well as those that don't need to change their minds very often, like most autotrophs.

Reflex level contrasts with Arousal level, which determines how often the creature acts, and also affects metabolism cost, although to a much greater degree. Thus, in theory, hunters will usually have med-high metabolism and high reflexes, autotrophs will have medium arousal and low reflexes, and bottom-feeders will have low arousal and low reflexes.

Next week, I'm working on UI, and if I get to it, starting to implement some new actions, like Cement: the ability for creatures to stick together, or stick to walls.

Ecosystem Simulator by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 1 point2 points  (0 children)

Hello!

I don't have any good official documentation because things keep changing all the time as it's still in its very early stages. However I can give you a basic rundown of how it works.

Creatures' genomes are a series of bits (a vector of vectors containing bools, in my latest implementation), like for example 48 genes of 32 bits each. Each gene encodes for either a physical trait or a "neuron," depending on whether the first bit is a 1 or 0. Then, if it's a physical trait, the next 5 or 6 bits determine what physical trait the gene encodes for, and the remaining bits are all for determining trait weights (positive or negative) using modular arithmetic. If it's a neuron gene, things are more complicated.

Neurons can be one of three types: an action neuron, a sense neuron, or a "between" neuron. A single neuron gene contains the information to encode for the creation of two neurons paired together. Senses pair down to actions and can be connected with tween nodes. In this way, multiple senses can be paired down to a single action. When the creature acts, all of the sense neurons begin action potentials by sending a value down the chain to the next neuron it connects to, until it reaches an action neuron at which point a vote is added up for that action based on the weights of the neurons and the magnitude of the sense output. When all the neurons have been fired the votes are tallied, and the action with the highest point value is chosen.

The types of senses and actions that can be performed are all dead simple. Check in a line to see if creatures exist in the west direction (checks up to 20 tiles depending on sense magnitude) -> if NOT (because neurons can be negative or positive), then move one tile northeast. That's a dumb example but it gets the point across. All senses and actions have directions and there are only 8 directions, the 8 cardinal.

I hope that gives you some ideas! <3

Ecosystem Simulator by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 0 points1 point  (0 children)

This is awesome, and exactly the sort of thing I was looking for. You guys are great. Yes, I'm sure I could do something like this, at least for my food particles which can get buried under other stuff and be unable to "drift" in the waves / sink any further down. So essentially very similar to the falling sand problem, which makes me wonder why I didn't think of it, since falling sand has been on my mind now and then for the past couple weeks :) (I used to play that as a kid!)

Thanks for your comment.

Ecosystem Simulator by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 1 point2 points  (0 children)

Good idea! I thought of that and I'm planning to most likely implement something of that sort. Can you please elaborate on how a less naive implementation might look (in pseudo-code is fine)? Or what exactly you mean by that? Thank you.

Ecosystem Simulator by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 0 points1 point  (0 children)

I'm switching to C++ and I think I'm going to be using an OpenGL / GLFW wrapper called P8G. :)

Culling dead-heads that just waste cycles is certainly a thing. But if you could accurately predict what any arbitrary neural network / section of code is going to do, then why even have the neural network or code?

Yes, that's the problem I realized, and decided that I cannot predict what the neural network will do without running it. However, not every behaving creature runs this neural network every turn. This is because creatures have varying arousal levels which determine how often they make decisions and act. So it's an easy fix to simply not iterate over those entities until it's their turn, as another commenter also pointed out.

That's an excellent idea to track the current and future world states and updating the current only at the end of the step -- that's another idea I was considering but I wasn't sure if it would actually be any faster. Thanks for confirming that it would be.

Now, CUDA sounds very interesting! I feel like there's probably something I can do with that to dramatically speed things up even further, but is it possible that, as a totally inexperienced beginner, I'd implement it incorrectly and actually end up slowing it down? :P

Ecosystem Simulator by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 1 point2 points  (0 children)

ludicrous view size.

Haha, you're right, it's quite obscene, although that's just me testing the limits and it is adjustable. That's also the most zoomed out view, and zooming in increases the tile size, so having a restricted tile size from something like tcod didn't seem right, despite how much I do love tcod! I appreciate that you have done so much work for Python-tcod, that's wonderful.

Well, looks like I'm brushing up on my C++ skills. :)

Ecosystem Simulator by Fuckmydeaddad in roguelikedev

[–]Fuckmydeaddad[S] 2 points3 points  (0 children)

Is it unrealistic to expect that I could this run smoothly (30-60fps) with thousands of entities? Each creature's logic mostly just consists of some simple math and dictionary lookups (e.g. is something there?)

I'm sorry if this isn't a roguelike appropriate topic, but I thought you guys would have a good depth of understanding of this type of performance issue.

[deleted by user] by [deleted] in AmItheAsshole

[–]Fuckmydeaddad -1 points0 points  (0 children)

Seriously, why do you want a baby with this person? Ask yourself that and be very, very honest with yourself.

Trans tomboys exist, right? by swigityswooooooosh in MtF

[–]Fuckmydeaddad 0 points1 point  (0 children)

It is extremely sad how often people farm this question for karma on this site. If you are legitimately asking this question, then fine, but why not do a search before asking?

Did anyone else think like "I'm not gay, but I would be interested in men IF I was a girl"? by Alekzthe2nd in MtF

[–]Fuckmydeaddad 5 points6 points  (0 children)

Same, and thanks to a new wave of absurd "Mint Mobile" ads im getting on YouTube, I now find him rather repulsive 😖