15 {
16 GardenBase garden_base;
18 if ( Class.CastTo(garden_base, target.GetObject()))
19 {
20 Slot slot;
21
22 array<string> selections = new array<string>;
23 garden_base.GetActionComponentNameList(target.GetComponentIndex(), selections);
24 string selection;
25
26 for (int s = 0; s < selections.Count(); s++)
27 {
28 selection = selections[s];
29 slot = garden_base.GetSlotBySelection( selection );
30 if (slot)
31 break;
32 }
33
34 if ( slot && slot.GetPlant() )
35 {
38 {
42 {
44 }
45 else
46 {
48 }
49 if ( action_data.m_MainItem )
50 {
52 }
54 {
56 }
57
59 }
60 }
61 }
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87 }
void ActionTarget(Object object, Object parent, int componentIndex, vector cursorHitPos, float utility, string surfaceName="")
float m_PlantNeededSpraying
ref Param1< float > m_SpentUnits
float m_QuantityUsedPerSecond