Jump to content

Cigi & Component behavior


photo

Recommended Posts

Hello,

I observe a different behavior of a IG Component depending on whether the component is solo or not in an entity. Let me explain:

Here is an excerpt from my ig_config.xml:

		<entity id="160" name="h160">
			<path>entities/h160/h160.node</path>
			<component id="34" name="rotor">
				<property>rotor</property>
				<parameter name="data1">rpm</parameter>
			</component>
			<component id="35" name="rotorwash">
				<property>rotorwash</property>
				<parameter name="data1">wind_percent</parameter>
				<parameter name="data2">sand_percent</parameter>
			</component>
		</entity>
		<entity id="260" name="rotorwash">
			<path>entities/rotorwash/rotorwash.node</path>
			<component id="35" name="rotorwash">
				<property>rotorwash</property>
				<parameter name="data1">wind_percent</parameter>
				<parameter name="data2">sand_percent</parameter>
			</component>
		</entity>

As you can see, the "rotorwash" component is solo for the entity #260 but not in the #160. What I observe at runtime (with Log::message) is that I can drive the wind_percent & sand_percent of the rotorwash through Cigi component control of entity #260, but not of #160.

(attached rotorwash component source, if it matters).

What am I doing wrong?

source.zip

Link to comment

Hi Amerio,

You need to specify the path to the node where the property is located.

<component id="35" name="rotorwash">
 <property>rotorwash</property>
 <node>path/to/node</node>
 <parameter name="data1">wind_percent</parameter>
 <parameter name="data2">sand_percent</parameter>
</component>

Note: NodeReference not supported in <node> tag.

Link to comment

I think this is it. But the property is indeed in a NodeReference. As you may have guessed, I made a NodeReference for the rotorwash effect that is embedded in many different helicopters, so they all share the same setup. So this isn't possible? Or should I do this differently?

Link to comment
  • 2 weeks later...
×
×
  • Create New...