• when you fuse a demon and the cathedral of shadows says "Whoops! Something went wrong" thats how you know its good

Code Snippets

you are free to use these code snippets in your ghosts, I just ask that I am credited under vita/yuyudev, with a link back to my site in your readme.

go back to main ukagaka dev page


Weather

please note that this code has been depreciated by Zi's weather station plugin, but I'm posting it for studying purposes. I use it in examples for my guides. this code makes use of html scraping and regex to display weather based on the user's zipcode. has options for current weather, forecast (10 day or hourly for current day), as well as the current moon phase.

download the code here


Tic Tac Toe

most of the following code wasn’t written by me - i’ve highlighted my additions. this code originally comes from a ghost named taromati, although I found it it zarla's hunter and smoker ghost. the original code has the ghost play perfectly, making it impossible for the user to win, so I added a small function to have the ghost make mistakes. specifically, I added the lines under the comments "determine if there are spaces left" and "tweak the chance as you feel like" I also commented on the original TTT code because I thought it was interesting!

download the code here


Higher or Lower

a simple minigame where the ghost pulls from a deck of cards, and the user guesses whether the next card will be higher or lower from the top card. call it using something like:

\![*]\q[Play HOL,holgame]

HOLPoints are used to give the player money, if your ghost has a money system. take them out if you aren’t using one. also, you’ll probably need to adjust the back menu portions of the code.

I used two envelopes to keep the code a little neater. add these to your word dic.

oldcarddisp{

    "\f[color,%(oldcard[3])]%(oldcard[2])%(oldcard[0])\f[color,default]"

}

newcarddisp {

    "\f[color,%(card[3])]%(card[2])%(card[0])\f[color,default]"

}

download the code here


go back to main ukagaka dev page