This week I’ve been migrating over the sprint functionality into the new Item architecture and fixing up a few issues that have been long standing with the way we handle sprinting. Our old implementation was held together with sticky tape, which you can see if you fire a rifle while running and the muzzle flash goes off pointing into the sky despite the bullet going forwards, also by sprinting just after swinging a pickaxe where the sprint would play over the swing animation.
We had to explicitly tell the movement simulator a timeout for the player not being able to sprint after doing certain tasks. We set this timeout wrong in a bunch of places because we had to predict the amount of time each action would take, not to mention remembering to do it at all whenever an item pulled you out of sprint. There was also an issue where we had no way of delaying an action on the equipment until sprint had finished, we would just do the action instantly and try to snap the animation.
Now each state in the state machine can flag if sprinting is allowed in that state. This information is fed to the movement simulator as an intention rather than an actual sprint value. Due to the fact that sprinting doesn’t start and end instantly, just because a state disallows sprint, doesn’t mean we aren’t still blending out of sprint. The movement simulator feeds the actual sprint amount back into the state machine blackboard so the equipment can make decisions based on the real sprint value.
In the clips below, you can see the CheckSprint states holding up the fire transition until the sprint transition has ended. (Projectiles are disabled as I am still working on that system)
I also had a play around with the arrow draw mechanics of the bow, previously the fire/draw was a single animation. Adding new states in the simulation that was written in code was a massive pain in the ass and hard to get right. Now its trivial.
Other sprint upgrades
Strafing while sprinting will no longer pull you out of sprint, it will now change your sprint direction left / right slightly. And as per the 10 requests per day, you will no longer need to hold down shift after initiating a sprint. I am not going to put in an autorun at this stage, if you need to leg it over very large distances and afk we are doing something wrong in the design of the gameplay. I would rather fix the reason you need to do this, or put something in the way to kill you if you were to do that.
I’m the honorary member of the Crusty Demons this week. I’ve had a lot of fun as I always do modeling vehicles. This low poly dirt bike base is looking sweet. We made the fuel tank look like it’s been built out of sheet metal to give it a bit of a scavenged look. I still have some dents, damage bits and maybe some geo to add to the tyres, but the base of the bike is mostly there.
I’ll do up some concepts on Monday for 3 sets of fairing designs. After the concepts are locked in I’ll do the high poly modeling, UV mapping, normal baking and texturing for the base core of the bike. After that I’ll build the 3 body kits (fairings) I may build some wheel variations after that but could be doing some work on combining the cities with the map.
Note: The spokes will actually be partly transparent normal mapped texture, to save on polycount.
I’ve been working on the raid drill this week! It’s been coming along pretty well. Functionally, it’s pretty done. You attach it to wall, insert fuel, press on, wall die. I’ve been trying to make it look super cool as well with a lot of small touches, that I hope will make the machine come alive a bit. For instance, some parts vibrate, and the drill bit will glow as the drill gets hotter.
However, we don’t want operating the drill to be trivial, something you set and forget. You’ll be able to control the drill’s RPM, where a higher RPM means more damage, but also more heat and quicker fuel consumption. If the drill does overheat, it will explode, taking out anyone nearby. It won’t take a rocket scientist to control, but nor will you be able to leave it alone. The drill might also jam sometimes, and require interaction to be unjammed. These are things that I’m currently playing around with, and trying to get something that feels interesting and dynamic, and where there’s no “stable” setting for the drill. You can hear it quite a way off, which will hopefully make it a risk as you have to announce your location. I imagine that the drill may take some balancing once it’s out in the wild, and the optimal raiding strategies change around it.
I also finally got round to fixing some cross-platform issues with the SDK, where it turns out the Mac OS filesystem has some… issues.
Not a whole bunch from me this week. I finalized the textures/materials for the vests and moved onto more gear, specifically some pants.
It was whilst doing this I realized I would need to modify the player character model, extending the mesh of his torso down a bit further than it currently is. Since I was already going to have to change his UV’s I ended up moving them all around to better make use of texture space. I then baked and fixed his existing textures to fit the new UV’s.
We also decided that he should have a normal map in order to bring him into line art-wise with all his new gear. In order to do this I edited the player model, removing tris and tweaking some of the poly flow so that it would sub divide with a minimum amount of artifacting. I then took this mesh into mudbox and did a pass adding some detail and cleaning up some areas. Another plus is that it helps to smooth out a bunch of the lighting errors we would get in places like his ear and underarm etc.
This week I’ve been continuing on with vehicle changes. I started with hooking up damage and the broken leg debuff into the crash system. When you’re crashing, large collisions will be able to hurt or even kill you and you can also be left with broken legs like when taking fall damage. Here’s a quick gif of me sliding down a hill on my bike and caving my head in on a cliff.
I’ve also done a bit of work polishing how the camera works with vehicles. Now when entering a vehicle in first person your view will automatically shift to the front of the vehicle. When exiting in both first and third person you’ll stay aiming in the same direction. I’ve also added a setting for vehicles to force them to be in third person camera. Although I added this setting to force third person during crashing it should also be a help to any vehicle modders who are using car models without the interior.
Lastly I’ve been adding destruction to the vehicle system. Vehicles now have health and they will explode into a burnt out shell when it runs out. The size and force of this explosion will be increased depending on how much fuel is in its storage. The burnt out vehicle corpses that get left behind can also be harvested for resources with the right tools. Obviously this is a significant change that we will have to rebalance things around but we want to make vehicles easier to obtain now that they will be less permanent.