Hm look at my example.
ActionToDoList.ForEach(item =>
{
AiAction action = GamePlay.gpGetAction(item); //<== you forget this line
if (action != null)
{
action.Do();
}
});
Second problem:
if ("G17".Equals(shortName) && active)
{
ActionToDoList.ForEach(item =>
{ //<== you forget this bracket
if (action != null)
{
action.Do();
}
});