# Save Data Table Value (Actor)

Grammar — Save value as name in the scope|Global/Local data table
FlagsNative | Action

Saves an actor value into a data table. Data tables allow you to store and recall values using a string identifier. If you save a data table value using a string identifier that already exists, you will overwrite the old value, even if it is a different data type than the value you are saving.

# Arguments

  • bool<preset::DataScope> — Scope
  • string — Name
  • actor — Value

Returns — void

native void DataTableSetActor(
	bool global,
	string name,
	actor val,
);

Category: Data Table / Save Value

# Examples

mods/heroesdata.stormmodbase.stormdata/TriggerLibs/HeroesLib.galaxy:3319

    // Automatic Variable Declarations
    // Implementation
    DataTableSetActor(true, libCore_gf__UnitDataName(libCore_ge__UnitDataType_Actor, lp_unit, lp_index), lp_actor);
}

mods/swarm.sc2modbase.sc2data/TriggerLibs/SwarmLib.galaxy:152

    // Automatic Variable Declarations
    // Implementation
    DataTableSetActor(true, libHots_gf__UnitDataName(libHots_ge__UnitDataType_Actor, lp_unit, lp_index), lp_actor);
}