so in the past 3 hours iv'e been looking for a way to insert lua commands into cheat engine. by that to make a simple trainer for fivem game.

The commands:

TriggerServerEvent('esx_drugs:startHarvestCoke')

TriggerServerEvent('esx_slotmachine:sv:2',100000)

i saw that people inserting there commands in command prompt, i thought about doing it in cheat engine inorder to make it trainer... so i had few errors that couldn't gave me silense iv'e tryied to search for solution on google but i couldn't find...

Errors: undefined lua error. (screenshot: https://prnt.sc/k6vs22) Error:attempt to call a nil value. (screenshot:http://prntscr.com/k6vtui) Can someone tell me how to properly do that?

best regards, Thanks in advance.