随笔分类 -  Unity

Unity
摘要:推荐: https://www.cnblogs.com/nanwei/p/7277417.html 上面链接作者的整个系列都写的不错 https://www.cnblogs.com/nanwei/category/1025420.html 【Unity Shader】 数据类型和关键字 一、基本数据 阅读全文
posted @ 2019-10-08 10:45 三页菌 阅读(547) 评论(0) 推荐(0)
摘要:整理了下以前写的 阅读全文
posted @ 2019-10-05 12:44 三页菌 阅读(214) 评论(0) 推荐(0)
摘要:效果: c# shader 使用image effect模板 噪点图 注意:需要将噪点图的warp mode设置为repeat ,否则就是一闪而过的波动 阅读全文
posted @ 2019-09-27 23:46 三页菌 阅读(2738) 评论(1) 推荐(1)
摘要:需要在粒子上挂脚本 脚本添加代码 这是个生命周期 粒子的 StopAction 设置成Callback 最好再加上 阅读全文
posted @ 2019-09-09 16:02 三页菌 阅读(4638) 评论(0) 推荐(0)
摘要:碰撞发生在帧的开始,所以你可以检测到冲突,并在LateUpdate复位: 阅读全文
posted @ 2019-08-31 14:48 三页菌 阅读(1239) 评论(0) 推荐(0)
摘要:using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.EventSystems; public class ClickTest : MonoBehaviour { // Use this for initialization void S... 阅读全文
posted @ 2019-08-19 13:19 三页菌 阅读(323) 评论(0) 推荐(0)
摘要:https://www.cnblogs.com/mrma/p/3998679.html 试了,确实可行,在unity也能用 值得注意的是UnityScript.Scripting.Evaluator 也有这个类,应该可以实现类似的功能,具体用法未研究 阅读全文
posted @ 2019-08-18 16:46 三页菌 阅读(254) 评论(0) 推荐(0)
摘要:unity 项目合集:https://michidk.github.io/Unity-Script-Collection/ ugui特效:https://github.com/mob-sakai/UIEffect?tdsourcetag=s_pctim_aiomsg ecs破碎特效:https:// 阅读全文
posted @ 2019-08-08 16:16 三页菌 阅读(336) 评论(0) 推荐(0)
摘要:以X轴指向的方向 阅读全文
posted @ 2019-08-06 13:30 三页菌 阅读(911) 评论(0) 推荐(0)
摘要:using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.UI; public class Jietu : MonoBehaviour { //ui //ui挂在一个unlitTexture材质球上 public Image img;... 阅读全文
posted @ 2019-08-06 11:36 三页菌 阅读(272) 评论(0) 推荐(0)
摘要:效果 素材 阅读全文
posted @ 2019-07-30 18:04 三页菌 阅读(1132) 评论(0) 推荐(0)
摘要:一种是alpha检测 一种是设置collider 参考: https://zhuanlan.zhihu.com/p/34204396 下面给出第二种方案代码 阅读全文
posted @ 2019-07-23 14:07 三页菌 阅读(1211) 评论(0) 推荐(0)
摘要:https://blog.csdn.net/e295166319/article/details/52370575 需要两个类:树节点类和界面实现类 1:树节点类(TreeNode) 2:界面实现类(CreateTreeList) 效果图: (点击后,被点击的节点红色显示,并在控制台输出被点击的节点 阅读全文
posted @ 2019-07-02 11:14 三页菌 阅读(1380) 评论(0) 推荐(0)
摘要:【DOTween】 SetEase 过渡类型 SetAutoKill 播放完不自动消除 DoMove 第三个参数 snapping 设置为 true ,Ease。Linear的设置才有效 Tweener t = GetComponent<RectTransform>().DOLocalMove(ne 阅读全文
posted @ 2019-06-19 13:44 三页菌 阅读(293) 评论(0) 推荐(0)
摘要:using UnityEngine; public enum AnchorPresets { TopLeft, TopCenter, TopRight, MiddleLeft, MiddleCenter, MiddleRight, BottomLeft, BottonCenter, ... 阅读全文
posted @ 2019-05-31 17:25 三页菌 阅读(1772) 评论(0) 推荐(0)
摘要:unity asset store 关联下载 ,添加这个书签 javascript:var url = window.location.href;var id = url.substr(url.lastIndexOf("-") + 1);var submitto = "http://www.cgso 阅读全文
posted @ 2019-05-16 15:27 三页菌 阅读(2587) 评论(0) 推荐(0)
摘要:效果: 点击按钮后: 这些碎片具有物理碰撞效果,下面会有隐形的支柱垫着碎片,n秒后支柱消失,碎片落下 当然你也可以控制生成的碎片,让他们从下而上一块一块地落下 插件源码: https://github.com/mjholtzem/Unity-2D-Destruction 基本使用说明 导入Unity 阅读全文
posted @ 2019-04-17 10:34 三页菌 阅读(2753) 评论(0) 推荐(0)
摘要:unity自带shader 即可 阅读全文
posted @ 2019-04-08 16:25 三页菌 阅读(1674) 评论(0) 推荐(0)
摘要:不需要编写额外的shader和任何代码,只使用自带的功能 新建一个材质球,取名为mask,选择自带的UI/Default,调节参数如下图 再新建一个材质球,取名为masked,调节参数如下图 如下图所示, 背景图为Panel 遮罩图为Image_m 注意层级关系! 即可实现 来源:https://a 阅读全文
posted @ 2019-04-02 18:23 三页菌 阅读(3945) 评论(0) 推荐(0)
摘要:using System.Collections; using System.Collections.Generic; using UnityEngine; using System; using System.Linq; public static class RandomHelper { // 阅读全文
posted @ 2019-02-06 11:32 三页菌 阅读(474) 评论(0) 推荐(1)