Ok. I’m going to run with the assumption that your variables are in the list in some kind of order, so that you know what each one is, and what type it should be? Example; if you have size (int64), color (string), position x (float), position y (float), position z (float), you might have a list like “202130”, “blue”, “123.23”, “123.35”, “022.34”, right?
Firstly you need to get outside data (your dictionary) accessible by a system. I don’t know a good way to do this yet (see here: DOTS Change Material within System apart from just using static variables. Let’s assume you have a static variable for your dictionary, which is populated before your system will attempt to run.
Your system will use an EntityCommandBuffer to instantiate entities and call AddComponent etc?
List<string> variables = myStaticDictionary[myIndex];
var newEntity = ecb.CreateEntity(yourArchetype);
var translation = new Translation {
Value = new float3(float.Parse(variables[4]), float.Parse(variables[5]), float.Parse(variables[6]))
};
ecb.SetComponent(newEntity, translation);
Is that what you’re trying to do? It seems fairly simple. Or is the data dynamic, depends on the entity type being constructed, and you need to dynamically create different kinds of IComponentData structs and set different variables on them depending on the type?