mirror of
https://gitgud.io/BondageProjects/Bondage-College.git
synced 2025-04-10 02:19:20 +00:00
Added a global MainCanvas to replace all the declared "ctx"
Added a global MainCanvas to replace all the declared "ctx"
This commit is contained in:
parent
f98821c45b
commit
7e4d84a1ba
57 changed files with 684 additions and 659 deletions
C000_Intro
C001_BeforeClass
C002_FirstClass
C003_MorningDetention
C004_ArtClass
C005_GymClass
C006_Isolation
C007_LunchBreak
C008_DramaClass
C009_Library
Intro
Library
Outro
Yuki
C010_Revenge
C101_KinbakuClub
ClubRoom1
ClubRoom2
ClubRoom3
Discipline
EricaBadEnd
Intro
Lauren
Outro
Transition
C999_Common
Drawing.jsStruggle.jsindex.html
|
@ -43,15 +43,14 @@ function C000_Intro_CreatePlayer_Run() {
|
|||
}
|
||||
|
||||
// Draw the player image and the text input for the name
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Player.jpg", 900, 0);
|
||||
DrawRect(ctx, 0, 0, 900, 600, "white");
|
||||
DrawText(ctx, GetText("EnterName"), 450, 100, "black");
|
||||
DrawText(ctx, GetText("ValidChars"), 450, 180, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Player.jpg", 900, 0);
|
||||
DrawRect(0, 0, 900, 600, "white");
|
||||
DrawText(GetText("EnterName"), 450, 100, "black");
|
||||
DrawText(GetText("ValidChars"), 450, 180, "black");
|
||||
|
||||
// Creates the "validate" button
|
||||
DrawRect(ctx, 300, 450, 300, 70, "#8c304e");
|
||||
DrawText(ctx, GetText("Validate"), 450, 485, "white");
|
||||
DrawRect(300, 450, 300, 70, "#8c304e");
|
||||
DrawText(GetText("Validate"), 450, 485, "white");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -10,16 +10,15 @@ function C000_Intro_Intro_Load() {
|
|||
function C000_Intro_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Draw the intro text
|
||||
DrawText(ctx, GetText("Intro1"), 450, 100, "White");
|
||||
DrawText(ctx, GetText("Intro2"), 450, 200, "White");
|
||||
DrawText(ctx, GetText("Intro3"), 450, 300, "White");
|
||||
DrawText(ctx, GetText("Intro4"), 450, 400, "White");
|
||||
DrawText(ctx, GetText("Intro5"), 450, 500, "White");
|
||||
DrawText(GetText("Intro1"), 450, 100, "White");
|
||||
DrawText(GetText("Intro2"), 450, 200, "White");
|
||||
DrawText(GetText("Intro3"), 450, 300, "White");
|
||||
DrawText(GetText("Intro4"), 450, 400, "White");
|
||||
DrawText(GetText("Intro5"), 450, 500, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -16,11 +16,7 @@ function C001_BeforeClass_Classroom_Load() {
|
|||
|
||||
// Chapter 1 - Classroom Run
|
||||
function C001_BeforeClass_Classroom_Run() {
|
||||
|
||||
// Draw the background image and the wait button on the bottom right of the image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background" + C001_BeforeClass_Classroom_Mode.toString() + ".jpg", 0, 0);
|
||||
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background" + C001_BeforeClass_Classroom_Mode.toString() + ".jpg", 0, 0);
|
||||
}
|
||||
|
||||
// Chapter 1 - Classroom Click
|
||||
|
|
|
@ -12,16 +12,15 @@ function C001_BeforeClass_FightIntro_Load() {
|
|||
function C001_BeforeClass_FightIntro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 800, 0);
|
||||
|
||||
// Each animation show an additional line of text
|
||||
DrawText(ctx, GetText("Intro1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 400, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 400, 350, "White");
|
||||
if ((TextPhase >= 3) && !IsMobile) DrawText(ctx, GetText("Intro4A"), 400, 450, "White");
|
||||
if ((TextPhase >= 3) && IsMobile) DrawText(ctx, GetText("Intro4B"), 400, 450, "White");
|
||||
DrawText(GetText("Intro1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 400, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 400, 350, "White");
|
||||
if ((TextPhase >= 3) && !IsMobile) DrawText(GetText("Intro4A"), 400, 450, "White");
|
||||
if ((TextPhase >= 3) && IsMobile) DrawText(GetText("Intro4B"), 400, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -19,16 +19,15 @@ function C001_BeforeClass_FightOutro_Load() {
|
|||
function C001_BeforeClass_FightOutro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Mildred.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Mildred.jpg", 800, 0);
|
||||
|
||||
// Each animation show an additional line of text
|
||||
if (C001_BeforeClass_FightOutro_FightResult == 0) DrawText(ctx, GetText("Intro1A"), 400, 150, "White");
|
||||
if (C001_BeforeClass_FightOutro_FightResult == 1) DrawText(ctx, GetText("Intro1B"), 400, 150, "White");
|
||||
if (C001_BeforeClass_FightOutro_FightResult == 2) DrawText(ctx, GetText("Intro1C"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 400, 450, "White");
|
||||
if (C001_BeforeClass_FightOutro_FightResult == 0) DrawText(GetText("Intro1A"), 400, 150, "White");
|
||||
if (C001_BeforeClass_FightOutro_FightResult == 1) DrawText(GetText("Intro1B"), 400, 150, "White");
|
||||
if (C001_BeforeClass_FightOutro_FightResult == 2) DrawText(GetText("Intro1C"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 400, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -10,18 +10,17 @@ function C001_BeforeClass_Intro_Load() {
|
|||
function C001_BeforeClass_Intro_Run() {
|
||||
|
||||
// Draw the background and player
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
if (TextPhase <= 2) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background1.jpg", 0, 0);
|
||||
else DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background2.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
if (TextPhase <= 2) DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background1.jpg", 0, 0);
|
||||
else DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background2.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Introduce chapter 1 with each clicks
|
||||
DrawText(ctx, GetText("Intro1"), 450, 50, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 450, 150, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 450, 250, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 450, 350, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Intro5"), 450, 450, "White");
|
||||
if (TextPhase >= 5) DrawText(ctx, GetText("Intro6"), 450, 550, "White");
|
||||
DrawText(GetText("Intro1"), 450, 50, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 450, 150, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 450, 250, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 450, 350, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Intro5"), 450, 450, "White");
|
||||
if (TextPhase >= 5) DrawText(GetText("Intro6"), 450, 550, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -23,20 +23,19 @@ function C001_BeforeClass_Outro_Load() {
|
|||
function C001_BeforeClass_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 800, 0);
|
||||
|
||||
// The text changes based on the trouble that was done
|
||||
if (TextPhase >= 0) DrawText(ctx, GetText("Intro1"), 400, 100, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 0) && (TextPhase >= 1)) DrawText(ctx, GetText("Intro2A"), 400, 250, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 1) && (TextPhase >= 1)) DrawText(ctx, GetText("Intro2B"), 400, 200, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 2) && (TextPhase >= 1)) DrawText(ctx, GetText("Intro2C"), 400, 200, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 3) && (TextPhase >= 1)) DrawText(ctx, GetText("Intro2D"), 400, 200, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 0) && (TextPhase >= 2)) DrawText(ctx, GetText("Intro3A"), 400, 400, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode >= 1) && (TextPhase >= 2)) DrawText(ctx, GetText("Intro3B"), 400, 300, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode >= 1) && (TextPhase >= 3)) DrawText(ctx, GetText("Intro4"), 400, 400, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode >= 1) && (TextPhase >= 4)) DrawText(ctx, GetText("Intro5"), 400, 500, "White");
|
||||
if (TextPhase >= 0) DrawText(GetText("Intro1"), 400, 100, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 0) && (TextPhase >= 1)) DrawText(GetText("Intro2A"), 400, 250, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 1) && (TextPhase >= 1)) DrawText(GetText("Intro2B"), 400, 200, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 2) && (TextPhase >= 1)) DrawText(GetText("Intro2C"), 400, 200, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 3) && (TextPhase >= 1)) DrawText(GetText("Intro2D"), 400, 200, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode == 0) && (TextPhase >= 2)) DrawText(GetText("Intro3A"), 400, 400, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode >= 1) && (TextPhase >= 2)) DrawText(GetText("Intro3B"), 400, 300, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode >= 1) && (TextPhase >= 3)) DrawText(GetText("Intro4"), 400, 400, "White");
|
||||
if ((C001_BeforeClass_Outro_Mode >= 1) && (TextPhase >= 4)) DrawText(GetText("Intro5"), 400, 500, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -39,11 +39,10 @@ function C002_FirstClass_Classroom_Load() {
|
|||
function C002_FirstClass_Classroom_Run() {
|
||||
|
||||
// Draw the background image and the wait button on the bottom right of the image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C002_FirstClass_Classroom_Sidney.toString() + ".jpg", 0, 0);
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C002_FirstClass_Classroom_Mildred.toString() + ".jpg", 300, 0);
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C002_FirstClass_Classroom_Amanda.toString() + ".jpg", 600, 0);
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C002_FirstClass_Classroom_Sarah.toString() + ".jpg", 900, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C002_FirstClass_Classroom_Sidney.toString() + ".jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C002_FirstClass_Classroom_Mildred.toString() + ".jpg", 300, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C002_FirstClass_Classroom_Amanda.toString() + ".jpg", 600, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C002_FirstClass_Classroom_Sarah.toString() + ".jpg", 900, 0);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -10,16 +10,15 @@ function C002_FirstClass_Intro_Load() {
|
|||
function C002_FirstClass_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 450, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 450, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 450, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 450, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Intro5"), 450, 500, "White");
|
||||
DrawText(GetText("Intro1"), 450, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 450, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 450, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 450, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Intro5"), 450, 500, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -17,18 +17,17 @@ function C002_FirstClass_Outro_Load() {
|
|||
function C002_FirstClass_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 800, 0);
|
||||
|
||||
// Write the chapter outro
|
||||
DrawText(ctx, GetText("Intro1"), 400, 150, "White");
|
||||
if ((TextPhase >= 1) && (C002_FirstClass_Classroom_MildredSubdueSuccess == false) && (C002_FirstClass_Classroom_MildredSubdueFailed == false)) DrawText(ctx, GetText("Intro2A"), 400, 250, "White");
|
||||
if ((TextPhase >= 1) && (C002_FirstClass_Classroom_MildredSubdueSuccess == true) && (C002_FirstClass_Classroom_MildredSubdueFailed == false) && (!C002_FirstClass_Outro_Restrained)) DrawText(ctx, GetText("Intro2B"), 400, 250, "White");
|
||||
if ((TextPhase >= 1) && (C002_FirstClass_Classroom_MildredSubdueSuccess == true) && (C002_FirstClass_Classroom_MildredSubdueFailed == false) && (C002_FirstClass_Outro_Restrained)) DrawText(ctx, GetText("Intro2C"), 400, 250, "White");
|
||||
if ((TextPhase >= 1) && (C002_FirstClass_Classroom_MildredSubdueFailed == true)) DrawText(ctx, GetText("Intro2D"), 400, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 400, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 400, 450, "White");
|
||||
DrawText(GetText("Intro1"), 400, 150, "White");
|
||||
if ((TextPhase >= 1) && (C002_FirstClass_Classroom_MildredSubdueSuccess == false) && (C002_FirstClass_Classroom_MildredSubdueFailed == false)) DrawText(GetText("Intro2A"), 400, 250, "White");
|
||||
if ((TextPhase >= 1) && (C002_FirstClass_Classroom_MildredSubdueSuccess == true) && (C002_FirstClass_Classroom_MildredSubdueFailed == false) && (!C002_FirstClass_Outro_Restrained)) DrawText(GetText("Intro2B"), 400, 250, "White");
|
||||
if ((TextPhase >= 1) && (C002_FirstClass_Classroom_MildredSubdueSuccess == true) && (C002_FirstClass_Classroom_MildredSubdueFailed == false) && (C002_FirstClass_Outro_Restrained)) DrawText(GetText("Intro2C"), 400, 250, "White");
|
||||
if ((TextPhase >= 1) && (C002_FirstClass_Classroom_MildredSubdueFailed == true)) DrawText(GetText("Intro2D"), 400, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 400, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 400, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -16,18 +16,17 @@ function C002_FirstClass_SarahIntro_Load() {
|
|||
function C002_FirstClass_SarahIntro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
if (ActorSpecificHasInventory("Amanda", "BallGag"))
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background_AmandaGag.jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background_AmandaGag.jpg", 0, 0);
|
||||
else
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 600, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 600, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 600, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 600, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Intro5"), 600, 500, "White");
|
||||
DrawText(GetText("Intro1"), 600, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 600, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 600, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 600, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Intro5"), 600, 500, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -31,9 +31,8 @@ function C003_MorningDetention_DetentionRoom_Run() {
|
|||
if (C003_MorningDetention_DetentionRoom_SidneyGone == true) C003_MorningDetention_DetentionRoom_Sidney = 6;
|
||||
|
||||
// Draw the background image and the wait button on the bottom right of the image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Yuki" + C003_MorningDetention_DetentionRoom_Yuki.toString() + ".jpg", 0, 0);
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Sidney" + C003_MorningDetention_DetentionRoom_Sidney.toString() + ".jpg", 600, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Yuki" + C003_MorningDetention_DetentionRoom_Yuki.toString() + ".jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Sidney" + C003_MorningDetention_DetentionRoom_Sidney.toString() + ".jpg", 600, 0);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -16,17 +16,16 @@ function C003_MorningDetention_Intro_Load() {
|
|||
function C003_MorningDetention_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 450, 50, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 450, 150, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 450, 250, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 450, 350, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Intro5"), 450, 450, "White");
|
||||
if (TextPhase >= 5) DrawText(ctx, GetText("Intro6"), 450, 550, "White");
|
||||
DrawText(GetText("Intro1"), 450, 50, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 450, 150, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 450, 250, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 450, 350, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Intro5"), 450, 450, "White");
|
||||
if (TextPhase >= 5) DrawText(GetText("Intro6"), 450, 550, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -19,15 +19,14 @@ function C003_MorningDetention_Outro_Load() {
|
|||
function C003_MorningDetention_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 800, 0);
|
||||
|
||||
// Write the chapter outro
|
||||
if (C003_MorningDetention_Outro_EscapedDetention == false) DrawText(ctx, GetText("Outro1A"), 400, 150, "White");
|
||||
if (C003_MorningDetention_Outro_EscapedDetention == true) DrawText(ctx, GetText("Outro1B"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Outro2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Outro3"), 400, 450, "White");
|
||||
if (C003_MorningDetention_Outro_EscapedDetention == false) DrawText(GetText("Outro1A"), 400, 150, "White");
|
||||
if (C003_MorningDetention_Outro_EscapedDetention == true) DrawText(GetText("Outro1B"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Outro2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Outro3"), 400, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -39,11 +39,10 @@ function C004_ArtClass_ArtRoom_Load() {
|
|||
function C004_ArtClass_ArtRoom_Run() {
|
||||
|
||||
// Draw the background image and the wait button on the bottom right of the image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C004_ArtClass_ArtRoom_Jennifer + ".jpg", 0, 0);
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C004_ArtClass_ArtRoom_Julia + ".jpg", 300, 0);
|
||||
if (C004_ArtClass_ArtRoom_ExtraModel != "") DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C004_ArtClass_ArtRoom_ExtraModelImage + "_Extra.jpg", 600, 0);
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C004_ArtClass_ArtRoom_Sarah + ".jpg", 900, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C004_ArtClass_ArtRoom_Jennifer + ".jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C004_ArtClass_ArtRoom_Julia + ".jpg", 300, 0);
|
||||
if (C004_ArtClass_ArtRoom_ExtraModel != "") DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C004_ArtClass_ArtRoom_ExtraModelImage + "_Extra.jpg", 600, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C004_ArtClass_ArtRoom_Sarah + ".jpg", 900, 0);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -14,16 +14,15 @@ function C004_ArtClass_Intro_Load() {
|
|||
function C004_ArtClass_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 450, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 450, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 450, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 450, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Intro5"), 450, 500, "White");
|
||||
DrawText(GetText("Intro1"), 450, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 450, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 450, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 450, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Intro5"), 450, 500, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -23,34 +23,33 @@ function C004_ArtClass_Outro_Load() {
|
|||
function C004_ArtClass_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
|
||||
// Write the chapter outro
|
||||
if (C004_ArtClass_Outro_Crime == "") {
|
||||
|
||||
// No crime outro
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
DrawText(ctx, GetText("NoCrime1"), 400, 150, "White");
|
||||
if ((TextPhase >= 1) && C004_ArtClass_Outro_Restrained) DrawText(ctx, GetText("NoCrime2A"), 400, 300, "White");
|
||||
if ((TextPhase >= 1) && !C004_ArtClass_Outro_Restrained && (C004_ArtClass_ArtRoom_ExtraModel == "Player")) DrawText(ctx, GetText("NoCrime2B"), 400, 300, "White");
|
||||
if ((TextPhase >= 1) && !C004_ArtClass_Outro_Restrained && (C004_ArtClass_ArtRoom_ExtraModel != "Player")) DrawText(ctx, GetText("NoCrime2C"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("NoCrime3"), 400, 450, "White");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
DrawText(GetText("NoCrime1"), 400, 150, "White");
|
||||
if ((TextPhase >= 1) && C004_ArtClass_Outro_Restrained) DrawText(GetText("NoCrime2A"), 400, 300, "White");
|
||||
if ((TextPhase >= 1) && !C004_ArtClass_Outro_Restrained && (C004_ArtClass_ArtRoom_ExtraModel == "Player")) DrawText(GetText("NoCrime2B"), 400, 300, "White");
|
||||
if ((TextPhase >= 1) && !C004_ArtClass_Outro_Restrained && (C004_ArtClass_ArtRoom_ExtraModel != "Player")) DrawText(GetText("NoCrime2C"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("NoCrime3"), 400, 450, "White");
|
||||
|
||||
} else {
|
||||
|
||||
// Crime outro
|
||||
if (TextPhase <= 1) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
if ((TextPhase >= 2) && (C004_ArtClass_Outro_Crime == "RestrainMildred")) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Mildred.jpg", 800, 0);
|
||||
if ((TextPhase >= 2) && (C004_ArtClass_Outro_Crime == "DrugYuki")) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Yuki.jpg", 800, 0);
|
||||
DrawText(ctx, GetText("Crime1"), 400, 100, "White");
|
||||
if ((TextPhase >= 1) && C004_ArtClass_Outro_Restrained) DrawText(ctx, GetText("Crime2A"), 400, 200, "White");
|
||||
if ((TextPhase >= 1) && !C004_ArtClass_Outro_Restrained && (C004_ArtClass_ArtRoom_ExtraModel == "Player")) DrawText(ctx, GetText("Crime2B"), 400, 200, "White");
|
||||
if ((TextPhase >= 1) && !C004_ArtClass_Outro_Restrained && (C004_ArtClass_ArtRoom_ExtraModel != "Player")) DrawText(ctx, GetText("Crime2C"), 400, 200, "White");
|
||||
if ((TextPhase >= 2) && (C004_ArtClass_Outro_Crime == "RestrainMildred")) DrawText(ctx, GetText("Crime3A"), 400, 300, "White");
|
||||
if ((TextPhase >= 2) && (C004_ArtClass_Outro_Crime == "DrugYuki")) DrawText(ctx, GetText("Crime3B"), 400, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Crime4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Crime5"), 400, 500, "White");
|
||||
if (TextPhase <= 1) DrawImage(CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
if ((TextPhase >= 2) && (C004_ArtClass_Outro_Crime == "RestrainMildred")) DrawImage(CurrentChapter + "/" + CurrentScreen + "/Mildred.jpg", 800, 0);
|
||||
if ((TextPhase >= 2) && (C004_ArtClass_Outro_Crime == "DrugYuki")) DrawImage(CurrentChapter + "/" + CurrentScreen + "/Yuki.jpg", 800, 0);
|
||||
DrawText(GetText("Crime1"), 400, 100, "White");
|
||||
if ((TextPhase >= 1) && C004_ArtClass_Outro_Restrained) DrawText(GetText("Crime2A"), 400, 200, "White");
|
||||
if ((TextPhase >= 1) && !C004_ArtClass_Outro_Restrained && (C004_ArtClass_ArtRoom_ExtraModel == "Player")) DrawText(GetText("Crime2B"), 400, 200, "White");
|
||||
if ((TextPhase >= 1) && !C004_ArtClass_Outro_Restrained && (C004_ArtClass_ArtRoom_ExtraModel != "Player")) DrawText(GetText("Crime2C"), 400, 200, "White");
|
||||
if ((TextPhase >= 2) && (C004_ArtClass_Outro_Crime == "RestrainMildred")) DrawText(GetText("Crime3A"), 400, 300, "White");
|
||||
if ((TextPhase >= 2) && (C004_ArtClass_Outro_Crime == "DrugYuki")) DrawText(GetText("Crime3B"), 400, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Crime4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Crime5"), 400, 500, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -14,16 +14,15 @@ function C005_GymClass_Intro_Load() {
|
|||
function C005_GymClass_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 450, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 450, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 450, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 450, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Intro5"), 450, 500, "White");
|
||||
DrawText(GetText("Intro1"), 450, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 450, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 450, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 450, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Intro5"), 450, 500, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -13,13 +13,12 @@ function C005_GymClass_Outro_Load() {
|
|||
function C005_GymClass_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
|
||||
// Draw the outro text
|
||||
DrawText(ctx, GetText("Outro1"), 400, 200, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Outro2"), 400, 400, "White");
|
||||
DrawText(GetText("Outro1"), 400, 200, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Outro2"), 400, 400, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@ function C006_Isolation_Intro_Load() {
|
|||
// Do not allow bondage when we begin
|
||||
Common_BondageAllowed = true;
|
||||
Common_SelfBondageAllowed = true;
|
||||
GameLogSpecificAdd(CurrentChapter, "", "Isolated");
|
||||
GameLogSpecificAdd(CurrentChapter, "", "Isolation");
|
||||
|
||||
// Gets the player crime chapter 2 or 3. If there's any, we go to chapter 6 instead of 5.
|
||||
if (GameLogQuery("C002_FirstClass", "Mildred", "Subdue") && !GameLogQuery("C002_FirstClass", "Mildred", "Release")) C006_Isolation_Intro_Teacher = "Mildred";
|
||||
|
@ -30,16 +30,15 @@ function C006_Isolation_Intro_Load() {
|
|||
function C006_Isolation_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 450, 150, "White");
|
||||
if ((TextPhase >= 1) && (C006_Isolation_Intro_Teacher == "Mildred")) DrawText(ctx, GetText("Intro2Mildred"), 450, 250, "White");
|
||||
if ((TextPhase >= 1) && (C006_Isolation_Intro_Teacher == "Yuki")) DrawText(ctx, GetText("Intro2Yuki"), 450, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 450, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 450, 450, "White");
|
||||
DrawText(GetText("Intro1"), 450, 150, "White");
|
||||
if ((TextPhase >= 1) && (C006_Isolation_Intro_Teacher == "Mildred")) DrawText(GetText("Intro2Mildred"), 450, 250, "White");
|
||||
if ((TextPhase >= 1) && (C006_Isolation_Intro_Teacher == "Yuki")) DrawText(GetText("Intro2Yuki"), 450, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 450, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 450, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -34,23 +34,22 @@ function C006_Isolation_Outro_Load() {
|
|||
function C006_Isolation_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
if (C006_Isolation_Outro_EarlyEscape) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Player.jpg", 800, 0);
|
||||
if (!C006_Isolation_Outro_EarlyEscape) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C006_Isolation_Intro_Teacher + ".jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
if (C006_Isolation_Outro_EarlyEscape) DrawImage(CurrentChapter + "/" + CurrentScreen + "/Player.jpg", 800, 0);
|
||||
if (!C006_Isolation_Outro_EarlyEscape) DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C006_Isolation_Intro_Teacher + ".jpg", 800, 0);
|
||||
|
||||
// Draw the outro text
|
||||
if (!C006_Isolation_Outro_EarlyRelease && !C006_Isolation_Outro_EarlyEscape) {
|
||||
if (C006_Isolation_IsolationRoom_Stage <= 1) DrawText(ctx, GetText("Outro1A"), 400, 150, "White");
|
||||
if (C006_Isolation_IsolationRoom_Stage == 2) DrawText(ctx, GetText("Outro1B"), 400, 150, "White");
|
||||
if ((C006_Isolation_IsolationRoom_Stage == 3) && !C006_Isolation_Outro_StuckPillory && !C006_Isolation_Outro_StuckCross) DrawText(ctx, GetText("Outro1C"), 400, 150, "White");
|
||||
if ((C006_Isolation_IsolationRoom_Stage == 3) && C006_Isolation_Outro_StuckPillory && !C006_Isolation_Outro_StuckCross) DrawText(ctx, GetText("Outro1D"), 400, 150, "White");
|
||||
if ((C006_Isolation_IsolationRoom_Stage == 3) && !C006_Isolation_Outro_StuckPillory && C006_Isolation_Outro_StuckCross) DrawText(ctx, GetText("Outro1E"), 400, 150, "White");
|
||||
if (C006_Isolation_IsolationRoom_Stage <= 1) DrawText(GetText("Outro1A"), 400, 150, "White");
|
||||
if (C006_Isolation_IsolationRoom_Stage == 2) DrawText(GetText("Outro1B"), 400, 150, "White");
|
||||
if ((C006_Isolation_IsolationRoom_Stage == 3) && !C006_Isolation_Outro_StuckPillory && !C006_Isolation_Outro_StuckCross) DrawText(GetText("Outro1C"), 400, 150, "White");
|
||||
if ((C006_Isolation_IsolationRoom_Stage == 3) && C006_Isolation_Outro_StuckPillory && !C006_Isolation_Outro_StuckCross) DrawText(GetText("Outro1D"), 400, 150, "White");
|
||||
if ((C006_Isolation_IsolationRoom_Stage == 3) && !C006_Isolation_Outro_StuckPillory && C006_Isolation_Outro_StuckCross) DrawText(GetText("Outro1E"), 400, 150, "White");
|
||||
}
|
||||
if (C006_Isolation_Outro_EarlyRelease) DrawText(ctx, GetText("Outro1F"), 400, 150, "White");
|
||||
if (C006_Isolation_Outro_EarlyEscape) DrawText(ctx, GetText("Outro1G"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Outro2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Outro3"), 400, 450, "White");
|
||||
if (C006_Isolation_Outro_EarlyRelease) DrawText(GetText("Outro1F"), 400, 150, "White");
|
||||
if (C006_Isolation_Outro_EarlyEscape) DrawText(GetText("Outro1G"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Outro2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Outro3"), 400, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -10,15 +10,14 @@ function C007_LunchBreak_Intro_Load() {
|
|||
function C007_LunchBreak_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 450, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 450, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 450, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 450, 450, "White");
|
||||
DrawText(GetText("Intro1"), 450, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 450, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 450, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 450, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -20,47 +20,46 @@ function C007_LunchBreak_Outro_Load() {
|
|||
// Chapter 7 - Lunch Break Run
|
||||
function C007_LunchBreak_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
if (C007_LunchBreak_ActorSelect_Actor == "") DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/EatAlone.jpg", 800, 0);
|
||||
else DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
// Paints the background
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
if (C007_LunchBreak_ActorSelect_Actor == "") DrawImage(CurrentChapter + "/" + CurrentScreen + "/EatAlone.jpg", 800, 0);
|
||||
else DrawImage(CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
|
||||
// Special Natalie/Kinbaku dialog for the outro
|
||||
if (C007_LunchBreak_ActorSelect_Kinbaku) {
|
||||
if (TextPhase >= 0) DrawText(ctx, GetText("Kinbaku1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Kinbaku2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Kinbaku3"), 400, 450, "White");
|
||||
if (TextPhase >= 0) DrawText(GetText("Kinbaku1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Kinbaku2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Kinbaku3"), 400, 450, "White");
|
||||
} else {
|
||||
|
||||
// Text for eating alone
|
||||
if (C007_LunchBreak_ActorSelect_Actor == "") {
|
||||
if (TextPhase >= 0) DrawText(ctx, GetText("EatAlone1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("EatAlone2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("EatAlone3"), 400, 450, "White");
|
||||
if (TextPhase >= 0) DrawText(GetText("EatAlone1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("EatAlone2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("EatAlone3"), 400, 450, "White");
|
||||
}
|
||||
|
||||
// Text for no food leave
|
||||
if ((C007_LunchBreak_ActorSelect_Actor != "") && C007_LunchBreak_ActorSelect_NoFood) {
|
||||
if (TextPhase >= 0) DrawText(ctx, GetText("NoFood1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("NoFood2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("NoFood3"), 400, 450, "White");
|
||||
if (TextPhase >= 0) DrawText(GetText("NoFood1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("NoFood2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("NoFood3"), 400, 450, "White");
|
||||
}
|
||||
|
||||
// Text for early/evil leave
|
||||
if ((C007_LunchBreak_ActorSelect_Actor != "") && (C007_LunchBreak_ActorSelect_EarlyLeave || C007_LunchBreak_ActorSelect_EvilEnding) && !C007_LunchBreak_ActorSelect_NoFood) {
|
||||
if ((TextPhase >= 0) && !C007_LunchBreak_ActorSelect_EvilEnding) DrawText(ctx, GetText("Early1"), 400, 150, "White");
|
||||
if ((TextPhase >= 0) && C007_LunchBreak_ActorSelect_EvilEnding) DrawText(ctx, GetText("Evil1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("EvilEarly2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("EvilEarly3"), 400, 450, "White");
|
||||
if ((TextPhase >= 0) && !C007_LunchBreak_ActorSelect_EvilEnding) DrawText(GetText("Early1"), 400, 150, "White");
|
||||
if ((TextPhase >= 0) && C007_LunchBreak_ActorSelect_EvilEnding) DrawText(GetText("Evil1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("EvilEarly2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("EvilEarly3"), 400, 450, "White");
|
||||
}
|
||||
|
||||
// Text for eating with someone
|
||||
if ((C007_LunchBreak_ActorSelect_Actor != "") && !C007_LunchBreak_ActorSelect_EarlyLeave && !C007_LunchBreak_ActorSelect_EvilEnding && !C007_LunchBreak_ActorSelect_NoFood) {
|
||||
if (TextPhase >= 0) DrawText(ctx, GetText("RegularBonus1"), 400, 150, "White");
|
||||
if ((TextPhase >= 1) && C007_LunchBreak_ActorSelect_BonusDone) DrawText(ctx, GetText("Bonus2"), 400, 300, "White");
|
||||
if ((TextPhase >= 1) && !C007_LunchBreak_ActorSelect_BonusDone) DrawText(ctx, GetText("Regular2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("RegularBonus3"), 400, 450, "White");
|
||||
if (TextPhase >= 0) DrawText(GetText("RegularBonus1"), 400, 150, "White");
|
||||
if ((TextPhase >= 1) && C007_LunchBreak_ActorSelect_BonusDone) DrawText(GetText("Bonus2"), 400, 300, "White");
|
||||
if ((TextPhase >= 1) && !C007_LunchBreak_ActorSelect_BonusDone) DrawText(GetText("Regular2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("RegularBonus3"), 400, 450, "White");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -9,18 +9,17 @@ function C008_DramaClass_DressingRoom_Load() {
|
|||
function C008_DramaClass_DressingRoom_Run() {
|
||||
|
||||
// Draw the background image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
|
||||
// Draw Sarah
|
||||
if (!GameLogQuery("C007_LunchBreak", "Sarah", "Stranded")) {
|
||||
if (C008_DramaClass_SarahIntro_CurrentStage == 0) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/SarahSearch.png", 0, 0);
|
||||
if (C008_DramaClass_SarahIntro_CurrentStage == 0) DrawImage(CurrentChapter + "/" + CurrentScreen + "/SarahSearch.png", 0, 0);
|
||||
else DrawActor("Sarah", 130, 50, 0.575);
|
||||
}
|
||||
|
||||
// Draw Amanda
|
||||
if (!GameLogQuery("C007_LunchBreak", "Amanda", "Stranded")) {
|
||||
if (C008_DramaClass_AmandaIntro_CurrentStage == 0) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/AmandaSearch.png", 800, 0);
|
||||
if (C008_DramaClass_AmandaIntro_CurrentStage == 0) DrawImage(CurrentChapter + "/" + CurrentScreen + "/AmandaSearch.png", 800, 0);
|
||||
else DrawActor("Amanda", 800, 50, 0.575);
|
||||
}
|
||||
|
||||
|
|
|
@ -10,15 +10,14 @@ function C008_DramaClass_Intro_Load() {
|
|||
function C008_DramaClass_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 450, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 450, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 450, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 450, 450, "White");
|
||||
DrawText(GetText("Intro1"), 450, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 450, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 450, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 450, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -30,31 +30,30 @@ function C008_DramaClass_Outro_Load() {
|
|||
function C008_DramaClass_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
|
||||
// If there was a crime that leads to chapter 10
|
||||
if ((C008_DramaClass_Outro_Crime == "AmandaStranded") || (C008_DramaClass_Outro_Crime == "SarahStranded") || (C008_DramaClass_Outro_Crime == "SidneyStranded") || (C008_DramaClass_Outro_Crime == "JenniferStranded")) {
|
||||
|
||||
// Draw the outro text to lead to chapter 10
|
||||
DrawText(ctx, GetText("Outro1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Outro2"), 400, 250, "White");
|
||||
if ((TextPhase >= 2) && ((C008_DramaClass_Outro_Crime == "AmandaStranded") || (C008_DramaClass_Outro_Crime == "SarahStranded"))) DrawText(ctx, GetText("AmandaSarah3"), 400, 350, "White");
|
||||
if ((TextPhase >= 3) && ((C008_DramaClass_Outro_Crime == "AmandaStranded") || (C008_DramaClass_Outro_Crime == "SarahStranded"))) DrawText(ctx, GetText("AmandaSarah4"), 400, 450, "White");
|
||||
if ((TextPhase >= 2) && ((C008_DramaClass_Outro_Crime == "SidneyStranded") || (C008_DramaClass_Outro_Crime == "JenniferStranded"))) DrawText(ctx, GetText("SidneyJennifer3"), 400, 350, "White");
|
||||
if ((TextPhase >= 3) && ((C008_DramaClass_Outro_Crime == "SidneyStranded") || (C008_DramaClass_Outro_Crime == "JenniferStranded"))) DrawText(ctx, GetText("SidneyJennifer4"), 400, 450, "White");
|
||||
DrawText(GetText("Outro1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Outro2"), 400, 250, "White");
|
||||
if ((TextPhase >= 2) && ((C008_DramaClass_Outro_Crime == "AmandaStranded") || (C008_DramaClass_Outro_Crime == "SarahStranded"))) DrawText(GetText("AmandaSarah3"), 400, 350, "White");
|
||||
if ((TextPhase >= 3) && ((C008_DramaClass_Outro_Crime == "AmandaStranded") || (C008_DramaClass_Outro_Crime == "SarahStranded"))) DrawText(GetText("AmandaSarah4"), 400, 450, "White");
|
||||
if ((TextPhase >= 2) && ((C008_DramaClass_Outro_Crime == "SidneyStranded") || (C008_DramaClass_Outro_Crime == "JenniferStranded"))) DrawText(GetText("SidneyJennifer3"), 400, 350, "White");
|
||||
if ((TextPhase >= 3) && ((C008_DramaClass_Outro_Crime == "SidneyStranded") || (C008_DramaClass_Outro_Crime == "JenniferStranded"))) DrawText(GetText("SidneyJennifer4"), 400, 450, "White");
|
||||
|
||||
// The image changes to show the girls
|
||||
if (TextPhase <= 1) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
if ((TextPhase >= 2) && ((C008_DramaClass_Outro_Crime == "AmandaStranded") || (C008_DramaClass_Outro_Crime == "SarahStranded"))) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/AmandaSarah.jpg", 800, 0);
|
||||
if ((TextPhase >= 2) && ((C008_DramaClass_Outro_Crime == "SidneyStranded") || (C008_DramaClass_Outro_Crime == "JenniferStranded"))) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/SidneyJennifer.jpg", 800, 0);
|
||||
if (TextPhase <= 1) DrawImage(CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
if ((TextPhase >= 2) && ((C008_DramaClass_Outro_Crime == "AmandaStranded") || (C008_DramaClass_Outro_Crime == "SarahStranded"))) DrawImage(CurrentChapter + "/" + CurrentScreen + "/AmandaSarah.jpg", 800, 0);
|
||||
if ((TextPhase >= 2) && ((C008_DramaClass_Outro_Crime == "SidneyStranded") || (C008_DramaClass_Outro_Crime == "JenniferStranded"))) DrawImage(CurrentChapter + "/" + CurrentScreen + "/SidneyJennifer.jpg", 800, 0);
|
||||
|
||||
} else {
|
||||
|
||||
// Draw the outro text to lead to chapter 9
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
DrawText(ctx, GetText("Outro1"), 400, 200, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Outro2"), 400, 400, "White");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
DrawText(GetText("Outro1"), 400, 200, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Outro2"), 400, 400, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -113,15 +113,12 @@ function C008_DramaClass_Theater_Load() {
|
|||
// Chapter 8 - Theater Run
|
||||
function C008_DramaClass_Theater_Run() {
|
||||
|
||||
// Draw the background image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
|
||||
// Draw the 3 actresses and Julia
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawActor(C008_DramaClass_Theater_Damsel, 50, 60, 0.55);
|
||||
DrawActor(C008_DramaClass_Theater_Villain, 300, 60, 0.55);
|
||||
DrawActor(C008_DramaClass_Theater_Heroine, 850, 60, 0.55);
|
||||
if (C008_DramaClass_Theater_GlobalStage < 300) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Julia.png", 550, 250);
|
||||
if (C008_DramaClass_Theater_GlobalStage < 300) DrawImage(CurrentChapter + "/" + CurrentScreen + "/Julia.png", 550, 250);
|
||||
else DrawActor("Julia", 575, 60, 0.55);
|
||||
|
||||
}
|
||||
|
|
|
@ -26,20 +26,19 @@ function C008_DramaClass_Transition_Load() {
|
|||
function C008_DramaClass_Transition_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Julia.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Julia.jpg", 800, 0);
|
||||
|
||||
// Sets if the transition is late or not
|
||||
var LateForDrama = "Transition";
|
||||
if (CurrentTime == 13.5 * 60 * 60 * 1000) LateForDrama = "Late";
|
||||
|
||||
// Draw the outro text
|
||||
DrawText(ctx, GetText(LateForDrama + "1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText(LateForDrama + "2"), 400, 300, "White");
|
||||
if ((TextPhase >= 2) && !GameLogQuery("C007_LunchBreak", "Amanda", "Stranded") && !GameLogQuery("C007_LunchBreak", "Sarah", "Stranded")) DrawText(ctx, GetText(LateForDrama + "3"), 400, 450, "White");
|
||||
if ((TextPhase >= 2) && GameLogQuery("C007_LunchBreak", "Amanda", "Stranded")) DrawText(ctx, GetText("Amanda"), 400, 450, "White");
|
||||
if ((TextPhase >= 2) && GameLogQuery("C007_LunchBreak", "Sarah", "Stranded")) DrawText(ctx, GetText("Sarah"), 400, 450, "White");
|
||||
DrawText(GetText(LateForDrama + "1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText(LateForDrama + "2"), 400, 300, "White");
|
||||
if ((TextPhase >= 2) && !GameLogQuery("C007_LunchBreak", "Amanda", "Stranded") && !GameLogQuery("C007_LunchBreak", "Sarah", "Stranded")) DrawText(GetText(LateForDrama + "3"), 400, 450, "White");
|
||||
if ((TextPhase >= 2) && GameLogQuery("C007_LunchBreak", "Amanda", "Stranded")) DrawText(GetText("Amanda"), 400, 450, "White");
|
||||
if ((TextPhase >= 2) && GameLogQuery("C007_LunchBreak", "Sarah", "Stranded")) DrawText(GetText("Sarah"), 400, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -11,16 +11,15 @@ function C009_Library_Intro_Load() {
|
|||
function C009_Library_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 450, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 450, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 450, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 450, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Intro5"), 450, 500, "White");
|
||||
DrawText(GetText("Intro1"), 450, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 450, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 450, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 450, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Intro5"), 450, 500, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -20,48 +20,45 @@ function C009_Library_Library_Load() {
|
|||
}
|
||||
|
||||
// Draw the navigation arrows
|
||||
function C009_Library_Library_Navigation(ctx, Zone, Direction, X, Y) {
|
||||
function C009_Library_Library_Navigation(Zone, Direction, X, Y) {
|
||||
if (C009_Library_Library_CurrentZone == Zone) {
|
||||
var Active = false;
|
||||
if ((MouseX >= X) && (MouseX <= X + 200) && (MouseY >= Y) && (MouseY <= Y + 200) && !IsMobile) Active = true;
|
||||
if ((Direction == "Up") && Active) DrawImage(ctx, Icons.Navigation.ArrowUpActive, X, Y);
|
||||
if ((Direction == "Up") && !Active) DrawImage(ctx, Icons.Navigation.ArrowUpInactive, X, Y);
|
||||
if ((Direction == "Down") && Active) DrawImage(ctx, Icons.Navigation.ArrowDownActive, X, Y);
|
||||
if ((Direction == "Down") && !Active) DrawImage(ctx, Icons.Navigation.ArrowDownInactive, X, Y);
|
||||
if ((Direction == "Left") && Active) DrawImage(ctx, Icons.Navigation.ArrowLeftActive, X, Y);
|
||||
if ((Direction == "Left") && !Active) DrawImage(ctx, Icons.Navigation.ArrowLeftInactive, X, Y);
|
||||
if ((Direction == "Right") && Active) DrawImage(ctx, Icons.Navigation.ArrowRightActive, X, Y);
|
||||
if ((Direction == "Right") && !Active) DrawImage(ctx, Icons.Navigation.ArrowRightInactive, X, Y);
|
||||
if ((Direction == "Up") && Active) DrawImage(Icons.Navigation.ArrowUpActive, X, Y);
|
||||
if ((Direction == "Up") && !Active) DrawImage(Icons.Navigation.ArrowUpInactive, X, Y);
|
||||
if ((Direction == "Down") && Active) DrawImage(Icons.Navigation.ArrowDownActive, X, Y);
|
||||
if ((Direction == "Down") && !Active) DrawImage(Icons.Navigation.ArrowDownInactive, X, Y);
|
||||
if ((Direction == "Left") && Active) DrawImage(Icons.Navigation.ArrowLeftActive, X, Y);
|
||||
if ((Direction == "Left") && !Active) DrawImage(Icons.Navigation.ArrowLeftInactive, X, Y);
|
||||
if ((Direction == "Right") && Active) DrawImage(Icons.Navigation.ArrowRightActive, X, Y);
|
||||
if ((Direction == "Right") && !Active) DrawImage(Icons.Navigation.ArrowRightInactive, X, Y);
|
||||
}
|
||||
}
|
||||
|
||||
// Chapter 9 - Library Run
|
||||
function C009_Library_Library_Run() {
|
||||
|
||||
// Draw the background image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + C009_Library_Library_CurrentZone + ".jpg", 0, 0);
|
||||
|
||||
// Draw the navigation arrows
|
||||
C009_Library_Library_Navigation(ctx, "001", "Left", 0, 400);
|
||||
C009_Library_Library_Navigation(ctx, "001", "Up", 500, 350);
|
||||
C009_Library_Library_Navigation(ctx, "001", "Right", 1000, 400);
|
||||
C009_Library_Library_Navigation(ctx, "002", "Up", 500, 200);
|
||||
C009_Library_Library_Navigation(ctx, "002", "Down", 500, 400);
|
||||
C009_Library_Library_Navigation(ctx, "002", "Left", 0, 400);
|
||||
C009_Library_Library_Navigation(ctx, "002", "Right", 1000, 400);
|
||||
C009_Library_Library_Navigation(ctx, "003", "Down", 500, 400);
|
||||
C009_Library_Library_Navigation(ctx, "004", "Up", 780, 150);
|
||||
C009_Library_Library_Navigation(ctx, "004", "Left", 80, 200);
|
||||
C009_Library_Library_Navigation(ctx, "004", "Left", 550, 150);
|
||||
C009_Library_Library_Navigation(ctx, "005", "Down", 500, 400);
|
||||
C009_Library_Library_Navigation(ctx, "006", "Right", 600, 200);
|
||||
C009_Library_Library_Navigation(ctx, "006", "Left", 400, 200);
|
||||
C009_Library_Library_Navigation(ctx, "006", "Down", 500, 400);
|
||||
C009_Library_Library_Navigation(ctx, "007", "Down", 500, 400);
|
||||
// Draw the background image and navigation arrows
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + C009_Library_Library_CurrentZone + ".jpg", 0, 0);
|
||||
C009_Library_Library_Navigation("001", "Left", 0, 400);
|
||||
C009_Library_Library_Navigation("001", "Up", 500, 350);
|
||||
C009_Library_Library_Navigation("001", "Right", 1000, 400);
|
||||
C009_Library_Library_Navigation("002", "Up", 500, 200);
|
||||
C009_Library_Library_Navigation("002", "Down", 500, 400);
|
||||
C009_Library_Library_Navigation("002", "Left", 0, 400);
|
||||
C009_Library_Library_Navigation("002", "Right", 1000, 400);
|
||||
C009_Library_Library_Navigation("003", "Down", 500, 400);
|
||||
C009_Library_Library_Navigation("004", "Up", 780, 150);
|
||||
C009_Library_Library_Navigation("004", "Left", 80, 200);
|
||||
C009_Library_Library_Navigation("004", "Left", 550, 150);
|
||||
C009_Library_Library_Navigation("005", "Down", 500, 400);
|
||||
C009_Library_Library_Navigation("006", "Right", 600, 200);
|
||||
C009_Library_Library_Navigation("006", "Left", 400, 200);
|
||||
C009_Library_Library_Navigation("006", "Down", 500, 400);
|
||||
C009_Library_Library_Navigation("007", "Down", 500, 400);
|
||||
|
||||
// TO REMOVE
|
||||
if ((C009_Library_Library_CurrentZone == "005") || (C009_Library_Library_CurrentZone == "007")) DrawText(ctx, "This zone will be available in another version", 600, 175, "white");
|
||||
if ((C009_Library_Library_CurrentZone == "005") || (C009_Library_Library_CurrentZone == "007")) DrawText("This zone will be available in another version", 600, 175, "white");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -15,14 +15,13 @@ function C009_Library_Outro_Load() {
|
|||
function C009_Library_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
|
||||
// Draw the outro text to lead to chapter 12
|
||||
DrawText(ctx, GetText("Outro1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Outro2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Outro3"), 400, 450, "White");
|
||||
DrawText(GetText("Outro1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Outro2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Outro3"), 400, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
15
C009_Library/Yuki/Intro_EN.csv
Normal file
15
C009_Library/Yuki/Intro_EN.csv
Normal file
|
@ -0,0 +1,15 @@
|
|||
Stage,LoveReq,SubReq,VarReq,IntroText,Image
|
||||
0,0,0,,"Good afternoon young lady. I've never|seen you before, are you a new student?",Library.jpg
|
||||
1,0,0,,Please don't make too much noise in the library.,Library.jpg
|
||||
10,0,0,,Yummy! My little pet girl is back.|I hope you remember our deal.,Library.jpg
|
||||
20,0,0,,Here you are! I've been searching for|you for hours. How did you escape?,Library.jpg
|
||||
30,0,0,,"So my ""good for nothing"" pet has came back.|I hope you learned something from isolation.",Library.jpg
|
||||
40,0,0,,I hope you learned something from isolation.|Are you now staying away from trouble?,Library.jpg
|
||||
50,0,0,,You must be COMMON_PLAYERNAME.|Mildred told me about you.,Library.jpg
|
||||
60,0,0,,"Young lady, I hope you will not fight again and|that you've learned a lesson from your detention.",Library.jpg
|
||||
70,0,0,,"Young lady, I hope you will not cause trouble again|and that you've learned a lesson from your detention.",Library.jpg
|
||||
80,0,0,,Which book are you looking for?,Library.jpg
|
||||
81,0,0,,Which book are you looking for?,Library.jpg
|
||||
82,0,0,,"Try the literature section. From the|main aisle, second shelve to your left.",Library.jpg
|
||||
100,0,0,,Is there anything else you need?,Library.jpg
|
||||
100,-3,0,,(She gives you an angry look.)|What do you want now?,Library.jpg
|
|
BIN
C009_Library/Yuki/Library.jpg
Normal file
BIN
C009_Library/Yuki/Library.jpg
Normal file
Binary file not shown.
After ![]() (image error) Size: 293 KiB |
66
C009_Library/Yuki/Script.js
Normal file
66
C009_Library/Yuki/Script.js
Normal file
|
@ -0,0 +1,66 @@
|
|||
var C009_Library_Yuki_CurrentStage = 0;
|
||||
var C009_Library_Yuki_BookAlreadyFound = false;
|
||||
var C009_Library_Yuki_DetentionBondage = false;
|
||||
var C009_Library_Yuki_DetentionFighting = false;
|
||||
var C009_Library_Yuki_IsolationMildred = false;
|
||||
var C009_Library_Yuki_IsolationYuki = false;
|
||||
var C009_Library_Yuki_IsolationPleasureYuki = false;
|
||||
var C009_Library_Yuki_IsolationOrgasmYuki = false;
|
||||
var C009_Library_Yuki_IsolationEarlyReleaseYuki = false;
|
||||
var C009_Library_Yuki_IsolationEscapeYuki = false;
|
||||
var C009_Library_Yuki_HasEgg = false;
|
||||
|
||||
// Chapter 9 Library - Yuki Load
|
||||
function C009_Library_Yuki_Load() {
|
||||
|
||||
// Load the scene parameters
|
||||
ActorLoad("Yuki", "Library");
|
||||
LoadInteractions();
|
||||
Common_SelfBondageAllowed = false;
|
||||
|
||||
// A few variables on what already happened
|
||||
C009_Library_Yuki_BookAlreadyFound = (C009_Library_Library_BookProgress > 40);
|
||||
C009_Library_Yuki_DetentionBondage = GameLogQuery("C001_BeforeClass", "Sidney", "PublicBondage");
|
||||
C009_Library_Yuki_DetentionFighting = (GameLogQuery("C001_BeforeClass", "Sidney", "FightVictory") || GameLogQuery("C001_BeforeClass", "Sidney", "FightDefeat"));
|
||||
C009_Library_Yuki_IsolationMildred = (GameLogQuery("C002_FirstClass", "Mildred", "Subdue") && GameLogQuery("C006_Isolation", "", "Isolation"));
|
||||
C009_Library_Yuki_IsolationYuki = (GameLogQuery("C002_FirstClass", "Yuki", "Drug") && GameLogQuery("C006_Isolation", "", "Isolation"));
|
||||
C009_Library_Yuki_IsolationPleasureYuki = GameLogQuery("C006_Isolation", "Yuki", "Pleasure");
|
||||
C009_Library_Yuki_IsolationOrgasmYuki = GameLogQuery("C006_Isolation", "Yuki", "Orgasm");
|
||||
C009_Library_Yuki_IsolationEarlyReleaseYuki = (GameLogQuery("C006_Isolation", "", "Release") && C009_Library_Yuki_IsolationYuki);
|
||||
C009_Library_Yuki_IsolationEscapeYuki = (GameLogQuery("C006_Isolation", "", "Escape") && C009_Library_Yuki_IsolationYuki);
|
||||
C009_Library_Yuki_HasEgg = ActorHasInventory("VibratingEgg");
|
||||
|
||||
// The first dialog can be different depending on what happened before
|
||||
if ((C009_Library_Yuki_CurrentStage == 0) && C009_Library_Yuki_IsolationOrgasmYuki && C009_Library_Yuki_IsolationEarlyReleaseYuki) C009_Library_Yuki_CurrentStage = 10;
|
||||
if ((C009_Library_Yuki_CurrentStage == 0) && C009_Library_Yuki_IsolationEscapeYuki) C009_Library_Yuki_CurrentStage = 20;
|
||||
if ((C009_Library_Yuki_CurrentStage == 0) && C009_Library_Yuki_IsolationPleasureYuki && !C009_Library_Yuki_IsolationOrgasmYuki) C009_Library_Yuki_CurrentStage = 30;
|
||||
if ((C009_Library_Yuki_CurrentStage == 0) && C009_Library_Yuki_IsolationYuki) C009_Library_Yuki_CurrentStage = 40;
|
||||
if ((C009_Library_Yuki_CurrentStage == 0) && C009_Library_Yuki_IsolationMildred) C009_Library_Yuki_CurrentStage = 50;
|
||||
if ((C009_Library_Yuki_CurrentStage == 0) && C009_Library_Yuki_DetentionFighting) C009_Library_Yuki_CurrentStage = 60;
|
||||
if ((C009_Library_Yuki_CurrentStage == 0) && C009_Library_Yuki_DetentionBondage) C009_Library_Yuki_CurrentStage = 70;
|
||||
|
||||
}
|
||||
|
||||
// Chapter 9 Library - Yuki Run
|
||||
function C009_Library_Yuki_Run() {
|
||||
BuildInteraction(C009_Library_Yuki_CurrentStage);
|
||||
DrawInteractionActor();
|
||||
}
|
||||
|
||||
// Chapter 9 Library - Yuki Click
|
||||
function C009_Library_Yuki_Click() {
|
||||
|
||||
// Regular and inventory interactions
|
||||
ClickInteraction(C009_Library_Yuki_CurrentStage);
|
||||
var ClickInv = GetClickedInventory();
|
||||
if (ClickInv == "Player") {
|
||||
C009_Library_Yuki_IntroText = OverridenIntroText;
|
||||
InventoryClick(ClickInv, CurrentChapter, CurrentScreen);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Chapter 9 Library - Yuki - When the player leaves
|
||||
function C009_Library_Yuki_PlayerLeave() {
|
||||
SetScene(CurrentChapter, "Library");
|
||||
}
|
18
C009_Library/Yuki/Stage_EN.csv
Normal file
18
C009_Library/Yuki/Stage_EN.csv
Normal file
|
@ -0,0 +1,18 @@
|
|||
Stage,LoveReq,SubReq,VarReq,Interaction,Result,NextStage,LoveMod,SubMod,Function
|
||||
0,0,0,,"Yes, it's my|first day here.","Welcome to our college then, I'm Teacher Yuki.|Don't make too much noise in the library.",1,0,0,
|
||||
0,0,0,,I'm surprised you|haven't heard of me.,I haven't heard of you. I'm Teacher Yuki.|Don't make too much noise in the library.,1,0,1,
|
||||
0,0,0,,"Yes Miss, a new|school is always scary.","Don't be scared, it will be fine, I'm Teacher Yuki.|Please don't make too much noise in the library.",1,0,-1,
|
||||
1,0,0,,(Nod silently.),Excellent. So are you|looking for a specific book?,80,1,-1,
|
||||
1,0,0,,"Yeah, yeah, I know.",(She gives you an angry look.)|Are you looking for a specific book?,80,-1,1,
|
||||
1,0,0,,I'll keep quiet.,Very well. So are you|looking for a specific book?,80,0,0,
|
||||
80,0,0,BookAlreadyFound,I've already|found my book.,Very well. You may find a|place to read in silence.,100,0,0,
|
||||
80,0,0,,The Count of|Monte Cristo.,"Try the literature section. From the|main aisle, second shelve to your left.",82,0,0,
|
||||
80,0,0,,Fifty Shades of Grey.,"Young lady, you will not find|such trash in our fine establishment.",81,-1,0,
|
||||
80,0,0,,Justine from the|Marquis de Sade.,You're not mature enough for this kind of literature.|This book isn't allowed for first year students.,81,1,1,
|
||||
81,0,0,,"I also need ""The Count|of Monte Cristo.""","Try the literature section. From the|main aisle, second shelve to your left.",82,0,0,
|
||||
81,0,0,,Thank you Miss.|(Walk away.),,100,0,1,PlayerLeave()
|
||||
81,0,0,,Thanks Yuki!|(Walk away.),,100,0,0,PlayerLeave()
|
||||
81,0,0,,(Walk away.),,100,-1,0,PlayerLeave()
|
||||
82,0,0,,Thank you Miss.|(Walk away.),,100,0,1,PlayerLeave()
|
||||
82,0,0,,Thanks Yuki!|(Walk away.),,100,0,0,PlayerLeave()
|
||||
82,0,0,,(Walk away.),,100,-1,0,PlayerLeave()
|
|
1
C009_Library/Yuki/Text_EN.csv
Normal file
1
C009_Library/Yuki/Text_EN.csv
Normal file
|
@ -0,0 +1 @@
|
|||
Tag,Content
|
|
|
@ -24,15 +24,14 @@ function C010_Revenge_EarlyEnding_Load() {
|
|||
function C010_Revenge_EarlyEnding_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
|
||||
// Draw the outro text
|
||||
DrawText(ctx, GetText(C010_Revenge_EarlyEnding_Type + "1"), 450, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText(C010_Revenge_EarlyEnding_Type + "2"), 450, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText(C010_Revenge_EarlyEnding_Type + "3"), 450, 450, "White");
|
||||
DrawText(GetText(C010_Revenge_EarlyEnding_Type + "1"), 450, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText(C010_Revenge_EarlyEnding_Type + "2"), 450, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText(C010_Revenge_EarlyEnding_Type + "3"), 450, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -17,28 +17,25 @@ function C010_Revenge_Intro_Load() {
|
|||
|
||||
// Chapter 10 - Revenge Run
|
||||
function C010_Revenge_Intro_Run() {
|
||||
|
||||
// Prepares the canvas
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
|
||||
// Amanda or Sarah intro
|
||||
if (GameLogQuery("C007_LunchBreak", "Amanda", "Stranded") || GameLogQuery("C007_LunchBreak", "Sarah", "Stranded")) {
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/BackgroundAmandaSarah.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawText(ctx, GetText("AmandaSarah1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("AmandaSarah2"), 400, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("AmandaSarah3"), 400, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("AmandaSarah4"), 400, 450, "White");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/BackgroundAmandaSarah.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
DrawText(GetText("AmandaSarah1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("AmandaSarah2"), 400, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("AmandaSarah3"), 400, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("AmandaSarah4"), 400, 450, "White");
|
||||
}
|
||||
|
||||
// Sidney or Jennifer intro
|
||||
if (GameLogQuery("C007_LunchBreak", "Sidney", "Stranded") || GameLogQuery("C007_LunchBreak", "Jennifer", "Stranded")) {
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/BackgroundSidneyJennifer.jpg", 0, 0);
|
||||
DrawPlayerTransition(ctx);
|
||||
DrawText(ctx, GetText("SidneyJennifer1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("SidneyJennifer2"), 400, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("SidneyJennifer3"), 400, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("SidneyJennifer4"), 400, 450, "White");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/BackgroundSidneyJennifer.jpg", 0, 0);
|
||||
DrawPlayerTransition();
|
||||
DrawText(GetText("SidneyJennifer1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("SidneyJennifer2"), 400, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("SidneyJennifer3"), 400, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("SidneyJennifer4"), 400, 450, "White");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -24,8 +24,7 @@ function C010_Revenge_Outro_Load() {
|
|||
function C010_Revenge_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
|
||||
// Sets the correct text to fetch
|
||||
var OutroText = "";
|
||||
|
@ -33,14 +32,14 @@ function C010_Revenge_Outro_Run() {
|
|||
if (GameLogQuery("C007_LunchBreak", "Sidney", "Stranded") || GameLogQuery("C007_LunchBreak", "Jennifer", "Stranded")) OutroText = "SidneyJennifer";
|
||||
|
||||
// Draw the background image
|
||||
if (TextPhase >= 2) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
if (TextPhase < 2) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + OutroText + ".jpg", 800, 0);
|
||||
if (TextPhase >= 2) DrawImage(CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
if (TextPhase < 2) DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + OutroText + ".jpg", 800, 0);
|
||||
|
||||
// Shows the text
|
||||
if (C010_Revenge_Outro_GoodEnding) OutroText = OutroText + "Good";
|
||||
DrawText(ctx, GetText(OutroText + "1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText(OutroText + "2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText(OutroText + "3"), 400, 450, "White");
|
||||
DrawText(GetText(OutroText + "1"), 400, 150, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText(OutroText + "2"), 400, 300, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText(OutroText + "3"), 400, 450, "White");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -8,24 +8,23 @@ function C101_KinbakuClub_ClubRoom1_Load() {
|
|||
function C101_KinbakuClub_ClubRoom1_Run() {
|
||||
|
||||
// Draw the background image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/ClubRoom1Arrows.jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/ClubRoom1Arrows.jpg", 0, 0);
|
||||
|
||||
// Draw Lauren
|
||||
if (!C101_KinbakuClub_Lauren_LaurenChairCuffed) {
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenStart.png", 230, 155);
|
||||
if (C101_KinbakuClub_Lauren_BlindfoldAvailable && C101_KinbakuClub_Lauren_CurrentStage <= 220) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenStartBlindfold.png", 420, 305);
|
||||
if (C101_KinbakuClub_Lauren_CurrentStage < 150) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenStartCuffs.png", 450, 325);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenStart.png", 230, 155);
|
||||
if (C101_KinbakuClub_Lauren_BlindfoldAvailable && C101_KinbakuClub_Lauren_CurrentStage <= 220) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenStartBlindfold.png", 420, 305);
|
||||
if (C101_KinbakuClub_Lauren_CurrentStage < 150) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenStartCuffs.png", 450, 325);
|
||||
}
|
||||
if (C101_KinbakuClub_Lauren_LaurenChairCuffed) {
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenChair.jpg", 230, 150);
|
||||
if (C101_KinbakuClub_Lauren_LaurenBallGagged) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenChairBallGag.jpg", 570, 190);
|
||||
if (C101_KinbakuClub_Lauren_LaurenTapeGagged) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenChairTapeGag.jpg", 570, 190);
|
||||
if (C101_KinbakuClub_Lauren_LaurenClothGagged) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenChairClothGag.jpg", 570, 190);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenChair.jpg", 230, 150);
|
||||
if (C101_KinbakuClub_Lauren_LaurenBallGagged) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenChairBallGag.jpg", 570, 190);
|
||||
if (C101_KinbakuClub_Lauren_LaurenTapeGagged) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenChairTapeGag.jpg", 570, 190);
|
||||
if (C101_KinbakuClub_Lauren_LaurenClothGagged) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenChairClothGag.jpg", 570, 190);
|
||||
}
|
||||
|
||||
//Draw Rope Discussion
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/RopeDiscussion1.jpg", 690, 100);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/RopeDiscussion1.jpg", 690, 100);
|
||||
}
|
||||
|
||||
// Chapter 101 - Club Room 1 Click
|
||||
|
|
|
@ -8,22 +8,21 @@ function C101_KinbakuClub_ClubRoom2_Load() {
|
|||
function C101_KinbakuClub_ClubRoom2_Run() {
|
||||
|
||||
// Draw the background image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/ClubRoom2Arrows.jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/ClubRoom2Arrows.jpg", 0, 0);
|
||||
|
||||
// Draw erica when tied
|
||||
if (C101_KinbakuClub_Erica_EricaTied) {
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/EricaBoundBackground.png", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/EricaBoundBackground.png", 0, 0);
|
||||
DrawActor("Erica", 0, 265, 0.4);
|
||||
}
|
||||
if (C101_KinbakuClub_Erica_EricaLeftCuffed) {
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/EricaBoundBackground.png", 0, 0);
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/EricaLeftCollaredCuffs.jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/EricaBoundBackground.png", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/EricaLeftCollaredCuffs.jpg", 0, 0);
|
||||
}
|
||||
if (!C101_KinbakuClub_Erica_EricaTied && !C101_KinbakuClub_Erica_EricaLeftCuffed) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/EricaStart.png", 0, 0);
|
||||
if (!C101_KinbakuClub_Erica_EricaTied && !C101_KinbakuClub_Erica_EricaLeftCuffed) DrawImage(CurrentChapter + "/" + CurrentScreen + "/EricaStart.png", 0, 0);
|
||||
|
||||
// Draw Cassidy and Alyssa
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/CassidyAlyssa.jpg", 800, 100);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/CassidyAlyssa.jpg", 800, 100);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -8,17 +8,16 @@ function C101_KinbakuClub_ClubRoom3_Load() {
|
|||
function C101_KinbakuClub_ClubRoom3_Run() {
|
||||
|
||||
// Draw the background image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/ClubRoom3Arrows.jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/ClubRoom3Arrows.jpg", 0, 0);
|
||||
|
||||
// Draw Chloe
|
||||
//if (C101_KinbakuClub_Chloe_CurrentStage == 0) {
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/ChloeBoard.png", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/ChloeBoard.png", 0, 0);
|
||||
//} else DrawActor("Chloe", 220, 170, 0.3333);
|
||||
|
||||
|
||||
// Draw CardGamers
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/CardGamers1.jpg", 570, 130);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/CardGamers1.jpg", 570, 130);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -9,23 +9,22 @@ function C101_KinbakuClub_Discipline_Load() {
|
|||
function C101_KinbakuClub_Discipline_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
if (TextPhase >= 0) {
|
||||
if (C101_KinbakuClub_Lauren_BullyCount >= 10) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/JennaGrab.jpg", 800, 0); // needs jenna grabbing player jpg
|
||||
else DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/JennaBlocking.jpg", 800, 0); // needs jenna blocking doorway jpg
|
||||
if (C101_KinbakuClub_Lauren_BullyCount >= 10) DrawImage(CurrentChapter + "/" + CurrentScreen + "/JennaGrab.jpg", 800, 0); // needs jenna grabbing player jpg
|
||||
else DrawImage(CurrentChapter + "/" + CurrentScreen + "/JennaBlocking.jpg", 800, 0); // needs jenna blocking doorway jpg
|
||||
}
|
||||
if (TextPhase >= 1) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/BagBlack.jpg", 800, 0);
|
||||
if (TextPhase >= 1) DrawImage(CurrentChapter + "/" + CurrentScreen + "/BagBlack.jpg", 800, 0);
|
||||
|
||||
// Dialog depending on the outro situation
|
||||
if (TextPhase >= 0) {
|
||||
if (C101_KinbakuClub_Lauren_BullyCount >= 10) DrawText(ctx, GetText("Bully1"), 400, 120, "White");
|
||||
else DrawText(ctx, GetText("Discipline1"), 400, 120, "White");
|
||||
if (C101_KinbakuClub_Lauren_BullyCount >= 10) DrawText(GetText("Bully1"), 400, 120, "White");
|
||||
else DrawText(GetText("Discipline1"), 400, 120, "White");
|
||||
}
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Discipline2"), 400, 240, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Discipline3"), 400, 360, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Discipline2"), 400, 240, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Discipline3"), 400, 360, "White");
|
||||
if (TextPhase >= 3) {
|
||||
DrawText(ctx, GetText("Discipline4"), 400, 480, "White");
|
||||
DrawText(GetText("Discipline4"), 400, 480, "White");
|
||||
PlayerLockInventory("Rope");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -11,62 +11,61 @@ function C101_KinbakuClub_EricaBadEnd_Load() {
|
|||
function C101_KinbakuClub_EricaBadEnd_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 700, 600, "black");
|
||||
DrawRect(0, 0, 700, 600, "black");
|
||||
|
||||
// Dialog depending on the outro situation
|
||||
if (TextPhase >= 0) {
|
||||
if (C101_KinbakuClub_Erica_EricaTied) DrawText(ctx, GetText("BadEnd1Dressed"), 350, 50, "White");
|
||||
if (!C101_KinbakuClub_Erica_EricaTied) DrawText(ctx, GetText("BadEnd1Free"), 350, 50, "White");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/EricaPinsPlayer.jpg", 700, 0);
|
||||
if (C101_KinbakuClub_Erica_EricaTied) DrawText(GetText("BadEnd1Dressed"), 350, 50, "White");
|
||||
if (!C101_KinbakuClub_Erica_EricaTied) DrawText(GetText("BadEnd1Free"), 350, 50, "White");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/EricaPinsPlayer.jpg", 700, 0);
|
||||
}
|
||||
if (TextPhase >= 1) {
|
||||
DrawText(ctx, GetText("BadEnd2"), 350, 100, "White");
|
||||
DrawText(GetText("BadEnd2"), 350, 100, "White");
|
||||
//CurrentTime = CurrentTime + 10000;
|
||||
//TextPhase++;
|
||||
}
|
||||
if (TextPhase >= 2) {
|
||||
DrawText(ctx, GetText("BadEnd3"), 350, 150, "White")
|
||||
DrawText(GetText("BadEnd3"), 350, 150, "White")
|
||||
//CurrentTime = CurrentTime + 10000;
|
||||
//TextPhase++;
|
||||
}
|
||||
if (TextPhase >= 3) {
|
||||
DrawText(ctx, GetText("BadEnd4"), 350, 200, "White");
|
||||
DrawText(GetText("BadEnd4"), 350, 200, "White");
|
||||
//CurrentTime = CurrentTime + 180000;
|
||||
//TextPhase++;
|
||||
PlayerLockInventory("Rope");
|
||||
PlayerLockInventory("BallGag");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/EricaBindsPlayer.jpg", 700, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/EricaBindsPlayer.jpg", 700, 0);
|
||||
}
|
||||
if (TextPhase >= 4) {
|
||||
DrawText(ctx, GetText("BadEnd5"), 350, 250, "White");
|
||||
DrawText(GetText("BadEnd5"), 350, 250, "White");
|
||||
//StopTimer(CurrentTime + 30 * 1000);
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/EricaHoldingHood.jpg", 700, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/EricaHoldingHood.jpg", 700, 0);
|
||||
}
|
||||
if (TextPhase >= 5) {
|
||||
DrawText(ctx, GetText("BadEnd6"), 350, 300, "White");
|
||||
DrawText(GetText("BadEnd6"), 350, 300, "White");
|
||||
//StopTimer(CurrentTime + 60 * 1000);
|
||||
DrawRect(ctx, 700, 0, 1200, 600, "black");
|
||||
DrawRect(700, 0, 1200, 600, "black");
|
||||
PlayerLockInventory("Collar");
|
||||
}
|
||||
if (TextPhase >= 6) {
|
||||
DrawText(ctx, GetText("BadEnd7"), 350, 350, "White");
|
||||
DrawText(GetText("BadEnd7"), 350, 350, "White");
|
||||
//StopTimer(CurrentTime + 10 * 1000);
|
||||
}
|
||||
if (TextPhase >= 7) {
|
||||
DrawText(ctx, GetText("BadEnd8"), 350, 400, "White");
|
||||
DrawText(GetText("BadEnd8"), 350, 400, "White");
|
||||
//StopTimer(CurrentTime + 300 * 1000);
|
||||
}
|
||||
if (TextPhase >= 8) {
|
||||
DrawText(ctx, GetText("BadEnd9"), 350, 450, "White");
|
||||
DrawText(GetText("BadEnd9"), 350, 450, "White");
|
||||
//StopTimer(CurrentTime + 180 * 1000);
|
||||
}
|
||||
if (TextPhase >= 9) {
|
||||
DrawText(ctx, GetText("BadEnd10"), 350, 500, "White");
|
||||
DrawText(GetText("BadEnd10"), 350, 500, "White");
|
||||
//StopTimer(CurrentTime + 10 * 1000);
|
||||
}
|
||||
if (TextPhase >= 10) {
|
||||
DrawText(ctx, GetText("BadEnd11"), 350, 550, "White");
|
||||
DrawText(GetText("BadEnd11"), 350, 550, "White");
|
||||
//StopTimer(CurrentTime + 10 * 1000);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,19 +14,18 @@ function C101_KinbakuClub_Intro_Load() {
|
|||
function C101_KinbakuClub_Intro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Background.jpg", 0, 0);
|
||||
|
||||
// Write the chapter introduction
|
||||
DrawText(ctx, GetText("Intro1"), 600, 150, "White");
|
||||
DrawText(GetText("Intro1"), 600, 150, "White");
|
||||
if (Common_ClubStatus == "ClubLunchVisited") {
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2"), 600, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3"), 600, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4"), 600, 450, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2"), 600, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3"), 600, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4"), 600, 450, "White");
|
||||
} else {
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Intro2New"), 600, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Intro3New"), 600, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Intro4New"), 600, 450, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Intro2New"), 600, 250, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Intro3New"), 600, 350, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Intro4New"), 600, 450, "White");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -82,41 +82,36 @@ function C101_KinbakuClub_Lauren_Run() {
|
|||
// Image overlays
|
||||
// Blindfold and cuffs on table
|
||||
if (C101_KinbakuClub_Lauren_CurrentStage <= 220) {
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
if (C101_KinbakuClub_Lauren_BlindfoldAvailable) {
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Blindfold.jpg", 735, 395);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Blindfold.jpg", 735, 395);
|
||||
}
|
||||
if (C101_KinbakuClub_Lauren_CurrentStage < 150) {
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Cuffs.jpg", 730, 450);
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Cuffs.jpg", 730, 450);
|
||||
}
|
||||
}
|
||||
|
||||
// Lauren chair cuffed looking behind
|
||||
if (C101_KinbakuClub_Lauren_CurrentStage == 450) {
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
if (ActorHasInventory("BallGag")) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenRealizedBall.jpg", 925, 80);
|
||||
if (ActorHasInventory("TapeGag")) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenRealizedTape.jpg", 925, 80);
|
||||
if (ActorHasInventory("ClothGag")) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenRealizedCloth.jpg", 925, 80);
|
||||
if (ActorHasInventory("BallGag")) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenRealizedBall.jpg", 925, 80);
|
||||
if (ActorHasInventory("TapeGag")) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenRealizedTape.jpg", 925, 80);
|
||||
if (ActorHasInventory("ClothGag")) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenRealizedCloth.jpg", 925, 80);
|
||||
}
|
||||
|
||||
// Lauren chair cuffed looking forwards and up
|
||||
// facial expression
|
||||
if (C101_KinbakuClub_Lauren_CurrentStage == 460 || C101_KinbakuClub_Lauren_CurrentStage == 470) {
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
if (ActorGetValue(ActorLove) >= 5 && (ActorGetValue(ActorLove) >= ActorGetValue(ActorSubmission))) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenLike.jpg", 870, 70);
|
||||
if (ActorGetValue(ActorSubmission) >= 5 && (ActorGetValue(ActorSubmission) > ActorGetValue(ActorLove))) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenSub.jpg", 870, 70);
|
||||
if (C101_KinbakuClub_Lauren_OrgasmDone) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenAshamed.jpg", 870, 70);
|
||||
if (ActorGetValue(ActorLove) >= 5 && (ActorGetValue(ActorLove) >= ActorGetValue(ActorSubmission))) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenLike.jpg", 870, 70);
|
||||
if (ActorGetValue(ActorSubmission) >= 5 && (ActorGetValue(ActorSubmission) > ActorGetValue(ActorLove))) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenSub.jpg", 870, 70);
|
||||
if (C101_KinbakuClub_Lauren_OrgasmDone) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenAshamed.jpg", 870, 70);
|
||||
}
|
||||
// gag
|
||||
if (C101_KinbakuClub_Lauren_CurrentStage == 460 || C101_KinbakuClub_Lauren_CurrentStage == 470 || C101_KinbakuClub_Lauren_CurrentStage == 900) {
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
if (ActorHasInventory("BallGag")) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenHelplessBall.png", 880, 80);
|
||||
if (ActorHasInventory("TapeGag")) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenHelplessTape.png", 895, 160);
|
||||
if (ActorHasInventory("ClothGag")) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/LaurenHelplessCloth.png", 875, 150);
|
||||
if (ActorHasInventory("BallGag")) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenHelplessBall.png", 880, 80);
|
||||
if (ActorHasInventory("TapeGag")) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenHelplessTape.png", 895, 160);
|
||||
if (ActorHasInventory("ClothGag")) DrawImage(CurrentChapter + "/" + CurrentScreen + "/LaurenHelplessCloth.png", 875, 150);
|
||||
}
|
||||
if (C101_KinbakuClub_Lauren_CurrentStage == 490 || C101_KinbakuClub_Lauren_CurrentStage == 500) {
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
if (PlayerHasLockedInventory("ClothGag")) DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/PlayerChairGagged.jpg", 850, 130);
|
||||
if (PlayerHasLockedInventory("ClothGag")) DrawImage(CurrentChapter + "/" + CurrentScreen + "/PlayerChairGagged.jpg", 850, 130);
|
||||
}
|
||||
|
||||
// While Lauren gets intimate with the player
|
||||
|
|
|
@ -9,16 +9,15 @@ function C101_KinbakuClub_Outro_Load() {
|
|||
function C101_KinbakuClub_Outro_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Bell.jpg", 800, 0);
|
||||
|
||||
// Dialog depending on the outro situation
|
||||
if (TextPhase >= 0) DrawText(ctx, GetText("Outro1"), 400, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Outro2"), 400, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("Outro3"), 400, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Outro4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Outro5"), 400, 500, "White");
|
||||
if (TextPhase >= 0) DrawText(GetText("Outro1"), 400, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Outro2"), 400, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("Outro3"), 400, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Outro4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Outro5"), 400, 500, "White");
|
||||
}
|
||||
|
||||
// Chapter 101 - Kinbaku Club Click
|
||||
|
|
|
@ -10,61 +10,60 @@ function C101_KinbakuClub_Transition_Load() {
|
|||
function C101_KinbakuClub_Transition_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/Jenna.jpg", 800, 0);
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/Jenna.jpg", 800, 0);
|
||||
|
||||
// Dialog depending on the outro situation
|
||||
if (TextPhase >= 0) DrawText(ctx, GetText("PlayerFree1"), 400, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("PlayerFree2"), 400, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(ctx, GetText("PlayerFree3"), 400, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("PlayerFree4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("PlayerFree5"), 400, 500, "White");
|
||||
if (TextPhase >= 0) DrawText(GetText("PlayerFree1"), 400, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("PlayerFree2"), 400, 200, "White");
|
||||
if (TextPhase >= 2) DrawText(GetText("PlayerFree3"), 400, 300, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("PlayerFree4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("PlayerFree5"), 400, 500, "White");
|
||||
|
||||
if (C101_KinbakuClub_Erica_PlayerIsSlave) {
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
if (TextPhase >= 0) DrawText(ctx, GetText("Enslaved1"), 400, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("Enslaved2"), 400, 200, "White");
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
if (TextPhase >= 0) DrawText(GetText("Enslaved1"), 400, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("Enslaved2"), 400, 200, "White");
|
||||
if (TextPhase >= 2) {
|
||||
DrawText(ctx, GetText("Enslaved3"), 400, 300, "White");
|
||||
DrawText(GetText("Enslaved3"), 400, 300, "White");
|
||||
PlayerUnlockInventory("Collar")
|
||||
}
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("Enslaved4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("Enslaved5"), 400, 500, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("Enslaved4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("Enslaved5"), 400, 500, "White");
|
||||
}
|
||||
|
||||
if (C101_KinbakuClub_Lauren_PlayerChairCuffed || C101_KinbakuClub_Lauren_PlayerStrappado) {
|
||||
DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
if (TextPhase >= 0) DrawText(ctx, GetText("ChairCuffed1"), 400, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(ctx, GetText("ChairCuffed2"), 400, 200, "White");
|
||||
DrawRect(0, 0, 800, 600, "black");
|
||||
if (TextPhase >= 0) DrawText(GetText("ChairCuffed1"), 400, 100, "White");
|
||||
if (TextPhase >= 1) DrawText(GetText("ChairCuffed2"), 400, 200, "White");
|
||||
if (TextPhase >= 2) {
|
||||
if (C101_KinbakuClub_Lauren_PlayerChairCuffed) DrawText(ctx, GetText("ChairCuffed3"), 400, 300, "White");
|
||||
if (C101_KinbakuClub_Lauren_PlayerChairCuffed) DrawText(GetText("ChairCuffed3"), 400, 300, "White");
|
||||
if (C101_KinbakuClub_Lauren_PlayerStrappado) {
|
||||
if (!C101_KinbakuClub_Lauren_PlayerLegCuffs) DrawText(ctx, GetText("LaurenCuffedStrppado"), 400, 300, "White");
|
||||
if (!C101_KinbakuClub_Lauren_PlayerLegCuffs) DrawText(GetText("LaurenCuffedStrppado"), 400, 300, "White");
|
||||
if (C101_KinbakuClub_Lauren_PlayerLegCuffs) {
|
||||
DrawText(ctx, GetText("LaurenCuffedStrppadoLegs"), 400, 300, "White");
|
||||
DrawText(GetText("LaurenCuffedStrppadoLegs"), 400, 300, "White");
|
||||
PlayerUnlockInventory("Collar");
|
||||
}
|
||||
}
|
||||
}
|
||||
if (TextPhase >= 3) DrawText(ctx, GetText("ChairCuffed4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(ctx, GetText("ChairCuffed5"), 400, 500, "White");
|
||||
if (TextPhase >= 3) DrawText(GetText("ChairCuffed4"), 400, 400, "White");
|
||||
if (TextPhase >= 4) DrawText(GetText("ChairCuffed5"), 400, 500, "White");
|
||||
}
|
||||
|
||||
//if (C101_KinbakuClub_Chloe_PlayingWithPlayer) {
|
||||
// DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
// if (TextPhase >= 0) DrawText(ctx, GetText("ChloeSub1"), 400, 120, "White");
|
||||
// if (TextPhase >= 1) DrawText(ctx, GetText("ChloeSub2"), 400, 240, "White");
|
||||
// if (TextPhase >= 2) DrawText(ctx, GetText("ChloeSub3"), 400, 360, "White");
|
||||
// if (TextPhase >= 3) DrawText(ctx, GetText("ChloeSub4"), 400, 480, "White");
|
||||
// DrawRect(0, 0, 800, 600, "black");
|
||||
// if (TextPhase >= 0) DrawText(GetText("ChloeSub1"), 400, 120, "White");
|
||||
// if (TextPhase >= 1) DrawText(GetText("ChloeSub2"), 400, 240, "White");
|
||||
// if (TextPhase >= 2) DrawText(GetText("ChloeSub3"), 400, 360, "White");
|
||||
// if (TextPhase >= 3) DrawText(GetText("ChloeSub4"), 400, 480, "White");
|
||||
//}
|
||||
|
||||
//if (C101_KinbakuClub_Chloe_PlayerLeftChairTied) {
|
||||
// DrawRect(ctx, 0, 0, 800, 600, "black");
|
||||
// if (TextPhase >= 0) DrawText(ctx, GetText("LeftChair1"), 400, 120, "White");
|
||||
// if (TextPhase >= 1) DrawText(ctx, GetText("LeftChair2"), 400, 240, "White");
|
||||
// if (TextPhase >= 2) DrawText(ctx, GetText("LeftChair3"), 400, 360, "White");
|
||||
// if (TextPhase >= 3) DrawText(ctx, GetText("LeftChair4"), 400, 480, "White");
|
||||
// DrawRect(0, 0, 800, 600, "black");
|
||||
// if (TextPhase >= 0) DrawText(GetText("LeftChair1"), 400, 120, "White");
|
||||
// if (TextPhase >= 1) DrawText(GetText("LeftChair2"), 400, 240, "White");
|
||||
// if (TextPhase >= 2) DrawText(GetText("LeftChair3"), 400, 360, "White");
|
||||
// if (TextPhase >= 3) DrawText(GetText("LeftChair4"), 400, 480, "White");
|
||||
//}
|
||||
}
|
||||
|
||||
|
|
|
@ -64,7 +64,7 @@ function DoubleFightLoad(Opp1ActorName, Opp1Difficulty, Opp1Icon, Opp2ActorName,
|
|||
}
|
||||
|
||||
// Draw the fight icons
|
||||
function DoubleFightDrawIcons(ctx, Opponent) {
|
||||
function DoubleFightDrawIcons(Opponent) {
|
||||
|
||||
// Scroll the fight icons with time
|
||||
var Seq = 0;
|
||||
|
@ -73,7 +73,7 @@ function DoubleFightDrawIcons(ctx, Opponent) {
|
|||
// Draw the move from 3 seconds before to 1 second after
|
||||
var currentOpponentIconTime = Opponent.FightMoves[Seq][FightMoveTime];
|
||||
if ((currentOpponentIconTime <= DoubleFightTimer + 3000) && (currentOpponentIconTime >= DoubleFightTimer - 1000))
|
||||
DrawImage(ctx, Opponent.FightIcon, Opponent.FightXOffset + 3 + (Opponent.FightMoves[Seq][FightMoveType] * 75), 410 + Math.floor((DoubleFightTimer - currentOpponentIconTime) / 6));
|
||||
DrawImage(Opponent.FightIcon, Opponent.FightXOffset + 3 + (Opponent.FightMoves[Seq][FightMoveType] * 75), 410 + Math.floor((DoubleFightTimer - currentOpponentIconTime) / 6));
|
||||
|
||||
// Remove the move from the sequence if it's past due
|
||||
if (currentOpponentIconTime < DoubleFightTimer - 1000) {
|
||||
|
@ -92,32 +92,32 @@ function DoubleFightDrawIcons(ctx, Opponent) {
|
|||
}
|
||||
|
||||
// Draw the fight bars to tell when the moves will hit
|
||||
function DoubleFightDrawBar(ctx, Opponent) {
|
||||
function DoubleFightDrawBar(Opponent) {
|
||||
|
||||
// Draw 4 bars per opponent
|
||||
for(BarNum = 0; BarNum <= 3; BarNum++) {
|
||||
|
||||
// The color changes when it's clicked or pressed
|
||||
DrawRect(ctx, Opponent.FightXOffset + 3 + (BarNum * 75), 437, 70, 27, "White");
|
||||
DrawRect(Opponent.FightXOffset + 3 + (BarNum * 75), 437, 70, 27, "White");
|
||||
if ((Opponent.LastMoveType == BarNum) && (Opponent.LastMoveTypeTimer >= DoubleFightTimer))
|
||||
DrawRect(ctx, Opponent.FightXOffset + 4 + (BarNum * 75), 438, 68, 25, "#66FF66");
|
||||
DrawRect(Opponent.FightXOffset + 4 + (BarNum * 75), 438, 68, 25, "#66FF66");
|
||||
else
|
||||
DrawRect(ctx, Opponent.FightXOffset + 4 + (BarNum * 75), 438, 68, 25, "Red");
|
||||
if (!IsMobile) DrawText(ctx, String.fromCharCode(Opponent.FightMoveTypeKeyUpper[BarNum]), Opponent.FightXOffset + 36 + (BarNum * 75), 451, "white");
|
||||
DrawRect(Opponent.FightXOffset + 4 + (BarNum * 75), 438, 68, 25, "Red");
|
||||
if (!IsMobile) DrawText(String.fromCharCode(Opponent.FightMoveTypeKeyUpper[BarNum]), Opponent.FightXOffset + 36 + (BarNum * 75), 451, "white");
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Draw the fight progress in the bottom of the fight scene
|
||||
function DoubleFightDrawProgress(ctx, Opponent) {
|
||||
DrawRect(ctx, Opponent.FightXOffset, 590, 300, 1, "white");
|
||||
DrawRect(ctx, Opponent.FightXOffset, 591, Opponent.FightProgress * 3, 9, "#66FF66");
|
||||
DrawRect(ctx, Opponent.FightXOffset + (Opponent.FightProgress * 3), 591, (100 - Opponent.FightProgress) * 3, 9, "red");
|
||||
function DoubleFightDrawProgress(Opponent) {
|
||||
DrawRect(Opponent.FightXOffset, 590, 300, 1, "white");
|
||||
DrawRect(Opponent.FightXOffset, 591, Opponent.FightProgress * 3, 9, "#66FF66");
|
||||
DrawRect(Opponent.FightXOffset + (Opponent.FightProgress * 3), 591, (100 - Opponent.FightProgress) * 3, 9, "red");
|
||||
}
|
||||
|
||||
// Draw the opponent actor on the screen
|
||||
function DoubleFightDrawOpponent(ctx, Opponent) {
|
||||
function DoubleFightDrawOpponent(Opponent) {
|
||||
|
||||
// Before the timer, we use the previous image
|
||||
if (Opponent.NextImageTime < DoubleFightTimer) {
|
||||
|
@ -135,12 +135,12 @@ function DoubleFightDrawOpponent(ctx, Opponent) {
|
|||
};
|
||||
|
||||
// Draw the image on the screen
|
||||
DrawImageZoom(ctx, Opponent.ImageName, 0, 0, 600, 900, Opponent.ImageXOffset, 50, 600 * 0.75, 900 * 0.75);
|
||||
DrawImageZoom(Opponent.ImageName, 0, 0, 600, 900, Opponent.ImageXOffset, 50, 600 * 0.75, 900 * 0.75);
|
||||
|
||||
}
|
||||
|
||||
// Renders a specific opponent
|
||||
function DoubleFightRenderOpponent(ctx, Opponent) {
|
||||
function DoubleFightRenderOpponent(Opponent) {
|
||||
|
||||
// Starts the fight at an even level and generates moves if there'S none left
|
||||
if (Opponent.FightProgress > 100) Opponent.FightProgress = 100;
|
||||
|
@ -148,20 +148,20 @@ function DoubleFightRenderOpponent(ctx, Opponent) {
|
|||
if ((Opponent.FightMoves.length == 0) && !DoubleFightEnded && Opponent.FightProgress > 0) Opponent.FightMoves = DoubleFightGenerateMoves(DoubleFightTimer, Opponent.DifficultyText);
|
||||
|
||||
// Draw the fighting actors
|
||||
DoubleFightDrawOpponent(ctx, Opponent);
|
||||
DoubleFightDrawOpponent(Opponent);
|
||||
|
||||
// Draw the fight icons, bars and bottom info when the fight is running
|
||||
if (!DoubleFightEnded) {
|
||||
if (DoubleFightTimer >= DoubleFightStartTime) {
|
||||
if (Opponent.FightProgress < 100) {
|
||||
DoubleFightDrawBar(ctx, Opponent);
|
||||
DoubleFightDrawIcons(ctx, Opponent);
|
||||
DoubleFightDrawProgress(ctx, Opponent);
|
||||
DoubleFightDrawBar(Opponent);
|
||||
DoubleFightDrawIcons(Opponent);
|
||||
DoubleFightDrawProgress(Opponent);
|
||||
}
|
||||
}
|
||||
else {
|
||||
DrawText(ctx, GetCSVText(DoubleFightText, "Opponent") + " " + Opponent.ActorName, Opponent.FightXOffset + 150, 250, "white");
|
||||
DrawText(ctx, GetCSVText(DoubleFightText, "Difficulty") + " " + GetCSVText(DoubleFightText, Opponent.DifficultyText), Opponent.FightXOffset + 150, 350, "white");
|
||||
DrawText(GetCSVText(DoubleFightText, "Opponent") + " " + Opponent.ActorName, Opponent.FightXOffset + 150, 250, "white");
|
||||
DrawText(GetCSVText(DoubleFightText, "Difficulty") + " " + GetCSVText(DoubleFightText, Opponent.DifficultyText), Opponent.FightXOffset + 150, 350, "white");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -253,22 +253,21 @@ function DoubleFightCheckClick(Opponent) {
|
|||
function C999_Common_DoubleFight_Run() {
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, "C999_Common/Fights/Backgrounds/" + DoubleFightBackgroundImage + ".jpg", 0, 0);
|
||||
DrawImage("C999_Common/Fights/Backgrounds/" + DoubleFightBackgroundImage + ".jpg", 0, 0);
|
||||
|
||||
// Increments the fight timer and renders the 2 opponents
|
||||
DoubleFightTimer = DoubleFightTimer + RunInterval;
|
||||
DoubleFightRenderOpponent(ctx, DoubleFightOpponent1);
|
||||
DoubleFightRenderOpponent(ctx, DoubleFightOpponent2);
|
||||
DoubleFightRenderOpponent(DoubleFightOpponent1);
|
||||
DoubleFightRenderOpponent(DoubleFightOpponent2);
|
||||
|
||||
// Draw the fight icons and bottom info when the fight is running
|
||||
if (!DoubleFightEnded && (DoubleFightTimer < DoubleFightStartTime)) DrawText(ctx, GetCSVText(DoubleFightText, "StartsIn") + " " + (5 - Math.floor(DoubleFightTimer / 1000)).toString(), 600, 30, "white");
|
||||
if (!DoubleFightEnded && (DoubleFightTimer < DoubleFightStartTime)) DrawText(GetCSVText(DoubleFightText, "StartsIn") + " " + (5 - Math.floor(DoubleFightTimer / 1000)).toString(), 600, 30, "white");
|
||||
|
||||
// Draw the end text
|
||||
if (DoubleFightEnded) {
|
||||
if ((DoubleFightOpponent1.FightProgress >= 100) && (DoubleFightOpponent2.FightProgress >= 100) && DoubleFightPerfect) DrawText(ctx, GetCSVText(DoubleFightText, "Perfect"), 600, 30, "white");
|
||||
if ((DoubleFightOpponent1.FightProgress >= 100) && (DoubleFightOpponent2.FightProgress >= 100) && !DoubleFightPerfect) DrawText(ctx, GetCSVText(DoubleFightText, "Victory"), 600, 30, "white");
|
||||
if ((DoubleFightOpponent1.FightProgress <= 0) || (DoubleFightOpponent2.FightProgress <= 0)) DrawText(ctx, GetCSVText(DoubleFightText, "Defeat"), 600, 30, "white");
|
||||
if ((DoubleFightOpponent1.FightProgress >= 100) && (DoubleFightOpponent2.FightProgress >= 100) && DoubleFightPerfect) DrawText(GetCSVText(DoubleFightText, "Perfect"), 600, 30, "white");
|
||||
if ((DoubleFightOpponent1.FightProgress >= 100) && (DoubleFightOpponent2.FightProgress >= 100) && !DoubleFightPerfect) DrawText(GetCSVText(DoubleFightText, "Victory"), 600, 30, "white");
|
||||
if ((DoubleFightOpponent1.FightProgress <= 0) || (DoubleFightOpponent2.FightProgress <= 0)) DrawText(GetCSVText(DoubleFightText, "Defeat"), 600, 30, "white");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -75,7 +75,7 @@ function FindFightImage() {
|
|||
}
|
||||
|
||||
// Draw the fight icons
|
||||
function DrawFightIcons(ctx) {
|
||||
function DrawFightIcons() {
|
||||
|
||||
// Scroll the fight icons with time
|
||||
var Seq = 0;
|
||||
|
@ -85,7 +85,7 @@ function DrawFightIcons(ctx) {
|
|||
var currentIconTime = FightMoves[Seq][FightMoveTime];
|
||||
var currentIconType = FightMoves[Seq][FightMoveType];
|
||||
if ((currentIconTime <= FightTimer + 3000) && (currentIconTime >= FightTimer - 1000))
|
||||
DrawImage(ctx, FightIcon, 812 + (currentIconType * 100), 410 + Math.floor((FightTimer - currentIconTime) / 6));
|
||||
DrawImage(FightIcon, 812 + (currentIconType * 100), 410 + Math.floor((FightTimer - currentIconTime) / 6));
|
||||
|
||||
// Remove the move from the sequence if it's past due
|
||||
if (FightMoves[Seq][FightMoveTime] < FightTimer - 1000) {
|
||||
|
@ -104,23 +104,23 @@ function DrawFightIcons(ctx) {
|
|||
}
|
||||
|
||||
// Draw the fight bars to tell when the moves will hit
|
||||
function DrawFightBar(ctx, SquareType) {
|
||||
function DrawFightBar(SquareType) {
|
||||
|
||||
// The color changes when it's clicked or pressed
|
||||
DrawRect(ctx, 810 + (SquareType * 100), 437, 80, 27, "White");
|
||||
DrawRect(810 + (SquareType * 100), 437, 80, 27, "White");
|
||||
if ((LastMoveType == SquareType) && (LastMoveTypeTimer >= FightTimer))
|
||||
DrawRect(ctx, 811 + (SquareType * 100), 438, 78, 25, "#66FF66");
|
||||
DrawRect(811 + (SquareType * 100), 438, 78, 25, "#66FF66");
|
||||
else
|
||||
DrawRect(ctx, 811 + (SquareType * 100), 438, 78, 25, "Red");
|
||||
if (!IsMobile) DrawText(ctx, String.fromCharCode(FightMoveTypeKeyUpper[SquareType]), 850 + (SquareType * 100), 451, "white");
|
||||
DrawRect(811 + (SquareType * 100), 438, 78, 25, "Red");
|
||||
if (!IsMobile) DrawText(String.fromCharCode(FightMoveTypeKeyUpper[SquareType]), 850 + (SquareType * 100), 451, "white");
|
||||
|
||||
}
|
||||
|
||||
// Draw the fight progress in the bottom of the fight scene
|
||||
function DrawFightProgress(ctx) {
|
||||
DrawRect(ctx, 800, 590, 400, 1, "white");
|
||||
DrawRect(ctx, 800, 591, FightProgress * 4, 9, "#66FF66");
|
||||
DrawRect(ctx, 800 + (FightProgress * 4), 591, (100 - FightProgress) * 4, 9, "red");
|
||||
function DrawFightProgress() {
|
||||
DrawRect(800, 590, 400, 1, "white");
|
||||
DrawRect(800, 591, FightProgress * 4, 9, "#66FF66");
|
||||
DrawRect(800 + (FightProgress * 4), 591, (100 - FightProgress) * 4, 9, "red");
|
||||
}
|
||||
|
||||
// Render the fight scene
|
||||
|
@ -138,15 +138,14 @@ function RenderFight() {
|
|||
FightProgress = 50;
|
||||
|
||||
// Paints the background depending on the current fight progress
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + FindFightImage(), 0, 0);
|
||||
DrawRect(ctx, 800, 0, 400, 600, "Black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + FindFightImage(), 0, 0);
|
||||
DrawRect(800, 0, 400, 600, "Black");
|
||||
|
||||
// Draw the fight icons and rectangles
|
||||
DrawFightBar(ctx, 0);
|
||||
DrawFightBar(ctx, 1);
|
||||
DrawFightBar(ctx, 2);
|
||||
DrawFightBar(ctx, 3);
|
||||
DrawFightBar(0);
|
||||
DrawFightBar(1);
|
||||
DrawFightBar(2);
|
||||
DrawFightBar(3);
|
||||
|
||||
// If there's no moves left, we full the move list again, there's no tie match
|
||||
if ((FightMoves.length == 0) && (!FightEnded))
|
||||
|
@ -155,19 +154,19 @@ function RenderFight() {
|
|||
// Draw the fight icons and bottom info when the fight is running
|
||||
if (!FightEnded) {
|
||||
if (FightTimer >= 5000) {
|
||||
DrawFightIcons(ctx);
|
||||
DrawFightProgress(ctx);
|
||||
DrawFightIcons();
|
||||
DrawFightProgress();
|
||||
}
|
||||
else {
|
||||
DrawText(ctx, GetText("StartsIn") + " " + (5 - Math.floor(FightTimer / 1000)).toString(), 1000, 510, "white");
|
||||
DrawText(ctx, GetText("Difficulty") + " " + GetText(FightDifficultyText), 1000, 555, "white");
|
||||
DrawText(GetText("StartsIn") + " " + (5 - Math.floor(FightTimer / 1000)).toString(), 1000, 510, "white");
|
||||
DrawText(GetText("Difficulty") + " " + GetText(FightDifficultyText), 1000, 555, "white");
|
||||
}
|
||||
}
|
||||
else {
|
||||
if ((FightProgress >= 100) && FightPerfect) DrawText(ctx, GetText("Perfect"), 1000, 150, "white");
|
||||
if ((FightProgress >= 100) && !FightPerfect) DrawText(ctx, GetText("Victory"), 1000, 150, "white");
|
||||
if (FightProgress <= 0) DrawText(ctx, GetText("Defeat"), 1000, 150, "white");
|
||||
DrawText(ctx, GetText("ClickContinue"), 1000, 300, "white");
|
||||
if ((FightProgress >= 100) && FightPerfect) DrawText(GetText("Perfect"), 1000, 150, "white");
|
||||
if ((FightProgress >= 100) && !FightPerfect) DrawText(GetText("Victory"), 1000, 150, "white");
|
||||
if (FightProgress <= 0) DrawText(GetText("Defeat"), 1000, 150, "white");
|
||||
DrawText(GetText("ClickContinue"), 1000, 300, "white");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -13,8 +13,7 @@ function C999_Common_GameLoad_Run() {
|
|||
// Build the game loading screen
|
||||
SaveStateSlotSummary();
|
||||
BuildInteraction(C999_Common_GameLoad_CurrentStage);
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawText(ctx, GetText("LoadGame"), 900, 420, "black");
|
||||
DrawText(GetText("LoadGame"), 900, 420, "black");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -15,8 +15,7 @@ function C999_Common_GameSave_Run() {
|
|||
// Build the game saving screen
|
||||
SaveStateSlotSummary();
|
||||
BuildInteraction(C999_Common_GameSave_CurrentStage);
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawText(ctx, GetText("SaveGame"), 900, 420, "black");
|
||||
DrawText(GetText("SaveGame"), 900, 420, "black");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -60,50 +60,47 @@ function C999_Common_Player_Run() {
|
|||
// Paints the player picture
|
||||
DrawPlayerImage(0, 0);
|
||||
|
||||
// Draw the player records, show every actors encountered
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
|
||||
// Draw the main frame
|
||||
DrawRect(ctx, 599, 0, 1, 600, "Black");
|
||||
DrawRect(ctx, 0, 0, 599, 600, "White");
|
||||
DrawRect(599, 0, 1, 600, "Black");
|
||||
DrawRect(0, 0, 599, 600, "White");
|
||||
|
||||
// Draw the profile tab (show the player name, title and skills)
|
||||
if (C999_Common_Player_ActiveTab == "Profile") {
|
||||
|
||||
// Shows the basic info
|
||||
DrawRect(ctx, 300, 0, 300, 50, "black");
|
||||
DrawRect(ctx, 301, 0, 298, 49, "silver");
|
||||
DrawText(ctx, GetText("Profile"), 150, 25, "black");
|
||||
DrawText(ctx, GetText("Relationships"), 450, 25, "white");
|
||||
DrawText(ctx, GetText("Name") + " " + Common_PlayerName, 300, 90, "black");
|
||||
DrawText(ctx, GetText("Title") + " " + C999_Common_Player_GetTitle(), 300, 130, "black");
|
||||
DrawRect(300, 0, 300, 50, "black");
|
||||
DrawRect(301, 0, 298, 49, "silver");
|
||||
DrawText(GetText("Profile"), 150, 25, "black");
|
||||
DrawText(GetText("Relationships"), 450, 25, "white");
|
||||
DrawText(GetText("Name") + " " + Common_PlayerName, 300, 90, "black");
|
||||
DrawText(GetText("Title") + " " + C999_Common_Player_GetTitle(), 300, 130, "black");
|
||||
|
||||
// Shows the current lover and owner
|
||||
if (Common_PlayerOwner != "") DrawText(ctx, GetText("Lover") + " " + Common_PlayerLover, 300, 170, "black");
|
||||
else DrawText(ctx, GetText("Lover") + " " + GetText("NoLover"), 300, 170, "black");
|
||||
if (Common_PlayerOwner != "") DrawText(ctx, GetText("Owner") + " " + Common_PlayerOwner, 300, 210, "black");
|
||||
else DrawText(ctx, GetText("Owner") + " " + GetText("NoOwner"), 300, 210, "black");
|
||||
if (Common_PlayerOwner != "") DrawText(GetText("Lover") + " " + Common_PlayerLover, 300, 170, "black");
|
||||
else DrawText(GetText("Lover") + " " + GetText("NoLover"), 300, 170, "black");
|
||||
if (Common_PlayerOwner != "") DrawText(GetText("Owner") + " " + Common_PlayerOwner, 300, 210, "black");
|
||||
else DrawText(GetText("Owner") + " " + GetText("NoOwner"), 300, 210, "black");
|
||||
|
||||
// List the skills
|
||||
DrawText(ctx, GetText("Skills"), 200, 270, "black");
|
||||
DrawText(ctx, GetText("Level"), 500, 270, "black");
|
||||
DrawRect(ctx, 30, 290, 539, 1, "Black");
|
||||
DrawText(GetText("Skills"), 200, 270, "black");
|
||||
DrawText(GetText("Level"), 500, 270, "black");
|
||||
DrawRect(30, 290, 539, 1, "Black");
|
||||
for (var S = 0; S < PlayerSkill.length; S++) {
|
||||
DrawText(ctx, GetText("Skill" + PlayerSkill[S][PlayerSkillName]), 200, 320 + S * 40, "black");
|
||||
DrawText(ctx, PlayerSkill[S][PlayerSkillLevel].toString(), 500, 320 + S * 40, "black");
|
||||
DrawText(GetText("Skill" + PlayerSkill[S][PlayerSkillName]), 200, 320 + S * 40, "black");
|
||||
DrawText(PlayerSkill[S][PlayerSkillLevel].toString(), 500, 320 + S * 40, "black");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Draw the relationships tab (show all known actors and their relationship with the player)
|
||||
if (C999_Common_Player_ActiveTab == "Relationships") {
|
||||
DrawRect(ctx, 0, 0, 300, 50, "black");
|
||||
DrawRect(ctx, 0, 0, 299, 49, "silver");
|
||||
DrawText(ctx, GetText("Profile"), 150, 25, "white");
|
||||
DrawText(ctx, GetText("Relationships"), 450, 25, "black");
|
||||
DrawRect(0, 0, 300, 50, "black");
|
||||
DrawRect(0, 0, 299, 49, "silver");
|
||||
DrawText(GetText("Profile"), 150, 25, "white");
|
||||
DrawText(GetText("Relationships"), 450, 25, "black");
|
||||
for (var A = 0; A < Actor.length; A++) {
|
||||
CurrentActor = Actor[A][ActorName];
|
||||
DrawActorStats(ctx, 300, A * 50 + 80);
|
||||
DrawActorStats(300, A * 50 + 80);
|
||||
}
|
||||
CurrentActor = "";
|
||||
}
|
||||
|
|
|
@ -91,7 +91,7 @@ function RaceLoad(Racer, RacerImageSet, AllowedMinutes, Difficulty, EndGoal, End
|
|||
}
|
||||
|
||||
// Draw the race icons
|
||||
function RaceDrawIcons(ctx) {
|
||||
function RaceDrawIcons() {
|
||||
|
||||
// Scroll the race icons with time
|
||||
var Seq = 0;
|
||||
|
@ -100,9 +100,9 @@ function RaceDrawIcons(ctx) {
|
|||
// Draw the move from 3 seconds before to 1 second after
|
||||
if ((RaceMoves[Seq][RaceMoveTime] <= RaceTimer + 3000) && (RaceMoves[Seq][RaceMoveTime] >= RaceTimer - 1000)) {
|
||||
if (RaceMoves[Seq][RaceMoveType] <= 3)
|
||||
DrawImage(ctx, RaceIconLeft, 3 + (RaceMoves[Seq][RaceMoveType] * 75), 410 + Math.floor((RaceTimer - RaceMoves[Seq][RaceMoveTime]) / 6));
|
||||
DrawImage(RaceIconLeft, 3 + (RaceMoves[Seq][RaceMoveType] * 75), 410 + Math.floor((RaceTimer - RaceMoves[Seq][RaceMoveTime]) / 6));
|
||||
else
|
||||
DrawImage(ctx, RaceIconRight, 603 + (RaceMoves[Seq][RaceMoveType] * 75), 410 + Math.floor((RaceTimer - RaceMoves[Seq][RaceMoveTime]) / 6));
|
||||
DrawImage(RaceIconRight, 603 + (RaceMoves[Seq][RaceMoveType] * 75), 410 + Math.floor((RaceTimer - RaceMoves[Seq][RaceMoveTime]) / 6));
|
||||
}
|
||||
|
||||
// Remove the move from the sequence if it's past due
|
||||
|
@ -122,7 +122,7 @@ function RaceDrawIcons(ctx) {
|
|||
}
|
||||
|
||||
// Draw the race bars to tell when the moves will hit
|
||||
function RaceDrawBar(ctx) {
|
||||
function RaceDrawBar() {
|
||||
|
||||
// Draw 4 bars on each sides
|
||||
var XOffset = 0;
|
||||
|
@ -132,26 +132,26 @@ function RaceDrawBar(ctx) {
|
|||
if (BarNum == 4) XOffset = 600;
|
||||
|
||||
// The color changes when it's clicked or pressed
|
||||
DrawRect(ctx, XOffset + 3 + (BarNum * 75), 437, 70, 27, "White");
|
||||
DrawRect(XOffset + 3 + (BarNum * 75), 437, 70, 27, "White");
|
||||
if ((RaceLastMoveType == BarNum) && (RaceLastMoveTypeTimer >= RaceTimer))
|
||||
DrawRect(ctx, XOffset + 4 + (BarNum * 75), 438, 68, 25, "#66FF66");
|
||||
DrawRect(XOffset + 4 + (BarNum * 75), 438, 68, 25, "#66FF66");
|
||||
else
|
||||
DrawRect(ctx, XOffset + 4 + (BarNum * 75), 438, 68, 25, "Red");
|
||||
if (!IsMobile) DrawText(ctx, String.fromCharCode(RaceMovesTypeKeyUpper[BarNum]), XOffset + 36 + (BarNum * 75), 451, "white");
|
||||
DrawRect(XOffset + 4 + (BarNum * 75), 438, 68, 25, "Red");
|
||||
if (!IsMobile) DrawText(String.fromCharCode(RaceMovesTypeKeyUpper[BarNum]), XOffset + 36 + (BarNum * 75), 451, "white");
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Draw the race progress in the bottom screen
|
||||
function RaceDrawStats(ctx) {
|
||||
DrawText(ctx, GetCSVText(RaceText, "Combo") + " " + RaceCombo.toString(), 400, 25, "white");
|
||||
DrawText(ctx, GetCSVText(RaceText, "Speed") + " " + RaceSpeed.toString(), 575, 25, "white");
|
||||
DrawText(ctx, GetCSVText(RaceText, "Timer") + " " + msToTime(RaceEndTimer - RaceTimer), 800, 25, "white");
|
||||
function RaceDrawStats() {
|
||||
DrawText(GetCSVText(RaceText, "Combo") + " " + RaceCombo.toString(), 400, 25, "white");
|
||||
DrawText(GetCSVText(RaceText, "Speed") + " " + RaceSpeed.toString(), 575, 25, "white");
|
||||
DrawText(GetCSVText(RaceText, "Timer") + " " + msToTime(RaceEndTimer - RaceTimer), 800, 25, "white");
|
||||
}
|
||||
|
||||
// Draw the actor on the screen
|
||||
function RaceDrawActor(ctx) {
|
||||
function RaceDrawActor() {
|
||||
|
||||
// Builds the image name
|
||||
var ImageName = "C999_Common/Races/Actors/" + RaceActor + "/" + RaceActorImageSet;
|
||||
|
@ -175,7 +175,7 @@ function RaceDrawActor(ctx) {
|
|||
|
||||
// Draw the image on the screen
|
||||
ImageName = ImageName + "_" + (RaceActorImageFrame).toString() + ".png";
|
||||
DrawImage(ctx, ImageName, 300, 0);
|
||||
DrawImage(ImageName, 300, 0);
|
||||
|
||||
}
|
||||
|
||||
|
@ -271,12 +271,11 @@ function C999_Common_Race_Run() {
|
|||
}
|
||||
|
||||
// Paints the background
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, "C999_Common/Races/Backgrounds/" + RaceBackgroundImage + ".jpg", RaceProgress * -1, 0);
|
||||
DrawImage("C999_Common/Races/Backgrounds/" + RaceBackgroundImage + ".jpg", RaceProgress * -1, 0);
|
||||
|
||||
// Increments the race timer and draw the actor
|
||||
if (!RaceEnded) RaceTimer = RaceTimer + RunInterval;
|
||||
RaceDrawActor(ctx);
|
||||
RaceDrawActor();
|
||||
|
||||
// If the race is over and not completed, we flag a defeat
|
||||
if ((RaceTimer >= RaceEndTimer) && !RaceEnded)
|
||||
|
@ -285,23 +284,23 @@ function C999_Common_Race_Run() {
|
|||
// Draw the race icons, bars and bottom info when the race is running
|
||||
if (!RaceEnded) {
|
||||
if (RaceTimer >= RaceStartTime) {
|
||||
RaceDrawBar(ctx);
|
||||
RaceDrawIcons(ctx);
|
||||
RaceDrawStats(ctx);
|
||||
RaceDrawBar();
|
||||
RaceDrawIcons();
|
||||
RaceDrawStats();
|
||||
}
|
||||
else {
|
||||
DrawText(ctx, RaceGoalText, 600, 25, "white");
|
||||
DrawText(ctx, GetCSVText(RaceText, "Difficulty") + " " + GetCSVText(RaceText, RaceDifficultyText), 500, 65, "white");
|
||||
DrawText(ctx, GetCSVText(RaceText, "StartsIn") + " " + (5 - Math.floor(RaceTimer / 1000)).toString(), 700, 65, "white");
|
||||
DrawText(RaceGoalText, 600, 25, "white");
|
||||
DrawText(GetCSVText(RaceText, "Difficulty") + " " + GetCSVText(RaceText, RaceDifficultyText), 500, 65, "white");
|
||||
DrawText(GetCSVText(RaceText, "StartsIn") + " " + (5 - Math.floor(RaceTimer / 1000)).toString(), 700, 65, "white");
|
||||
}
|
||||
}
|
||||
|
||||
// Draw the end text
|
||||
if (RaceEnded) {
|
||||
if ((RaceProgress >= RaceGoal) && RacePerfect) DrawText(ctx, GetCSVText(RaceText, "Perfect"), 600, 25, "white");
|
||||
if ((RaceProgress >= RaceGoal) && !RacePerfect) DrawText(ctx, GetCSVText(RaceText, "Victory"), 600, 25, "white");
|
||||
if (RaceProgress < RaceGoal) DrawText(ctx, GetCSVText(RaceText, "Defeat"), 600, 25, "white");
|
||||
DrawText(ctx, GetCSVText(RaceText, "RaceTime") + " " + msToTime(RaceTimer - RaceStartTime), 600, 65, "white");
|
||||
if ((RaceProgress >= RaceGoal) && RacePerfect) DrawText(GetCSVText(RaceText, "Perfect"), 600, 25, "white");
|
||||
if ((RaceProgress >= RaceGoal) && !RacePerfect) DrawText(GetCSVText(RaceText, "Victory"), 600, 25, "white");
|
||||
if (RaceProgress < RaceGoal) DrawText(GetCSVText(RaceText, "Defeat"), 600, 25, "white");
|
||||
DrawText(GetCSVText(RaceText, "RaceTime") + " " + msToTime(RaceTimer - RaceStartTime), 600, 65, "white");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
206
Drawing.js
206
Drawing.js
|
@ -1,3 +1,6 @@
|
|||
// The main game canvas where everything will be drawn
|
||||
var MainCanvas;
|
||||
|
||||
// A bank of all the chached images
|
||||
var CacheImage = {};
|
||||
|
||||
|
@ -43,116 +46,106 @@ function DrawGetImage(Source) {
|
|||
}
|
||||
|
||||
// Draw a zoomed image from a source to the canvas
|
||||
function DrawImageZoom(ctx, Source, SX, SY, SWidth, SHeight, X, Y, Width, Height) {
|
||||
ctx.drawImage(DrawGetImage(Source), SX, SY, Math.round(SWidth), Math.round(SHeight), X, Y, Width, Height);
|
||||
function DrawImageZoom(Source, SX, SY, SWidth, SHeight, X, Y, Width, Height) {
|
||||
MainCanvas.drawImage(DrawGetImage(Source), SX, SY, Math.round(SWidth), Math.round(SHeight), X, Y, Width, Height);
|
||||
}
|
||||
|
||||
// Draw an image from a source to the canvas
|
||||
function DrawImage(ctx, Source, X, Y) {
|
||||
ctx.drawImage(DrawGetImage(Source), X, Y);
|
||||
}
|
||||
|
||||
// Draw an image from a file to the canvas, without using the cache system
|
||||
function DrawImageNoCache(ctx, Source, X, Y) {
|
||||
|
||||
// The image is created dynamically every time
|
||||
var img = new Image;
|
||||
img.src = Source;
|
||||
ctx.drawImage(img, X, Y);
|
||||
|
||||
function DrawImage(Source, X, Y) {
|
||||
MainCanvas.drawImage(DrawGetImage(Source), X, Y);
|
||||
}
|
||||
|
||||
// Draw a text in the canvas
|
||||
function DrawText(ctx, Text, X, Y, Color) {
|
||||
function DrawText(Text, X, Y, Color) {
|
||||
|
||||
// Replace the COMMON_PLAYERNAME keyword with the player name
|
||||
Text = Text.replace("COMMON_PLAYERNAME", Common_PlayerName);
|
||||
|
||||
// Font is fixed for now, color can be set
|
||||
ctx.font = "24px Arial";
|
||||
ctx.fillStyle = Color;
|
||||
ctx.textAlign = "center";
|
||||
ctx.textBaseline = "middle";
|
||||
MainCanvas.font = "24px Arial";
|
||||
MainCanvas.fillStyle = Color;
|
||||
MainCanvas.textAlign = "center";
|
||||
MainCanvas.textBaseline = "middle";
|
||||
|
||||
// Split the text if there's a |
|
||||
// Split the text on two lines if there's a |
|
||||
if (Text.indexOf("|") == -1)
|
||||
ctx.fillText(Text, X, Y);
|
||||
MainCanvas.fillText(Text, X, Y);
|
||||
else {
|
||||
ctx.fillText(Text.substring(0, Text.indexOf("|")), X, Y - 19);
|
||||
ctx.fillText(Text.substring(Text.indexOf("|") + 1, 1000), X, Y + 19);
|
||||
MainCanvas.fillText(Text.substring(0, Text.indexOf("|")), X, Y - 19);
|
||||
MainCanvas.fillText(Text.substring(Text.indexOf("|") + 1, 1000), X, Y + 19);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Draw a button
|
||||
function DrawButton(ctx, Left, Top, Width, Height, Label) {
|
||||
function DrawButton(Left, Top, Width, Height, Label) {
|
||||
|
||||
// Draw the button rectangle
|
||||
ctx.beginPath();
|
||||
ctx.rect(Left, Top, Width, Height);
|
||||
ctx.fillStyle = 'white';
|
||||
ctx.fillRect(Left, Top, Width, Height);
|
||||
ctx.fill();
|
||||
ctx.lineWidth = '2';
|
||||
ctx.strokeStyle = 'black';
|
||||
ctx.stroke();
|
||||
ctx.closePath();
|
||||
MainCanvas.beginPath();
|
||||
MainCanvas.rect(Left, Top, Width, Height);
|
||||
MainCanvas.fillStyle = 'white';
|
||||
MainCanvas.fillRect(Left, Top, Width, Height);
|
||||
MainCanvas.fill();
|
||||
MainCanvas.lineWidth = '2';
|
||||
MainCanvas.strokeStyle = 'black';
|
||||
MainCanvas.stroke();
|
||||
MainCanvas.closePath();
|
||||
|
||||
// Draw the text
|
||||
DrawText(ctx, Label, Left + Width / 2, Top + Height / 2, "black");
|
||||
DrawText(Label, Left + Width / 2, Top + Height / 2, "black");
|
||||
|
||||
}
|
||||
|
||||
// Draw a basic rectangle
|
||||
function DrawRect(ctx, Left, Top, Width, Height, Color) {
|
||||
ctx.beginPath();
|
||||
ctx.rect(Left, Top, Width, Height);
|
||||
ctx.fillStyle = Color;
|
||||
ctx.fillRect(Left, Top, Width, Height);
|
||||
ctx.fill();
|
||||
ctx.closePath();
|
||||
function DrawRect(Left, Top, Width, Height, Color) {
|
||||
MainCanvas.beginPath();
|
||||
MainCanvas.rect(Left, Top, Width, Height);
|
||||
MainCanvas.fillStyle = Color;
|
||||
MainCanvas.fillRect(Left, Top, Width, Height);
|
||||
MainCanvas.fill();
|
||||
MainCanvas.closePath();
|
||||
}
|
||||
|
||||
// Draw a basic circle
|
||||
function DrawCircle(ctx, CenterX, CenterY, Radius, LineWidth, LineColor) {
|
||||
ctx.beginPath();
|
||||
ctx.arc(CenterX, CenterY, Radius, 0, 2 * Math.PI, false);
|
||||
ctx.lineWidth = LineWidth;
|
||||
ctx.strokeStyle = LineColor;
|
||||
ctx.stroke();
|
||||
function DrawCircle(CenterX, CenterY, Radius, LineWidth, LineColor) {
|
||||
MainCanvas.beginPath();
|
||||
MainCanvas.arc(CenterX, CenterY, Radius, 0, 2 * Math.PI, false);
|
||||
MainCanvas.lineWidth = LineWidth;
|
||||
MainCanvas.strokeStyle = LineColor;
|
||||
MainCanvas.stroke();
|
||||
}
|
||||
|
||||
// Draw --- if zero, +value in green if positive, -value in red if negative
|
||||
function DrawPosNegValue(ctx, Value, X, Y) {
|
||||
if (Value == 0) DrawText(ctx, "---", X, Y, "black");
|
||||
if (Value > 0) DrawText(ctx, "+" + Value.toString(), X, Y, "#00BB00");
|
||||
if (Value < 0) DrawText(ctx, Value.toString(), X, Y, "#BB0000");
|
||||
function DrawPosNegValue(Value, X, Y) {
|
||||
if (Value == 0) DrawText("---", X, Y, "black");
|
||||
if (Value > 0) DrawText("+" + Value.toString(), X, Y, "#00BB00");
|
||||
if (Value < 0) DrawText(Value.toString(), X, Y, "#BB0000");
|
||||
}
|
||||
|
||||
// Draw the current actor stats toward the player
|
||||
function DrawActorStats(ctx, Left, Top) {
|
||||
function DrawActorStats(Left, Top) {
|
||||
|
||||
// Draw the actor name and icon
|
||||
DrawText(ctx, CurrentActor, Left - 200, Top + 17, "black");
|
||||
DrawImage(ctx, "Icons/Heart.png", Left - 110, Top);
|
||||
DrawImage(ctx, "Icons/Submission.png", Left - 10, Top);
|
||||
DrawImage(ctx, "Icons/Orgasm.png", Left + 90, Top);
|
||||
DrawImage(ctx, "Icons/Bondage.png", Left + 190, Top);
|
||||
DrawPosNegValue(ctx, ActorGetValue(ActorLove), Left - 50, Top + 17);
|
||||
DrawPosNegValue(ctx, ActorGetValue(ActorSubmission), Left + 50, Top + 17);
|
||||
DrawText(ctx, ActorGetValue(ActorOrgasmCount).toString(), Left + 150, Top + 17, "black");
|
||||
DrawText(ctx, ActorGetValue(ActorBondageCount).toString(), Left + 250, Top + 17, "black");
|
||||
DrawText(CurrentActor, Left - 200, Top + 17, "black");
|
||||
DrawImage("Icons/Heart.png", Left - 110, Top);
|
||||
DrawImage("Icons/Submission.png", Left - 10, Top);
|
||||
DrawImage("Icons/Orgasm.png", Left + 90, Top);
|
||||
DrawImage("Icons/Bondage.png", Left + 190, Top);
|
||||
DrawPosNegValue(ActorGetValue(ActorLove), Left - 50, Top + 17);
|
||||
DrawPosNegValue(ActorGetValue(ActorSubmission), Left + 50, Top + 17);
|
||||
DrawText(ActorGetValue(ActorOrgasmCount).toString(), Left + 150, Top + 17, "black");
|
||||
DrawText(ActorGetValue(ActorBondageCount).toString(), Left + 250, Top + 17, "black");
|
||||
|
||||
}
|
||||
|
||||
// Draw the intro box
|
||||
function DrawIntro(ctx, Intro, CurrentStagePosition, LoveLevel, SubLevel) {
|
||||
function DrawIntro(Intro, CurrentStagePosition, LoveLevel, SubLevel) {
|
||||
|
||||
// Draw the top box and stats
|
||||
DrawRect(ctx, 0, 0, 599, 150, "White");
|
||||
DrawRect(0, 0, 599, 150, "White");
|
||||
if (CurrentActor != "") {
|
||||
DrawRect(ctx, 30, 60, 539, 1, "Black");
|
||||
DrawActorStats(ctx, 300, 15);
|
||||
DrawRect(30, 60, 539, 1, "Black");
|
||||
DrawActorStats(300, 15);
|
||||
}
|
||||
|
||||
// Find the correct intro text
|
||||
|
@ -166,24 +159,24 @@ function DrawIntro(ctx, Intro, CurrentStagePosition, LoveLevel, SubLevel) {
|
|||
ShowText = Intro[I][IntroText];
|
||||
|
||||
// Draw the intro
|
||||
if (CurrentActor != "") DrawText(ctx, ShowText, 300, 105, "black");
|
||||
else DrawText(ctx, ShowText, 300, 75, "black");
|
||||
if (CurrentActor != "") DrawText(ShowText, 300, 105, "black");
|
||||
else DrawText(ShowText, 300, 75, "black");
|
||||
|
||||
}
|
||||
|
||||
// Draw a selectable option on the screen
|
||||
function DrawOption(ctx, OptionText, Left, Top) {
|
||||
function DrawOption(OptionText, Left, Top) {
|
||||
|
||||
// Draw the rectangle and text
|
||||
if (OptionText.substr(0, 1) == "@") OptionText = OptionText.substr(1);
|
||||
DrawRect(ctx, Left, Top, 299, 89, "White");
|
||||
if ((MouseX >= Left) && (MouseX <= Left + 299) && (MouseY >= Top) && (MouseY <= Top + 89) && !IsMobile) DrawText(ctx, OptionText, Left + 150, Top + 45, "#00BB00");
|
||||
else DrawText(ctx, OptionText, Left + 150, Top + 45, "#BB0000");
|
||||
DrawRect(Left, Top, 299, 89, "White");
|
||||
if ((MouseX >= Left) && (MouseX <= Left + 299) && (MouseY >= Top) && (MouseY <= Top + 89) && !IsMobile) DrawText(OptionText, Left + 150, Top + 45, "#00BB00");
|
||||
else DrawText(OptionText, Left + 150, Top + 45, "#BB0000");
|
||||
|
||||
}
|
||||
|
||||
// Draw all the possible interactions
|
||||
function DrawInteraction(ctx, Stage, CurrentStagePosition, LoveLevel, SubLevel) {
|
||||
function DrawInteraction(Stage, CurrentStagePosition, LoveLevel, SubLevel) {
|
||||
|
||||
// Find all the correct interactions for the current stage
|
||||
var Pos = 0;
|
||||
|
@ -192,7 +185,7 @@ function DrawInteraction(ctx, Stage, CurrentStagePosition, LoveLevel, SubLevel)
|
|||
if (ActorInteractionAvailable(Stage[S][StageLoveReq], Stage[S][StageSubReq], Stage[S][StageVarReq], Stage[S][StageInteractionText], false)) {
|
||||
|
||||
// Draw the box and interaction
|
||||
DrawOption(ctx, Stage[S][StageInteractionText], (Pos % 2) * 300, 151 + (Math.round((Pos - 1) / 2) * 90));
|
||||
DrawOption(Stage[S][StageInteractionText], (Pos % 2) * 300, 151 + (Math.round((Pos - 1) / 2) * 90));
|
||||
Pos = Pos + 1;
|
||||
|
||||
}
|
||||
|
@ -222,13 +215,12 @@ function BuildInteraction(CurrentStagePosition) {
|
|||
if ((CurrentIntro != null) && (CurrentStage != null)) {
|
||||
|
||||
// Paints the background depending on the current stage
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, CurrentChapter + "/" + CurrentScreen + "/" + FindImage(CurrentIntro, CurrentStagePosition), 600, 0);
|
||||
DrawRect(ctx, 0, 0, 600, 600, "Black");
|
||||
DrawImage(CurrentChapter + "/" + CurrentScreen + "/" + FindImage(CurrentIntro, CurrentStagePosition), 600, 0);
|
||||
DrawRect(0, 0, 600, 600, "Black");
|
||||
|
||||
// Build all the options for interaction
|
||||
DrawIntro(ctx, CurrentIntro, CurrentStagePosition, 0, 0);
|
||||
DrawInteraction(ctx, CurrentStage, CurrentStagePosition, 0, 0);
|
||||
DrawIntro(CurrentIntro, CurrentStagePosition, 0, 0);
|
||||
DrawInteraction(CurrentStage, CurrentStagePosition, 0, 0);
|
||||
|
||||
}
|
||||
|
||||
|
@ -251,26 +243,26 @@ function GetPlayerIconImage() {
|
|||
}
|
||||
|
||||
// Draw all the inventory icons
|
||||
function DrawInventory(ctx) {
|
||||
function DrawInventory() {
|
||||
|
||||
// Draw the player icon
|
||||
if (((MouseX >= 1) && (MouseX <= 74) && (MouseY >= 601) && (MouseY <= 674)) || (IsMobile))
|
||||
DrawImage(ctx, "Icons/" + GetPlayerIconImage() + "_Active.png", 0, 601);
|
||||
DrawImage("Icons/" + GetPlayerIconImage() + "_Active.png", 0, 601);
|
||||
else
|
||||
DrawImage(ctx, "Icons/" + GetPlayerIconImage() + "_Inactive.png", 0, 601);
|
||||
DrawImage("Icons/" + GetPlayerIconImage() + "_Inactive.png", 0, 601);
|
||||
|
||||
// Draw an arrow over the player head if there's a skill level up
|
||||
if (PlayerSkillShowLevelUp > 0) DrawImage(ctx, "Icons/SkillLevelUp.png", 0, 601);
|
||||
if (PlayerSkillShowLevelUp > 0) DrawImage("Icons/SkillLevelUp.png", 0, 601);
|
||||
|
||||
// Scroll in the full inventory to draw the icons and quantity, draw a padlock over the item if it's locked
|
||||
var Pos = 1;
|
||||
for (var I = 0; I < PlayerInventory.length; I++) {
|
||||
var ImgState = "Inactive";
|
||||
if (((MouseX >= 1 + Pos * 75) && (MouseX <= 74 + Pos * 75) && (MouseY >= 601) && (MouseY <= 674)) || (IsMobile)) ImgState = "Active";
|
||||
DrawImage(ctx, "Icons/" + PlayerInventory[I][PlayerInventoryName] + "_" + ImgState + ".png", 1 + Pos * 75, 601);
|
||||
DrawText(ctx, PlayerInventory[I][PlayerInventoryQuantity].toString(), Pos * 75 + 64, 661, "#000000");
|
||||
DrawImage("Icons/" + PlayerInventory[I][PlayerInventoryName] + "_" + ImgState + ".png", 1 + Pos * 75, 601);
|
||||
DrawText(PlayerInventory[I][PlayerInventoryQuantity].toString(), Pos * 75 + 64, 661, "#000000");
|
||||
if (PlayerHasLockedInventory(PlayerInventory[I][PlayerInventoryName]))
|
||||
DrawImage(ctx, "Icons/Lock_" + ImgState + ".png", Pos * 75, 600)
|
||||
DrawImage("Icons/Lock_" + ImgState + ".png", Pos * 75, 600)
|
||||
Pos = Pos + 1;
|
||||
};
|
||||
|
||||
|
@ -278,12 +270,12 @@ function DrawInventory(ctx) {
|
|||
for (var I = 0; I < PlayerLockedInventory.length; I++)
|
||||
if (!PlayerHasInventory(PlayerLockedInventory[I])) {
|
||||
if (((MouseX >= 1 + Pos * 75) && (MouseX <= 74 + Pos * 75) && (MouseY >= 601) && (MouseY <= 674)) || (IsMobile)) {
|
||||
DrawImage(ctx, "Icons/" + PlayerLockedInventory[I] + "_Active.png", 1 + Pos * 75, 601);
|
||||
DrawImage(ctx, "Icons/Lock_Active.png", Pos * 75, 600);
|
||||
DrawImage("Icons/" + PlayerLockedInventory[I] + "_Active.png", 1 + Pos * 75, 601);
|
||||
DrawImage("Icons/Lock_Active.png", Pos * 75, 600);
|
||||
}
|
||||
else {
|
||||
DrawImage(ctx, "Icons/" + PlayerLockedInventory[I] + "_Inactive.png", 1 + Pos * 75, 601);
|
||||
DrawImage(ctx, "Icons/Lock_Inactive.png", Pos * 75, 600);
|
||||
DrawImage("Icons/" + PlayerLockedInventory[I] + "_Inactive.png", 1 + Pos * 75, 601);
|
||||
DrawImage("Icons/Lock_Inactive.png", Pos * 75, 600);
|
||||
}
|
||||
Pos = Pos + 1;
|
||||
};
|
||||
|
@ -294,21 +286,20 @@ function DrawInventory(ctx) {
|
|||
function BuildBottomBar() {
|
||||
|
||||
// Paints the background depending on the current stage
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawRect(ctx, 0, 600, 1200, 1, "black");
|
||||
DrawRect(ctx, 0, 601, 1200, 74, "white");
|
||||
DrawRect(ctx, 975, 600, 1, 675, "black");
|
||||
DrawInventory(ctx);
|
||||
DrawRect(0, 600, 1200, 1, "black");
|
||||
DrawRect(0, 601, 1200, 74, "white");
|
||||
DrawRect(975, 600, 1, 675, "black");
|
||||
DrawInventory();
|
||||
|
||||
// Draw the leave icon and clock
|
||||
if (LeaveIcon != "") {
|
||||
DrawImage(ctx, "Icons/Clock.png", 985, 621);
|
||||
DrawText(ctx, msToTime(CurrentTime), 1073, 637, "black");
|
||||
if (((MouseX >= 1125) && (MouseX <= 1200) && (MouseY >= 600) && (MouseY <= 675)) || (IsMobile)) DrawImage(ctx, "Icons/" + LeaveIcon + "_Active.png", 1125, 600);
|
||||
else DrawImage(ctx, "Icons/" + LeaveIcon + "_Inactive.png", 1125, 600);
|
||||
DrawImage("Icons/Clock.png", 985, 621);
|
||||
DrawText(msToTime(CurrentTime), 1073, 637, "black");
|
||||
if (((MouseX >= 1125) && (MouseX <= 1200) && (MouseY >= 600) && (MouseY <= 675)) || (IsMobile)) DrawImage("Icons/" + LeaveIcon + "_Active.png", 1125, 600);
|
||||
else DrawImage("Icons/" + LeaveIcon + "_Inactive.png", 1125, 600);
|
||||
} else {
|
||||
DrawImage(ctx, "Icons/Clock.png", 1010, 621);
|
||||
DrawText(ctx, msToTime(CurrentTime), 1110, 637, "black");
|
||||
DrawImage("Icons/Clock.png", 1010, 621);
|
||||
DrawText(msToTime(CurrentTime), 1110, 637, "black");
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -358,15 +349,13 @@ function DrawGetPlayerImageName(IncludePose) {
|
|||
|
||||
// Draw the regular player image (600x600) (can zoom if an X and Y are provided)
|
||||
function DrawPlayerImage(X, Y) {
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
if ((X == 0) && (Y == 0)) DrawImage(ctx, "C999_Common/Player/" + DrawGetPlayerImageName(false) + ".jpg", 600, 0);
|
||||
else DrawImageZoom(ctx, "C999_Common/Player/" + DrawGetPlayerImageName(false) + ".jpg", X, Y, 600, 600, 600, 0, 1200, 1200);
|
||||
if ((X == 0) && (Y == 0)) DrawImage("C999_Common/Player/" + DrawGetPlayerImageName(false) + ".jpg", 600, 0);
|
||||
else DrawImageZoom("C999_Common/Player/" + DrawGetPlayerImageName(false) + ".jpg", X, Y, 600, 600, 600, 0, 1200, 1200);
|
||||
}
|
||||
|
||||
// Draw the transparent player image (600x900) with a zoom if required
|
||||
function DrawTransparentPlayerImage(X, Y, Zoom) {
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImageZoom(ctx, "Actors/Player/" + DrawGetPlayerImageName(true) + ".png", 0, 0, 600, 900, X, Y, 600 * Zoom, 900 * Zoom);
|
||||
DrawImageZoom("Actors/Player/" + DrawGetPlayerImageName(true) + ".png", 0, 0, 600, 900, X, Y, 600 * Zoom, 900 * Zoom);
|
||||
}
|
||||
|
||||
// Draw the transparent actor over the current background
|
||||
|
@ -410,8 +399,7 @@ function DrawActor(ActorToDraw, X, Y, Zoom) {
|
|||
if (ActorSpecificGetValue(ActorToDraw, ActorPose) != "") ImagePose = "_" + ActorSpecificGetValue(ActorToDraw, ActorPose);
|
||||
|
||||
// Draw the full image from all parts
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImageZoom(ctx, "Actors/" + ActorToDraw + "/" + ImageCloth + ImageBondage + ImageCollar + ImageGag + ImageBlindfold + ImagePose + ".png", 0, 0, 600, 900, X, Y, 600 * Zoom, 900 * Zoom);
|
||||
DrawImageZoom("Actors/" + ActorToDraw + "/" + ImageCloth + ImageBondage + ImageCollar + ImageGag + ImageBlindfold + ImagePose + ".png", 0, 0, 600, 900, X, Y, 600 * Zoom, 900 * Zoom);
|
||||
|
||||
}
|
||||
|
||||
|
@ -428,9 +416,9 @@ function DrawInteractionActor() {
|
|||
}
|
||||
|
||||
// Draw a ramdom image of the player as transition from chapter to chapter
|
||||
function DrawPlayerTransition(ctx) {
|
||||
function DrawPlayerTransition() {
|
||||
var ImgRnd = (Math.round(new Date().getTime() / 5000) % 5) + 1;
|
||||
DrawImage(ctx, "Actors/PlayerTransition/Player0" + ImgRnd.toString() + ".png", 900, 0);
|
||||
DrawImage("Actors/PlayerTransition/Player0" + ImgRnd.toString() + ".png", 900, 0);
|
||||
}
|
||||
|
||||
// Returns a the path to a icon. IconName can be preceeded by additional paths.
|
||||
|
|
17
Struggle.js
17
Struggle.js
|
@ -96,19 +96,18 @@ function StruggleGetImage(StruggleStage) {
|
|||
function StruggleDraw(NoStruggleMessage, StruggleStage) {
|
||||
|
||||
// Draw the background image
|
||||
var ctx = document.getElementById("MainCanvas").getContext("2d");
|
||||
DrawImage(ctx, StruggleGetImage(StruggleStage), 0, 0);
|
||||
DrawImage(StruggleGetImage(StruggleStage), 0, 0);
|
||||
|
||||
// Draw the struggle text on top
|
||||
if (StruggleProgress <= 0) DrawText(ctx, NoStruggleMessage, 600, 30, "white");
|
||||
if (StruggleProgress >= 100) DrawText(ctx, StruggleDoneMessage, 600, 30, "white");
|
||||
if ((StruggleProgress > 0) && (StruggleProgress < 100)) { DrawText(ctx, StruggleMessage, 600, 30, "white"); DrawCircle(ctx, StruggleX, StruggleY, StruggleRadius + 4, 4, "white"); }
|
||||
if ((StruggleProgress > 50) && (StruggleProgress < 100)) DrawText(ctx, StruggleDifficultyShown, StruggleX, StruggleY + StruggleRadius + 30, "white");
|
||||
if (StruggleProgress <= 0) DrawText(NoStruggleMessage, 600, 30, "white");
|
||||
if (StruggleProgress >= 100) DrawText(StruggleDoneMessage, 600, 30, "white");
|
||||
if ((StruggleProgress > 0) && (StruggleProgress < 100)) { DrawText(StruggleMessage, 600, 30, "white"); DrawCircle(StruggleX, StruggleY, StruggleRadius + 4, 4, "white"); }
|
||||
if ((StruggleProgress > 50) && (StruggleProgress < 100)) DrawText(StruggleDifficultyShown, StruggleX, StruggleY + StruggleRadius + 30, "white");
|
||||
|
||||
// Draw the progress meter
|
||||
DrawRect(ctx, 399, 579, 402, 12, "white");
|
||||
DrawRect(ctx, 400, 580, StruggleProgress * 4, 10, "#66FF66");
|
||||
DrawRect(ctx, 400 + (StruggleProgress * 4), 580, (100 - StruggleProgress) * 4, 10, "red");
|
||||
DrawRect(399, 579, 402, 12, "white");
|
||||
DrawRect(400, 580, StruggleProgress * 4, 10, "#66FF66");
|
||||
DrawRect(400 + (StruggleProgress * 4), 580, (100 - StruggleProgress) * 4, 10, "red");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -100,6 +100,7 @@
|
|||
<script src="C009_Library/Library/Script.js"></script>
|
||||
<script src="C009_Library/Search/Script.js"></script>
|
||||
<script src="C009_Library/Jennifer/Script.js"></script>
|
||||
<script src="C009_Library/Yuki/Script.js"></script>
|
||||
<script src="C009_Library/Outro/Script.js"></script>
|
||||
<script src="C010_Revenge/Intro/Script.js"></script>
|
||||
<script src="C010_Revenge/AmandaSarah/Script.js"></script>
|
||||
|
@ -146,6 +147,7 @@
|
|||
|
||||
// When the code is loaded, start on "Chapter 0" to select a chapter and loads the default language
|
||||
window.onload = function() {
|
||||
MainCanvas = document.getElementById("MainCanvas").getContext("2d");
|
||||
if (localStorage.getItem("CurrentLanguageTag")) CurrentLanguageTag = localStorage.getItem("CurrentLanguageTag");
|
||||
IsMobile = DetectMobile();
|
||||
document.getElementById("MainCanvas").addEventListener("keypress", KeyDown);
|
||||
|
|
Loading…
Add table
Reference in a new issue