Closed ajw120 closed 4 years ago
@ebeshero @alnopa9 @KSD32
@ajw120 I can help from here at my house!
If you push the code you're working we can help debug it, etc.
2 problems:
Xslt: I can't figure out how to match onto an attribute stored in a conditions element as seen in the Waterfall.xsl file stored in the XSLT folder.
Javascript: We have a .png of an image of the world map of Undertale. We're trying to use javascript to make it that when you hover over a certain part of the map it lights up, and then when you click on it it takes you to the dialogue we have for the area of the map.
@Bennediction On XSLT: Matching on attributes can be tricky! It might be better to make the template match on the <conditions>
element that's hosting the attribute, and then work with the attribute inside the template rule.
@Bennediction To make JavaScript work on your game map image, you need to do something called image-mapping first. We did this on the Pokemon project, for example: http://pokemon.newtfire.org/
It's a bit of work to plan out. For Pokemon, when you click on an area of the map, it brings up a window to the right (they used CSS flex boxes to organize the page for that). For you, I think you just want the image map to contain clickable links, so they open new pages, right?
Let me hunt up some good resources for creating an image map--and I'll open a new issue for that on your repo.
One thing about that, for each individual condition I was going to make the xslt output the condition before the dialogue.
example:
1 times spared, bandana equipped Sans: dialogue
my plan for this was to match on each attribute and then write the code such
<b>Equipped: <xsl:value-of select="@equipped"/></b>
</span>
<xsl:apply-templates></xsl:apply-templates>
</xsl:template> ```
also yes, that is exactly what we want to do for javascript
@Bennediction Can you open a new issue on this repo just to focus on the XSLT? Also, I'm not clear on what the problem is exactly--and it'll help to point me to the whole XSLT file that you're working on. (If you can do that in the new issue, it'll help me to help you.
Also, I'm bundling up some resources we used for the Pokemon project on image mapping. It's not difficult to do, but you need to see how it works to make clickable code that refers to areas of an image.
just looked at my code again and figured out the XSLT, no problems there anymore
Hi!
Robby, Ben and I are together currently trying to get work done for the project. We were wondering if anyone would be available to help us with JavaScript today?
Thank you!