Coder Social home page Coder Social logo

Comments (7)

chexiongsheng avatar chexiongsheng commented on June 3, 2024

热补丁的基本原理是在il层面上对原有代码加了一点逻辑实现的。
而Hotfix标签相当于白名单,列出哪些类型要做上述预处理。
当然,要默认对用户所有类型都预处理也是可以的,看需求,如果需求强烈,可以设置一个宏,不用打标签,对所有类型都处理。
ps:上面所说的“一点逻辑”,类似这样
int Add(int a, int b)
{
if (hotfix_Add != null) return hotfix_Add(this, a, b);
...原有逻辑...
}

from xlua.

xclouder avatar xclouder commented on June 3, 2024

谢谢回复,全部都打上也有点浪费,还要考量打包速度、il2cpp编译后包大小问题。

from xlua.

chexiongsheng avatar chexiongsheng commented on June 3, 2024

对的!

from xlua.

wzhfantastic avatar wzhfantastic commented on June 3, 2024

原理是il层面的话, unity5.3之前的安卓平台是不支持il的吧?

from xlua.

chexiongsheng avatar chexiongsheng commented on June 3, 2024

@wzhfantastic ,il一直都都支持。
android下,backend是mono的话,直接运行il,backend是il2cpp的话,是生成il后转cpp。
我开发环境就是5.2.3f1.

from xlua.

wzhfantastic avatar wzhfantastic commented on June 3, 2024

@chexiongsheng
谢谢,原来是这样!

from xlua.

daaoling avatar daaoling commented on June 3, 2024

当然,要默认对用户所有类型都预处理也是可以的,看需求,如果需求强烈,可以设置一个宏,不用打标签,对所有类型都处理。

这一块我不是很明白?这个宏指的是HOTFIX_ENABLE?

from xlua.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.