自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

Eijnew's blog

技术积累 一点一滴

  • 博客(29)
  • 资源 (9)
  • 收藏
  • 关注

原创 利用fontmin给cocos2d-x游戏字体瘦身

清宫Q传有很多文本需要显示,同时为了效果也使用了很多种不同的字体,导致字体文件占据程序包很大比例的空间,搜索了一下,找到了一款工具fontmin可以有效减少字体大小。fontmin简介fontmin是一个纯 JavaScript 实现的字体子集化方案,提供了 ttf 子集化,eot/woff/svg格式转换,css 生成等功能。虽说是被设计用来提升网页体验的,但也可以通过减少字体体积从而减少iOS/

2016-07-27 13:24:25 2494 1

原创 cocos2d-lua android解决启动时因为资源加载而黑屏的问题

cocos2d-lua android解决启动时因为资源加载而黑屏的问题

2016-07-08 22:57:14 8752 4

原创 Cocos2d-lua 3.10 图片资源加密

在游戏发布之前,最好将图片加密,为apk/ipa加一层保护

2016-06-13 18:47:44 6106 7

原创 Cocos2d-lua自动重新加载SpriteFrames

收到 didReceiveMemoryWarning之后Cocos2d-lua自动重新加载SpriteFrames

2016-05-04 16:30:15 8193 1

原创 升级到cocos2d-x 3.10之后被遗忘的ccui.PageView.pageTurningEvent()

升级到cocos2d-x 3.10之后被遗忘的ccui.PageView.pageTurningEvent()

2016-05-03 19:34:27 5370 1

原创 为安卓App加个退出键

近期需要把一款手游迁移到Android上,由于一直用cocos2d-lua,对Android不熟悉,漏掉了退出键的实现,在测试童鞋的反馈下才意识到。想着这些问题一定有很多Android前辈遇到过,翻墙一查,还没看到解决方法,先看到一场关于『结束正在运行的Android程序』的争论,见StackOverflow这里。提问者的疑问是,为什么安卓系统决定了何时退出App,而不是用户决定。

2016-05-02 22:31:20 2082

原创 cocos2d-lua集成Mob-SMSSDK-for-android

新项目使用cocos2d-lua(based on cocos2d-x 3.6 and quick 3.5)开发,需要集成SMSSDK。 SMSSDK分别对iOS/android平台提供了SDK,由于没有android开发经验,在集成android SDK的时候遇到了很多问题,也花了很多时间解决,在此记录一下。

2015-10-24 22:44:25 2493

原创 Polymorphism in CSharp

Polymorphism in CSharpThere are three kinds of polymorphism in CSharpCompile time polymorphismRuntime polymorphismParametric polymorphismExamplesPolymorphism in CSharpThere are three kinds of pol

2015-04-20 18:58:00 1527

原创 [Unity3D]调用函数时出现NullReferenceException的一个可能原因

今天遇到一个报错,如下图:NullReferenceException UnityEngine.MonoBehaviour.StartCoroutine (IEnumerator routine) (at C:/BuildAgent/work/d3d49558e4d408f4/artifacts/EditorGenerated/UnityEngineMonoBehaviour.cs:6

2014-11-27 14:20:16 23557 4

原创 import in python

import做了什么在sys.modules中寻找该模块是否之前被引入过,如果有,引入该名字[import mode相当于mod = sys.modules['mod']]如果没有:在sys.path中寻找该模块,如果没找到,报错如果找到,创建一个空的模块对象,通常为dict()将该模块写入sys.modules加载该模块文件(如果有必要,先编译)执行该模块代码,def, im

2014-08-11 16:47:54 2430

转载 Running Your iOS App in the Simulator From The Command Line

While Apple doesn’t provide an “official” way to launch an app in the iOS Simulator from the command line, there’s a few private tricks we can employ.First, the iOS Simulator app itself is located i

2013-08-09 15:35:25 2391

原创 iOS crash log report tools

crashlyticshttp://try.crashlytics.com/HockeyApphttp://hockeyapp.net/

2013-05-04 14:30:09 1932

转载 Compiler Warnings for Objective-C Developers

Compiler warnings are one of the most helpful tools for developers. The compiler can not only warn you about obvious mistakes (such as a method you forgot to implement); it also identifies many code p

2013-04-29 13:37:51 2621

转载 Why C++ Supports both Class and Typename for Type Parameters

Recently, someone asked me why we support both class and typename within C++ to indicate a type parameter since the keywords do not hold any platform significance – for example, class is not meant to

2012-03-21 14:50:05 1608

原创 Shell编程笔记(未完待续)

1.shell中单双引号的区别 单引号关闭所有有特殊作用的字符而双引号只要求shell忽略大多数,除了①美元符号②反引号③反斜杠,这3种特殊字符不被忽略。具体而言:单引号包括的内容均被原样输出双引号会做变量替换,命令替换和转义,除此之外原样输出示例:#!/bin/bashDT="today is" SINGLEQUOTE='\"$DT

2012-03-20 10:06:28 1620

原创 C++中POD是什么?

什么是POD? POD 的全称是 Plain Old Data,在C++标准中,POD是这样定义的: Arithmetic types (3.9.1), enumeration types, pointer types, and pointer to member types (3.9.2), and cv-qualified(注2) versions of these types (3.

2012-03-19 15:41:54 9911

翻译 char **和char *[M]有什么区别?

原文链接在此在函数参数中,extern int func(char **);和extern int func(char *[M]);是代表不同含义的。前者表示函数期望一个指针,该指针指向一块内存,该内存中包含N个指针,每个指针指向一块内存;这些指针指向的内存可能是连续的,也可能不连续,长度并且不一定相同;其中&a[0][0]和&[1][0]无

2012-03-05 15:31:03 4391

原创 为什么不能使用成员变量的值作为成员函数的默认参数?

在解决工作中遇到一个问题时,我定义了一个类c(如下所示),包含两个功能类似的公共查询接口Rate()和Rate(char bs_flag, char sh_flag),二者的区别是,在实例化对象的时候,会包含bs_flag和sh_flag,因此我希望有一个不用指定查询条件的Rate函数,用来反映默认情形;但有时又需要变更查询条件查询,如第二个指定查询条件的Rate函数,那么能否将这两个函数合并呢?

2012-03-01 17:00:14 4617

原创 在operator=或拷贝构造中对所有数据成员赋值

1. operator=赋值操作符Effective C++条款16中描述到,在派生类中重写赋值操作符函数时,要注意不要忘记对基类对象部分也要赋值,而这一点恐怕是许多新手容易忘记的,他们很自然地不会想到这一点(例如我),比如下述代码:class CBase{public: CBase& operator=(const CBase& another) {

2012-02-29 16:11:57 1766

原创 C++异常处理 -- 异常对象(Exception Object)

在C++异常处理中,throw可以抛出任何对象,可以是int类型,也可以是class类型,对于catch块而言,有两种选择:1)catch这个类型,例:int main(){ int a=1; try { throw a; } catch(int) // 捕获int型异常,无法获知a的内容 { cout<

2012-02-28 15:34:22 4688

原创 多机调度问题的贪心解法

多机调度问题:有n个独立的作业需要在m台相同的机器上进行加工处理. 作业i需要的加工时间为ti. 每个作业可以任选一台机器加工, 但加工结束前不能中断, 作业不允许拆分.要求给一种作业调度方案, 使所给的n个作业在尽可能短的时间内完成.问题分析:为什么是NP问题? (待求证)问题解答:采用最长处理时间作业优先的贪心选择策略可以设计出较好的近似算法

2012-02-15 10:25:15 8448

原创 二分搜索(BinarySearch)的分治思想C语言实现

二分搜索是常用的搜索算法, 要求给定的元素集合非递减排序, 根据给定待查找元素, 查找其索引, 如果未找到, 返回-1.代码为:// 二分搜索 5 // @pre : a非递减序, 且长度为len 6 // @post: 返回x在a中的索引或-1 7 int binary_search(int a[], int len, int x)

2012-02-14 13:33:01 2694

原创 字符组合问题的分治算法

题目是这样的:把一个字符串中所有字符的所有可能的组合打印出来(字符串中没有重复的字符),不考虑字符顺序('123'和'312'是一样的)该算法使用分治思想的C语言描述如下:void generate_all_combinations(char *str, int len, char *prefix){ if (len==0) {

2012-02-14 09:18:40 1166

转载 Linux多线程函数解析

Linux多线程函数解析Linux多线程函数用得比较多的是下面的3个pthread_create(),pthread_exit(),pthread_join();它们都是在头文件之中。编译时需要加静态库-lpthread 下面是函数的说明:  pthread_create是UNIX环境创建线程函数 int pthread_create(      pthread_t *

2011-12-29 13:57:14 862

原创 使用const_cast转换全局const变量导致程序崩溃的原因

#include using namespace std;const int gc_var = 300;int main(){ const int lc_blah = 100; int &l_blah = const_cast(lc_blah); l_blah = 200; cout<<"l_blah: "<<l_blah<<endl; // Will

2011-12-29 12:28:26 2064

翻译 如何拖动文件到python脚本中作为输入参数?

默认情况下,我们无法拖放一个文件给python脚本让其去处理这个文件,这是因为windows认为python脚本不是一个合法的可拖放的目的对象(drop target)。为了实现拖放目的,我们只需在注册表中配置一下即可,具体做法为:新建.reg文件,文件名随意,内容为:W

2011-08-17 16:30:23 17422 5

原创 如何在linux下快速替换多个文件的文本?

    哥现在参与的产品无比庞大,每次部署环境,都要修改无数配置文件,让开发/测试尤其是去客户现场实施的人员头疼不已.据粗略估计,有数十个模块,每个模块下面一个配置文件,模块之间藕断丝连,有着难以割舍的关系--当然,如果不该割的割了,就要出大问题了,你懂的--,这其中,配置文件起着决定性的调度作用,模块与模块的沟通协作,可以说,是靠着配置文件实现的.    问题是什么呢?由于需要去不同的客户处安装我们的系统,而每个客户的具体环境又是不同的,诸如IP,端口等基本设置就要进行批量修改,如果没有合适的工具或命

2011-02-19 13:19:00 4023

原创 如何在shell中快速切换目录?

<br />经常在shell下工作的筒子们经常会在不同的目录来回切换,那么,如何能提高切换的效率呢?不用每次手动输入cd /path/to/dir1; cd /path/to/dir2?<br />在只有两个目录的情况下,有个很简单也很直观的办法:<br />$ cd -          #表示回到之前的目录                                    <br />多说一句,这个-还有其他的一个典型用法:如果文件名参数是一个单破折号"-",表示从标准输入读取文件列表:

2011-02-16 14:44:00 3845

原创 linux如何根据进程ID查找启动程序的路径

<br />昨天遇到一个问题,背景是这样的:我们工作环境不正常,使用ps命令查看,发现有程序A的两个进程状态一个是<defunct>状态,一个是正常运行.由于该程序A是个通用服务程序,被拷贝成多份,分发到不同的目录中单独启动,只有各自配置不同而已,因此想知道是哪个目录的A程序处于僵死状态.<br /><br />正常运行中的进程树关系如下(为了简化,只显示一部分进程):<br />$ ps x<br />  PID TTY      STAT   TIME COMMAND<br />1727

2011-02-15 14:12:00 24047

Odin Validator V3.1.6 Unity3D

Find and fix errors in Unity with Odin Validator, the most powerful validation tool ever made for Unity. Odin Validator scans your project for issues and helps you fix them as they happen.

2022-10-25

ShapesV2.3.2

Shapes 是一款实时向量图库,带有高质量的线条画和无限分辨率的图形,并以高级的抗锯齿技术渲染 网站 • 文档 • 更改日志 • 反馈中心 • Twitter 完成了 Shader Forge 之后,我想做出一些不同的东西。有一件事让我一直很困扰,由于某种原因,html5 画布比 Unity 还更适合绘制原始版本。我真的很想助力做出这些清晰的线条、圆盘、多线条以及形状!因此我才创建了它~ 如果你要在 Twitter 上分享作品的话,请勿犹豫以 #madewithshapes 来标注我 我将很乐意看到你的作品!♥

2020-11-17

ALineV1.3.1

ALINE 可完全替代 Unity 的内置 Debug.Draw 和 Gizmo 绘制功能以及其他所有绘制需求。它更快,功能更丰富,渲染质量更高。 是否已厌倦 Unity 有限且不一致的绘制用 API? 是否曾经希望通过在 Burst 或 ESC 任务中绘制调试线,从而对其进行调试? 甚至希望在独立游戏中绘制?或者希望制作关卡编辑器? 可以借助 ALINE 实现这一切效果! 这是一个全新的资源包。这正是为何在短暂的测试期内可以以低价买到这一资源包。测试期结束后,价格可能会上涨。这也意味着,即便该资源包已用于制作,其中可能还是存在性能不佳的漏洞或工作流程。请报告这些漏洞或不足,我们会即

2020-11-17

EasySave3.unitypackage

EasySave3 (3.3.1f9) Why use Easy Save? For Amateurs... It's easy to use and well documented For Experts... It's fast, feature-rich and extremely flexible

2020-07-26

EnhancedScrollerV2.25.1.unitypackage

Features: * Dynamic, data-driven lists * MVC framework to maintain a separation of concerns * Efficient recycling of list items * Optional infinite looping * Multiple list item sizes supported, or pass a global size * List items are fully customizable to fit your project * Optional snapping locks your scroller * Tweening to ease jumping and snapping * Demos, tutorials and full C# source code are all included.

2020-07-17

AstarPathfindingProjectV4.2.15.unitypackage

The A* Pathfinding Project is a powerful and easy to use pathfinding system for Unity. With blazing fast pathfinding your AIs will be able to find the player in complex mazes in no time at all. Perfect for TD, FPS and RTS games.

2020-04-17

OdinInspectorV2.1.11.unitypackage

Odin Inspector 文件大小 2.8 MB 最新版本 2.1.11 最新发布日期 2020年3月26日 支持Unity版本 5.3.0或更高 Odin puts your Unity workflow on steroids, making it easy to build powerful and advanced user-friendly editors for you and your entire team.

2020-04-15

AntiCheatToolkitV2.2.1.unitypackage

Anti-Cheat Toolkit (ACTk) 最新版本V2.2.1 最新版本 2.2.1 最新发布日期 2020年3月17日 2017.4.1或更高 在这里为那些在你的游戏中作弊/破解/破解某些东西的人增加了一些额外的痛苦。 在一个地方包括各种反作弊技巧和技术,易于使用,完整的来源,详细的文档和角落案件护理。

2020-04-15

MoreEffectCoroutinesProV3.10.1.unitypackage

More Effective Coroutines [PRO] V3.10.1 2020年3月16日最新版(PRO) More Effective Coroutines (MEC) is an improved implementation of coroutines. When you use Unity's built-in default coroutines you will have to be very careful about how you use them or else they will allocate memory that the garbage collector later has to clean up. This can cause your app to randomly skip frames. MEC solves that issue for coroutines, while also making coroutines more powerful by running about twice as fast as Unity's default coroutines do and providing you with a host of new options that Unity's default coroutines don't have. This is the Pro version. The free version of MEC contains the mininum set of features, whereas the Pro version contains the full set. Both versions run on the same super-fast core. Switching between MEC coroutines and Unity's default coroutines is really easy. They can even be used side by side in the same project.

2020-04-15

MoreEffectiveCoroutinesV3.08.0.unitypackage

More Effective Coroutines [PRO] V3.08.0 2019年8月27日最新版(PRO) More Effective Coroutines (MEC) is an improved implementation of coroutines. When you use Unity's built-in default coroutines you will have to be very careful about how you use them or else they will allocate memory that the garbage collector later has to clean up. This can cause your app to randomly skip frames. MEC solves that issue for coroutines, while also making coroutines more powerful by running about twice as fast as Unity's default coroutines do and providing you with a host of new options that Unity's default coroutines don't have. This is the Pro version. The free version of MEC contains the mininum set of features, whereas the Pro version contains the full set. Both versions run on the same super-fast core. Switching between MEC coroutines and Unity's default coroutines is really easy. They can even be used side by side in the same project.

2019-12-08

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除