New York's attorney general has launched a lawsuit against Valve, alleging its loot boxes are illegal gambling that endangers young gamers.