Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  how to remove fixed state
#6
(14-02-2019, 09:12 AM)Richard Wrote: I copied code like the image and added. Some two errors happened."Assets\AddConstraints.cs(14,50): error CS0411: The type arguments for method 'Component.GetComponent<T>()' cannot be inferred from the usage. Try specifying the type arguments explicitly." and "Assets\AddConstraints.cs(15,76): error CS0021: Cannot apply indexing with [] to an expression of type 'IEnumerable<ObiConstraintBatch>'". How can I solve the errors.


Hi,

Sorry, the < and > signs weren't rendering properly in the page. We've corrected it. The code should be:

Code:
ObiDistanceConstraints constraints = GetComponent<ObiDistanceConstraints>();
     ObiDistanceConstraintBatch batch = (ObiDistanceConstraintBatch)constraints.GetFirstBatch();
Reply


Messages In This Thread
how to remove fixed state - by Richard - 14-02-2019, 02:43 AM
RE: how to remove fixed state - by josemendez - 14-02-2019, 08:11 AM
RE: how to remove fixed state - by Richard - 14-02-2019, 08:38 AM
RE: how to remove fixed state - by josemendez - 14-02-2019, 08:52 AM
RE: how to remove fixed state - by Richard - 14-02-2019, 09:12 AM
RE: how to remove fixed state - by josemendez - 14-02-2019, 09:19 AM
RE: how to remove fixed state - by Richard - 14-02-2019, 10:04 AM
RE: how to remove fixed state - by josemendez - 14-02-2019, 10:28 AM
RE: how to remove fixed state - by Richard - 14-02-2019, 10:32 AM
RE: how to remove fixed state - by josemendez - 14-02-2019, 10:51 AM
RE: how to remove fixed state - by Richard - 14-02-2019, 11:14 AM
RE: how to remove fixed state - by josemendez - 14-02-2019, 11:21 AM
RE: how to remove fixed state - by josemendez - 14-02-2019, 11:25 AM
RE: how to remove fixed state - by Richard - 14-02-2019, 11:37 AM
RE: how to remove fixed state - by josemendez - 14-02-2019, 12:10 PM
RE: how to remove fixed state - by Richard - 14-02-2019, 12:20 PM
RE: how to remove fixed state - by josemendez - 14-02-2019, 12:28 PM
RE: how to remove fixed state - by Richard - 14-02-2019, 12:47 PM
RE: how to remove fixed state - by josemendez - 14-02-2019, 12:55 PM
RE: how to remove fixed state - by Richard - 14-02-2019, 01:03 PM
RE: how to remove fixed state - by Richard - 14-02-2019, 04:05 PM
RE: how to remove fixed state - by josemendez - 14-02-2019, 04:18 PM
RE: how to remove fixed state - by Richard - 14-02-2019, 04:46 PM
RE: how to remove fixed state - by Richard - 14-02-2019, 10:58 AM
RE: how to remove fixed state - by josemendez - 14-02-2019, 11:04 AM