Read a game's files
klyo_game_filesYour game's files to read, without a ZIP from the owner. Target: a game's slug or a waiting-room package's upload_id. Without path you get the list (path, size, whether it is text, hash); with path, the content of one text file, up to 200 KB at a time (read further with from_line, narrow with lines); with changes: true, what changed in the waiting version compared with the version players have: how much code, visuals and sound (the same numbers the studio shows at “Release”) and the line differences. When the game has a waiting version (a workshop from klyo_game_patch or a new package) you read that one; otherwise the version players are playing. Pass the hash field as expected_hash to klyo_game_patch. Images and sounds are not returned as content, only their size. Read-only.
Examples: • Show the files of my game czworki • Read js/gra.js from lantern-thief starting at line 200 • What changed in the waiting version of slice-rush?
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | File to read, relative to the game, for example js/gra.js. Without this field you get the file list. | |
| slug | No | Game address, for example lantern-thief (from klyo_my_games). Give this or `upload_id`. | |
| lines | No | Maximum number of lines (reading stops at 200 KB anyway). | |
| changes | No | Together with the list: what changed in the waiting version compared with the version players have. | |
| from_line | No | Line to start reading from (default 1). | |
| upload_id | No | A waiting-room package (from klyo_upload_package), when there is no game yet. |