Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Bug / Crash  Can't add script behavior ObiActor
#2
(15-11-2021, 12:50 AM)Tancy Wrote: I'm trying to add a component for Obi Particle Attachment, but after I click this component, it shows "Invalid operation: Can't add script behavior ObiActor. The script class can't be abstract."  Huh

Other information if in need: 
Unity Version: 2020.3.14
Obi Rope Version: 6.2

Indeed, ObiActor is an abstract class, used as a base for ObiRope and ObiRod. You can't add it to an object because it doesn't make any sense.

Probably you're trying to add a ObiParticleAttachment (which requires the object to have any ObiActor subclass) to an object that has neither a ObiRope component or an ObiRod component. So Unity is telling you that it can't decide for you which component to add, and it cannot add their base class because it's abstract.

Either add a ObiRope or ObiRod component, then add a ObiParticleAttachment to attach them. From the manual:
http://obi.virtualmethodstudio.com/manua...ments.html

Quote:Quite often you´ll want to "glue" part of a ObiActor (rope, cloth or softbody) to another object. This can be easily achieved by using an attachment.
Reply


Messages In This Thread
Can't add script behavior ObiActor - by Tancy - 15-11-2021, 12:50 AM
RE: Can't add script behavior ObiActor - by josemendez - 15-11-2021, 08:45 AM