There are number of commands and actions you can execute in the game, these mostly control the GUI and where a button takes you, but there are other commands which perform specific actions like setting flags in the players profile.
Each command seems only to work at the appropriate stage ofthe game.
Commands available in MapWorldView
Actions
These commands are normally used in the onclick event of a button.
island{number} : Go to island{number}
selectprofile : Display the profile select screen.
credits : Show the credits movie
quit : Exit the game
wogcorp : Play the active WoG Corp level
Display commands
These commands are normally used in the onmouseenter and onmouseexit events of buttons
island{number}showtext : Show the CHAPTERx_NAME and CHAPTERx_DESCRIPTION text
islandhidetext : Hide the Chapter Name and Description Text
wogcorpshowtext : Show the Name and Description for WoG Corp
wogcorpdshowtext : Show the Name and Description for WoG Corp Destroyed
showtooltip : Show the text specified in the tooltip attribute
hidetooltip : Hide the tooltip
Commands available in Map Levels (Chapters / Islands)
Actions
These commands are normally used in the onclick event of a button.
pl_{levelname} : Play the level {levelname}
pm_{moviename} : Play the movie {moviename}
wogcorp_from_island : Play the WoG Corp level, but return to this island when finished.
zoomout : In effect "back".. return to the MapWorldView
Display commands
These commands are normally used in the onmouseenter and onmouseexit events of buttons
ss_{levelname} : Show the Level Name and Number of Goos collected for {levelname}
hs_{levelname} : hide the level name and number of goos collected
Commands available in / after levels
Profile Flags
The commands are used in the onclick event of a button, or in the oncomplete attribute of the <level> in the island.xml
oncomplete actions are executed when the level is "complete".
If the level is "normal" (ie. Pipe collecting Goos) the command is executed when the drop-down continue handle is clicked. ie before the scores are displayed.
If the level has any other type of endcondition, the command is executed when that condition is met.
unlockwogcorp : Set the WoG Corp Unlock Profile Flag (2)
This controls the enabled / disable state of the wogcorp_intact button in MapWorldView
undeletenow : Set the WoG Corp Destroyed Profile Flag (4)
See Special Levels - Undelete Pill for details.
NB: Executing this command in the "oncomplete" does work, however there is then a 20second delay before another button can be pressed.
unlockwhistle : Set the Whistle Found Profile Flag ( 8 )
The whistle becomes active immediately.
accepttermsandconditions : Set the Terms Accepted Profile Flag (16)
This unlocks the Deliverance level see Special Levels - Deliverance
Other Actions
restartlevelyes and restartlevelrightnow
These both appear to do the same thing, which is immediately restart / retry the level.
expandchapter4 : This command appears in the island4.xml as an oncomplete for the Hello World! level. However it does not appear in the game exe, and does nothing.
- Printer-friendly version
- Login to post comments
Thu, 10/07/2010 - 20:14
Where did you find pm_ ? It seems useful...is there also a way to launch another level when you beat one? (oncomplete="pl_levelname")?
Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.
Thu, 10/07/2010 - 20:15
Found another...expandisland4 in HelloWorld. Any ideas?
Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.
Fri, 10/08/2010 - 03:44
pl_ is an island / Map Level command... oncomplete is specified in the island, but it's executed in the level..
so oncomplete="pl_..." doesn't work.
pm_: I found the string lurking in the exe, and took a guess at what it meant... and was right!
expandchapter4 is another of these "appear in the XML but doesn't do anything" things.
So I didn't include it. Maybe I should, then at least people know I didn't miss it.
Tue, 07/03/2012 - 23:11
Where is
showmom
?EDIT:
I tried
oncomplete=undeletenow
(edit it in island.xml.bin) in a custom level and the game crashed when I completed the level. Any ideas?| Things I made | And even more |
Wed, 07/04/2012 - 07:51
Did you already undelete everything?
Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.
Wed, 07/04/2012 - 08:14
Yes... No...
What actually do you mean? The level I modified is ending with pipes and I have already finished Deliverance.
| Things I made | And even more |
Wed, 07/04/2012 - 16:09
If you have finished Deliverance all the spam is undeleted already, therefore it can't get undeleted again, what makes the game crash. Try it with a fresh profile.
on the run | keep on running | two-stroke-engine
Fri, 07/06/2012 - 00:37
OK. I will try that.
One more question here.
hs_{levelname} : hide the level name and number of goos collected
EDIT: The game still crashed with a clean player. The level I modified is Going Up.
EDIT again: Interestingly, oncomplete=restartlevelyes, restartlevelrightnow, quit all works, but the level record will be saved.
EDIT once again: oncomplete=showmom works too after you destroyed WoGCorp! Unfortunately you can't click ok and you can't do anything.
EDIT twice again: onclick=zoomout, undeletenow, unlockwhistle, accepttermsandconditions in a normal level all works.
| Things I made | And even more |
Sat, 07/07/2012 - 13:55
Forget what I said. I just shot out in the dark without thinking about it and totaly missed.
Now reconsidering it I think oncomplete=undeletnow crashes because undeletenow is triggering a message which ends the level deliverence. (endonmessage END_DELIVERANCE)
Before that It also adds the letterbox bars, prevents the player of interacting with goo and makes some camera movements in the level itself.
This can't happen if the level is already completed.
Just what I 'm thinking, I might be wrong again.
on the run | keep on running | two-stroke-engine
Sat, 07/07/2012 - 18:11
Okay... I hope
showmom
will be added to this book page.And could someone explain why doesn't the game display moves used in the last original level?
| Things I made | And even more |
Mon, 07/09/2012 - 08:13
After toying around with onclick=fullversion, it appears that only works in the demo, not the full game. Which is interesting, since the demo .exe behaves like the original .exe when the "res" folder is copied over. I reckon that was added to the demo version, but never the original. Apart from that and file size (The demo is 0.01 MB smaller), I think the demo and full game executables are identical.
IRC | Chapter Tutorial | Reference Guide
Fri, 07/27/2012 - 19:40
Hey! @wogfan found lots and lots of commands in res/scenes!
Here are them: continue, submit_and_flush, update_submit_level_stats (weirdly latch is set to true), showocdcriteria, backtoisland, resumegame.
EDIT: Found some interesting stuffs in iOS version:
And something in Android:
| Things I made | And even more |
Sat, 07/28/2012 - 10:07
enablemouse?! That sounds interesting.
Steam
Sun, 07/07/2013 - 12:48
Just discovered that onclick="quit" works in any level as well.
Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.
Sun, 07/07/2013 - 20:52
Actually these commands work in any level: showtooltip, hidetooltip, restartlevelyes, restartlevelrightnow, quit, zoomout, undeletenow, unlockwhistle, accepttermsandconditions, showmom, continue, showocdcriteria, backtoisland.
But using
@onclick="quit"
in a level is not a good choice.| Things I made | And even more |
Mon, 07/08/2013 - 05:15
I used it in Sleeping Gooballs at first, but I replaced it with restartlevelrightnow. I also wonder what will happen if I click a button which delete my profile in a level, does it work?
Steam
Mon, 07/08/2013 - 07:49
I don't know, but I'm not willing to try it. Anyone interested?
I'm using these to improve my islandUi with lots more commands.
Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.
Tue, 04/09/2019 - 07:58
While looking trough the exe i found the command 'destroycotm', i think it has something to do with the unused chapter 6. is it possible to add this to the list of commands?
Benjers Squared: now with more sodium.