Doraemon Speedster
Type: Multiplayer Racing
View: 3d
Fun points: multiplayer online, racing, and fun scene exploration
Time: 2015-2018
Personal Responsibilities:
- Participate in native DEMO R&D and production
- Participate in the discussion, development and optimization of the basic game framework
- Responsible for optimizing the game physics system
- Responsible for the in-game camera language function
- Maintenance throughout the game life cycle
- Responsible for the discussion and development of some functions of the game server
- Develop animation editing tools. Special effects rigging tools
- Optimize workflow, production management tools: animation state machine related, animation import, log management, etc.
- SDK access integration and document writing
Module division:
1. Newbie guide
Guidance is implemented in two parts, inside and outside the game. The game needs to handle the paused transition state of the game and different input methods. Outsiders only need to handle the button click process.
In-office guidance
Press and hold the guide. The picture above shows a left turn. You need to keep pressing the left joystick for a period of time. If you just tap it lightly, you need to display the prompt UI again when you lift your finger. At this time, the state switching process is difficult.
point.Press and hold multiple keys to guide
The picture above is a drift tutorial. You need to hold down the direction key and the drift key at the same time. If you just hold down one side, the process cannot be triggered correctly. This type is similar to the hold type above, but there is one more case. The difficulty lies in one more input. Dimensions need to handle duplicate codes between types.
External guidance
External guidance mainly controls player clicks, and is divided into forced guidance chapters and open guidance chapters.
The difference is that the forced guidance chapter is in the early stage of the game. After entering the game, the entire game process is under the control of the guidance and proceeds in sequence.
When a new functional page is opened later, a separate open guide will be triggered.
The difficulty of this system is to click on the production and use of the focus mask, click on the penetration detection button, and trigger the button.
2. In-game physics
- Body structure
Body collision body composition:
- Main body Capsule
This collision body is mainly responsible for collision physics, such as collision detection with walls, collision detection with the ground, and collision detection between cars.
Simulate collision physics. When the car body is hit, use a script to obtain the collision direction and collision point. Based on the current speed of the car, calculate the motion state of the car after the collision, and set it in a physical frame after the collision.
- Prop detection box This collider is a trigger and is only responsible for detecting function triggers.
For example:
- Hit with attack props
- Pick up the prop box
- Enter the acceleration zone
- Enter the flight start zone
- Engine power
Engine Power, the value responsible for forward speed
If engine power = 1, you can move forward, and the acceleration is determined by the attributes of the car itself.
Engine power = -1, then retreat, the retreat speed is a fixed value (the official version does not have this function)
If engine power = 0, it will stay in place, such as when being immobilized by an item.
- top speed
The maximum MPH (miles per hour) value that can be reached, determined by the car's attributes. When the engine power of the car is 1, if the current speed is higher than the maximum speed value, the speed will decrease. If the current speed is lower than the maximum speed, the speed will continue to accelerate.
When in sprint state, the current maximum MPH value will break through and become higher.
- sprint state
There are many categories of sprints, including acceleration zones, props, and drift nitrogen. Each sprint has its own independent
acceleration,
Increased maximum MPH value,
type enum
The sprint state is a kind of status buff
- Steering power
Steering power, responsible for the value of steering angular velocity
Engine power = 1 then turn left
Engine power = -1 then turn right
Engine power = 0 then execute
The maximum angular velocity and angular acceleration of the steering are determined by the properties of the car.
- Drift
The implementation of drift is composed of animation + physical simulation + tire tracks.
After pressing and holding the drift button and any direction key, the drift is triggered. At this time, pressing the left direction will drift to the left, and pressing the right direction key will drift to the right.
The drift animation will cause the car body to tilt, and the tire marks that appear at the same time will show the state of burning tires.
Physical simulation is the essence of this design. When it is in a drifting state, the car body will exert a lateral thrust in the opposite direction of drifting to simulate out-of-control drifting.
- Bamboo Dragonfly
Bamboo Dragonfly is a gameplay mode specially designed for Doraemon IP. After entering the special flying area, all racing cars will temporarily disappear and be replaced by Doraemon's prop, Bamboo Dragonfly. At this time, the player is in flight mode, which can still be controlled, but drift cannot be used and only the direction can be controlled.
The implementation of the bamboo dragonfly mode mainly uses path points, coupled with the lateral calculation of the movement range.
- anti-gravity
In the game, many maps can be designed against gravity, similar to going up a wall.
The realization of anti-gravity requires the use of an excessive gravity trigger. After passing this trigger, the direction of gravity received by the car will change. For example, after entering the wall gravity trigger, the direction of gravity will become perpendicular to the wall. direction. After entering the lower wall platform, there will be another gravity trigger to return the car's gravity to the normal negative Y-axis direction.
- All terrain
The anti-gravity design, coupled with the special design of the map scene, can turn it into an all-terrain similar to a space planet. In this special generation, cars can drive on both sides of the road, hang overhead, and so on.
- Ground adsorption
During the development process, it was discovered many times that the car would leave the ground, especially if there were collision joints on the ground, horizontal fluctuations, etc. When driving on curved surfaces, there is even jitter and the inability to climb hills.
In response to this situation, I used ground adsorption to solve it. The difficulty of ground adsorption is that under normal circumstances, the car needs to maintain ground adsorption, but on a high platform such as a jumping platform, or when taking off, it needs to be able to lift off the ground.
- Falling from a height
It is also difficult to deal with falling from a height to the ground. Due to the acceleration of gravity, the car falls too fast and can easily penetrate the ground collision body. During the experiment, thickening and multiple ground collisions were used. None of the physical methods has completely solved the penetration problem. Finally, the speed prediction method was used to completely solve the problem.
3. Lens language
Camera language is definitely the most important part of this game. In racing games, cars move very fast, so once the camera is not handled well, it can easily affect the player experience.
uphold
The shots that players cannot discover are the best shots.
this principle. This part of the functionality went through many rounds of iterations.
From the initial FixedUpdate following, to the delayed following point, to the camera placed child node following,
From fixed rotation angle, to interpolation delayed rotation angle following,
During this period, a very strange screen "stuttering" phenomenon was also discovered.
Finally, through a lot of experiments and using the most critical patching needle design, the problem was solved.
I don’t know if there is any ready-made camera plug-in to solve this part of the problem.
(Most game development in the later period did not have lens-heavy language)
4. Animation
The animation structure is divided into racing animation and character animation.
There will be binding points designed to bind the character on the racing model. The character can be installed by placing the character into the racing binding point and returning it to zero local coordinates.
The biggest difficulty in the development process of character animation and racing animation is that there are no less than 20 animation control files for racing cars and about 10 character animation control files, which is a big trouble in modification and maintenance.
For this point, I specially developed a batch generation and binding tool for animation control files. I used a basic template file to copy and generate new files, and then obtained the animations corresponding to different models and placed them in the new animation files.
The debugged animation control files can finally be conveniently applied to all cars and characters in batches.
Both character animation and racing animation use animation layering technology. For example, when using props, the character's arm layer will play the animation of throwing props, but at this time, the player on the base layer will play idle.
5.SDK
The version at that time was connected to some domestic SDKs for data testing.
Top comments (0)