- 博客(17)
- 资源 (7)
- 收藏
- 关注
原创 unity播放使用Videoplayer播放视频
使用videoplayernot all platforms transcoded Clip is not guaranteed to be compatible on platforms without transcoding;点击视频,在Inspector勾选Transcode,CodeC勾选为VP8;并且H265格式打包后不能播放,修改为H264
2022-04-12 14:03:17
2997
原创 Unity排版下拉ScrollRect,Mask,VerticalLayoutGroup,ContentSizeFilter,ScrollBar使用
建立两个大小一致的空物体,父物体添加ScrollRect组件 ,Mask和Image子物体panel添加一个VerticalLayoutGroup以及一个ContentSizeFilter此时下拉框添加子物体则可以实现合理的效果
2021-09-18 18:07:29
375
1
原创 Unity网络数据(Socket)应用,一台为服务器,另一台为客户端
服务器端:using System.Collections.Generic;using System.Net;using System.Net.Sockets;using System.Text;using System.Threading;using UnityEngine;using Utils;public class TCPServer : MonoBehaviour{ public string ipAdress; public int port;...
2021-03-04 13:42:51
218
1
原创 Unity中如何将图片数字文字转化为自制字体(Font)
1.下载ACDSee(非必须,ACDSee可以有效的对图片进行明名)和bmfont642.打开bmfont,点击Edit下的Open Image Manger,然后点击Image,分别是Import Image ,Edit Image和SelectedDelete;点击Import Image导入你想要改成字体的图片(比如:汉字:赢,字母:Aa,数字:1;前提条件必须有相对应的ASCII值)3.点...
2020-08-07 14:31:28
1895
原创 2020-08-07 VideoPlayer播放多个视频
记录VideoPlayer按顺序播放多个视频,clipName = clip.name;if ((long)video.frameCount - video.frame <= 5) { switch (clipName) { case "1": video.clip = videoClips[1]; break;
2020-08-07 14:25:11
1039
4
原创 c#中的观察者设计模式
//观察者模式interface Subject{ void Notify(); string SubjectState{set;get;}}//事件委托管理delegate void PatrolHandle();class Teacher :Subject{ //事件和委托最主要的区别就是事件不能当做形参传递,但是委托可以public event
2017-08-16 21:02:21
313
原创 c#学习第五天 枚举和结构体
//enum在c#中可以再创建一个.cs文件,也可以在默认的cs文件里面创建(program.cs)//enum和类是同等级关系enum Color{ red, green, yellow, blue}class Program{static void Main(string[] args){Color c = (C
2017-07-31 16:48:12
325
原创 c#中选择排序和冒泡排序比较
//冒泡排序 冒泡排序需要双循环一个是趟数 一个是循环次数int [] array ={12,22,11,21,32,25,26,70};int temp;for(int i = 1; i for(int j =1; j if(array[j-1]>array[j]){ temp = array[j-1];
2017-07-30 17:14:08
2859
原创 c#学习第四天
1.冒泡排序:冒泡排序设计到双循环,外层控制趟数,内层循环控制比较次数 int[] array ={8,6,4,1};for(int i = 0; i for(int j=0;j if(array[j]>array[j+1]){ int temp = array[j];//定义一个变量作为交换暂时存放的值
2017-07-28 20:38:47
192
原创 c#第三天 三大循环语句和一维数组
循环结构----while语法格式:while(条件判断){循环体;}小案例:输出十句hello worldint x=0; while(xConsole.WhiteLine("hello world");x++;}2.打印五十份卷子,输出显示int x= 5;while(x>0){Console.WhiteLine("还剩下{
2017-07-27 17:53:25
730
原创 c#输入三个数,打印出中间的数值
Console.WriteLine("请输入三个数:");int a = int.Parse(Console.WriteLine());int b = int.Parse(Console.WriteLine());int c = int.Parse(Console.WriteLine());int max = a>b?a:b;max=max>c?:max:c;int min
2017-07-26 21:32:57
3983
原创 c#if,switch语句
using System;namespace _02ClassCode{ class Program { static void Main(string[] args){ //if语句有三种分支情况 /****第一种:单分支if语句*****///写法: if(条件表达式){语句块}/******
2017-07-26 18:22:09
712
原创 c#第一天练习题
编写一个程序,要求用户输入一个美金数量, 然后显示出如何用最少的20美元、10美元、5美元和1美元来付款: Enter a dollar amout:93 $20 bills: 4 $10 bills: 1 $5 bills:0 $1 bills:3 1. 熟练掌握运算符的组合使用2. 熟练掌握数据类型的相互转换3. 熟练掌握
2017-07-25 21:52:08
525
原创 C#第一天的作业
编写一个程序,要求用户输入一个美元数量,然后显示出增加%5税率后的相应金额。格式如下所示:Enter an amount:100.00With tax:$105.00作业目标及能力提升1. 熟练掌握运算符和基本数据类型的使用2. 熟练掌握基本输出语句的使用3. 熟练掌握数值与字符串类型的转换 解题思路1. 通过命令端输入需要参与计算的数值,因为接收的输入值的
2017-07-25 20:48:52
708
原创 c#学习第一天的内容
//using是使用的意思,导入命名空间(路径)using System;namespace _01ClassCode{//class类关键字class Program{//一个项目至少包含一个Main函数,Main函数是程序的主入口 static void Main(string[] args){ //输出语句Console.WriteLine
2017-07-25 19:45:10
261
讯飞AIUI,c#版本
2022-04-12
EXEForExchange.zip
2019-10-25
SerialPortMoveTest.zip
2019-10-17
CKTest.zip
2019-09-25
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人