My cash always zero

Why is my cash always zero? I generated some money through the API.CreateMoneyPickups() function, but when I picked up the money, my cash was still zero