Comments (14)
I've got gokit running in a bunch of projects on Unity 5. What are you seeing?
On Tue, Jun 9, 2015 at 5:04 PM, AaronRelish [email protected]
wrote:
Hey guys. As you may know, Apple just began enforcing the inclusion of 64-bit architecture in all ios submissions. For those created in Unity, this requires using the 'IL2CPP' scripting backend rather than 'Mono 2.1' in order to enable 'Universal' in the Architecture Settings.
Does Prime31 have any plans to update GoTween to accommodate this new restriction? Presently it works fine in the IDE, but most tweens cause errors on iOS.
Reply to this email directly or view it on GitHub:
#70
from gokit.
It's not a Unity 5 thing, it only comes up when using the architecture requirements now required by apple. To reproduce it, you'd have to make the iOS export changes I mentioned above (Change Scripting Backend to 'IL2CPP' and Architecture to 'Universal'), run a build out to XCode, and test on a device. Ideally your test case would have extensive use of GoTween, with features like completion handlers and chaining.
from gokit.
Yup. What issues are you seeing?
On Tue, Jun 9, 2015 at 5:31 PM, AaronRelish [email protected]
wrote:
It's not a Unity 5 thing, it only come up when using the architecture requirements now required by apple. To reproduce it, you'd have to make the iOS export changes I mentioned above (Change Scripting Backend to 'IL2CPP' and Architecture to 'Universal'), run a build out to XCode, and test on a device. Ideally your test case would have extensive use of GoTween, with features like completion handlers and chaining.
Reply to this email directly or view it on GitHub:
#70 (comment)
from gokit.
Was on the road earlier -- I'd love a stack trace to help us narrow down some of the issues. I'm aware of one problem right now with canvasGroup.alpha. More is always helpful, though.
from gokit.
Sure thing, I'll have to grab that when I'm back in the office tomorrow morning.
from gokit.
Hey Aaron -- still waiting on some examples that cause the issue.
I don't think I'm going to be able to take some time tonight to create a test case, but it seems like the main reason why these things are occurring is that some of the property references that you are using are being accessed via reflection, and and those classes are being stripped out with the IL2CPP build process.
These would be things like floatProp, colorProp, and a bunch of others. You need to make sure you're adding the objects within the link.xml file so Unity doesn't strip those classes on build: http://docs.unity3d.com/Manual/iphone-playerSizeOptimization.html
Please let me know if this helps resolve your issue. Not quite sure what we can do to resolve this automatically.
from gokit.
Hey @zapdot I'm having a similar issue and hoping you can help out. We're doing an iOS build using IL2CPP to satisfy Apple's 64-bit requirements and having some issues with tweens. The messages we're getting look like this:
ArgumentNullException: Argument cannot be null.
Parameter name: method
at System.Type.GetTypeFromHandle (RuntimeTypeHandle handle) [0x00000] in <filename unknown>:0
at System.Delegate.CreateDelegate (System.Type type, System.Object firstArgument, System.Reflection.MethodInfo method, Boolean throwOnBindFailure) [0x00000] in <filename unknown>:0
at System.Delegate.CreateDelegate (System.Type type, System.Object firstArgument, System.Reflection.MethodInfo method) [0x00000] in <filename unknown>:0
at GoTweenUtils.getterForProperty[Func`1] (System.Object targetObject, System.String propertyName) [0x00000] in <filename unknown>:0
at FloatTweenProperty.prepareForUse () [0x00000] in <filename unknown>:0
at UnityEngine.Advertisements.ShowOptions.set_resultCallback (System.Action`1 value) [0x00000] in <filename unknown>:0
at GoTween.onInit () [0x00000] in <filename unknown>:0
at UnityEngine.Advertisements.ShowOptions.set_resultCallback (System.Action`1 value) [0x00000] in <filename unknown>:0
at GoTween.update (Single deltaTime) [0x00000] in <filename unknown>:0
at UnityEngine.Advertisements.ShowOptions.set_resultCallback (System.Action`1 value) [0x00000] in <filename unknown>:0
at Go.handleUpdateOfType (GoUpdateType updateType, Single deltaTime) [0x00000] in <filename unknown>:0
at Go.Update () [0x00000] in <filename unknown>:0
at Replacements.RemotingServices.CreateClientProxy (System.Type objectType, System.String url, System.Object[] activationAttributes) [0x00000] in <filename unknown>:0
Replacements.RemotingServices:CreateClientProxy(Type, String, Object[])
and
ArgumentNullException: Argument cannot be null.
Parameter name: method
at System.Type.GetTypeFromHandle (RuntimeTypeHandle handle) [0x00000] in <filename unknown>:0
at System.Delegate.CreateDelegate (System.Type type, System.Object firstArgument, System.Reflection.MethodInfo method, Boolean throwOnBindFailure) [0x00000] in <filename unknown>:0
at System.Delegate.CreateDelegate (System.Type type, System.Object firstArgument, System.Reflection.MethodInfo method) [0x00000] in <filename unknown>:0
at GoTweenUtils.getterForProperty[Func`1] (System.Object targetObject, System.String propertyName) [0x00000] in <filename unknown>:0
at ColorTweenProperty.prepareForUse () [0x00000] in <filename unknown>:0
at UnityEngine.Advertisements.ShowOptions.set_resultCallback (System.Action`1 value) [0x00000] in <filename unknown>:0
at GoTween.onInit () [0x00000] in <filename unknown>:0
at UnityEngine.Advertisements.ShowOptions.set_resultCallback (System.Action`1 value) [0x00000] in <filename unknown>:0
at GoTween.update (Single deltaTime) [0x00000] in <filename unknown>:0
at UnityEngine.Advertisements.ShowOptions.set_resultCallback (System.Action`1 value) [0x00000] in <filename unknown>:0
at Go.handleUpdateOfType (GoUpdateType updateType, Single deltaTime) [0x00000] in <filename unknown>:0
at Go.Update () [0x00000] in <filename unknown>:0
at Replacements.RemotingServices.CreateClientProxy (System.Type objectType, System.String url, System.Object[] activationAttributes) [0x00000] in <filename unknown>:0
Replacements.RemotingServices:CreateClientProxy(Type, String, Object[])
Some of these are tweens on colors, others on the anchoredPosition3D
of RectTransform
s. Some tweens use onComplete()
callbacks.
Can you provide an example of what I'd need to put in my link.xml
file? It's not really clear to me what should go in it Do I need to put GoKit classes in there or something else?
from gokit.
Unity's link.xml docs are here: http://docs.unity3d.com/Manual/iphone-playerSizeOptimization.html GoKit uses reflection to fetch the getter/setter so the section "How to Deal with Stripping when Using Reflection" is relevant.
from gokit.
Sorry to reopen this. But I'm having this same problem. I have read the "How to Deal with Stripping when Using Reflection". Unfortunately, I am newer to C# and Unity, and I'd really appreciate some help on what to put in the link.xml file. I'm using the GoKit floatProp on my the main camera's Camera.fieldOfView variable. Can you help me with what I'd put in my link.xml file?
Any help would be greatly appreciated.
from gokit.
If your link.xml file is empty/non-existent, you'd create the "link.xml"
file in your Assets directory, and put this in it:
<linker>
<assembly fullname="UnityEngine">
<type fullname="UnityEngine.Camera" preserve="all"/>
</assembly>
</linker>
from gokit.
Thanks so much for the help, that worked perfectly!
from gokit.
Hi @zapdot.
Sorry to comment on an old thread but I've come across the same issue with GoKit and I'm having trouble determining how to stop the code stripping too.
My code that's calling GoKit is doing an alpha fade within a class called AlphaFader
:
Go.to(spriteRenderer, fadeTime, new GoTweenConfig().colorProp("color", new Color(1.0f, 1.0f, 1.0f, alpha)).onComplete(onComplete));
And my link.xml (which doesn't currently work) is:
<linker>
<assembly fullname="UnityEngine">
<type fullname="UnityEngine.WWW" preserve="all" />
</assembly>
<assembly fullname="Assembly-CSharp-firstpass">
<type fullname="AlphaFader" preserve="all" />
</assembly>
</linker>
Do I need to preserve GoKit rather than my AlphaFader
class?
Sorry, it's unclear from the Unity documentation as to what the assembly
and type
names should be. I've made the assumption that it's within the Assembly-CSharp-firstpass
but this may be wrong too!
Thanks for your help.
from gokit.
So the problem isn't your class that is using this, it's the class/property that you're trying to reference via reflection. Since you are trying to edit the spriteRenderer.color property, the SpriteRenderer class is the one you want to add to the link.xml.
If you look at the Scripting API: http://docs.unity3d.com/ScriptReference/SpriteRenderer.html
You'll see that's in the UnityEngine namespace.
So your link.xml should look like:
<linker>
<assembly fullname="UnityEngine">
<type fullname="UnityEngine.WWW" preserve="all" />
<type fullname="UnityEngine.SpriteRenderer" preserve="all" />
</assembly>
</linker>
Let me know if you have any more questions.
from gokit.
@zapdot Thank you so much! That's the clearest explanation I've read of the link file and I was completely misunderstanding it. It seems so obvious now you've said it that it's the reflected field of the used class that has no reference.
Your link.xml
works great! Thanks again.
from gokit.
Related Issues (20)
- GoDummyPathEditor "Shift Path to Start at Origin" seems to be incorrect
- AbstractGoTween.goTo does not update rotation HOT 1
- Android streaming GoSpline asset bug? HOT 2
- Built-in support for inserting functions into GoTweenCollections HOT 6
- Docs: link not working anymore (README.md) HOT 3
- Doesn't compile for Windows Phone 8 HOT 1
- What do you think about rearranging this repo so it could be a submodule or a subtree? HOT 5
- [Question] Player Camera on Path HOT 1
- Non functioning Tween when reusing a GoTween instance with modified TweenProperties HOT 5
- Canceling / destroying a tween collection HOT 4
- Changing the speed/during of a GoTween/GoTweenChain while it is playing HOT 2
- Is there a way to save all running tweens? HOT 1
- Need help with playBackwards() HOT 3
- How to check if Go has no animation running HOT 2
- [FEATURE REQUEST] ECS Support HOT 2
- [Request] Tween value without using property HOT 6
- Tweening Rotations Shortest Distance HOT 1
- Is there a way to queue Tweens by GoKit itself?
- Documentation installation (via github?) HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gokit.