Frame 1
function switchslide(newslide) {
currentslide = newslide;
}
function saveslide() {
slide[dia] = currentslide;
}
function playslide() {
currentvideo = slide[currentdialog];
swapvideo();
}
function playvideo(index) {
screen.attachMovie(video[index], "slide", 0);
}
function swapvideo() {
if (currentvideo != previousvideo) {
playvideo(currentvideo);
}
previousvideo = currentvideo;
}
video = new Array();
video[1] = "slide1";
video[2] = "slide2";
video[3] = "slide3";
video[4] = "slide4";
video[5] = "slide5";
video[6] = "slide6";
video[7] = "slide7";
video[8] = "slide8";
video[9] = "slide9";
video[10] = "slide10";
video[11] = "slide11";
video[12] = "slide12";
video[13] = "slide13";
video[14] = "slide14";
video[15] = "slide15";
video[16] = "slide16";
video[17] = "slide17";
video[18] = "slide12_2";
video[19] = "slide8_2";
video[20] = "slide14_2";
video[21] = "slide1_2";
slide = new Array();
currentslide = 1;
currentvideo = 1;
previousvideo = 0;
function resettext() {
textbox.text = "";
textbox.gotoAndPlay("reset");
}
function settext(text, color, speed, newdelay) {
textbox.delay = newdelay;
textbox.color = color;
textbox.text = text;
textbox.speed = speed;
textbox.gotoAndPlay("reset");
stop();
}
function setdialog(number) {
var _local2;
_local2 = 3;
currentdialog = number;
settext(dialog[number * _local2], dialog[(number * _local2) + 1], dialog[(number * _local2) + 2], delays[number]);
playslide();
}
function nextdialog() {
if ((currentdialog + 1) < (dialog.length / 3)) {
currentdialog = currentdialog + 1;
} else {
currentdialog = 0;
}
setdialog(currentdialog);
}
function previousdialog() {
currentdialog = currentdialog - 2;
if (currentdialog < 0) {
currentdialog = (dialog.length / 3) - 2;
}
play();
}
function initdialog(text, color, speed) {
var _local1;
_local1 = 3;
dialog[dia * _local1] = text;
dialog[(dia * _local1) + 1] = color;
dialog[(dia * _local1) + 2] = speed;
saveslide();
delays[dia] = currentdelay;
currentdelay = 0;
dia++;
}
function setdelay(delay) {
currentdelay = delay;
}
esp = 0;
fla = 1;
gla = 2;
mig = 3;
character1 = 4;
dialog = new Array();
delays = new Array();
currentdelay = 0;
currentdialog = -1;
dia = 0;
Frame 2
switchslide(17);
initdialog("Click this textbox.", character1, 10);
initdialog("Press RIGHT. DO IT NOW!", character1, 10);
initdialog("Now press LEFT!", character1, 10);
initdialog("This is a short tutorial teaching the basics\nof linework layers in SAI.", character1, 10);
initdialog("To get started", character1, 10);
switchslide(1);
initdialog("To get started we need a sketch.", character1, 10);
initdialog("Okay, let's ink it now.", character1, 10);
switchslide(2);
initdialog("First, make a new linework layer.", character1, 10);
switchslide(3);
initdialog("Select the pen tool, keep pressure sensitivity deactivated.", character1, 10);
switchslide(4);
initdialog("Draw a line.", character1, 10);
switchslide(5);
initdialog("Now hold Ctrl and you should see points along the line.", character1, 10);
switchslide(6);
initdialog("You can add and move points by clicking and dragging the line while holding ctrl.", character1, 10);
switchslide(7);
initdialog("Alt+click removes points. Do that to smooth lines out.", character1, 10);
initdialog("Large, slightly curvy lines are no problem this way.", character1, 10);
switchslide(1);
initdialog("And that's all you're working with.", character1, 10);
switchslide(8);
initdialog("And that's all you're working with.\nInk the sketch now.", character1, 10);
switchslide(15);
initdialog("Press ctrl+A to select all points.", character1, 10);
switchslide(9);
initdialog("Select the weight tool.\nActivate pressure sensitivity and click a line.", character1, 10);
initdialog("After that, clear the selection (Ctrl + right click).\nMake sure no point is selected!", character1, 10);
switchslide(10);
initdialog("Select the pressure tool.", character1, 10);
switchslide(11);
initdialog("click and drag points to adjust the lines weight.", character1, 10);
switchslide(19);
initdialog("Apply that on all the lines.\nHow exactly you do that is up to you.", character1, 10);
switchslide(12);
initdialog("Almost done.", character1, 10);
switchslide(13);
initdialog("Select the Pen tool with pressure sensitivity activated.", character1, 10);
switchslide(18);
initdialog("Select the Pen tool with pressure sensitivity activated.\nNow you can add some fine details.", character1, 10);
switchslide(14);
initdialog("Done.", character1, 10);
switchslide(16);
initdialog("Linework layers are freely resizeable just like vectors.\nIf you want a larger picture, now is the time to make adjustments.", character1, 10);
switchslide(20);
initdialog("And now", character1, 10);
switchslide(1);
initdialog("And now your turn.", character1, 10);
switchslide(21);
initdialog("And now your turn.\n\nEND", character1, 10);
Frame 3
nextdialog();
Instance of Symbol 73 MovieClip "screen" in Frame 3
on (keyPress "<Right>") {
_parent.textbox.buttonpress();
}
on (keyPress "<Left>") {
with (_parent) {
previousdialog();
}
}
Frame 4
gotoAndPlay ("dialog");
Symbol 67 Button
on (release) {
buttonpress();
}
Symbol 70 Button
on (release) {
_parent.previousdialog();
}
Symbol 71 MovieClip Frame 1
function buttonpress() {
if (delay <= 0) {
if (q < text.length) {
q = text.length;
} else {
_parent.play();
}
}
}
q = 1;
text = "";
prevtext = text;
textcolors = new Array(8396458, 11964690, 812969, 5395026, 0);
color = 1;
speed = 0.5;
delay = 0;
Symbol 71 MovieClip Frame 2
if (prevtext.substring(0, q - speed) != text.substring(0, q - speed)) {
q = 1;
textbox = "";
}
prevtext = text;
Symbol 71 MovieClip Frame 3
textboxx.textColor = textcolors[color];
if (delay <= 0) {
if (q < text.length) {
textbox = text.substring(0, q);
q = q + speed;
} else {
textbox = text;
}
} else {
delay = delay - 1;
}
dialognumber = _root.currentdialog;
slidenumber = _root.currentvideo;
Symbol 71 MovieClip Frame 4
gotoAndPlay (3);