Difference between revisions of "A beginner's guide, lesson 6 - Quest Dialogue"
A beginner's guide, lesson 6 - Quest Dialogue (edit)
Revision as of 05:24, 28 July 2010
, 05:24, 28 July 2010→Three Problems: editing English
imported>Pyrocow2 (→Scripting: Editing English) |
imported>Pyrocow2 (→Three Problems: editing English) |
||
Line 573: | Line 573: | ||
You can now test this mod in the game, but it might be best not to SAVE the game in Oblivion as we will be changing things. | You can now test this mod in the game, but it might be best not to SAVE the game in Oblivion as we will be changing things. | ||
== | ==Two Problems== | ||
There are | There are two problems with the mod as it stands: | ||
The first problem | The first problem is that the text does not stay on the screen very long, and our NPC will just look at us. This is due to the way the game handles speech. | ||
It expects to find for each dialogue response files which we have not created. One is an MP3 which contains the sound files the others | It expects to find for each dialogue response files, which we have not created. One is an MP3 which contains the sound files, and the others are lip synch files used to animate the actor's face as we carry out the dialogue. The text is supposed to appear on screen for the duration of these files. | ||
Since we don't have them yet the text runs very quickly. In later tutorials we will look at polishing this mod to include these files. For now these are cosmetic problems. It's irritating not to see the text for any length of time but it can't be helped | Since we don't have them yet, the text runs very quickly. In later tutorials we will look at polishing this mod to include these files. For now, these are cosmetic problems. It's irritating not to see the text for any length of time, but it can't be helped until we add those MP3's. | ||
It doesn't stop the quest running. You can repeatedly play the on-screen text by selecting the topic message for you until you get the message | It doesn't stop the quest running. You can repeatedly play the on-screen text by selecting the topic message for you until you get the message | ||
The second problem deals with the script as it currently stands and may not be so obvious to a non-scripter. | The second problem deals with the script as it currently stands and may not be so obvious to a non-scripter. A quest script runs every 5 seconds. That means that every 5 seconds this script tries to add the topic BGMMessage4u to the players topic list. I don't honestly know what the effect of repeatedly adding a topic to the player's list is, but I suspect that extra requests to add the topic are simply ignored. | ||
However, this is still an untidy way to script. If we only want | However, this is still an untidy way to script. If we only want something to happen once, we should write our script that way! | ||
This leads us to one of the most important and common scripting ideas | This leads us to one of the most important and common scripting ideas: a do once loop. | ||
==If-EndIf Blocks== | ==If-EndIf Blocks== |