When playing Battlefield 2042, I found a large screen simulating the display of RGB pixels: the content in the far view is a complete image, and the close view is a glowing RGB pixel. This effect is very interesting. It can be reproduced in Unity. The effect of the implementation is the screenshot moving picture (GIF). The content of this article is implemented with Unity, but some of the content is referred to the Unreal E of Youtube/Jam2go ……

A long time ago, I used Stencil Test in a 3D sliding list. This review, I try to use it to make a double-sided through the door. The effect principle is to write a value into Stencil Buffer. In the subsequent rendering of other tiles at the same location, if template testing is enabled, the preset value will be compared with the value in Stencil Buffer (i.e. Test), based on the comparison result ……

You want to display the Android interface in Unity, but do not want to export the Unity project for editing in Android Studio, so explore the method of exporting activity to AAR package, compiling and packaging with Unity. Description This article describes how to package multiple Acts including Android Activity through Unity Editor ……

UnityPlayer is often used when interfacing with Android interface UnitySendMessage sends some messages to Unity. If the App enters the background, the Unity method will not be called even if the Android code executes normally. Problem description When an application enters the background for a period of time, even though the Android Java code executes normally, it calls UnityPlayer UnitySe ……

In Unity 2018.4 and below, when the UI is hidden and displayed again in hover status, the highlighted status does not reset, most of which are Button. The problem description UGUI button A hides itself when clicked (SetActive (false)). Later, it was turned on by other means, and it was found that A still remained highlighted and did not reset. This situation ……

When the Android AAR/JAR plug-in is used in Unity, if the Android java method is called in the main thread, it can be called normally, but when a new thread is opened, it will flash back. Record the solution here. The problem recurrence has the following test code, which generates an Android object and calls its JAVA instance method TestFunc. 1. Synchronous call (normal) Calling Android in the Unity main thread ……

I happened to see a website with a 3D terrain display column, which described that it was made with Unity+grayscale image. It looked very interesting, so I studied something related by the way. I don't have a corresponding realistic map in the effect picture, so I used the shader of particles to make a color gradient for demonstration. Basics 1. Points, lines, faces and mesh points form lines, lines form faces, faces and their related vertices, and additional information form mesh. Rendering in modern 3d ……

The preface often encounters some irregular models that do not need accurate collision. At this time, only one BoxCollider is needed to wrap it and its sub objects. Adding the collision box manually is very troublesome. Not only is the center point inaccurate, but the size also needs to be adjusted manually. By using the Renderer component, you can obtain the rendering size and center point of the model, and automatically generate a suitable BoxCollider after simple calculation. Realize 1. Key parties ……

Before the preface, there is a requirement that one or more objects move along the specified path. I made a little modification according to the script written by the Spirit Re god, and finally completed this requirement. Principle The simple movement in this article does not involve complex things such as curves, so you can use an array to save the moved coordinate points, and then move in turn by calculating the displacement coordinates. Realize 1 PathDefine.cs Used for PathDefine script ……

This article is the second in the series "Analysis of HeliHell Source Code for Unity Helicopter Flight". Please refer to Unity Helicopter Flight HeliHell Source Code Analysis (1) - Camera Slow Motion Tracking for source code download and the previous article. The flight effect of hinge joints is mainly achieved through hinge joints. First, analyze the structure of hinge joints in this project: an empty object ChopperControllerHu can be found in the hierarchical view ……