Refactored code to use arrays instead of structures. Instruction size too large now