I try to call a method with a float parameter, but the method it receives is not Which I have sent.
is the code for the call (the last part of the actual call last line, [child Setfesdiraisn: direcao];):
direcao = dirRadianos * 180 / Mopiai; // direcao = Value which I send NSLog (@ "value sent:% f", direcao); // Log in what I am sending (CNNode * for children in SuperName) ([Responds to the child Tsechel: @Security Direction :)) [Child Set Direction: Direcau]; Here is the code for the method:
- (zero) setFaceDirection: (float) angle {nslog (@ "Value received:% f" , Angle); [The Association Set Rotation: - Angle]; } Here is the declaration of float variable directives
@ interface purse control node: CCND and LT; CCTticated Touch Delegate & gt; {// ... float directo; // ...} // ... @end Here is the output from NSLog:
Sent value: -16.699266 received value : 0.000000 sent and received values: -16.699301 price: 36893488147419103232.000000 price sent the -16.699625 price: -0.000000 value sent gain value 48.366463: 2.000000 value sent: 48.366451 value gain -36893488147419103232.000000 value sent receiving 48.366428 price: 0.000000 Price sent: 48.366444 Price received: -0.000000 Price sent to: 14.036244 Price received: -0.000000 Price sent to: 14.036 Went to get 238 values: -2.000000 value sent receiving 14.036201 Price: -36893488147419103232.000000 value sent receiving 14.036191 Price: -0.000000 value sent receiving 14.036273 Price: 36893488147419103232.000000 value sent receiving 12.528809 value transmitted 0.000000 Price: 12.528766 value obtained: 36893488147419103232.000000 value sent receiving 12.528852 price: -2.000000 value sent gain value 12.528863: 0.000000 value sent went to get -101.309929 value: -36893488147419103232.000000 value sent: -101.309860 Price Received: -2.000000 What am I doing wrong? I'm new to Objective-C. Thanks for anyone trying to help.
PS This works better if I use int instead of float, but still, some errors are still there.
I am experiencing the same problem when float values pass through those methods which only * I apply to files but not declared in .h files.
Example:
If you are using calling method:
- (zero) updatescreenshot: (float) value; {...}
Ensure that it has been declared in the respective interface file of that class. And make sure you do not have any warning: "The object can not be answered - (zero) updated screen ....."
Whatever function I gave to my interface file And it worked perfectly.
Comments
Post a Comment