Posts

Showing posts from April, 2020

Corona-cation (Day 23)

Image
Refactoring... yay     Today I felt the full impact of all my impromptu decisions during the jam. Every, "oh, this'll do for now" had to be cleaned up and thoughtfully reworked. The majority of it had to do with the communication between buttons and the objects they activate. I had originally planned for there to be one or maybe two plate/button per stair/door. I was very wrong.     Today I was sent a screenshot of a prototype for level 6, and well, it speaks for itself... Credit: Destin LeClear     It became apparent I had to prepare for multiple buttons per object. I thought that it would do nicely if I had an array of buttons that could activate a door or something. Then I realized that to do that I would need to rework the activation/deactivation system, but then I would also need to be able to generalize activation objects, and I'm sure you can see where this is going.      I settled on the following system. One parent class for buttons (the things

Corona-cation (Day 22)

Image
Post-jam fixes and tweaks     After the step back project was released yesterday I had some friends play-test. There were multiple bugs found and I got some good feedback. Today (and part of yesterday) I started implementing changes and fixing some of the more game-breaking bugs.     One of the first things I did was edit the player's movement. The friends I had play it thought movement felt floaty and imprecise. I fixed the floatiness by changing some of unreal's standard settings. I increased "air control" to .8 and that felt much better already. Now if you jumped you could actively make corrections instead of being helplessly stuck in mid-air until you were to land. I want to edit the jump more in the future and make it more like Nexus from last year.     I also messed around with the door collision because one of the biggest complaints was on level 3 when you had to push a box through a doorway it would get stuck 9/10 times. I fixed this by making the doo

Corona-cation (Day 21)

First game of the year released     Today we finished our submission for the "Step Back" game jam. We expect to continue working on it but the game jam version is now released. It includes seven levels with multiple types of puzzles that get progressively more difficult.      I only did a few things today on the game to round out the features. The biggest one was fixing a small bug where if an object (door, stairs, etc.) could be activated by multiple buttons, the object would always be deactivated in reverse time. This was because one of the activation objects would not be interacted with and while reversing would always be setting 'deactivated'. I fixed this by adding a check to see if the value had changed and only set the activation state if it was changed.      I also found a humorous bug that would allow the player to fly. The premise is that if you have a pick-up cube you can pick it up while it's underneath you then lift it up and fly on the box

Corona-cation (Day 20)

Image
Too much progress     There was so much progress done today that I will struggle writing it all down here. Basically, over the four or so hours I spent on the game today it is functionally complete. The last thing we have left to do is make the levels and test.      The day started with me getting access to some art assets. I got a box, door, pressure plate, extendable stairs, and a test level. Within about 30 min I had the pressure plate extending the stairs and opening doors when a box was pushed onto them. The code is most likely the messiest I have ever made and probably equally inefficient, but hey, it's a game jam so who cares.      I put what I had into the test level to show the team and they said that we needed to have big boxes that you could only push and buttons that you could press and both would reverse with time. On top of that I needed to be able to pick up the smaller boxes. This last feature I was relying on another programmer for, but he wasn't res

Corona-cation (Day 19)

Git Commit: 439d000 Git Commit: b2162a7 "Finished timer and added post process effect" & "Added time reversable cubes"     Today took a bit of a turn from what I expected yesterday. I thought I would be working more on the multiplayer system for top-down game, but instead I started work on a game jam project. The theme being "Step back" our team decided on a puzzle game where time steps back every so often, helping or hindering you as the player.      I took on the job of doing the time mechanic. As far as I know, the only objects that will reverse will be the boxes. The boxes reversing will in turn activate or deactivate pressure plates opening/closing doors etc.      Today I started a first person project and added the timer and the boxes. The timer was very simple and is controlled by the level blueprint. It loops a timer and the timer on the player's screen will follow that timer, getting remaining time if time is going forward,

Corona-cation (Day 18)

Success with multiplayer ft. Steam     I spent all of today looking more into how to get internet multiplayer working. The first attempt was the port-forwarding from yesterday. Either I did it wrong or it didn't help. I thought I opened port 7777 but after I did nothing changed and I wasn't able to connect to anyone. It's possible that the other person also needs to have a firewall rule for the same port? But I don't know.      The next thing I tried was the advanced sessions plugin that I originally tried with for the creative jam. This time I went through the setup step-by-step to see if I could get it to work. Very long story short... it (and I cannot stress enough)  FINALLY  works. I followed along with this  tutorial series up until part 7 and over 3 hours later it was all worth it.      There were some hurdles but I am overjoyed now that it works. The initial setup required adding lots of #includes to source files (one of them from the video didn't wo

Corona-cation (Day 17)

Why is online so hard?     So I continued my adventures in networking and I have had one minor success. That success being that I figured out how to test an online session over LAN. That is to just not "use LAN" when finding sessions. It sounds simple when I say it like that but it's actually really great because now I can test all I want from home.      That was really the only god thing that I found today, everything else wasn't all too helpful. I tried going back to the IP based connection but that didn't work still. I tried using public IP's and no luck. I manually opened port 7777 (unreal's default port) in my firewall and still no luck. After I opened the port I tried again with the sessions system but that failed as well.      I have decided for the time being that I am going to try to use the sessions system just because that gives me more options readily without any extra effort. After I decided this I did lots of reading into the online

Corona-cation (Day 16)

Figuring out networking     Today I continue my search to find a way to make this game work over the internet. I started out trying to find a way to test the game when I was ready. I wanted to be able to do it all at my house, not having to rely on anyone else to test. But after looking around I couldn't find a way to do this. I wanted to be able to simulate an internet connected game over my own LAN but the only solutions I found were sketchy programs and complex router/modem crap that I didn't understand. For now I have to rely on the availability of my team to be able to test new prototypes.      Once I had that behind me I did some research into ports, public IP addresses, game sessions, and how exactly unreal handles all of it. I didn't find much that was helpful, but I did find this video from 2014 when the blueprint networking nodes were introduced. This made me give the blueprint approach one more look. It seems to work in every environment that I've tes

Corona-cation (Day 15)

First play-tests and edited Skeleton mesh Play-testing:     So far today I have done two play-tests. One with my brother's computer on the same network and one with a team member on a different network. The one on the same network worked seamlessly. I was able to join the games, choose different classes, and end the game with an improvised trigger volume. The test across different networks didn't work though. When you would hut join nothing would happen. I should do more tests to make sure ti is a LAN issue and not an issue with the tester's computer. Although if the problem is that the current system won't work if it's not LAN, then I have a lot of work cut out for me. Skeleton:     Also I received two separate models today for the skeleton and his bow. This has made me realize one thing though; for items that need to animate (e.g the bow string) there will need to be a separate anim BP for that item. This will be a problem for future me though as af

Corona-cation (Day 14)

Git Commit:  9004b33 "Added architecture and props, Added skeleton mesh and anim" Added architecture and props:     Literally just imported any finished models from our modeler and animator. I gave feedback on scale and now everything is perfect at normal scale. Added skeleton mesh and anim:     Part of the imported props was the skeleton mesh. I applied this to the archer character and began to give it a very simple animation blueprint. This AnimBp only has three states: Idle, Walking, or Shooting. The idle and walking worked just fine but the attacking gave me some problems.      I had not planned well for this so now I had to figure out a way to know if the BT is attacking. I did this with a simple boolean that the AnimBp would check. I figure there's a better way to do this in the future, but this is all I had for now. After I had the boolean I had to allow the clients to be able to see it as the host (server) is the only thing that runs the AI. I s

Corona-cation (Day 13)

Image
Git Commit: 3d3319b "Fixed video settings, Added sharpshooter collateral hits, Changed AI MoveTo task" Fixed video settings:     This was just because I realized the reverting video settings function was not working. I found that if you wanted to revert the fullscreen mode or whatever in a packaged game it wouldn't work. This ended up being because you have to "Confirm video settings" in order to revert to them. By doing this I also figured out that these settings work differently in a packaged game versus the in engine simulation. Added sharpshooter collateral hits:     I thought of this when I was showing friends the progres of the game. that it would be cool if you could shoot through multiple enemies at once. I implemented this by just doing a multi hit line trace and damaging each enemy with decreasing damage with each layer. Changed AI MoveTo task:     I was wanting to do this for quite awhile but I finally got around to it today. I ba

Corona-cation (Day 12)

Image
Git Commit: ???? "Added video settings, Changed Sharpshooter sprint" Added video settings:     This part was my major work of today. It wasn't difficult at all, just time consuming to do all of it. I expanded the settings menu to include: Fullscreen modes Resolution Frame-rate limiting V-sync     Luckily for me, all of these settings were already built into unreal so all I had to do was put them together. The only thing I really had to do by myself was the safety measure of popping up the "Confirm Resolution" menu with a timeout that will reset the settings if they aren't confirmed. This is what all that looks like:     I also had to set the values when the player first loads up the menu. Here's that:       The current menu states look like this: Very good design, I know     I did all this for three reasons. One: I wasn't assigned anything else. Two: It would have to be done at some point. Three (the main on

Corona-cation (Day 11)

Image
Git Commit: ???? "Added Sharpshooter stamina, Fixed PlagueDoctor targeting" Added Sharpshooter stamina:     I haven't been given much to do so I decided to go back to something that I left from earlier. I was told earlier that the sharpshooter would have limited stamina. Before today though stamina was unlimited. It wasn't too hard though, I used this video as a starting point and went from there. The video talked about the timers and that was all I was missing from before. The final system will let you run to empty and stop sprinting there or deplete the stamina some fraction and charge up back to full. This is the final stamina system:     After that was done I had to have some way of conveying this to the player. I went into the first person HUD and just repurposed the cleric's mana bar as a stamina bar for the sharpshooter. But instead of making a duplicate I just had the same bar display mana if it was the cleric and stamina if it was the sh

Corona-cation (Day 10)

Image
Git Commit: d8cb5eb "Plague Doctor working prototype"     At long last... he is complete. (For now)     Today I made the changes I wanted to make from yesterday as well as added some extra features. The first and most important thing I did today was to make the enemy attack in a cycle of random attacks. I said yesterday that I thought I would do this with custom decorators but this turned out to be unnecessary. All I had to do was use what I already had along with conditional loops. Basically, the problem was that when the doctor needed to walk somewhere it would do It for a single tick then rerun the entire tree. I added a conditional loop to the MoveTo and that fixed it. Because I could now get him to go places reliably, I added MoveTo's to the other attacks to make sure he was within range and the attack would have a higher chance of hitting. (Picture 1)     Once I had a reliable system that would not lock up like yesterday I went on to testing the actual at

Corona-cation (Day 9)

Image
Git Commit: None     Still nothing finished yet for the Plague Doctor. It is proving to be much harder than I originally thought it would be. The only difference between this enemy and the others I have worked on is that this one has multiple attacks. That one difference has taken up two full days of work and it has yet to be fully figured out.      From the last time I worked on it I changed a few things. The first being the random attack generator. I had this in a service before but now it is a task. I realized that a service is not what I would want because it ticks and that would change the attack type rapidly, confusing the hell out of the AI. But with that figured out, I went back to figuring out how to have the attacks cycle. This was the part I was stuck on for the majority of my time today.      The problem was, once an attack was chosen it would do that attack (as expected) but then it wouldn't return to the state where it would choose a new attack. I experimente

Corona-cation (Day 8)

Git Commit: None     Today was cut short by other responsibilities but I was still able to start on a new enemy. This was the Plague Doctor for the medieval area. I wanted to do this enemy because it would be the first (and most likely easiest) enemy that would have multiple attacks. According to the current design doc these were an AOE and cone attack that would poison a player for some amount of time and a slash that would do immediate damage.      The base of the enemy was pretty simple with most of the same code being used from the basic melee enemy until the part where I had to implement the multiple attacks. The idea was that when the enemy goes to attack it would execute a service that would set a random attack from an enum. This randomness was supposed to be weighted according to the design doc with some attacks being more common than others. I decided that this feature can wait until I know it is possible for the rest of the system to work correctly.      I got the ra

Corona-cation (Day 7)

Image
Git Commit: b6e0596 "Changed first person UI, Fixed enemy pathfinding" Changed first person UI:     The simple change of today had to do with the first person UI, namely the health bar. Our UI artist finished the first edition of the health bar and wanted to see how it looked in-game as to adjust anything necessary before he went on to make more. The first thing we noticed was that the .png file that was exported had really bug padding around the edges that made the scale wonky which really screwed with positioning and getting clean values. Right now, it looks like this: Fixed enemy pathfinding:     When I loaded up the project today I was prepared to work on the archer enemy. Before starting that though I wanted to make sure everything else worked up to that point. I added a standard melee character to the level to make sure they play nice. They did, but I noticed that the melee character would jump up to the statue's pedestal, and, given enough time,

Corona-cation (Day 6)

Git Commit: cd7dff7 "Fixed enemy health bar,  Added statue enemy" Fixed enemy health bar:     Just fixed this small issue I noticed when I was testing the new statue enemy. The issue being that the health bars above enemies heads would appear and disappear at the wrong time. I intended for the health bar to appear when the player is looking more or less directly at the enemy. What actually happened was the health bar would appear from the far left of the screen to the correct spot on the right. the problem was that I was just using the wrong conversion node from screen to world. I found the correct node from this thread.  Added statue enemy:     From the design doc I was told to make an enemy that: "These do not move on patrols they stay in one location and wait till attack come within range". Additionally during a meeting I was told that they would be stationary on a pedestal until they jump on and off to attack the player. This made me learn about AI