- 博客(629)
- 资源 (46)
- 收藏
- 关注
原创 ComputeScreenPos的bug
这个不是真的bug,是在使用的时候需要注意下。在进行基于Grab或者blit的全屏RenderTexture的时候需要使用ComputeGrabScreenPos 代替,里面做了平台处理 UNITY_UV_STARTS_AT_TOP,否则会出现采样的贴图是反着的情况。inline float4 ComputeGrabScreenPos (float4 pos) { #if UNITY_UV_STARTS_AT_TOP float scale = -1.0; #else .
2021-08-22 12:01:34 293
转载 曲棍球游戏
https://gamedevelopment.tutsplus.com/tutorials/create-a-hockey-game-ai-using-steering-behaviors-game-mechanics--cms-23026
2020-01-06 12:45:14 430
转载 气球及粘性效果
https://stackoverflow.com/questions/33630415/which-are-the-control-points-to-create-approximate-a-circle-using-8-cubic-bezi
2019-11-26 10:54:39 269
原创 FileMerge与Gitbox没有关联
sudo /usr/bin/xcode-select -switch /Applications/Xcode.app/Contents/Developer
2019-10-15 20:25:10 173
原创 XLua 的async_to_sync使用步骤
1. C#端写一个方法,最后一个需要是Callback, 可以支持带参数 public static void ShowConfirmBox(string message, string title, Action<bool> onFinished = null)2. 用util.async_to_sync定义一个lua的变量与C#绑定local sync_confir...
2019-10-14 13:45:32 2000
原创 hierarchyWindowItemOnGUI编辑器
[InitializeOnLoad] public class AppEngineInitializeOnLoad { static AppEngineInitializeOnLoad() { EditorApplication.hierarchyWindowItemOnGUI += HierarchyItemCB; ...
2019-08-06 08:56:43 1025
原创 gdiplus.dll on Unity Mac
First check your mono.framework version: /Library/Frameworks/Mono.framework/Versions/5.4.1/lib/libgdiplus.dylib Then in your Unity config, you can find here: " /Applications/Unity/Uni...
2019-06-08 17:05:20 851
转载 我怎样才能知道我的场景Bundle中有什么东西?
https://support.unity3d.com/hc/zh-cn/articles/217123266-%E6%88%91%E6%80%8E%E6%A0%B7%E6%89%8D%E8%83%BD%E7%9F%A5%E9%81%93%E6%88%91%E7%9A%84%E5%9C%BA%E6%99%AFBundle%E4%B8%AD%E6%9C%89%E4%BB%80%E4%B9%88%E4...
2019-06-04 15:45:53 157
转载 Unity3D通过官方工具获取Bundle信息
1.CMD到U3D目录下面Editor/Data/Tools2.WebExtract 命令 包 比如: WebExtract D:\1.unity3d 然后会生成一个文件夹3.Binary2Text 生成的文件
2019-05-29 14:15:32 1122
转载 UVPreview扩展
http://www.lsngo.net/2017/10/22/unityeditor_uvpreview/?rifmxg=3bepp3
2019-05-27 16:04:42 408
转载 扩展内置组件的Inspector面板
using UnityEngine;using UnityEditor;using System.Reflection;using System.Collections; [CustomEditor(typeof(Transform))]public class TransformInspectorExt : Editor{ private Editor m_Trans...
2019-05-27 16:03:12 340
转载 SetReplacementShader
http://www.unitybeginner.com/index.php/archives/354.html
2019-05-23 14:58:54 614
原创 强制unity编译
找了好久,终于找到了一个方法 MonoScript cMonoScript = MonoImporter.GetAllRuntimeMonoScripts()[ 0 ]; MonoImporter.SetExecutionOrder( cMonoScript, MonoImporter.GetExecutionOrder( cMonoScript ) );详细原理自行Google...
2019-02-22 11:13:25 1518
转载 物理公式
一、质点的运动(1)——直线运动 1)匀变速直线运动1.平均速度V=s/t(定义式)2.有用推论Vt*Vt-Vo*Vo=2as3.中间时刻速度Vt/2=V平=(Vt+Vo)/24.末速度Vt=Vo+at5.中间位置速度Vs/2=[(Vo*Vo+Vt*Vt)/2]1/26.位移s=V平t=Vot+at*t/2=Vt/2t7.加速度a=(Vt-Vo)/t{以Vo为正...
2018-11-12 14:25:02 690
转载 守望先锋
http://gad.qq.com/article/detail/28682http://gad.qq.com/article/detail/29595http://gad.qq.com/article/detail/28219https://mp.weixin.qq.com/s?__biz=MjM5NTMxNTU0MQ==&mid=2649869814&idx=1&a...
2018-11-07 15:56:58 410
转载 playable animation
https://connect.unity.com/p/playable-api-ding-zhi-ni-de-dong-hua-xi-tong
2018-10-08 11:33:35 301
转载 The Future of Matchmaking with Unity and Google
https://www.youtube.com/watch?v=qasAmy_ko2o&feature=youtu.behttps://github.com/GoogleCloudPlatform/open-match
2018-09-17 14:43:29 232
转载 Unity-Android交互(.aar包的使用)
https://blog.csdn.net/xingqing_myz/article/details/78868198
2018-06-03 00:19:38 577
转载 shader向外扩
fixed4 frag(v2f_img i) : SV_Target { //计算uv到中间点的向量(向外扩,反过来就是向里缩) float2 dv = float2(0.5, 0.5) - i.uv; //归一化 float2 dv1 = normalize(dv); //计算每个像素uv的偏移值...
2018-02-25 19:05:01 1201 1
转载 扰动
在unity中实现一个水面扰动的效果,这里用到了UV移动,和uv扰动这里我组合了这两个shader实现了一个水面扰动的效果,使用了一个波纹纹理,然后用一张2维噪声扰动uv。产生的效果还是比较乐观的关键代码v2f vert (appdata v) { v2f o; o.vertex = UnityObjectTo...
2018-02-25 17:43:48 520
转载 扭曲的原理
转自:http://blog.csdn.net/lly707649841/article/details/78848071原理所谓扭曲就是扰动一个物体的uv坐标,表现出来就是一个扰动效果,如火焰扭曲空气,和水波对水底的影响。 1. 在shader 中我们需要一张当前渲染的纹理 2. 给一个物体渲染并使用当前纹理,用屏幕坐标作为uv坐标加上一个扰动值unity1. unity提供了抓取的pass: ...
2018-02-25 17:21:46 1203
转载 转:图形化调试
http://blog.sina.com.cn/s/blog_471132920101gxzf.html 图形化调试 【前言】图形化调试可以加速开发。例如在战斗中,可能需要知道所有单位的仇恨值,如果这些信息全打log的话,很难有直观感受,而如果在Scene窗口里,单位头顶有一个球,越红表示仇恨越高,越暗表示仇恨越
2018-02-04 11:53:17 332
转载 Unity2017.3新功能:程序集定义(Assembly Definition File)功能详解
http://www.ceeger.com/forum/read.php?tid=594387&fid=2http://www.ceeger.com/forum/read.php?tid=594387&fid=2
2018-01-11 15:29:46 2674
原创 设计模式-适配器
适配器设计模式应用在哪里:a. 想使用一个已经存在的类,而它的接口不符合你的需求,想修改一个已经投产中的接口时,b. 想创建一个复用的类,该类可以与其他不相关的类或不可预见的类协同工作c. 为了以后能扩展,让别人去继承实现接口,以达到适配的目的d. 需要一个统一的输出接口,而输入端的类型不可预知案例1: 图形绘制软件,Shape类,子类,LineShape, P
2018-01-07 11:38:28 215
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人