[英]Payment Stripe With Asset Unistripe Unity Worked In Development Build But Not In Production Build C# Unity
I have make an app with unity. 我有一个统一的应用程序。 The app have a payment feature which i used a stripe as my payment gateway.
该应用程序具有付款功能,我使用条纹作为付款网关。 I also use asset from unity call Unistripe to just create a token .
我还使用统一调用Unistripe中的资产来创建令牌 。
The apps and the payment work well when in development build (where I tick development build and script debugging in player setting and then build and run) But when i untick development build and script debugging for production release the payment is not working. 在开发阶段(我在播放器设置中打勾开发阶段和脚本调试,然后进行构建并运行)时,应用程序和付款工作良好。但是,当我取消开发阶段的开发版本和脚本调试时,付款不起作用。
What could possible cause the payment not working ? 有什么可能导致付款无效? Is there something that i am missing in here ?
我在这里缺少什么吗? Or is there any setting that i am missing in here ?
还是在这里我缺少任何设置?
Or 要么
Is there any code that i am missing in here ? 我在这里缺少任何代码吗?
Thank You 谢谢
Note : This apps is a donation. 注意:此应用是捐赠。 So it is permitted to use a third party payment.
因此,允许使用第三方付款。
Edited : 编辑:
This is the error from the log cat : 这是来自log cat的错误:
"java.net.ConnectException: Failed to connect to localhost/127.0.0.1:80"
"java.lang.ClassNotFoundException: com.onevcat.UniStripe.UniStripe"
I have found the problem myself. 我自己发现了问题。 So the problem is there is a class didn't include in the final bundle when build.
因此,问题是在构建时最终的捆绑包中没有包含一个类。
So when build the game, i have set the build system to "Grade" and set the minify to "Proguard" . 因此,在构建游戏时,我将构建系统设置为“ Grade” ,并将最小化设置为“ Proguard” 。
This setting didn't keep all the class when build. 构建时,此设置未保留所有类。 If you want to keep all the class you must set the config in the Proguard_text.txt to keep the file when build.
如果要保留所有类,则必须在Proguard_text.txt中设置配置以在构建时保留文件。
So to easy solve this problem i just change the build system to "Internal (Deprecated)" since this build system keep all the class. 因此,为了轻松解决此问题,我只将构建系统更改为“内部(已弃用)”,因为此构建系统保留了所有类。
That's all. 就这样。
Note : use proguard and change the proguard_text.txt config to keep the "com.onevcat.UniStripe.UniStripe" didn't worked as well. 注意:使用proguard并更改proguard_text.txt配置,以使“ com.onevcat.UniStripe.UniStripe”无法正常运行。 Maybe they are more class didn't include in the final bundle.
也许他们更多的课没有包含在最后的捆绑中。
For more : 有关更多:
To keep the class Just type : 要保留课程,只需输入:
-keep class com.onevcat.UniStripe.** -保持类com.onevcat.UniStripe。**
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.