improved menu, moved email functionality to a separate file
This commit is contained in:
139
ghost/master/email.dic
Normal file
139
ghost/master/email.dic
Normal file
@ -0,0 +1,139 @@
|
||||
//**** Mail Checking *******************************************************************
|
||||
|
||||
/**
|
||||
* Answer to check email prompt
|
||||
* reference2 - name of the server being checked
|
||||
*/
|
||||
OnBIFFBegin
|
||||
{
|
||||
"\0\s[0]Ага, предоставь это Люме.\e"
|
||||
|
||||
"\0\s[0]Почта? Сейчас проверю.\e"
|
||||
|
||||
"\0\s[0]\f[name,Hymmnos,hymmnos.ttf]\f[height,16]j.w. mea ADDR => \f[default]\n\n%(reference2)\e"
|
||||
}
|
||||
|
||||
/**
|
||||
* Email number successfully retieved.
|
||||
* reference0 - number of emails
|
||||
* reference2 - name of the server being checked
|
||||
* reference7 - the senders and titles delimited by C_BYTE1 characters
|
||||
* see: https://ukagakadreamteam.github.io/ukadoc/manual/list_shiori_event.html
|
||||
*/
|
||||
OnBIFFComplete
|
||||
{
|
||||
if reference0 == 0
|
||||
{
|
||||
"\0\s[0]%(username), в ящике пусто. Наверное лучше проверить позже.\e"
|
||||
|
||||
"\0\s[0]Ничего нового.\e"
|
||||
}
|
||||
elseif reference0 > 0 && reference0 < 13
|
||||
{
|
||||
"\0\s[0]Ответ от сервера получен, пришло %( OnCorrectEmailNumberSuffix( reference0 % 10 ) ). Посмотрим?"
|
||||
|
||||
"\0\s[0]Передача данных завершена. На сервере %( OnCorrectEmailNumberSuffix( reference0 % 10 ) )."
|
||||
|
||||
"\0\s[0]Письма из Хогвартса там всё ещё нет, но есть %( OnCorrectEmailNumberSuffix( reference0 % 10 ) ) новых писем. Сейчас зачитаю..."
|
||||
|
||||
--
|
||||
|
||||
"\n\n\![set,autoscroll,disable]\_q%( OnPrintMailAsList( reference7 ) )\e"
|
||||
}
|
||||
elseif reference0 > 12 && reference0 < 100
|
||||
{
|
||||
"\0\s[0]%( OnCorrectEmailNumberSuffix( reference0 % 10 ) ), довольно много. Давай не будем читать каждое.\e"
|
||||
}
|
||||
elseif reference0 > 99
|
||||
{
|
||||
"\0\s[0]%( OnCorrectEmailNumberSuffix( reference0 % 10 ) )? %(username), давно ты в последний раз проверял свой почтовый ящик?\e"
|
||||
|
||||
"\0\s[0]%( OnCorrectEmailNumberSuffix( reference0 % 10 ) ). Наверное, тебе всё таки стоит начать их читать.\e"
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Dialogs in case Lyuma cannot fetch email for some reason
|
||||
* reference[0] - error code
|
||||
*/
|
||||
OnBIFFFailure
|
||||
{
|
||||
if reference0 == "timeout" //If the connection times out.
|
||||
{
|
||||
"\0\s[0]Сервер не отвечает, %(username).\e"
|
||||
|
||||
"\0\s[0]Сервер не отвечает, нет смысла ждать дальше.\e"
|
||||
}
|
||||
/*
|
||||
* If the account blocks the ghost from accessing it.
|
||||
* In gmail it might happen if POP access is not allowed in the account settings, or Gmail has not proccessed POP access request yet.
|
||||
* might need to wait or go to Gmail > all settings > pop/imap forwarding
|
||||
*/
|
||||
elseif reference0 == "kick"
|
||||
{
|
||||
"\0\s[0]Сервер отказал в доступе. Люма что-то сделала не так?\e"
|
||||
}
|
||||
elseif reference0 == "defect" // If the information put into the POP menu is wrong.
|
||||
{
|
||||
"\0\s[0]Не получается. С этим аккаунтом что-то не так. Ты точно всё правильно настроил в настройках POP?\e"
|
||||
}
|
||||
else
|
||||
{
|
||||
"\0\s[0]Не работает. Вот, что говорит: '%(reference[0])'\e"
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Function that prints a string of email senders and titles as unordered list
|
||||
* _argv[0] - a string of entries in format "SenderName <Sender@email.eg> Message title" separated by SOH(U+0001) chars
|
||||
* returns formatted headers as list
|
||||
* : last modifier will ensure only last return candidate gets returned
|
||||
*/
|
||||
OnPrintMailAsList : last
|
||||
{
|
||||
_headers = SPLIT(_argv[0],"")
|
||||
_letters = ""
|
||||
_headerRegex = "\s*(\S+)\s*<([^>]+)>\s(.*)" // Name <email@example.com> Message title
|
||||
|
||||
foreach _headers; _header
|
||||
{
|
||||
if RE_MATCH(_header,_headerRegex) > 0
|
||||
{
|
||||
_letterTitle = SHIORI3FW.EscapeAllTags(RE_GETSTR[3])
|
||||
if RE_GETSTR[3] == ""
|
||||
{
|
||||
_letterTitle = "<не указано>"
|
||||
}
|
||||
_letters += "От: %(RE_GETSTR[1]) \nАдрес: %(RE_GETSTR[2]) \nТема: '%(_letterTitle)'\n\n"
|
||||
}
|
||||
}
|
||||
|
||||
_letters // returning formatted string
|
||||
}
|
||||
|
||||
/**
|
||||
* Function to get a correct spelling for the given given number of emails
|
||||
* _argv[0] - number of emails recieved
|
||||
* returns - <number> письмо(-сьма,-сем)
|
||||
*
|
||||
* NOTE: It's not placed in word.dic because its only useful for the function above, there is little use in adding it to the global envelope dictionary
|
||||
* furthermore its more of a function than a dictionary
|
||||
*/
|
||||
OnCorrectEmailNumberSuffix
|
||||
{
|
||||
case _argv[0]
|
||||
{
|
||||
when 1
|
||||
{
|
||||
"одно новое письмо"
|
||||
}
|
||||
when 2-4
|
||||
{
|
||||
"%(_argv[0]) новых письма"
|
||||
}
|
||||
when 0,5,6,7,8,9
|
||||
{
|
||||
"%(_argv[0]) новых писем"
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -184,140 +184,6 @@ OnVanished
|
||||
"\0\s[0]Пока, %(reference0).\e"
|
||||
}
|
||||
|
||||
|
||||
//**** Mail Checking *******************************************************************
|
||||
//The next set of functions have to do with checking your email. This function is a slippery little thing - I've had people test it following my directions and have it work, but I've never actually gotten it to report back the right amount of emails myself. Very frustrating. But perhaps you'll have more luck with it, haha.
|
||||
//Girl and Triangle can't actually read your email, they can just tell you how many emails you have. I've seen ghosts that can read the HEADERS of email, but I still don't think ghosts can actually display the contents of an email. You should be using your actual email client for that. It's still kind of a neat feature though.
|
||||
|
||||
/**
|
||||
* When you first tell the ghost to check your email. An intro statement, if you will.
|
||||
* reference2 - name of the server being checked
|
||||
*/
|
||||
OnBIFFBegin
|
||||
{
|
||||
"\0\s[0]Ага, предоставь это Люме.\e"
|
||||
|
||||
"\0\s[0]Почта? Сейчас проверю.\e"
|
||||
|
||||
"\0\s[0]\f[name,Hymmnos,hymmnos.ttf]\f[height,16]j.w. mea ADDR => \f[default]\n\n%(reference2)\e"
|
||||
}
|
||||
|
||||
/**
|
||||
* Email number successfully retieved.
|
||||
* reference0 - number of emails
|
||||
* reference2 - name of the server being checked
|
||||
* reference7 - the senders and titles delimited by C_BYTE1 characters
|
||||
* see: https://ukagakadreamteam.github.io/ukadoc/manual/list_shiori_event.html
|
||||
*/
|
||||
OnBIFFComplete
|
||||
{
|
||||
if reference0 == 0
|
||||
{
|
||||
"\0\s[0]%(username), в ящике пусто. Наверное лучше проверить позже.\e"
|
||||
|
||||
"\0\s[0]Ничего нового.\e"
|
||||
}
|
||||
elseif reference0 > 0 && reference0 < 13
|
||||
{
|
||||
"\0\s[0]Ответ от сервера получен, пришло %( OnCorrectEmailNumberSuffix( reference0 % 10 ) ). Посмотрим?"
|
||||
|
||||
"\0\s[0]Передача данных завершена. На сервере %( OnCorrectEmailNumberSuffix( reference0 % 10 ) )."
|
||||
|
||||
"\0\s[0]Письма из Хогвартса там всё ещё нет, но есть %( OnCorrectEmailNumberSuffix( reference0 % 10 ) ) новых писем. Сейчас зачитаю..."
|
||||
|
||||
--
|
||||
|
||||
"\n\n\![set,autoscroll,disable]\_q%( OnPrintMailAsList( reference7 ) )\e"
|
||||
}
|
||||
elseif reference0 > 12 && reference0 < 100
|
||||
{
|
||||
"\0\s[0]%(reference0) новых писем, довольно много. Давай не будем читать каждое.\e"
|
||||
}
|
||||
elseif reference0 > 99
|
||||
{
|
||||
"\0\s[0]%(reference0) новых писем? %(username), давно ты в последний раз проверял свой почтовый ящик?\e"
|
||||
|
||||
"\0\s[0]%(reference0) новых писем. Наверное, тебе всё таки стоит начать их читать.\e"
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Function that prints a string of email senders and titles as unordered list
|
||||
* _argv[0] - a string of entries in format "SenderName <Sender@email.eg> Message title" separated by SOH(U+0001) chars
|
||||
* returns formatted headers as list
|
||||
* : last modifier will ensure only last return candidate gets returned
|
||||
*/
|
||||
OnPrintMailAsList : last
|
||||
{
|
||||
_headers = SPLIT(_argv[0],"")
|
||||
_letters = ""
|
||||
_headerRegex = "\s*(\S+)\s*<([^>]+)>\s(.*)" // Name <email@example.com> Message title
|
||||
|
||||
foreach _headers; _header
|
||||
{
|
||||
if RE_MATCH(_header,_headerRegex) > 0
|
||||
{
|
||||
_letterTitle = SHIORI3FW.EscapeAllTags(RE_GETSTR[3])
|
||||
if RE_GETSTR[3] == ""
|
||||
{
|
||||
_letterTitle = "<не указано>"
|
||||
}
|
||||
_letters += "От: %(RE_GETSTR[1]) \nАдрес: %(RE_GETSTR[2]) \nТема: '%(_letterTitle)'\n\n"
|
||||
}
|
||||
}
|
||||
|
||||
_letters // returning formatted string
|
||||
}
|
||||
|
||||
/**
|
||||
* _argv[0] - number of emails recieved
|
||||
* returns a string representing a correct russian ending for a word "letter" for given number
|
||||
*/
|
||||
OnCorrectEmailNumberSuffix
|
||||
{
|
||||
case _argv[0]
|
||||
{
|
||||
when 1
|
||||
{
|
||||
"одно новое письмо"
|
||||
}
|
||||
when 2-4
|
||||
{
|
||||
"%(_argv[0]) новых письма"
|
||||
}
|
||||
when 0,5,6,7,8,9
|
||||
{
|
||||
"%(_argv[0]) новых писем"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//Various error messages that can happen when your ghost tries to connect to an email account. Replace the dialogue as appropriate.
|
||||
OnBIFFFailure
|
||||
{
|
||||
if reference0 == "timeout" //If the connection times out.
|
||||
{
|
||||
"\0\s[0]The connection has timed out.\e"
|
||||
}
|
||||
elseif reference0 == "kick" //If the account blocks the ghost from accessing it. I think gmail may do this at first to try and protect your account from unapproved applications using it. It gives you the option to change the setting in the warning email they send you about it.
|
||||
{
|
||||
"\0\s[0]We can't access the account.\e"
|
||||
}
|
||||
elseif reference0 == "defect" //If the information put into the POP menu is wrong.
|
||||
{
|
||||
"\0\s[0]The email account was not set up properly.\w8\1\s[10]It can be reset at the POP menu.\w8\![open,configurationdialog]\e"
|
||||
|
||||
//Note that this ends with \![open,configurationdialog]. This will open up the preferences menu I described above automatically. More on \! functions in the walkthrough. You can delete the \! tag here if you want to.
|
||||
}
|
||||
else //if there's some other kind of error.
|
||||
{
|
||||
"\0\s[0]We can't connect to the account.\w8\1\s[10]The error returned is '%(reference[0])'.\e"
|
||||
|
||||
//reference0 here stores the error message the email server would have given the ghost, hopefully.
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//**** Network Update *****************************************************************
|
||||
//The following functions are for the Network Update of your ghost, where it will connect to your website, check for new files, and update itself. This is a handy feature, but tricky to set up. If you have no intention of using Network Update, you can disregard these, but it won't hurt to fill them out anyway just in case. More details about how to set up Network Update are in the walkthrough (http://www.ashido.com/ukagaka/).
|
||||
|
||||
|
||||
@ -1,10 +1,6 @@
|
||||
//---------------------------Menus--------------------------
|
||||
|
||||
//--OpenSakuraMenu
|
||||
//This is a bit of intro dialogue before the main character opens their menu. You can see below that there are three pieces of separate dialogue listed before it goes to MenuRun. The character will randomly choose one of those pieces of dialogue before opening the rest of their menu. You can customize this with individual greetings for the character, such as "Yes, %(username)?" or "Need something, %(username)?" or things like that. Note that none of the lines end with \e!
|
||||
//The \b2 tag tells the ghost to use their big balloon for this dialogue. If your menu has a lot of stuff, this'll probably look better than the small one.
|
||||
//If you don't want multiple responses before opening the menu, you can delete the dialogue and just leave MenuRun.
|
||||
|
||||
// The character will randomly choose one of those pieces of dialogue before opening the rest of their menu. You can customize this with individual greetings for the character, such as "Yes, %(username)?" or "Need something, %(username)?" or things like that. Note that none of the lines end with \e!
|
||||
OpenSakuraMenu
|
||||
{
|
||||
"\0\s[0]\b2А?"
|
||||
@ -13,41 +9,32 @@ OpenSakuraMenu
|
||||
MenuRun
|
||||
}
|
||||
|
||||
//--MenuRun
|
||||
// This actually fills out the rest of the menu. If you're going to be adding or changing functions, this is where you'll be doing your edits.
|
||||
|
||||
MenuRun : all
|
||||
{
|
||||
wd = GetWeekDay
|
||||
ap = GetAP
|
||||
//These four statements basically get the day of the week, whether it's AM or PM, the hour, and the time. It's putting together the information to display the time at the bottom of the balloon.
|
||||
--
|
||||
"\n\n\_q\b2" //The \n\n means two new lines as detailed in the walkthrough, and \_q means quick session, meaning all the text from this point on will display instantly instead of a few letters at a time like normal ghost dialogue. You can ignore it.
|
||||
"\n\n\_q\b2"
|
||||
--
|
||||
if lastTalk != "" //What this does is check to see if the ghost has already said a random bit of dialogue on its own, essentially by seeing if the lastTalk thing is NOT empty (!= means "does not equal").
|
||||
{
|
||||
"\![*]\q[Repeat Last Dialogue,OnLastTalk]\n\n[half]"
|
||||
//If the ghost has said something, it will then display this menu option. You can replace "Repeat Last Dialogue" with whatever caption you like, such as "What were you saying?" or "What did you say?" or "Could you repeat that?" or something like that.
|
||||
|
||||
//*********************Advanced User Info*******************************
|
||||
//These text boxes are meant for those who have an interest in expanding or using more complicated functions in their ghost. Also for my own reference in the future since I plan on using this template too, haha. If you have no interest in any of this and just want to keep things as simple as possible, feel free to skip these boxes.
|
||||
|
||||
//I briefly touched in bootend.dic about \q, but I'll again cover it here. Pay very close attention to how this bit of dialogue is formatted. You'll see it goes \![*]\q[Displayed Name,linkedfunction]. Breaking it down, \![*] puts the balloon's option icon in front of the choice (usually a > or something), \q sets up the choice, Displayed Name which is the text that will display in the ghost's balloon, then linkedfunction, which is what the choice is linked to when the user clicks it. As you go through this file, look at how every menu option is set up, and you will see they all follow this format, give or take a \![*]. If you're going to be adding new options to menus or creating your own functions and such, make sure you follow this format and learn it well. Make sure to read the coding page of the walkthrough.
|
||||
//***********************************************************************
|
||||
}
|
||||
--
|
||||
"\![*]\q[Say something,OnAiTalk]\n"
|
||||
|
||||
"\![*]\q[Скажи что нибуть,OnAiTalk]\n"
|
||||
"\![*]\q[Давай проверим почту,MailCheck]\n"
|
||||
|
||||
//This option will force the ghost to say something from aitalk if the user clicks it. Just replace "Say something" with whatever caption you think would be appropriate.
|
||||
//Advanced users, you can add multiple captions for any option you add to a menu you make just like this, as long as you separate it from the other options into its own section with two dashes above and below. Note that you can't do this if the Function above has ": all" after it, since that will put every potential option in. You'll have to set it your menu up differently to take --s into account. I commented it out here because of ": all" above, but you can see the basic idea.
|
||||
--
|
||||
"\![*]\q[Config Menu,configmenu]\n"
|
||||
"\![*]\q[Functions,dosomething]\n\n[half]"
|
||||
"\![*]\q[Nevermind,CANCEL]\n\n\n[half]%(wd) %(nowhour):%(nowmin) %(ap), %(month)/%(day)/%(year)\e"
|
||||
|
||||
//These three lead to the Config Menu, the Function menu, and Cancel. You can leave these alone if you like. All the envelopes at the end (see word.dic) basically display the year, month, day, weekday, and time.
|
||||
"\![*]\q[Нужно кое-что сделать,dosomething]\n\n[half]"
|
||||
"\![*]\q[Настройки,configmenu]\n"
|
||||
"\![*]\q[Я передумал,CANCEL]\n\n\n[half]%(wd) %(nowhour):%(nowmin) %(ap), %(month)/%(day)/%(year)\e"
|
||||
}
|
||||
|
||||
// WILD UNFORMATTED CODE BELOW --------------
|
||||
|
||||
|
||||
//Leave this alone
|
||||
OnLastTalk
|
||||
{
|
||||
@ -480,9 +467,9 @@ Select.TEACHNAME
|
||||
//If the user selects cancel in a menu. Replace as you like, or just leave them blank.
|
||||
Select.CANCEL
|
||||
{
|
||||
"\0\s[0]This is a cancel message.\e"
|
||||
//"\0\s[0]This is a cancel message.\e"
|
||||
|
||||
"\0\s[0]This is another cancel message.\e"
|
||||
//"\0\s[0]This is another cancel message.\e"
|
||||
}
|
||||
|
||||
|
||||
@ -511,7 +498,6 @@ Select.dosomething : all
|
||||
//the actual menu options.
|
||||
|
||||
"\![*]\q[Open Calendar,CALENDAR]\n"
|
||||
"\![*]\q[Check Email,MailCheck]\n"
|
||||
"\![*]\q[Open SSP Preferences,sspconfig]\n"
|
||||
|
||||
//"\![*]\q[Empty Recycle Bin,ChoiceGarbagecan]\n"
|
||||
@ -643,13 +629,14 @@ OpenKeroMenu : all
|
||||
}
|
||||
|
||||
//There are no real set things for the second character to do, really. You can mostly add whatever functions you want to them, their menu is totally free reign. In mine for example, Hunter has some games, a pseudo-FAQ for users, a bug report, an update option, and most importantly, a test variable. A lot of that is fairly complicated though, so I won't get into it here. Advanced Users can pick up Hunter and Smoker and study their menu.dic to see how I did it though, and those who read the coding page of the walkthrough and want to make their own functions can feel free to add them here.
|
||||
//For the purposes of this simple template, I'll include two options that may come in handy - an update option and a bug report option, as well as the test variable.
|
||||
|
||||
//If you click cancel. Replace dialogue as you want.
|
||||
/*
|
||||
Select.keroCANCEL
|
||||
{
|
||||
"\1\s[10]This is menu cancel dialogue.\e"
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
//This is when they select bug report. This is mostly meant to briefly give the user information about you, the creator, and how to report a problem to you. This can be handy if the person forgot where they got their ghost or how to contact you. Add whatever info you like here.
|
||||
|
||||
@ -1,39 +1,15 @@
|
||||
//---------------------------Envelopes--------------------------
|
||||
//This .dic file is probably one of the simplest you will have to edit, and in fact, if the way it works doesn't appeal to you, you can completely ignore it if you like!
|
||||
|
||||
//Basically, what this file does is set up some things that, for the purposes of this file, I'll call envelopes (this is what they're referred to as on the CROW-SSP Dictionary site... at least, that's what I remember, it's been a while since I've checked it). They are technically functions and can do many things, but this file is mostly an organizational tool for storing lists you may use.
|
||||
|
||||
|
||||
//**** START EXAMPLES ***************************************************************
|
||||
|
||||
//For the purposes of this file, an envelope is a list that you can populate with items, and this list can be called later during dialogue with the %(name) format. If you've read the walkthrough or gone through any of the other .dic files, you've probably seen these before. %(username) is one, which displays the user's name, and %(heshe) is another, which displays the right pronoun depending on what the user selected in bootend.dic or menu.dic. Other ones include %(passmin), which shows how many minutes have passed since the ghost was started, %(screenheight) which shows the height of the display they're currently on, and %(keroname) for the name of the second character, among many, many others. Many of these are predefined by the AYA scripting and will be listed on the CROW-SSP site mentioned above, and many of them you will never have to use.
|
||||
|
||||
//So where does this file come in? Well, you can define your own envelopes/variables if you want! Here's an example.
|
||||
|
||||
exampleenvelope
|
||||
{
|
||||
"Example Envelope Dialogue 1"
|
||||
"Example Envelope Dialogue 2"
|
||||
"Example Envelope Dialogue 3"
|
||||
}
|
||||
|
||||
//As you can see, we stated a word, opened some brackets, wrote some text, and closed the brackets. Now when you write ghost dialogue, you can write %(exampleenvelope) and your ghost will randomly display any of the three bits of text within the brackets! You can go ahead and test this yourself to see how it works, and I'll include some sample dialogue with this in aitalk.dic.
|
||||
|
||||
//What can you use this kind of envelope for? You can store tons of random information to keep your ghost's dialogue varied! You can store various cities you like in %(city), musicians you like in %(musicians), places your ghost has been in %(places), food you like in %(food), movies you like in %(movie), fandoms you like in %(fandom), characters you like in %(fandomcharacter), celebrities you like under %(celebrity) or friends of yours in %(friends) or bnfs in %(bnfs), folders on your computer under %(folders), Pokemon you like under %(pokemon), insults under %(insult), swear words under %(swearword) which could potentially be hilarious, just about anything! You can make lists of absolutely anything to use with dialogue for your ghost! This .dic file is only limited by your imagination!
|
||||
|
||||
//Not only that, but you can put an envelope IN an envelope. Here's another example.
|
||||
|
||||
internalenvelope
|
||||
{
|
||||
"Internal Envelope Dialogue 1 - %(exampleenvelope)"
|
||||
"%(username)'s computer"
|
||||
"Here is a blanklist object - %(blanklist)."
|
||||
}
|
||||
|
||||
//You can nest envelopes all day long, although it might get kind of convoluted if you don't keep track. This is particularly handy with %(username), so your ghost can be specific if they're talking about something of the user's, like their files or folders for example. I'll leave a few lists in here you can fill out as you like. And if this doesn't give you ideas, you can ignore this file, since nothing in it will show up unless you write it into the dialogue. You can add or take away as many items as you want from each list.
|
||||
|
||||
//*********************Advanced User Info*******************************
|
||||
//These text boxes are meant for those who have an interest in expanding or using more complicated functions in their ghost. Also for my own reference in the future since I plan on using this template too, haha. If you have no interest in any of this and just want to keep things as simple as possible, feel free to skip these boxes.
|
||||
|
||||
//Because these are basically their own functions, you can do other things with them as well as display dialogue. You can add if/else checks, run other functions, have pools of alternate dialogue... the possibilities are really endless.
|
||||
|
||||
//One particularly useful thing you can do is add value changes to an envelope, if your dialogue is in a place where it's not easy to add the change directly. For example...
|
||||
|
||||
//FeelingsGoUp
|
||||
@ -71,41 +47,13 @@ internalenvelope
|
||||
|
||||
//And have him randomly pick one whenever I use %(scared) in dialogue. This can be an easy way to vary certain poses without having to manually put them in one at a time, and have some variety when your ghost goes back to its neutral pose in SurfaceRestore.
|
||||
|
||||
//***********************************************************************
|
||||
//Not only that, but you can put an envelope IN an envelope. Here's another example.
|
||||
|
||||
blanklist
|
||||
internalenvelope
|
||||
{
|
||||
"List object 1"
|
||||
"List object 2"
|
||||
"List object 3"
|
||||
"List object 4"
|
||||
"List object 5"
|
||||
}
|
||||
|
||||
blanklist2
|
||||
{
|
||||
"List object 1"
|
||||
"List object 2"
|
||||
"List object 3"
|
||||
"List object 4"
|
||||
"List object 5"
|
||||
"List object 6"
|
||||
"List object 7"
|
||||
"List object 8"
|
||||
}
|
||||
|
||||
blanklist3
|
||||
{
|
||||
"List object 1"
|
||||
"List object 2"
|
||||
"List object 3"
|
||||
"List object 4"
|
||||
}
|
||||
|
||||
blanklist4
|
||||
{
|
||||
"List object 1"
|
||||
"List object 2"
|
||||
"Internal Envelope Dialogue 1 - %(exampleenvelope)"
|
||||
"%(username)'s computer"
|
||||
"Here is a blanklist object - %(blanklist)."
|
||||
}
|
||||
|
||||
//This envelope in particular I think is fun. You can use this in dialogue to pretend like your ghost is looking through your user's files!
|
||||
@ -117,18 +65,6 @@ usersfolder
|
||||
"%(username)'s secret folder"
|
||||
}
|
||||
|
||||
|
||||
//Now, this next envelope is unique. I've called it a double envelope at times, but this is actually technically an array. Note that it has a word, a comma, then another word. This is essentially a list being stored in this envelope. You can call one of the values by using brackets around the number of the list entry. So, the first value (the Korean word) would be %(lessonkor[0]) since all arrays start at 0. The second value (the definition) would be %(lessonkor[1]). If you have a longer array, like "word,word,word,word,word", you can keep calling values by changing the numbers, like %(lessonkor[5]) or %(lessonkor[10]). Arrays can be very powerful and useful for storing a lot of information in a condensed space, but I must level with you, I'm not very good at arrays or figuring out how to use them. :B They can be VERY useful though, if you can wrap your head around how they work. An example of pulling information from this array can be seen in aitalk.dic.
|
||||
|
||||
lessonkor
|
||||
{
|
||||
"사과(sa-gua),apple"
|
||||
"노동(no-dong),labor"
|
||||
"손가락(son-ga-rak),finger"
|
||||
"마르크스(ma-r-k-s),Marx"
|
||||
"자본주의(ja-bon-ju-yi),capitalism"
|
||||
}
|
||||
|
||||
//You can also format your envelopes like this as one line separated by semicolons, but personally I think the spaced lists above look nicer. It's up to you however you want to set them up.
|
||||
|
||||
blanklistparagraph
|
||||
@ -137,6 +73,10 @@ blanklistparagraph
|
||||
}
|
||||
|
||||
|
||||
//**** END EXAMPLES ***************************************************************
|
||||
|
||||
|
||||
|
||||
//**** Don't touch this ***************************************************************
|
||||
//This is code stuff and nothing for you to worry about, just save the .dic and move on! You're done!
|
||||
|
||||
|
||||
@ -1,40 +1,41 @@
|
||||
//These define what character set your ghost will be using. Don't touch any of them.
|
||||
|
||||
charset, UTF-8
|
||||
charset, UTF-8
|
||||
charset.dic, UTF-8
|
||||
charset.output, UTF-8
|
||||
charset.file, UTF-8
|
||||
charset.save, UTF-8
|
||||
charset.extension, UTF-8
|
||||
|
||||
|
||||
//---- Dictionary Files ---------------------------------------------------------------------
|
||||
|
||||
//These are the .dic files your ghost will be using. You can add new .dic files or take them away as you like, just always make sure to test your ghost to make sure it still works if you do. This can be finicky.
|
||||
//I would recommend adding the initials of your ghost to the front of your .dic files, such as hs_string or hs_bootend, particularly if you're going to be editing multiple ghosts at once, or studying other ghost's files to see how they work. It'll help you keep the files straight in Notepad++. You don't have to though, that's optional. If you do, make sure to change the filenames here too, so if you changed the filename to hs_string, make sure you come back here and change the line here to dic,hs_string.
|
||||
|
||||
dicdir, yaya_base
|
||||
dic, string.dic
|
||||
|
||||
// Random talk
|
||||
dic, aitalk.dic
|
||||
dic, bootend.dic
|
||||
dic, mouse.dic
|
||||
|
||||
// Miscellaneous utitility scripts such as installation,
|
||||
// removal, update and file manipilation event callbacks
|
||||
dic, etc.dic
|
||||
|
||||
// Menu
|
||||
dic, menu.dic
|
||||
dic, word.dic
|
||||
dic, commu.dic
|
||||
dic, nameteach.dic
|
||||
dic, anchor.dic
|
||||
|
||||
//---- Log Location -------------------------------------------------------------------------
|
||||
//I'm not entirely sure what this does, but basically don't touch it.
|
||||
// Lyuma Email functionality
|
||||
dic, email.dic
|
||||
|
||||
//---- Log Location -------------------------------------------------------------------------
|
||||
|
||||
//log, ayame.log
|
||||
msglang,english
|
||||
|
||||
//Don't touch anything in here.
|
||||
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
//実行ログ
|
||||
//実行ログをayame.logに記録します。開発時には記録しておいたほうが良いです。
|
||||
|
||||
Reference in New Issue
Block a user