diff --git a/src/spritekit.cs b/src/spritekit.cs index 4331609fd4e7..062b85aeff56 100644 --- a/src/spritekit.cs +++ b/src/spritekit.cs @@ -299,14 +299,18 @@ partial interface SKNode : NSCoding, NSCopying { [Export ("attributeValues", ArgumentSemantic.Copy)] NSDictionary AttributeValues { get; set; } +#if !XAMCORE_4_0 + // [Obsolete ("Please use the subtype's method")] [iOS (9,0),Mac(10,11)] [Export ("valueForAttributeNamed:")] [return: NullAllowed] SKAttributeValue GetValue (string key); + // [Obsolete ("Please use the subtype's method")] [iOS (9,0),Mac(10,11)] [Export ("setValue:forAttributeNamed:")] void SetValue (SKAttributeValue value, string key); +#endif #if !WATCH // Extensions from GameplayKit, inlined to avoid ugly static extension syntax @@ -376,6 +380,17 @@ partial interface SKEffectNode : SKWarpable { [NullAllowed] // by default this property is null [Export ("shader", ArgumentSemantic.Retain)] SKShader Shader { get; set; } + +#if XAMCORE_4_0 + [iOS (9,0), Mac(10,11)] + [Export ("valueForAttributeNamed:")] + [return: NullAllowed] + SKAttributeValue GetValue (string key); + + [iOS (9,0), Mac(10,11)] + [Export ("setValue:forAttributeNamed:")] + void SetValue (SKAttributeValue value, string key); +#endif } delegate Vector3 SKFieldForceEvaluator (/* vector_float3 */ Vector4 position, /* vector_float3 */ Vector4 velocity, float /* float, not CGFloat */ mass, float /* float, not CGFloat */ charge, double time); @@ -712,6 +727,17 @@ partial interface SKSpriteNode : SKWarpable { [TV (10,0)] [Export ("scaleToSize:")] void ScaleTo (CGSize size); + +#if XAMCORE_4_0 + [iOS (9,0), Mac(10,11)] + [Export ("valueForAttributeNamed:")] + [return: NullAllowed] + SKAttributeValue GetValue (string key); + + [iOS (9,0), Mac(10,11)] + [Export ("setValue:forAttributeNamed:")] + void SetValue (SKAttributeValue value, string key); +#endif } [Watch (3,0)] @@ -935,6 +961,17 @@ partial interface SKEmitterNode { [iOS (9,0)][Mac (10,11, onlyOn64 : true)] [Export ("particleRenderOrder", ArgumentSemantic.Assign)] SKParticleRenderOrder ParticleRenderOrder { get; set; } + +#if XAMCORE_4_0 + [iOS (9,0), Mac(10,11)] + [Export ("valueForAttributeNamed:")] + [return: NullAllowed] + SKAttributeValue GetValue (string key); + + [iOS (9,0), Mac(10,11)] + [Export ("setValue:forAttributeNamed:")] + void SetValue (SKAttributeValue value, string key); +#endif } [Watch (3,0)] @@ -1053,6 +1090,17 @@ partial interface SKShapeNode { [iOS (8,0), Mac (10,10)] [Export ("lineLength")] nfloat LineLength { get; } + +#if XAMCORE_4_0 + [iOS (9,0), Mac(10,11)] + [Export ("valueForAttributeNamed:")] + [return: NullAllowed] + SKAttributeValue GetValue (string key); + + [iOS (9,0), Mac(10,11)] + [Export ("setValue:forAttributeNamed:")] + void SetValue (SKAttributeValue value, string key); +#endif } [Watch (3,0)] @@ -2981,6 +3029,17 @@ interface SKTileMapNode : NSCopying, NSCoding [Export ("tileMapNodesWithTileSet:columns:rows:tileSize:fromNoiseMap:tileTypeNoiseMapThresholds:")] SKTileMapNode[] FromTileSet (SKTileSet tileSet, nuint columns, nuint rows, CGSize tileSize, GKNoiseMap noiseMap, NSNumber[] thresholds); #endif + +#if XAMCORE_4_0 + [iOS (9,0), Mac(10,11)] + [Export ("valueForAttributeNamed:")] + [return: NullAllowed] + SKAttributeValue GetValue (string key); + + [iOS (9,0), Mac(10,11)] + [Export ("setValue:forAttributeNamed:")] + void SetValue (SKAttributeValue value, string key); +#endif } [Watch (3,0)]