Skip to content

Commit

Permalink
More Art Spots
Browse files Browse the repository at this point in the history
  • Loading branch information
RepeatGitHub committed May 15, 2024
1 parent 60d2afc commit 2dc8df2
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 15 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
38 changes: 23 additions & 15 deletions Source/VinkiModModule.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,33 +35,41 @@ public class VinkiModModule : EverestModule {
"scenery/car/body","decals/1-forsakencity/big_sign_b","decals/1-forsakencity/camping_medium","decals/1-forsakencity/hanging_sign","decals/1-forsakencity/big_sign_e",//0-4
"decals/1-forsakencity/big_sign_d","decals/1-forsakencity/big_sign","decals/1-forsakencity/big_sign_c","scenery/memorial/memorial","decals/3-resort/painting_d",//5-9
"decals/4-cliffside/rockaline","decals/5-temple/statue_f","decals/5-temple/statue_c","decals/SJ2021/BeginnerLobby/jizo_game_a","decals/vinki/graffiti/0_dream_x",//10-14
"decals/vinki/graffiti/0_heart_x","decals/vinki/graffiti/0_dream2_x","decals/vinki/graffiti/0_bad_x","decals/vinki/graffiti/1_pico8_x","decals/vinki/graffiti/1_sicktricks_x"//15-19
"decals/vinki/graffiti/0_heart_x","decals/vinki/graffiti/0_dream2_x","decals/vinki/graffiti/0_bad_x","decals/vinki/graffiti/1_pico8_x","decals/vinki/graffiti/1_sicktricks_x",//15-19
"decals/vinki/graffiti/0_dream3_x","decals/vinki/graffiti/1_gross_x","decals/vinki/graffiti/1_oshiro_x"//20-24
];
public static String[] textureReplaceNamespaces = [
"decals/vinki/car/body","decals/vinki/big_sign_b","decals/vinki/camping_medium","decals/vinki/hanging_sign","decals/vinki/big_sign_e",
"decals/vinki/big_sign_d","decals/vinki/big_sign","decals/vinki/big_sign_c","decals/vinki/memorial","decals/vinki/painting_d",//5-9
"decals/vinki/rockavink","decals/vinki/statue_f","decals/vinki/statue_c","decals/vinki/jizo_game_a","decals/vinki/graffiti/0_dream_y",//10-14
"decals/vinki/graffiti/0_heart_y","decals/vinki/graffiti/0_dream2_y","decals/vinki/graffiti/0_bad_y","decals/vinki/graffiti/1_pico8_y","decals/vinki/graffiti/1_sicktricks_y"//15-19
"decals/vinki/graffiti/0_heart_y","decals/vinki/graffiti/0_dream2_y","decals/vinki/graffiti/0_bad_y","decals/vinki/graffiti/1_pico8_y","decals/vinki/graffiti/1_sicktricks_y",//15-19
"decals/vinki/graffiti/0_dream3_y","decals/vinki/graffiti/1_gross_y","decals/vinki/graffiti/1_oshiro_y"//20-24
];
public static String[] hasArtSpots = ["Celeste/0-Intro","Celeste/1-ForsakenCity","Celeste/2-OldSite","Celeste/3-CelestialResort","Celeste/4-GoldenRidge","Celeste/5-MirrorTemple","StrawberryJam2021/0-Lobbies/1-Beginner"];
// Add _Normal, _BSide, or _CSide based on the side.
public static String[] hasArtSpots = ["Celeste/0-Intro_Normal","Celeste/1-ForsakenCity_Normal","Celeste/2-OldSite_Normal","Celeste/3-CelestialResort_Normal","Celeste/4-GoldenRidge_Normal","Celeste/5-MirrorTemple_Normal","StrawberryJam2021/0-Lobbies/1-Beginner_Normal","Celeste/3-CelestialResort_BSide"];
public static int[][][] artSpots = [//x,y,w,h,textureNamespaces directory
[[-180,120,80,50,0]],//intro
[[1115,-1072,30,20,1],[695,-1064,40,30,2],[1742,-1440,38,22,3],[3040,-1880,40,24,3],[2233,-1344,40,66,4],[2665,-1600,20,25,5],[3340,-1950,70,35,6],[3465,-2575,75,30,7],[3985,-3140,40,80,8]],//forsaken city
[[790,1725,50,20,2],[1724,508,144,80,14],[115,-515,35,50,15],[1400,268,22,22,16],[835,-1645,32,40,17]],//old site
[[1590,-75,50,30,9],[5632,-69,56,32,18],[3193,-555,16,8,19]],//celestial resort, not hotel
[[790,1725,50,20,2],[1724,508,144,80,14],[115,-515,35,50,15],[1400,268,22,22,16],[835,-1645,32,40,17],[884,-28,24,32,20],[34,1796,60,100,8]],//old site
[[1590,-75,50,30,9],[5632,-69,56,32,18],[3193,-555,16,8,19],[5644,280,40,50,21],[5976,-184,24,40,22]],//celestial resort, not hotel
[[5145,-1425,100,25,10]],//golden ridge
[[3960,424,80,120,11],[7248,-504,240,50,12]],//mirror temple
[[3272,324,64,32,13]]//sj beginner lobby
[[3272,324,64,32,13]],//sj beginner lobby
[[10712,-457,80,120,22]]//celestial resort b-side
];

public static String[] decalNamespaces = ["0_heart","0_dream","0_dream2","0_bad","1_pico8","1_sicktricks"];
public static String[] decalNamespaces = [
"0_heart","0_dream","0_dream2","0_bad","1_pico8",//0-4
"1_sicktricks","0_dream3","1_gross","1_oshiro"//5-9
];

public static String[] hasCustomDecals = ["Celeste/2-OldSite","Celeste/3-CelestialResort","StrawberryJam2021/5-Grandmaster/maya"];
public static String[] hasCustomDecals = ["Celeste/2-OldSite_Normal","Celeste/3-CelestialResort_Normal","StrawberryJam2021/5-Grandmaster/maya_Normal","Celeste/3-CelestialResort_BSide"];

public static int[][][] customDecals = [//x,y,w,h,bg/fg/sfg=0/1/2,decals/vinki/graffiti/(this index in decalNamespaces)(_x or _y depending on off/on status).png
[[130,-510,1,1,0,0],[1760,524,1,1,1,1],[1412,279,1,1,1,2],[852,-1644,1,1,0,3],[111,1137,1,1,0,0]],//old site
[[5660,-68,1,1,0,4],[3164,-556,1,1,0,5]],//celestial resort
[[-6100,1397,1,1,0,4]]//pumber
[[130,-510,1,1,0,0],[1760,524,1,1,1,1],[1412,279,1,1,1,2],[852,-1644,1,1,0,3],[896,-12,1,1,1,6],[111,1137,1,1,0,0]],//old site
[[5660,-68,1,1,0,4],[3164,-556,1,1,0,5],[5664,297,1,1,0,7],[5992,-169,1,1,0,8]],//celestial resort
[[-6100,1397,1,1,0,4]],//pumber
[[10752,-392,1,1,0,8]]//celestial resort b-side
];

public VinkiModModule() {
Expand Down Expand Up @@ -166,8 +174,8 @@ public static void vinkiButtonPress(On.Celeste.Player.orig_Update orig, Player s
Session.vinkiRenderIt[0]=0;
if (SkinModHelperModule.GetPlayerSkinName(-1)=="Vinki_Scug") {
if (!Session.sessionStuffLoaded) {
if (Array.IndexOf(hasArtSpots,self.SceneAs<Level>().Session.Area.SID)!=-1) {
Session.sessionArtSpots=artSpots[Array.IndexOf(hasArtSpots,self.SceneAs<Level>().Session.Area.SID)];
if (Array.IndexOf(hasArtSpots,self.SceneAs<Level>().Session.Area.SID+"_"+self.SceneAs<Level>().Session.Area.Mode.ToString())!=-1) {
Session.sessionArtSpots=artSpots[Array.IndexOf(hasArtSpots,self.SceneAs<Level>().Session.Area.SID+"_"+self.SceneAs<Level>().Session.Area.Mode.ToString())];
}
Session.sessionStuffLoaded=true;
}
Expand Down Expand Up @@ -203,9 +211,9 @@ private static void vinkiRenderer(Level self) {
}
// but here's the DECAL CODE
private void vinkiDecalier(Level self, Player.IntroTypes playerIntro, bool isFromLoader) {
if (Array.IndexOf(hasCustomDecals,self.Session.Area.SID)!=-1) {
if (Array.IndexOf(hasCustomDecals,self.Session.Area.SID+"_"+self.Session.Area.Mode.ToString())!=-1) {
// If the current level is within hasCustomDecals, it sets variable myLvl for convenience.
var myLvl=Array.IndexOf(hasCustomDecals,self.Session.Area.SID);
var myLvl=Array.IndexOf(hasCustomDecals,self.Session.Area.SID+"_"+self.Session.Area.Mode.ToString());
for (var a=0;a<customDecals[myLvl].Length;a++) {
// Then, for each custom decal in the array, it places that decal in the level.
Logger.Log(LogLevel.Warn,"VinkiMod_vinkiRenderer",a.ToString());
Expand Down

0 comments on commit 2dc8df2

Please sign in to comment.