1 / 15

GML Key Ideas

GML Key Ideas. GML. GML : Gamemaker Programming Language Looks like java/C++ More power than drag and drop. GML Getting Started. // starts a comment Computer ignores rest of line. GML Getting Started. = is assignment Makes/sets a varaible on left to value on right.

clark-wall
Download Presentation

GML Key Ideas

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. GML Key Ideas

  2. GML • GML : Gamemaker Programming Language • Looks like java/C++ • More power than drag and drop

  3. GML Getting Started // starts a comment Computer ignores rest of line

  4. GML Getting Started = is assignment Makes/sets a varaible on left to value on right

  5. GML Getting Started name() indicates a function call Does some work for us, gives back an answer

  6. GML Getting Started name() indicates a function call Anything inside ( ) are arguments - extra information to help function do its job Help file documents functions

  7. GML Getting Started • if makes a decision • { } surround block that depends on decision • Else means otherwise do this

  8. GML Variables • A variable set in GML can be used in drag & drop:

  9. Global • Each object has its own variables • Hits in bad guy different than hits in hero

  10. Global • Each object has its own variables • Hits in bad guy different than hits in hero

  11. Global • Each object has its own variables • Hits in bad guy different than hits in hero

  12. Global • Each object has its own variables • Hits in bad guy different than hits in hero

  13. Global • This would be an error:

  14. Global • A variable titled global.XXXX is shared • lasts the entire game • available from everywhere

  15. Global • A variable titled global.XXXX is shared • lasts the entire game • available from everywhere

More Related