Logitech Gaming Software Script Help Two Macros into One

I need a hand making these two scripts work together. Currently only the bottom script will work. I am trying to merge two scripts together.