updated C wrapper for MCPE