• 博客园logo
  • 会员
  • 周边
  • 新闻
  • 博问
  • 闪存
  • 众包
  • 赞助商
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
 






无语_

 
 

Powered by 博客园
博客园 | 首页 | 新随笔 | 联系 | 订阅 订阅 | 管理
1 2 下一页

2017年10月23日

unity 真机包乱码解决方案
摘要: private bool isFontRebuilt = false; private Font dirtyFont = null; public void Awake () { Font.textureRebuilt += delegate (Font font1) { isFontRebuilt = true; ... 阅读全文
posted @ 2017-10-23 10:48 无语_ 阅读(436) 评论(0) 推荐(0)
 

2014年2月13日

Unity3d Editor使用
摘要: 1:生成类A,用来保存相关数据public class AudioSource : MonoBehaviour{ public AudioClip m_AudioClip; void Awake() { } // Use this for initialization void Start () { }}2:生成类B,继承Editorusing UnityEditor;[CustomEditor(typeof(AudioSource))]public class InspectorAudioSource : Editor { public override void OnInspector.. 阅读全文
posted @ 2014-02-13 11:03 无语_ 阅读(665) 评论(0) 推荐(0)
 
Unity3D 代码保存prefab
摘要: Object tempPrefab = EditorUtility.CreateEmptyPrefab("Assets/res/audio/AudioSourcePrefab/" + gameObject.name + ".prefab");tempPrefab = EditorUtility.ReplacePrefab(gameObject, tempPrefab); 阅读全文
posted @ 2014-02-13 10:58 无语_ 阅读(2681) 评论(0) 推荐(0)
 
Unity3d TweenRotation 使用
摘要: /* * parentQuate:需要变换的对像 * angleX,angleY,angleZ: 旋转哪个方向 * angle:需要旋转的角度 0~360 */ static public Quaternion ChangeRotation(GameObject parnetQuate, float angleX, float angleY, float angleZ, float angle,bool IsAnimation,float duration) { Quaternion ans = Quaternion.identity; if( parnetQuat... 阅读全文
posted @ 2014-02-13 10:57 无语_ 阅读(1548) 评论(0) 推荐(0)
 

2013年12月4日

Keyboard 位置变化
摘要: #ifdef __IPHONE_5_0 float version = [[[UIDevice currentDevice] systemVersion] floatValue]; if (version >= 5.0) { [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(keyboardWillShow:) name:UIKeyboardWillChangeFrameNotification object:nil]; }#endif5.0后版本可以使用#prag... 阅读全文
posted @ 2013-12-04 10:22 无语_ 阅读(263) 评论(0) 推荐(0)
 

2013年10月9日

[NSArray count]if比较问题
摘要: 不能够直接使用[NSArray count]在if中做比较,会有错误发生int tempCount = -1;NSArray* array = [[NSArray alloc] init];if( tempCount >= [array count]){ int NewsChangeParam = -1;}因为array是无符号int型,所以比较的时候会把前面的int也转为无符号int型。-1 无符号int型 等于:4294967295所以本判断是成立的。会进入到int NewsChangeParam = -1;需要使用这种方法去做array count比... 阅读全文
posted @ 2013-10-09 14:08 无语_ 阅读(366) 评论(0) 推荐(0)
 

2013年9月30日

正则表达示
摘要: //利用正则表达式验证邮箱地址合法性-(BOOL)isValidateEmail:(NSString *)email { NSString *emailRegex = @"[A-Z0-9a-z._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,4}"; NSPredicate *emailTest = [NSPredicate predicateWithFormat:@"SELF MATCHES %@", emailRegex]; return [emailTest evaluateWithObject:email]; } 阅读全文
posted @ 2013-09-30 15:33 无语_ 阅读(109) 评论(0) 推荐(0)
 

2013年9月24日

webview设置字体
摘要: NSString* string = [[_parentDict objectForKey:@"context"] objectForKey:@"text"]; string = [string stringByReplacingOccurrencesOfString:@"FONT-SIZE"withString:@"a"]; string=[string stringByAppendingString:@""]; string=[string stringByAppendingString:@ 阅读全文
posted @ 2013-09-24 14:50 无语_ 阅读(537) 评论(0) 推荐(0)
 
ios 中文 url encod
摘要: 将中文转成指定encod 与中文网站交互NSString* string2 = [@"南昌" stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]NSLog string2====%E5%8D%97%E6%98%8C将网站返回的中文字符转为nsstringNSURL *url = [NSURL URLWithString:urlString]; NSError *error = nil;NSString *responseString = [NSStringstringWithContentsOfUR 阅读全文
posted @ 2013-09-24 11:24 无语_ 阅读(349) 评论(0) 推荐(0)
 

2013年9月2日

ios 排序
摘要: [Array sortUsingComparator:^NSComparisonResult(id obj1, id obj2) { NSMutableDictionary* tempDict = obj1; NSMutableDictionary* tempDict2 = obj2; NSTimeInterval Num1 = [[tempDict objectForKey:@"date"] timeIntervalSince1970]; NSTimeInterval Num2 = [[tempDi... 阅读全文
posted @ 2013-09-02 09:15 无语_ 阅读(211) 评论(0) 推荐(0)
 
1 2 下一页