Search Unity

Games Mittens' Adventure - Top down shooter + multiplayer

Discussion in 'Works In Progress - Archive' started by newjerseyrunner, May 18, 2018.

  1. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Vehicles are an important part of some of the levels, and this particular level has a special kind of indoor "vehicle." I wonder what kind of vehicles is in this room? (Think like Yoshi ;)). It almost looks like a dog house.
    Screen Shot 2019-10-14 at 3.23.18 PM.png
     
  2. tcz8

    tcz8

    Joined:
    Aug 20, 2015
    Posts:
    504
    LMAO!
     
  3. tcz8

    tcz8

    Joined:
    Aug 20, 2015
    Posts:
    504
    Make sure your stream encoder is using hardware encoding. Also, if you're using a gaming GPU and your processor is from Intel, your CPU most likely has a built in video card that isn't being used. You will have to google it but there are ways to enable that 2nd video card in the background and switch over video encoding to it which will free up resources on both your CPU and Gaming GPU while streaming. I've read about people using that built in video card to accelerate all sorts of things.


    Regarding that picture above, what are we looking at? :confused: It's quite dark on my screen.
     
  4. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,780
    The game doesn't look like need quantum computer.
    Unless you run on potato? (no pun intended).

    Sorry, I did not grasp the message from the screenshot. What it suppose to represent?
     
  5. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    It's definitely OBS's fault, not the game. The game itself is a rock solid 30FPS, even with 4 player splitscreen and tons of explosions. OBS ruins the framerate of anything I try to run on my computer, it even screws with emulating simple NES games. I'll look at the settings and see what I can do. I use a Macbook Air, so I definitely don't have any GPU to spare.

    My last screenshot looks terrible, not sure why I used it. Anyway, it's a dog house, and you'll be able to ride a powerful dog like you do Yoshi in Mario. It'll bite and claw at anything that gets near you automatically and can breathe fireballs on command.
     
  6. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I've noticed that even though I've embedded a lot of math in the code to prevent framerate from altering the experience, it was still causing problems at very low framerates. The player could suddenly jump much higher, so I broke down and finally did the real calculus as opposed to approximate fixes.

    I build this to handle this problem: https://forum.unity.com/threads/framerate-independent-accelerators.765248/

    I'm working on integrating it into Mittens. This may allow me to remove the framerate cap, but I may still leave that because it gives it a 90s feel.
     
  7. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Man, texturing and lighting levels takes forever. Still doing that, spacing it out by working on multiple levels simultaneously.
     
  8. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Build the behavior of the final boss. He has a variety of turrets at his disposal as well as drones that fly in and drop bombs. Will probably add a few more environmental hazards as well.
     
  9. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I love my decals, but I want to have my entire arena covered in blood by the end of a long fight. Since the decals are in pools, once you start fighting somewhere else, some decals get removed from previous areas. Now, I'm drawing decals directly onto a secondary texture that will allow these things to become a permanent part of the scene.



    This is going to allow me to send dirt all over the place and have it stick to walls, blood will platter on walls, then even streak down them.
     
    Last edited: Oct 30, 2019
  10. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I also realize that I can use my new tool to create secondary maps like
    This which I can use to paint secondary textures. I can use that to dirty up the bottom of walls and get rid of repetition and also hide seams. I’m going to go nuts with the blood I know it.
     
  11. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    So I had a blood and decal system all set up, but then I realized that I could create a large texture, map it with the light map and give all my static objects a secondary texture which contains all of the decals, eliminating the ceiling for the number on screen completely. I considered my game pretty bloody before, but check this out.

    Screen Shot 2019-11-13 at 1.26.59 PM.png
     
  12. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Still texturing. So glad this is the last step, levels are getting done about once a week.
     
  13. oriongu

    oriongu

    Joined:
    Jun 18, 2015
    Posts:
    7
    Looks very bloody! That must have been a hell of a fight! :)
     
  14. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Oh, it was. All levels should end up covered in blood if you're playing the way I expect players too.
     
  15. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I wish I had known more about texturing technique when I was building my levels. Almost every level's geometry is remaining unchanged, but the underlying triangles are constantly having to be redone so that textures line up properly without warping. Such a pain, my next game I will do basic texturing as I build my levels.
     
  16. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Created checklist
    I kept second guessing myself about which levels I'd done what to since to actually call a level "finished" a long checklist of like 30 items has to be completed. I created a nice spreadsheet and started filling it in, which will allow me to gauge my progress better. I'm moving again and had some crazy days at work in the past few months, but I fully intend on getting back into the groove once we're fully moved in.

    Controls fine tuning
    The time away did give me some time to lose my muscle memory, so I'm going to play my demo this weekend and see what controls I can improve on.

    Bullet magnetism
    I actually am in the middle of a quality of life improvement. My game has a very helpful crosshair magnetism mechanism, that helps you aim. My game's challenge is not meant to be shooting itself, but strafe running and crowd control. "Close Enough" should hit. I noticed though with the small faster moving enemies, the automatic weapon wasn't very useful at long range. This is a problem because I designed it to be the primary weapon against hordes of the fast, small, but super weak enemies. The crosshairs would be on them, but the bullets would slightly miss. Now though, bullets are allowed to curve slightly towards a target. It makes a HUGE difference and feels right. Different weapons have different magnetism levels, and the more you power up the weapon, the more the bullets will be allowed to curve. You'll still have to lead shots with your pistol, but the AR is spray and kill now.

    Editor issues
    Something is causing my editor to laaaaaaag. When the game is built, it very easily hits it's 30FPS cap. There is almost no slowdown even in intense battles. In the editor though, recently it's been getting as low as 1 FPS. Tonight I'm finally going to tackle that and figure out what the F*** is going on. The profile just says "Editor" without being able to dig deeper, but I know some tricks to find chokepoints.
     
    Last edited: Feb 7, 2020
  17. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Bullet Magnetism
    This is finished, and it's a huge improvement. The precision weapons still feet the same but the spray guns feet a lot more deadly. It also introduced some more advanced types of gunplay. With a flick of the mouse, it's actually now possible to curve bullets around corners.

    Huge speedups
    I have a lot of things happening all at once. Every character has IK and reactive animation code running, as well as Nav and AI behavior all over the place. I realized the reason the editor was so slow is because it was constantly refreshing tons of transforms. To fix this, I wrote code that calculates whether or not a character is on screen, and also how far on or off screen they are. If they are far off screen, they now no longer do any of these animations, and their AI gets scaled way back, leaving more horsepower for what the camera is looking at. I've also been able to do useful things like preventing particle systems from spawning if they are way off screen.
     
  18. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Bullet Decals
    I've changed the bullet hits to look more like paintball splatter than actual bullet holes. It makes the levels more colorful. After a deathmatch battle, the entire arena will be covered in bullet holes.
    Screen Shot 2020-02-12 at 9.30.38 PM.png

    Level Progress
    I completed texturing and separating meshes. I also created a nice spreadsheet full of a 30 point checklist for each level, and have been filling it in as I do things.
     
  19. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    More level Progress
    I started texturing one of the levels I'm most excited about. It's based on Rat Race from Halo CE, and I expect some really good multiplayer games on this map.
    pic.png
     
    Antypodish likes this.
  20. Deleted User

    Deleted User

    Guest

    @newjerseyrunner You had me at "Rat Race" lmao but I've rarely checked this thread, and it seems pretty slick!
     
  21. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Glad you see something you like. A couple of my levels are actually based on old Halo levels. As well as Doom and Quake.

    I’ve added a step where all levels will now have a 2048px texture. For levels that are finished that didn’t use its entire atlas, I’m making myself use the rest of the space for more texture variety.
     
  22. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    When I created my first couple of levels, I kept the texture count to a minimum because I wasn't sure how much the hardware could handle. Now that I have multiple levels using 2048 textures, I've gone back over my first couple levels and expanded their texture sets. I've learned a lot since I created them, so I spent some time retexturing parts of them to make them more interesting.

    Today was President's day so I managed to get quite a bit done.
     
  23. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    @TenKHoursDev. If you're a fan of Halo, check this level out. It's meant for capture the flag style gameplay and flow is heavily influenced by the Halo 2 map Relic.
    Screen Shot 2020-02-17 at 5.44.53 PM.png
     
  24. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Last night I was lighting a level and ran into an interesting problem. The level is mostly lit by lava. I was using an emission light in realtime, but for the baked light I wasn't sure of what to do. My custom tools don't work with emission lights so I had to figure something else out. So last night I wrote a script that will take a mesh and attach dim point lights all over it, which creates a pseudo area light for a mesh. I can then bake from that, which makes everything look really creepy. This test scene below has no environmental or sun lighting, it's lit entirely by the lava.

    pic.png
     
  25. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Wife has been ill, so I haven't had any time to work on my game recently. Been trying to figure out the best way to UV map certain large levels so that the decal layer works properly.
     
    Antypodish likes this.
  26. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Got laid off so you’d expect Id be working on the game a lot, but wife is home too and we’re both suffering from covid-19, so I haven’t been. Tomorrow though, I plan on tweaking the standard shader to make my decal system work a little better. I’m also gonna make colors pop more and get rid of the standard shader “unity look” of my static objects. I also want to add normal maps to me decals.
     
    Antypodish likes this.
  27. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,780
    When you said suffering, do you mean also you got ill? Or general consequences of the whole world situation?

    Whatever is, or isn't, I keep thumbs up for you, to settle matters. Maybe is good time, to go game delving, and make living on it?
     
  28. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    We’re both sick, but seems like we’re on the other side of it now. We live right in the epicenter and we’re one of the first few dozen positive tests.
     
    Last edited: Mar 25, 2020
    Antypodish likes this.
  29. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I really dislike how unity’s lightmappers bounce lights around. I suppose it’s realistic, but I want a more cartoony look to my game so I want colored lights to bounce around more. I wrote a new component that bakes this into a texture for me. It’s currently too slow to put into production but I also wrote a nice BSP to optimize it and plan on plugging it in tomorrow. It’s making the level look better but also the weapons.
     
  30. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,780
    I hope you got no more than mild side effects on that.
    As long you can recover quick that is positive thing.
    Keep up on life and your fav project ;)
     
  31. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Wife stayed in bed all day, so I actually worked on my new system quite a bit. I had it working perfectly last night, but when I needed to scale it up, I ran into the problem that greatly increasing resolution increased render time by a factor of a cube. I first set up a BSP tree to make scanning for pixels faster, but with the higher resolution, the iteration had to get much much smaller. This was not sustainable linearly, so I incorporated a recursive search for every hit, down like 4 levels to hone in on the right stuff, which cuts down by hours and hours.

    First, it builds the BSP tree
    Screen Shot 2020-03-27 at 8.17.08 PM.png


    Then I adjust the iterator parameters so that every pixel gets covered. I built in a preview system, right now, the crisscross pattern tells me the searching isn't fine-tuned enough, but I can adjust the values as it works so that I can get it to exactly the right amount.
    Screen Shot 2020-03-27 at 8.17.42 PM.png

    That's full coverage.
    Screen Shot 2020-03-27 at 8.28.19 PM.png

    Now that all the pixels have been given real-world positions and normals, I snap a camera to each of those positions and perform a render with the full post processing stack and a fisheye fov. I can adjust the render resolution to whatever I want, but 128 seems to be the right amount. If I select the camera itself, I can even watch it pop around and see what it's currently rendering. In this particular frame, it looks like it's rendering from a pixel in a canyon.
    Screen Shot 2020-03-27 at 8.53.01 PM.png

    It works in real time, so I can examine the texture and even see it changing the texture as it moves. You can see a clear place where one wall is in the middle of being processed, one side is bluer than the other, because it's mostly reflecting the blue sky.
    Screen Shot 2020-03-27 at 8.59.25 PM.png

    I'm trying a large scale render of this scene overnight. It's not fast enough to go full 2048, but I think I'll go 512 and scale it up in GIMP to be able to draw on it and really give some variety to the level.
     
    Antypodish likes this.
  32. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Still trying to get this thing to work in a reasonable time frame. Without an extremely high level of detail in my recasting, pixels always get missed. So I added another pass that will look for holes in the texture and see if nearby pixels can help me hone in on where it should be. This step has actually allowed the number of initial passes to be much lower with a much higher coverage rate. It's now able to do a 2048 pixel texture in the time that I was doing a 256.
     
  33. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Process for baking decal texture
    • Make sure UV for lighting is right scale on grounds, adjust scalar in decal layer if needed
    • Bake lighting with low res
    • Create new UV in Blender and reimport
    • Run 128 until coverage is right
    • Verify that all second decal-able objects also map correctly
    • Make texture import have no mipmaps, and be read/write
    • Scale up to 512 and use as a decorative texture for second render
    • Render at 512
    • Put in GIMP file to scale up and add decals by layers and paint transitions manually
    • Put exported 2048 in the decal layer slot of decal object
    • Rebake lighting with high res
    • Create new UV in Blender and reimport
    • Verify that UVs still light up
     
    Last edited: Apr 2, 2020
  34. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    So I finally got all of the decals layer stuff linked up and it looks gorgeous. Even more brutal, is that you can track blood around on your feet and leave long tracks. Check out this scene before and after playing the level.

    Screen Shot 2020-03-28 at 11.00.32 PM.png
    Screen Shot 2020-03-28 at 11.00.14 PM.png

    Since it's all drawn on a texture, as opposed to physical decals, the amount of blood have 0 impact on performance. You can even see a few sets of tracks where me (or an enemy) walked through a dead body's pool of blood and started tracking it around. They can also track mud around from the level itself.
     
  35. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I was having trouble around the edges of triangles, so I wrote a post-processing step that bleeds the edges of the images. I iterate every pixel and if it hasn't been rendered, but the one or more of the ones around it was, it'll blend the nearby ones into it.

    I also added a bunch of presets because every time I wanted to test something new, I had to undo settings that I wanted to keep. Now I can just select the type of render from a pulldown and it sets all the values for me.

    I’m iterating over some of the lower resolution presets and timing them to see how each parameter affects time so that the bigger ones are easier to predict and the number of hours comes down.
     
    Last edited: Mar 29, 2020
  36. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Found a horrible bottleneck. The step that fills in holes from extrapolating existing data continues to repeat until no new pixels can be found. It seems along edges, the algorithm can repeatedly just add a single pixel but is then forced to repeat the whole sequence. I’m going to add a system that eliminates the need for that and only flags certain parts of the image that need to be rechecked. Should cut down on work by a factor of several thousand. This is one of those things that just requires many many layers of optimization to make work completely and efficiently, three bsp trees for different reasons, multiple passes just to find everything and post processing was not what I first pictured when I thought it’s be a one day build but it looks so nice that I have to see it through. I’ll probably clean the code up too and post it in the assets forum so that anyone else can use it too.
     
  37. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    So I've been working hard trying to get this whole UV map thing to work. I figured out that if I bake the light map first, then reserve blender with more UVs, it'll allow me to keep the lightmap and have the secondary UV map. It allows for the dynamic decals like blood and bullet holes, but also lets me paint on the level to make the repeating textures in the atlas less noticeable.

    Here is a before and after of the first combat arena
    test.png test2.png
     
  38. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I have a spreadsheet that contains columns for each level and rows for each major task. While I'm home sick, I'm iterating through each level to at least get it functional and textured. Not all of the levels have enemies put in them yet, but I can at least make sure all of the doors and switches working as well as the end of level triggers. Being able to run through a large section of the campaign will allow me to work on pacing as well.
     
    Antypodish likes this.
  39. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I reworked my spreadsheet and rearranged the hierarchy in the first couple of levels so that they’re all identical and match the spreadsheet. This is making it far easier to just iterate through levels filling in pieces. I expect by the end of next week I will have all levels fully functional and even be able to do a complete run through of the game front to back. Still about half of the levels need texturing, lighting, and decoration, but having everything working will make a large chunk of my shreds sheet green as well as allow me to debug AI and catch random exceptions and harden the code since everything will be running through a much wider range of circumstance. Each night I’m also baking either a light map or a decal map while I sleep.
     
  40. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Did a bunch today and yesterday.

    Shaders
    Created a new shader for the levels so that I can use more than the two UVs.

    DecalLayer baking
    Rewrote part of the baking mechanism, found a way to make it way more efficient, but it's not finished yet. I'm now using the actual mesh vertices rather than trying to raycast everything.


    I also iterated through a ton of building levels. I made all of the hierarchies exactly the same, and have most of the front half finished. Each level now has this type of hierarchy.

    • Model Stuff
      • Name all objects - Make sure blender objects are all named correctly
      • Secret Areas - Make sure the level has a number of secret areas
      • Monster closets - Make sure there are doors that can open to repopulate areas you will enter more than once
      • Optimize mesh - Remove doubles, minimize triangles
      • Split mesh for lightmap low res - The tops of the level doesn't need as high resolution lightmap as the actual level, so make it it's own mesh which can be given a separate scalar value
      • Split mesh for living parts - Parts of the level that are living will be using a special shader, so they have to be a different mesh
      • Navmesh - Make sure the navmesh bakes correctly and that there aren't any holes
      • Use all atlas space - I'm putting a 2048 texture in the GPU, make sure I use all the pixels
      • Textured - UV0 is fully configured in blender.
      • Normal map - Either draw or generate the normal map
      • Low-res light map - Keep the configuration values low until ready to release
      • Decal Bake - Bake the full 2048 decal, make sure lighting is calculated first, figure out which UV to use
      • Decal Decoration - Once baked, draw manually on the baked image to make the scene more unique
      • Collider / Static / Wall Layer - Make sure everything that needs a collider, nav obstacle gets it and that the objects are static and on the right layer. Make sure doors get the right scripts attached to them.
    • Functional - All of the stuff that is needed to make the level load correctly and insert itself into the session manager
      • Thumbnail camera - Used for debugging without a session as well as taking a picture for the multiplayer thumbnail.
      • Snippet Microphone - A specialized microphone that mixes the 3D audio from 1-4 player characters, which is impossible with a normal mic.
      • Level Sound - a 3 channel looper with fadeins and delays set up for the level
      • No Wall Jump areas - In order to prevent players from wall jumping completely out of the level, I have volumes at the top of tight areas that prevent the wall jump ability. There are usually about a dozen of these little volumes in the level
      • Canvas - The UI that displays ammo, timer, and other info
      • Dust Zones - The little smoke puffs that pop up every time the character's foot touches down can be colored for things like mud, water, purple goo. Some of theme can even be tracked around on the feet. There are usually a dozen of these in a level.
      • Reverb Zones - Hallways, arenas, stone, walls, all reflect sound differently, so these two dozen or so spheres alter the audio processing
    • Campaign - Everything that's specific to the campaign mode, not multiplayer, since each level is dual purpose
      • Mittens spawns for all checkpoints - Like DOOM, I have you hunting keycards and switches, but for quality of life, if you die after one of these events, you'll now respawn close to it, so each level has up to 3 checkpoints and 4 spawners. Most of the time coop players spawn together, but on some maze levels, I separate them.
      • Hints / Initial Phrase / Door Messages - In early levels, I provide hints if the player stays stuck in an area too long. There is always a message with a basic assignment ala "Get to the teleporter" that pops up when you spawn, and if you come across a door that's lock, it'll tell you which switch opens it.
      • Switches - The switch objects all together so I can easily go to them, they also can pan the camera to what they open.
      • Weapons - All weapon upgrades and ammo
      • Powerups - Armor, invisibility, wrath, time manipulation
      • Vehicles - Some big levels are meant for vehicles, this spawns them all. Also make sure that enemies are linked to the vehicles they are supposed to pilot
      • Enemies - They get placed into spawning groups. Sometimes there are too many enemies to efficiently run all at once, so trigger volumes can enable them. I also put them into a hierarchy, so lower ranks have a superior, animals have a master, groups have a leader... The group AI in my game is very important to how it feels. I then also separate them into difficulty groups, so different enemies spawn at different difficulty levels.
      • Music Triggers - Triggers that alter one or more of the channels in the Level Sound object, allows me to increase the tempo or change from outdoor ambience to indoor.
      • NavLinks - The bake is decent, but my enemies like to jump around, so I create a hundred or so extra links that allow enemies to move around the map in far more intelligent ways.
      • 3D Nav - Flying enemies have a custom navigation system, which is baked. This holds the info for the paths.
      • LoadAndTrapTriggers - These are the volumes that actually cause groups of enemies to spawn when you enter them. There are also triggers for traps here that open and close doors to expose more enemies or trap you.
    • Lights
      • Functional - The minimum required to see, sometimes a sun and shadow
      • Team Lights - Red and blue lights in each base to show which is which
      • Guide Lights - Have lights help guide the player where to go, directional spotlights mostly
      • Decorative Lights - Lights all over the scifi stuff and room lighting
      • Light Volume Probes - I have a custom object that calculations where probes need to go, this is where those bakers live.
    • OtherObject - Random things that are part of the level and not mulitplayer or campaign specific
      • Barrels - Explosive barrels that chain react are fun, I put them all over to make it easy to gib big groups of enemies
      • Trees - Some levels are inside a forest
      • Misc - Random decorations
     
    Last edited: Apr 6, 2020
    Antypodish likes this.
  41. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Still making big strides, multiple levels coming online every day. Filling in all the enemies, trying up all of the triggers, placing weapons and powerups. I'll be able to play all the way through very soon.
     
  42. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I've been having a lot of fun grouping all of my enemies in all of the levels. How to trigger them so that you never see the spawn and keeps the countdown is like a little puzzle. I also am fleshing out the different species nicely. The rats have a militaristic structure with varying ranks and a chain of commands, while their attack dogs have a pack mentality, and the later enemy has a hive mind. These aren't special features in the code, these are how I chose to group and link them together in the editor, so I can really make each species feel unique.

    I got three levels left in the front half to make functional, then I plan on playing the whole thing straight through and fixing any exceptions I come across and profile anything that starts to dip the framerate. I’ll probably complete these levels tomorrow. Once everything is working, I will also then finish the final half.
     
    Last edited: Apr 8, 2020
  43. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    So psyched, I completed the Cats vs Rats section of my game in terms of functionality. My checklist is getting more and more green. I plan on playing through the first part tomorrow and profiling before continuing to fill it in. Taking a little break has actually worked for me since now I don't remember where everything is, so I'll have to find it same as a player.

    Screen Shot 2020-04-08 at 6.43.27 PM.png
     
  44. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I differentiated the various rat types a little more in terms of their behavior. I had them all circle strafing more or less the same way, but I introduced code that allows me to adjust the “circle strafe ring” distance. Shotgunners now get up close, while rocket and pistol wielding rats hold a mid range and machine gunners harass you from a greater distance.

    Someone was excited for the Halo CE based map, so here is a video of me playing through it for the first time after making it functional. It looks a little wonky because I haven't baked any light maps for it yet nor are their any light probes, but the functionality is all there.



    If you're wondering what those green boxes are above me, they show me the frame rate. Red is bad, green is good.
     
  45. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Sometimes Unity seems just dumb. I've been struggling with triangle math with Unity. I need to convert between multiple UVs back and forth and am using the triangles to calculate relative positions, but it ALWAYS came out wrong. This is basic math to me and I kept checking and rechecking the code, stepping through it and everything and it always seemed right but the final few steps always started giving the wrong data. I finally figured out the reason. In mathematics, triangles are universally described in a counter clockwise direction. Unity has the vertices labeled clockwise. Once I flipped the first and last points, everything started working perfectly. Damn I was tearing my hair out over this one. Now I can finally account for normal maps when baking reflections.
     
  46. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Another level, this one is meant to be a Rat Base, so the difficulty is already high. I went in with low health on the hardest mode, so I got destroyed. It shows off the shiny new decal system though with proper lighting. All that blood and grime and bullet holes would not have been possible with regular decals.

     
  47. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    My decal Baker is now about 100x faster and can support full 2048 baking, as opposed to what I had been doing which was baking at 512 and up scaling.

    The hiatus from the play made me aware of some annoyances that I promptly fixed. Attack dogs are slowed down to prevent them from mobbing the player. I increased the players movement slightly and acceleration fairly heavily since it’s required to quickly dodge back and forth between projectiles.
     
  48. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I’ve also decided to make all the dialog be displayed as text. Easier localization, and easier to edit. Besides, I wasn’t really sure how to get voice actors.
     
  49. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    I lit the rat race level today and will bake the decal later overnight. I have plans to extend the functionality of my decal Baker and invoice the ability to paint directly in Unity. I plan on maybe releasing the tech once I’m done with it and got the kinks worked out.
     
  50. newjerseyrunner

    newjerseyrunner

    Joined:
    Jul 20, 2017
    Posts:
    966
    Spent today fixing up some of the levels. I finished baking the light for the rat race level, which allowed me to bake the decal. I then added a script to the camera that allows me to fly around and paint the walls in real time.

    It’s fascinating how something as simple as some dirt on the walls and especially in the corners makes it so much more organic. I can also draw cracks in walls, signs for direction, bullet holes, shades of grass, paint, add blood, and I’m putting a note to my wife in every level.