Custom levels in chapter 4

18 replies [Last post]
Joined: 09/03/2012

Can someone give me a quite easy to understand tutorial of how to put my custom level in chapter 4 to display ish signs, yes I have seen the mod but I just don't want to tell people to download another mod just to play mine. Thanks. :)and yes I know i am a newbie.

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529

Joined: 07/05/2011

My new level Central Processing Unit would be a good sample for you. And I'm not good at explaining those complex things in English. Wink

Joined: 09/03/2012

I really like the level but I dont know what you did mabye you could give me the XML with the commands?

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529

Joined: 08/06/2010

Just copy the file /merge/islands/island4.xml.xsl from that goomod, and replace the level name and description and such.

Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.

Joined: 12/23/2010

Hey Snapper, in the future please try to keep all related discussion in one thread. You didn't have to make a new one for this since you already asked for this in your other one.

Joined: 09/03/2012

Ok puggsoy, Thanks everyone for your help.

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529

Joined: 07/05/2011

And to make your level appear in the Chapter 4, you need to generate merge/res/levels/island4/island4.scene.xsl and island4.level.xsl. You need to put your level name and text in the text.xml and reference it in the island4.xml.xsl.

Joined: 09/03/2012

I put my level in and everything worked but when I click on chapter 4 it just stays on meanwhile and comes up with fatal error the type is a mod too.

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529

Joined: 07/05/2011

It seems there's something error with your XSL. Check it.

Joined: 09/03/2012

Which one and what could be wrong?
Here is what i wrote in res/levels/island4/island4scenexml.xsl:

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:output encoding="UTF-8"/>
  <!--Select all nodes-->
  <xsl:template match="node()|@*">
    <xsl:copy>
      <xsl:apply-templates select="node()|@*"/>
    </xsl:copy>
  </xsl:template>
  <xsl:template match="/scene/rectangle[@id='bin']">
    <xsl:copy>
      <xsl:apply-templates select="node()|@*"/>
    </xsl:copy>
    <button alpha="1" colorize="255,255,255" depth="1" id="lb_VirtualCliffHanger" onclick="pl_VirtualCliffHanger" onmouseenter="ss_VirtualCliffHanger" onmouseexit="hs_VirtualCliffHanger" over="IMAGE_SCENE_ISLAND4_LEVELMARKER_ISH_A_OVER" rotation="-3.49" scalex="0.951" scaley="1.084" up="IMAGE_SCENE_ISLAND4_LEVELMARKER_ISH_A_UP" x="-170.5" y="623.549"/>
    <SceneLayer alpha="1" anim="ocdFlagWave" animspeed="1" colorize="255,255,255" depth="0.2" id="ocd_VirtualClifHanger" image="IMAGE_SCENE_ISLAND4_OCD_FLAGISH" name="OCD_flagIsh" rotation="-4.77" scalex="1" scaley="1" x="-159.34" y="671.18"/>
  </xsl:template>
</xsl:stylesheet>
 
Here is what I wrote in res/islands/island4xml.xsl:
 
<code>
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:output encoding="UTF-8"/>
  <!--Select all nodes-->
  <xsl:template match="node()|@*">
    <xsl:copy>
      <xsl:apply-templates select="node()|@*"/>
    </xsl:copy>
  </xsl:template>
  <xsl:template match="/island/level[@id='HelloWorld']">
    <xsl:copy>
      <xsl:apply-templates select="node()|@*"/>
    </xsl:copy>
    <level id="VirtualCliffhanger" name="LEVEL_NAME_VirtualCliffHanger" text="LEVEL_TEXT_VirtualCliffHanger" ocd="balls,22" depends="HelloWorld"/>
  </xsl:template>
</xsl:stylesheet>
 
Can you see whats wrong? 

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529

Joined: 07/05/2011

You should name it island4.scene.xsl.
And have you define LEVEL_NAME_VirtualCliffHanger in text.xml?
I recommend you to use capital letters, change it to LEVEL_NAME_VIRTUALCLIFFHANGER.

Joined: 09/03/2012

Ok, thanks I will try that. Smile

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529

Joined: 09/03/2012

Still wont work what is wrong with it? Can I email the goomod to you so you can see whats wrong? if yes what is you're email adress if not what do I do to make it work.
Edit: sorry did I just double post forgot about that Sad

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529

Joined: 07/05/2011

OK, email me at mygodstudio (at) gmail (dot) com

EDIT:
Three problems detected:

  1. id="VirtualCliffhanger" in island4.xml.xsl.
  2. id="ocd_VirtualClifHanger" in island4.scene.xsl.
  3. Two texts of sign post is missing.

And I found rectangle[@id="bin"] matched 5 rectangles. So I improved the XSL.

island4.xml.xsl:

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:output encoding="UTF-8"/>
  <!--Select all nodes-->
  <xsl:template match="node()|@*">
    <xsl:copy>
      <xsl:apply-templates select="node()|@*"/>
    </xsl:copy>
  </xsl:template>
  <xsl:template match="/island/level[@id='HelloWorld']">
    <xsl:copy>
      <xsl:apply-templates select="node()|@*"/>
    </xsl:copy>
    <level id="VirtualCliffHanger" name="LEVEL_NAME_VIRTUALCLIFFHANGER" text="LEVEL_TEXT_VIRTUALCLIFFHANGER" ocd="balls,22" depends="HelloWorld"/>
  </xsl:template>
</xsl:stylesheet>

island4.scene.xsl:

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:output encoding="UTF-8"/>
  <!--Select all nodes-->
  <xsl:template match="node()|@*">
    <xsl:copy>
      <xsl:apply-templates select="node()|@*"/>
    </xsl:copy>
  </xsl:template>
  <xsl:template match="/scene/buttongroup/button[@id='lb_HelloWorld']">
    <xsl:copy>
      <xsl:apply-templates select="node()|@*"/>
    </xsl:copy>
    <button alpha="1" colorize="255,255,255" depth="1" id="lb_VirtualCliffHanger" onclick="pl_VirtualCliffHanger" onmouseenter="ss_VirtualCliffHanger" onmouseexit="hs_VirtualCliffHanger" over="IMAGE_SCENE_ISLAND4_LEVELMARKER_ISH_A_OVER" rotation="-3.49" scalex="0.951" scaley="1.084" up="IMAGE_SCENE_ISLAND4_LEVELMARKER_ISH_A_UP" x="-170.5" y="623.549"/>
  </xsl:template>
  <xsl:template match="/scene/SceneLayer[@id='ocd_BulletinBoardSystem']">
    <xsl:copy>
      <xsl:apply-templates select="node()|@*"/>
    </xsl:copy>
    <SceneLayer alpha="1" anim="ocdFlagWave" animspeed="1" colorize="255,255,255" depth="0.2" id="ocd_VirtualCliffHanger" image="IMAGE_SCENE_ISLAND4_OCD_FLAGISH" name="OCD_flagIsh" rotation="-4.77" scalex="1" scaley="1" x="-159.34" y="671.18"/>
  </xsl:template>
</xsl:stylesheet>

Joined: 09/03/2012

I installed it and it came up with a error saying: addin format exception in Virtualcliffhanger:
error transforming res/islands/island4.xml.xsl:
Could not compile stylesheet (com.goofans.gootoolv)
HELP i am so sick of error after error:(

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529

Joined: 07/05/2011

That's weird. It works well for me. Check if you copied them all.

Joined: 09/03/2012

Do you think you can email me the working goomod if not what can I do?
My Email is Snapper576(at)gmail(dot)com
Edit:As soon as I get a working goomod you are so going in additional authors! Wink

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529

Joined: 07/05/2011

Emailed.

Joined: 09/03/2012

Thank you so much I put the sign text back in and it is all working i am going to upload it know thanks again Smile

Check out my Awesome THREE Levels!!!!!!!!!
http://goofans.com/user/12529