Parser/new format implemented

main
Lojemiru 5 years ago
parent c4b353e516
commit 1abcdeeb64

@ -25,176 +25,92 @@
<arguments> <arguments>
<argument> <argument>
<kind>1</kind> <kind>1</kind>
<string>CREDITS_LENGTH = 160; <string>/*
TARGET_WIDTH = 240; FORMATTING KEY:
; = linebreak marker (NOT # because we want to handle it manually and insert them later)
for (var i = 0; i &lt; CREDITS_LENGTH; i++) { = = split into left/right strings here
for (var j = 0; j &lt; 3; j++) { / = centered name
/* * = centered header (gets custom display color)
0 - first row */
1 - second row
3 - (TO BE IMPLEMENTED) titles (so that they can have a different color/be centered) // Refer to key key
*/ text = "*Another " + global.monsterStr + " 2 Remake;;;;;;;;;;;;*Producer;/Milton 'DoctorM64' Guasti;;*Graphic Design;Ramiro Negri=MichaelGabrielR;Jasper=Jack Witty;/Steve 'Sabre230' Rothlisberger;/Kirill '1Eni1' Fevralev;;*Promo Art;/Azima 'Zim' Khan;;*Writing;/James 'Ridley' Hobbs;/Paulo 'Latinlingo' Villalobos;;*Platform Engine Code;/Martin Piecyk;;*Music Composition;/Milton 'DoctorM64' Guasti;/Darren Kerwin;/Torbjørn 'Falcool' Brandrud;;*Debug;/Dragondarch;/Hemse;/Esteban 'DruidVorse' Criado;/Verneri 'Naatiska' Viljanen;;*Playtesting;Jennifer Potter=Mario Crestanello;Live4Truths=Torbjørn 'Falcool' Brandrud;Lise Trehjørningen=Gabriel Kaplan;Nommiin=Nicolas 'Skol' Del Negro;Darren Kerwin=Robert Sephazon;;*Community Management;Dragonheart91=Ammypendent;/Karrde;;*Special Thanks;Nommiin=Nathan 'wickedclown' Hess;Tyler Rogers=Kousoru;Infinity's End=Isabelle Amponin;CapCom=The " + global.monsterStr + " Community;;;;*Source Code Reconstruction;/YellowAfterlife;;;;*Continued Revisions;;*Development;Gatordile=Lojemiru;/Alex 'Wanderer' Mack;;*Programming;Craig Kostelecky=" + global.monsterStr + "3D;;*Art Lead;/Dannon 'Shmegleskimo' Yates;;*Art;ShirtyScarab=Cooper Garvin;Chris 'Messianic' Oliveira=ChloePlz;;*Special Thanks;Banjo=Jean-Samuel Pelletier;King Bore=Scooterboot;Reaku The Crate=Grom PE;Sylandro=TheKhaosDemon;Unknown=Iwantdevil;PixHammer=CaptGlitch;Nokbient=EODTex;Electrix=gponys;/Japanese Community;;;;;;*Original " + global.monsterStr + " II Staff;;*Producer;/Gunpei Yokoi;;*Director;Hiroji Kiyotake=Hiroyuki Kimura;;*Main Programmer;/Takahiro Harada;;*Programmer;Masaru Yamanaka=Masao Yamamoto;/Isao Hirano;;*Graphic Designer;Hiroji Kiyotake=Hiroyuki Kimura;;*Program Assistant;Yuzuru Ogawa=Nobuhiro Ozaki;;*Sound Programmer;/Ryohji Yoshitomi;;*Designer;Makoto Kanoh=Masafumi Sakashita;Tomoyoshi Yamane=Takehiko Hosokawa;/Yasuo Inoue;;*Debug;Masaru Okadaga=Kenji Nishizawa;Hirofumi Matsuoka=Tohru Ohsawa;Kohta Fukui=Keisuke Terasaki;Kenichi Sugino=Hitoshi Yamagami;Katsuya Yamaoe=Yuji Hori;;;;;;;;;;/In Memory of Satoru Iwata;";
// Constants
TEXT_ROWS = string_count(";", text);
X_POS = room_width / 2;
// Vars
var arrayIndex = 0;
var subStr = "";
var line = 0;
// Generate blank space in 2D array...
for (var i = 0; i &lt; TEXT_ROWS; i++) {
for (var j = 0; j &lt; 4; j++) {
textArray[i, j] = ""; textArray[i, j] = "";
} }
} }
// Parse text
var i = 0; for (var i = 1; i &lt;= string_length(text); i++) {
textArray[i++, 0] = "Another " + global.monsterStr + " 2 Remake"; // Get next char
i += 11; var nextChar = string_char_at(text, i);
textArray[i++, 0] = "Producer";
textArray[i++, 0] = "Milton 'DoctorM64' Guasti"; // Parsing - refer to key above
i++; if (nextChar == "=") { // Split
textArray[i++, 0] = "Graphic Design"; // Store subStr as left (technically anything but left is what it /should/ be)
textArray[i++, 0] = "Ramiro Negri"; textArray[line, arrayIndex] = subStr;
textArray[i++, 0] = "Steve 'Sabre230' Rothlisberger";
textArray[i++, 0] = "Jack Witty"; // Reset subStr
textArray[i++, 0] = "Kirill '1Eni1' Fevralev"; subStr = "";
textArray[i++, 0] = "Jasper";
textArray[i++, 0] = "MichaelGabrielR"; // Set next index to right
i++; arrayIndex = 1;
textArray[i++, 0] = "Promo Art"; }
textArray[i++, 0] = "Azima 'Zim' Khan"; else if (nextChar == ";") { // Linebreak
i++; // Store subStr to index
textArray[i++, 0] = "Writing"; textArray[line, arrayIndex] = subStr;
textArray[i++, 0] = "James 'Ridley' Hobbs";
textArray[i++, 0] = "Paulo 'Latinlingo' Villalobos"; // Reset subStr/index
i++; subStr = "";
textArray[i++, 0] = "Platform Engine Code"; arrayIndex = 0;
textArray[i++, 0] = "Martin Piecyk";
i++; // Drop to next line
textArray[i++, 0] = "Music Composition"; line++;
textArray[i++, 0] = "Milton 'DoctorM64' Guasti"; }
textArray[i++, 0] = "Darren Kerwin"; else if (nextChar == "/") { // Centered
textArray[i++, 0] = "Torbjørn 'Falcool' Brandrud"; // Set index to center
i++; arrayIndex = 2;
textArray[i++, 0] = "Debug"; }
textArray[i++, 0] = "Hemse"; else if (nextChar == "*") { // Centered header
textArray[i++, 0] = "Dragondarch"; // Set index to header
textArray[i++, 0] = "Esteban 'DruidVorse' Criado"; arrayIndex = 3;
textArray[i++, 0] = "Verneri 'Naatiska' Viljanen"; }
i++; else {
textArray[i++, 0] = "Playtest"; // Add current char to subStr
textArray[i++, 0] = "Jennifer Potter"; subStr += nextChar;
textArray[i++, 0] = "Mario Crestanello"; }
textArray[i++, 0] = "Live4Truths";
textArray[i++, 0] = "Torbjørn 'Falcool' Brandrud";
textArray[i++, 0] = "Lise Trehjørningen";
textArray[i++, 0] = "Nommiin";
textArray[i++, 0] = "Gabriel Kaplan";
textArray[i++, 0] = "Nicolas 'Skol' Del Negro";
textArray[i++, 0] = "Darren Kerwin";
textArray[i++, 0] = "Robert Sephazon";
i++;
textArray[i++, 0] = "Community Management";
textArray[i++, 0] = "Dragonheart91";
textArray[i++, 0] = "Ammypendent";
textArray[i++, 0] = "Karrde";
i++;
textArray[i++, 0] = "Special Thanks";
textArray[i++, 0] = "Nommiin";
textArray[i++, 0] = "Nathan 'wickedclown' Hess";
textArray[i++, 0] = "Tyler Rogers";
textArray[i++, 0] = "Kousoru";
textArray[i++, 0] = "Infinity's End";
textArray[i++, 0] = "CapCom";
textArray[i++, 0] = "Isabelle Amponin";
textArray[i++, 0] = "The " + global.monsterStr + " Community";
i += 3;
textArray[i++, 0] = "Source Code Reconstruction";
textArray[i++, 0] = "YellowAfterlife";
i += 3;
textArray[i++, 0] = "Continued Revisions";
i++;
textArray[i++, 0] = "Development";
textArray[i++, 0] = "Gatordile";
textArray[i++, 0] = "Alex 'Wanderer' Mack";
textArray[i++, 0] = "Lojemiru";
i++;
textArray[i++, 0] = "Programming";
textArray[i++, 0] = "Craig Kostelecky";
textArray[i++, 0] = "" + global.monsterStr + "3D";
i++;
textArray[i++, 0] = "Art Lead";
textArray[i++, 0] = "Dannon 'Shmegleskimo' Yates";
i++;
textArray[i++, 0] = "Art";
textArray[i++, 0] = "ShirtyScarab";
textArray[i++, 0] = "Cooper Garvin";
textArray[i++, 0] = "Mccad00";
textArray[i++, 0] = "Nao";
textArray[i++, 0] = "Chris 'Messianic' Oliveira";
textArray[i++, 0] = "ChloePlz";
i++;
textArray[i++, 0] = "Debug";
textArray[i++, 0] = "DruidVorse";
textArray[i++, 0] = "Miepee";
i++;
textArray[i++, 0] = "Special Thanks";
textArray[i, 0] = "Banjo"; textArray[i++, 1] = "Grom PE";
textArray[i, 0] = "King Bore"; textArray[i++, 1] = "Jean-Samuel Pelletier";
textArray[i, 0] = "Reaku The Crate"; textArray[i++, 1] = "Scooterboot";
textArray[i, 0] = "Sylandro"; textArray[i++, 1] = "TheKhaosDemon";
textArray[i, 0] = "Unknown"; textArray[i++, 1] = "Iwantdevil";
textArray[i, 0] = "PixHammer"; textArray[i++, 1] = "CaptGlitch";
textArray[i, 0] = "Nokbient"; textArray[i++, 1] = "EODTex";
textArray[i, 0] = "Electrix"; textArray[i++, 1] = "gponys";
textArray[i++, 0] = "Japanese Community";
i += 5;
textArray[i++, 0] = "Original " + global.monsterStr + " II Staff";
i++;
textArray[i++, 0] = "Producer";
textArray[i++, 0] = "Gunpei Yokoi";
i++;
textArray[i++, 0] = "Director";
textArray[i, 0] = "Hiroji Kiyotake"; textArray[i++, 1] = "Hiroyuki Kimura";
i++;
textArray[i++, 0] = "Main Programmer";
textArray[i++, 0] = "Takahiro Harada";
i++;
textArray[i++, 0] = "Programmer";
textArray[i, 0] = "Masaru Yamanaka"; textArray[i++, 1] = "Masao Yamamoto";
textArray[i++, 0] = "Isao Hirano";
i++;
textArray[i++, 0] = "Graphic Designer";
textArray[i, 0] = "Hiroji Kiyotake"; textArray[i++, 1] = "Hiroyuki Kimura";
i++;
textArray[i++, 0] = "Program Assistant";
textArray[i, 0] = "Yuzuru Ogawa"; textArray[i++, 1] = "Nobuhiro Ozaki";
i++;
textArray[i++, 0] = "Sound Programmer";
textArray[i++, 0] = "Ryohji Yoshitomi";
i++;
textArray[i++, 0] = "Designer";
textArray[i, 0] = "Makoto Kanoh"; textArray[i++, 1] = "Masafumi Sakashita";
textArray[i, 0] = "Tomoyoshi Yamane"; textArray[i++, 1] = "Takehiko Hosokawa";
textArray[i++, 0] = "Yasuo Inoue";
i++;
textArray[i++, 0] = "Debug";
textArray[i, 0] = "Masaru Okadaga"; textArray[i++, 1] = "Kenji Nishizawa";
textArray[i, 0] = "Hirofumi Matsuoka"; textArray[i++, 1] = "Tohru Ohsawa";
textArray[i, 0] = "Kohta Fukui"; textArray[i++, 1] = "Keisuke Terasaki";
textArray[i, 0] = "Kenichi Sugino"; textArray[i++, 1] = "Hitoshi Yamagami";
textArray[i, 0] = "Katsuya Yamaoe"; textArray[i++, 1] = "Yuji Hori";
i += 9;
textArray[i++, 0] = "In Memory of Satoru Iwata";
text1 = "";
text2 = "";
for (var i = 0; i &lt; CREDITS_LENGTH; i++) {
text1 += textArray[i, 0] + "#";
text2 += textArray[i, 1] + "#";
} }
// Create text strings
textLeft = "";
textRight = "";
textCenter = "";
textHeader = "";
// Compile arrays into their respective strings; add newlines
for (var i = 0; i &lt; TEXT_ROWS; i++) {
textLeft += textArray[i, 0] + "#";
textRight += textArray[i, 1] + "#";
textCenter += textArray[i, 2] + "#";
textHeader += textArray[i, 3] + "#";
}
yoffset = 0; yoffset = 0;
fadeout = 0; fadeout = 0;
canfadeout = 0; canfadeout = 0;
//canfadeout = 1; //remove this!
alarm[0] = 1; alarm[0] = 1;
image_alpha = 0; image_alpha = 0;
if (global.creditsmenuopt == 1) { if (global.creditsmenuopt == 1) {
@ -207,170 +123,6 @@ if (global.creditsmenuopt == 1) {
} }
if (os_type == os_android) os_powersave_enable(false); if (os_type == os_android) os_powersave_enable(false);
widespace = oControl.widescreen*53;
/*
text = "Another " + global.monsterStr + " 2 Remake
Producer
Milton 'DoctorM64' Guasti
Graphic Design
Ramiro Negri
Steve 'Sabre230' Rothlisberger
Jack Witty
Kirill '1Eni1' Fevralev
Jasper
MichaelGabrielR
Promo Art
Azima 'Zim' Khan
Writing
James 'Ridley' Hobbs
Paulo 'Latinlingo' Villalobos
Platform Engine Code
Martin Piecyk
Music Composition
Milton 'DoctorM64' Guasti
Darren Kerwin
Torbjørn 'Falcool' Brandrud
Debug
Hemse
Dragondarch
Esteban 'DruidVorse' Criado
Verneri 'Naatiska' Viljanen
Playtest
Jennifer Potter
Mario Crestanello
Live4Truths
Torbjørn 'Falcool' Brandrud
Lise Trehjørningen
Nommiin
Gabriel Kaplan
Nicolas 'Skol' Del Negro
Darren Kerwin
Robert Sephazon
Community Management
Dragonheart91
Ammypendent
Karrde
Special Thanks
Nommiin
Nathan 'wickedclown' Hess
Tyler Rogers
Kousoru
Infinity's End
CapCom
Isabelle Amponin
The " + global.monsterStr + " Community
Source Code Reconstruction
YellowAfterlife
Continued Revisions
Lead - Former
Gatordile
Alex 'Wanderer' Mack
Lead
Lojemiru
Development
Craig Kostelecky
" + global.monsterStr + "3D
Art Lead
Dannon 'Shmegleskimo' Yates
Art
ShirtyScarab
Cooper Garvin
Chris 'Messianic' Oliveira
ChloePlz
Special Thanks
Banjo, Grom PE,
King Bore, Jean-Samuel Pelletier,
Reaku The Crate, Scooterboot,
Sylandro, TheKhaosDemon,
Unknown, Iwantdevil,
PixHammer, CaptGlitch,
Nokbient, EODTex,
Electrix, gponys,
Japanese Community
Original " + global.monsterStr + " II Staff
Producer
Gunpei Yokoi
Director
Hiroji Kiyotake, Hiroyuki Kimura
Main Programmer
Takahiro Harada
Programmer
Masaru Yamanaka, Masao Yamamoto,
Isao Hirano
Graphic Designer
Hiroji Kiyotake, Hiroyuki Kimura
Program Assistant
Yuzuru Ogawa, Nobuhiro Ozaki
Sound Programmer
Ryohji Yoshitomi
Designer
Makoto Kanoh, Masafumi Sakashita,
Tomoyoshi Yamane, Takehiko Hosokawa,
Yasuo Inoue
Debug
Masaru Okadaga, Kenji Nishizawa,
Hirofumi Matsuoka, Tohru Ohsawa,
Kohta Fukui, Keisuke Terasaki,
Kenichi Sugino, Hitoshi Yamagami,
Katsuya Yamaoe, Yuji Hori
In Memory of Satoru Iwata";
</string> </string>
</argument> </argument>
</arguments> </arguments>
@ -532,37 +284,32 @@ if (global.creditsmenuopt == 0) {
<arguments> <arguments>
<argument> <argument>
<kind>1</kind> <kind>1</kind>
<string>display_set_gui_size(320,240); <string>// Setup
display_set_gui_size(320, 240);
draw_set_alpha(image_alpha); draw_set_alpha(image_alpha);
draw_set_font(fontGUI2); draw_set_font(fontGUI2);
draw_set_color(c_black);
draw_set_halign(fa_left); // Left
draw_text(x + 1 - widespace, y + 17, text1);
draw_set_halign(fa_right); draw_set_halign(fa_right);
draw_text(x + 1 - widespace + TARGET_WIDTH,y + 17, text2); draw_cool_text(X_POS - 12, y + 17, textLeft, c_black, c_white, c_white, 1);
draw_set_color(c_white);
// Right
draw_set_halign(fa_left); draw_set_halign(fa_left);
draw_text(x - widespace, y + 16, text1); draw_cool_text(X_POS + 12, y + 17, textRight, c_black, c_white, c_white, 1);
draw_set_halign(fa_right);
draw_text(x - widespace + TARGET_WIDTH, y + 16, text2);
draw_set_alpha(1);
draw_set_color(c_black);
draw_rectangle(0 - widespace, 0, 330 + widespace, 120 - yoffset, false);
draw_rectangle(0 - widespace, 120 + yoffset, 330 + widespace, 250, false);
// Center
draw_set_halign(fa_center);
draw_cool_text(X_POS, y + 17, textCenter, c_black, c_white, c_white, 1);
/* //Old code in draw event // Header
//draw_set_color(c_gray);
draw_cool_text(X_POS, y + 17, textHeader, c_black, c_dkgray, c_gray, 1);
draw_set_alpha(image_alpha); // Draw black bars
draw_set_font(fontGUI2);
draw_set_color(c_black);
draw_text(round(x + 1), round(y + 17), text);
draw_set_color(c_white);
draw_text(round(x), round(y + 16), text);
draw_set_alpha(1); draw_set_alpha(1);
draw_set_color(c_black); draw_set_color(c_black);
draw_rectangle(0, 0, 330, 120 - yoffset, false); draw_rectangle(0 - widespace, 0, 330 + widespace, 120 - yoffset, false);
draw_rectangle(0, 120 + yoffset, 330, 250, false); draw_rectangle(0 - widespace, 120 + yoffset, 330 + widespace, 250, false);
</string> </string>
</argument> </argument>
</arguments> </arguments>

Loading…
Cancel
Save