Skip to main content

Basic Example

I'll go through a quick walkthrough to get you familiar with the end-to-end flow of ModScripting.

Changing Memeorang Man's Gravity

  1. First, open the Level Builder, and open the level options panel:

  2. Enable experimental features:

  3. Exit the level options panel, then find and click on Memeorang Man. Then click the blue script button:

  4. Create a new ModScript, and you'll see something like this:

  5. Open the API Reference, and find the gravityScale field of the Player's Rigidbody2D component:

  6. Click the Copy Example button:

  7. Paste that example into the script editor, and add the line memeorangManRigidbody2D.gravityScale = 0.069 at the end to change the gravity:

  8. Now exit the ModScript panel, and enter play mode. You should see low gravity while jumping with Memeorang Man. Congratulations.