trigger_copyvalue

A trigger_copyvalue copies a key of one entity into a key of other entities, once for each trigger or again and
again while it is on. It can combine the copied value with the current one, as a
trigger_changevalue does.
Attributes
The entity also has these common keys:
- Naming and triggering: Name
netnameNames the entity to read: the first entity with this name, or !activator or !caller.
m_iszSrcValueNameNames the key to read.
targetNames the entities to write: the first entity with this name, or every entity with this name with Multiple destinations, or !activator or !caller.
m_iszDstValueNameNames the key to write.
m_iFloatConversionSets how the entity writes a number with decimals into a text key or a whole-number key: with a number of decimal places, or rounded.The 9 choices
6 decimal places (default) (0)dmgWith Constant, sets how many seconds pass between two copies.
0m_iszValueTypeSets the operation, as on a trigger_changevalue.The 27 choices
Replace (= new value) (0)m_trigonometricBehaviourSets the unit of the angle operations.
- Degrees (0) - Sin, Cos, Tan and Cot take the value in degrees, and Arcsin, Arccos, Arctan and Arccot give degrees, so the sine of 30 is 0.5
- Radians (1) - Both are in radians
Degrees (0)m_iAppendSpacesFor text, adds this many spaces after the result, up to 255.
0messageFires this target after each copy. It can be a name, !activator or !caller.
Flags
1Don't use XThe X of a vector stays as it is
2Don't use YThe Y of a vector stays as it is
4Don't use ZThe Z of a vector stays as it is
8ConstantA trigger turns the copying on or off. While the copying is on, the entity copies every Copy interval seconds
16Start onWith Constant, the copying is on from the start
32Invert target valueThe current value becomes negative before the operation
64Invert source valueThe copied value becomes negative before the operation
128Multiple destinationsThe entity writes every entity named in Destination entity, not only the first
Notes
- Each trigger copies once. With Constant, a trigger with On also turns the copying on, Off turns it off and Toggle switches it
- The entity writes nothing if a key names a model or a sound, or the destination key is
classnameorheadscale. It also writes nothing if the source entity, the source key or the destination key is missing. Withdeveloper 1set in the console, the console says so - Setups from Sven Co-op carry over, because the class names, key names, flags and operation numbers are the same
See also
trigger_changevalue- writes a value into a key- Changing keys - every operation and what can change
Changes since 1.38
trigger_copyvalueis new

