#Space Warp
1 messages · Page 6 of 1
(it doesn't compile btw)
Newtonsoft.Json prior to version 13.0.1 is vulnerable to Insecure Defaults due to improper handling of StackOverFlow exception (SOE) whenever nested expressions are being processed. Exploiting this vulnerability results in Denial Of Service (DoS), and it is exploitable when an attacker sends 5 requests that cause SOE in time frame of 5 minutes. ...
A bit too shrunk
@gilded kettle This is what you wanted somewhat?
How did the blank space at the top get added back @timber cedar?
Yup it looks good!
btw what field is that? Plugin_Name?
or is it the swinfo?
Its the swinfo
I might actually play some KSP2 for a bit
lmao havent done that in a while ngl
I still don't know what to work on w/ space warp rn, nobody makes feature requests ree
I'll make one
Ability to reload files
i want that to be able to reload textures on TUX so that artists dont have to reopen the game everytime they change a texture
Maybe only allow reloading textures that have already been loaded, so you only have to look at a limited number of paths
also the ability to load .cfg files, my plan is to make TUX export .cfg with the textures and settings that the artists set, this would work with configuration manager (i think)
Also the ability to get .jsons!!
and when present in the Mod/assets/images/partName/shader.cfg it would be loaded by TUX (or Colors) with the right configuration
this would also allow for part configuration out of the json i believe, but still have to dive into that
want me to put all this on a feature request?
Also would be nice to be able to get assets by their name, ignoring the rest of the path since thats how KSP2 does too(mostly), right now Colors has to store the modGUID in order to find the textures
Only problem w/ that is if 2 mods define an asset by the same name
hmm true, well i can always get the modguids on the SpaceWarp so its all good
but the .cfg and .json is a must!
and the Reload or ReImport
Also 

Broken for the moment?
Excel, but the CSV looks fine?
Key,Type,Description,English
SpaceWarp/ModList/Header,Text,,spacewarp.modlist
SpaceWarp/ModList/SpaceWarpMods,Text,,SpaceWarp Mods
SpaceWarp/ModList/UnmanagedMods,Text,,Unmanaged Mods
SpaceWarp/ModList/Version,Text,,Version
SpaceWarp/ModList/Author,Text,,Author
SpaceWarp/ModList/outdated,Text,,outdated
SpaceWarp/ModList/Source,Text,,Source
SpaceWarp/ModList/Description,Text,,Description
SpaceWarp/ModList/KSP2Version,Text,,KSP2 Version
SpaceWarp/ModList/Dependencies,Text,,Dependencies
SpaceWarp/ModList/OpenConfigManager,Text,,Open Configuration Manager
SpaceWarp/ModList/unsupported,Text,,unsupported
SpaceWarp/Mods,Text,,Mods
@gilded kettle it's loading the terms it seems?
But why isn't it localizing them
hmm yeah everything seems fine, thats very wierd, probably you need to acess them differently
these are custom fields, only tried to loc KSP2 fields
This is how I access them
Localization sus?
Cool, got it to show the missing translation warning
If any <@&1078770539688112168> or <@&1079271050644303922> wants to try and figure out what I am doing wrong w/ localizing?
https://github.com/SpaceWarpDev/SpaceWarp/tree/localizations
Change your line endings to lf
Are you kidding me
That is specified in the docs I wrote
I'm about to commit crime over this, I forgot that excel saved w/ crlf
That worked
@lime plaza thank you for reminding me
@timber cedar can you do russian localization of Space Warps UI text?
Or was someone else doing russian
i thought about that but i assumed u already checked that 😭
I can do portuguese
wheres the spreadsheet?
also, i wonder whats the language name... Cuz theres Portuguese, Portuguese-PT and portuguese-BR
SpaceWarpBuildTempate/Localizations
okdoki, any idea where i can find the correct language name?
http://inter-illusion.com/assets/I2LocalizationManual/LanguagesTab.html tells me its set on unity....
ig, works too lmao
Xd
bruh
i dont think that in Excel 2022 you can change this wtf
mine doesnt show that
it goes straight to the windows file manager when i click on the path
I really hate that microsfot defaults all my programs with portuguese
im not used to this at all
i'll use notepad++ for now ig
I'll be sitting in the office for another two hours in case anyone needs something but I'm bored af so might as well try to finish the mod toggling lol
bro why didnt they use the gobally used pt-pt, en-us, en-gb format????
LMAO
I didn't select anyone to ping
he is all the devs at the same time
discord why

Well, you can specify those
Instead of just English you can use English[en-US] etc
Portuguese should work then, why does it not? 
It should
lol ok
If you don't use CRLF
Oops
cries in çõ
Dumb font with no international support
But since it's just the SpaceWarp font, it can be changed
*cries in UITK being a buggy mess*
If we could get it to work properly it would make things so much easier lol
whats the current problem?
iirc it has color selection and i'd like to add that to TUX
https://discord.com/channels/1078696971088433153/1085537097714245662 you can look here
Basically the UI seems to be taking on colors from the background (probably some shader issue?) and fonts are either rendering as rectangles or not rendering at all
Specifically this: #1085537097714245662 message
doesnt it use a material for the font?
hmm thats such a wierd bug tho
i wonder whats the default uitk shader
When you export a prefab with a UITK UIDocument into a bundle, it includes the font and the shaders
The shaders it uses are called Hidden/UIE-Runtime, Hidden/UIE-RuntimeWorld and Hidden/UIE-AtlasBlit
have u tried exporting it as an addressable?, doenst make that much sense but idk
Since KSP shader are also in addressables ie
and fonts too iirc
Still, the prefab can be loaded just fine from the bundle and it should contain references to all those things
references are clearly broken tho
Actually
or either referencing another thing
I know for a fact that the shaders are loaded
font seems to be getting a camera shader
Because I even load them manually
Since I want to enable using just pure UXML and USS to render the UIs (without any bundles), I have a bundle with all three of the shaders exported and load them all manually, then I Harmony patch all the methods in the UITK namespace which try to Shader.Find(...) these shaders and instead inject the manually loaded ones
Since as far as I know, there's no way to allow shaders that are loaded at runtime dynamically to be found using Shader.Find(...)
And I'm sure that these shaders are being used since I can see their names in the UIDocument properties in UnityExplorer
hmmm
Shaders do have properties, i think shader.find just gives a default one
so maybe you'd need to do material.set[etc...]
Well i just patched the already existing code in the UITK assembly
And they don't seem to be doing any of it
So idk
Well there are some shader disassembly not supported on DXBC messages in there
my guess is that the font shader points to a 2d coordinate where the leter is, no 2d coordinate it just uses the whole camera and tahts what were seeing in the fonts
just the properties is enough to test i think
Sure, can send you those
as for background, it either is average color or color under a pixel, but i couldnt figure out what pixel it was getting it from......
Yeah it seems to be from a specific pixel but can't tell where
my guess is, if its not set its 0,0, so left bottom
That makes sense
the OAB has the green lines and the yellow lines
Since on the main menu screen it would change color pretty much only when a Kerbal starts flying in from the bottom left corner
yes then i think we found the problem
shader properties have to be set
Font uses a 2d coordinate, and height and width probably on the font texture, no font texture it just uses default
Background color probably has some shenanigan for getting the color, maybe a texture with all the used colors? idk
its possible that this is all done inside unity editor thus u not finding it on the UITK source
Yeah it is
I was testing it in an empty Unity project with just UITK installed
Made a UI with UXML, ran the scene, looked just fine
Then i exported the prefab and tried to load it in KSP
And the result is what you saw
probably decompile the editor, and search for Shader.Find(UITK shader)
i'm heading out but i can help you figure out the values once im back
in about 2h
Works fine from me, that's around when I'll be getting home from work
also look at #1087665539264020540 source code, i already have a shader editing base there, you can copy it for tests
all in Patch.cs and TUXPlugin.cs iirc
repo is on my profile btw, idk if it is on the forum here on disc
@gilded kettle did you ever get portuguese translations to work
I dont see a pr lemme check again
Oh yeah i was having auth issues when pring from github desktop
Btw if u need i can also help on spacewarp development in general not just colors
Would be helpful
Great! Ill see what i can do!
#1088215385490333706 message
should we add a message if the player as an outdated spacewarp?
Using the url for the swinfo of the most recent one
We do already
Space Warp version checks itself post 1.0.0
my mistake sorry i added an extra Guilayout.label(“”) by accident
it’s right above the GUILayout.Button(“SpaceWarp Mods”)
i think ^
that’s just from memory
I fixed ity
ye
I can confidently say that I don't look forward to merging all these changes into my current code

combining it and ty 
optimized
should this happen?
[Info :sorry/images/t-38_v1.rar] registering path "sorry/images/t-38_v1.rar"
it loaded a .rar
It doesnt check image extensions
why would it?
that would prevent you from doing anything :D
so in theory the "load .cfg and .json" is already implemented, great work guys :D
oh yeah, @timber cedar config manager cant really load it from custom paths right?
it’s the bepinex confit manger :D
so i mean, in what way
do you want a drag and drop files
i guess you could give it an absolute path
hmmm, idk if would be optimal, will look into it tho
cuz suposedly, every parts would have a config for their shader settings
well no need to be every part obviouslyt
only if the artist desires so
theres an "advanced" tab for the config manager, i guess you could use that :D idk
@wicked wyvern do you wanna look into creating UITK UIs for space warp
As that would be a great feature to release 1.1.0 w/
I can try
just need to finish the toggle feature first
quick q: would it be bad to straight up copy one method from BIE source code?
I'd rather not have to do a transpiler
Licensing...
@little bay can help ya w/ this one
wha
but what method are you thinking of copying
I'll need to most likely patch Chainloader.Start
yeah thought so
and do lots of stuff there
oh damn, thanks
I'll quickly put together the resulting "patched" method I need until then
just try to keep the number of "blocks" you add fairly low to make it easier on me 😅
a block being like
if you add three statements between two lines, I can emit all of those at once really easy
yep, got it, will try my best
if you put 3 statements in completely different places, I have to jump around to emit them
yeah
yes
@little bay actually the patch might be as simple as this:
foreach (var plugin in pluginInfos)
{
if (File.ReadAllLines(DisabledPluginsFilepath).Contains(plugin.Metadata.GUID))
{
DisabledPlugins.Add(plugin);
pluginInfos.Remove(plugin);
}
}
I don't think I actually need it to do anything else, just need it to prevent plugins with GUIDs from that file from being loaded and to instead get their PluginInfos into my own property
it's just a public static property in the patch's class
which I then fetch in SpaceWarp
I just wrote the code inside the actual BIE file to be able to inspect the code more easily
That looks like an easy enough patch
I think I could maybe take a look at how to do that for you
@wicked wyvern what function is that?
Chainloader.Start()
So here
yep between the first two lines should be it
but doesn't really matter
can be below any of them
all the way up to the first foreach that follows, really
Actually wait I can just go to an index, as BIEs dll will not update
oh yeah actually that's true
lol
to be fair I expected the patch to be much more complex but then I kinda just built the rest of the feature around it to make it as simple as possible
so I might have as well just done it myself in the end without annoying everyone else here to help
😅
I'm getting close
@little bay this should work?
I'm doing it before, so it modifies the item on the stack just before storing it
I think I need to return it though
@wicked wyvern
using System;
using System.Collections.Generic;
using System.IO;
using BepInEx;
using BepInEx.Bootstrap;
using HarmonyLib;
using MonoMod.Cil;
namespace SpaceWarp.Patching;
[HarmonyPatch]
public static class ExampleHarmonyPatchMunix
{
const int BepinexChainloaderIndex = 116;
public static List<PluginInfo> DisabledPlugins = new();
public static string DisabledPluginsFilepath = "";
[HarmonyILManipulator]
[HarmonyPatch(typeof(Chainloader), nameof(Chainloader.Start))]
private static void PatchInitializationsIL(ILContext ilContext, ILLabel endLabel)
{
ILCursor ilCursor = new(ilContext);
// ilCursor.Goto(BepinexChainloaderIndex, MoveType.After);
ilCursor.GotoNext(MoveType.Before, instruction => instruction.MatchStloc(3));
ilCursor.EmitDelegate<Func<List<PluginInfo>,List<PluginInfo>>>(static (pluginInfos) =>
{
foreach (var plugin in pluginInfos)
{
if (File.ReadAllLines(DisabledPluginsFilepath).Contains(plugin.Metadata.GUID))
{
DisabledPlugins.Add(plugin);
pluginInfos.Remove(plugin);
}
}
return pluginInfos;
});
}
}
Try this
Modify it to reference the correct things, but this should be correct
It's entirely possible I'm just being dumb again, but the patch doesn't seem to be doing anything
as in, I can see the Harmony patch loading in the preloader section in console
but can't actually get the code to do anything, including logging
hm 
it's definitely because of your refactor 
always blame the healer 
well actually
I have like the first one you did
and there are some exceptions because of it
so who knows 
most stuff works and I need to test this code and make it work before I break it again completely with another batch of conflicts 
need this one
can we please switch the console font to the rounded
like jetbrains mono
because the pixel one is fucking unreadable xdd
I just use the BepInEx console tbh
:hope:
:D
lets goooo
WOOOOOOO
YEAHHHHHHHH
i get to channel my frontend coding ability
thanks to cheese noticing one dumb mistake of mine, I finally managed to get it working within KSP2
lol
y ping
while you're here: #1079531175380521043 message
not my choice
am in vr no can look
heh
in the metaverse
Cheese, ill send you the youtube link tommarow once the 1080p version is odne processing to youtube
meatverse is the opposite of VR 
its taking forever to process the 1080p
cheese we should play vr chat
apparently 40 minute long 1080p video is too good for youtube

im quite the meatverse enjoyer
omg noo
I just rebased my branch to the current 1.1.0
just kill me now
so many conflicts
🥲
this is irrelevant to the channel
good point
well
if anyone wants to have a look at it, it's here: https://github.com/jan-bures/SpaceWarp/tree/feature-mod-toggles
I think most of it is done but the transpiler just doesn't seem to be doing anything
i mean if there was a specific pr that i could see the dif in 
ah okok
(just check the only one from me at the end of the list)
it looks p good :D
but it doesn't work
that's the issue lol
^
i see now
@wicked wyvernyou could try this instead
using System;
using System.Collections.Generic;
using System.IO;
using BepInEx.Bootstrap;
using BepInEx.Logging;
using HarmonyLib;
using Mono.Cecil;
using Mono.Cecil.Cil;
using MonoMod.Cil;
namespace SpaceWarpPatcher;
public sealed class Patcher
{
public static IEnumerable<string> TargetDLLs
{
get
{
Harmony.CreateAndPatchAll(typeof(ChainloaderPatch), "SpaceWarpChainloaderPatch");
ChainloaderPatch.DisabledPlugins = File.ReadAllLines("some path here");
ChainloaderPatch.Logger = Logger.CreateLogSource("SpaceWarp Disabled Plugins");
return Array.Empty<string>();
}
}
public static void Patch(AssemblyDefinition unused) { }
}
[HarmonyPatch]
internal static class ChainloaderPatch
{
public static string[] DisabledPlugins;
public static ManualLogSource Logger;
[HarmonyILManipulator]
[HarmonyPatch(typeof(Chainloader), nameof(Chainloader.Start))]
private static void DisablePluginsIL(ILContext il)
{
ILCursor c = new(il);
c.GotoNext(MoveType.Before,
x => x.MatchLdcI4(0),
x => x.MatchStloc(24)
);
c.Emit(OpCodes.Ldloc, 24); // current plugin guid
c.Emit(OpCodes.Ldloc, 5); // set of denied plugins so far
// false means skip to this plugin, true means continue loading it
c.EmitDelegate(static bool(string pluginGuid, HashSet<string> deniedSet) =>
{
if (Array.IndexOf(DisabledPlugins, pluginGuid) != -1)
{
deniedSet.Add(pluginGuid);
Logger.LogInfo($"{pluginGuid} was disabled, skipping loading...");
return false;
}
return true;
});
var continueLabel = c.DefineLabel();
c.Emit(OpCodes.Brfalse, continueLabel);
ILLabel realContinueLabel = default;
c.GotoNext(
x => x.MatchLdloc(29), // some log message, just need this to find where to branch to
x => x.MatchCall(AccessTools.DeclaredMethod(typeof(Logger), "LogWarning")),
x => x.MatchBr(out realContinueLabel)
);
continueLabel.Target = realContinueLabel.Target;
}
}
no idea what you guys want the path for this file to be, or its format
alright, will try, thanks!
😆

debugging at its finest
looks familiar 
localization ^
file localization, index localization, term localization 
oh well its simpler now anyway
a true coder 

idk you see if this DLL in your patchers folder breaks your game
virus
oh, also
make a random file called test.txt in your game directory
it can be empty
just needs to exist
i was lazy and just did
ChainloaderPatch.DisabledPlugins = File.ReadAllLines(Path.Combine(Paths.GameRootPath, "test.txt"));
lmao
okay sure
it's literally just a file with one BIE GUID per line
.
.o file
i mean
.d
i guess that is technically a csv
for disabled
I mean technically 
it's just called disabled_plugins in the repo lol
anyway, does that freeze your game
lovely
is that good xd
xd
yep, stuck on preloader finished
aaron not using __result

it's beautiful that's what that is
what method is missing
I need it here 
a
that's all there is in the Unity debug console
fun
logs don't even get written into
i can try to attach a debugger
wdym?
well, merged into main
thats nice
munix can you buy me nitro
why does everything I work on end up like this with 86746815 people debugging it and it not working
🥲

oprah
EVERYBODY GETS NITRO
ahhhhh
i see now
i think
i think i'm making BepInEx.dll load too early?
or at least i'm forcing it to compile Start too early
would removing the reference to BIE in the patcher and changing typeof(Chainloader) and nameof(Chainloader.Start) to literals help?
oh alright
is that good news or bad news? lol
my experience with Harmony has so far been "if the game breaks, at least you know the patch is being run" 

i am currently very confused
i think thats why munix is not sw dev
i mean
says the refactor master 
what's wrong?
the Chainloader consumed him

i have a new way to make this work
thats what they all say
^
guys here me out
omg
ok
so
we should make a mod
that skips loading screens
???? GENUIS
"Game studios hate this simple trick"
frfr
hear me otu
like fr
make mod
that gives the game 10ms
if it takes longer it just cuts it and breaks the update loop
🧠
i think
is the best thing ever made
its the pinicle of human creation
munix why no vc
and I'm extremely insecure about my spoken English lol
i can barely speak it
you speak it fine
stfu im trying to make him feel better

munix we can speak insert your language here
I mean I used to go to all sorts of competitions during elementary and high school and would usually win or at least place in the top 3, but I haven't been speaking for quite a while now and it's just getting worse and worse
u should vc
all it took was
public static class Patcher
{
public static IEnumerable<string> TargetDLLs => new[] { "UnityEngine.CoreModule.dll" };
public static void Patch(AssemblyDefinition asm)
{
var targetType = asm.MainModule.GetType("UnityEngine.Application");
var targetMethod = targetType.Methods.Single(x => x.Name == ".cctor");
using var thisAsm = AssemblyDefinition.ReadAssembly(typeof(Patcher).Assembly.Location);
var delayer = thisAsm.MainModule.GetType("SpaceWarpPatcher.Delayer");
var patchMethod = delayer.Methods.Single(m => m.Name == "PatchChainloaderStart");
ILContext il = new(targetMethod);
ILCursor c = new(il);
c.GotoNext(MoveType.Before,
x => x.MatchCall("BepInEx.Bootstrap.Chainloader", "Start")
);
c.Emit(OpCodes.Call, il.Module.ImportReference(patchMethod));
}
}
internal static class Delayer
{
public static void PatchChainloaderStart()
{
ChainloaderPatch.Logger = Logger.CreateLogSource("SpaceWarp Disabled Plugins");
ChainloaderPatch.DisabledPlugins = File.ReadAllLines(Path.Combine(Paths.GameRootPath, "test.txt"));
Harmony.CreateAndPatchAll(typeof(ChainloaderPatch));
}
}
basically inserting myself in the same place bepinex does
immediately in between Chainloader.Initialize and Chainloader.Start
patching Start immediately before it runs
^^ i almost had him vc
and you distracted him
awesome, thanks a lot!
I mean it's 4 am and my flatmate is asleep and working tomorrow
so there was no chance anyway 

i need to make a discord bot for the server
for what
to truly track the
and
counts
the disabled plugins file
just put it in the plugins folder
Path.Combine(Paths.PluginPath, "SpaceWarp", "disabled_plugins"); originally here
i think it would make more sense in the main bepinex folder
you should put it in the downloads folder
would it? even if it's SpaceWarp that creates/uses it?
the spacewarp plugin doesnt use it
it does
the patcher does
that's where I set the values from
a stale mate
well since its used by both, might as well go to the common place between them, the main folder :p
from SpaceWarp's ModListUI class
but i'll put it there for now
put it in the common place
at least give it a .txt extension though
easier for users
so its openable in a text editor (easily)
no
text editor
ok what about like .cfg or something then?
.conf
to make it obvious it's important and not just a random text file
.bat
.mp4
cfg should be fine, i suppose
just files with no extension are annoying on windows
so
or I could just make it .disabled-plugins or something
eww
that would make it hidden by default on linux
on windows to
seems like a good compromise
yeah
no, windows doesnt use that rule
munix trying to take over spacewarp
thanks again
bruh
Saint
true and real
i'm going to do some other random things real quick
now that this has multiple projects in it
sure thing
learn Shakespeare
munix could get org inv tbh
theyve done a lot
well, not really that much on the actual code of SpaceWarp
but I'll happily accept and contribute more

i think bride ^
aight bet
Invitation sent
:O
Pog
pog
I haven't even tried to import .uss into the game yet, so this might be fun
Just use asset bundles :3
also first I need to figure out whether UITK now works with all three of my methods
- complete UITK prefab in a bundle (we know this works)
- UXML and USS in a bundle
- UXML and USS loaded from disk
since the goal is to allow modders to write the UI without using Unity
Fair
But at some point I feel like using unity is going to be inevitable
Honestly, I just realized an idea that might be useful ... making our own editor scripts for unity
like for part definitions
well UITK already is a UI library basically
but I want to make a default KSP2 theme for it to include with SpaceWarp
like it already has a skin for IMGUI
first I just want to finish the plugin itself, it's pretty barebones and without any API
this is the new spacewarp csproj btw
<?xml version="1.0" encoding="utf-8"?>
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<Version>$(SpaceWarpVersion)</Version>
</PropertyGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp" Private="false" Publicize="true" />
<Reference Include="Unity.TextMeshPro" Private="false" />
<Reference Include="UnityEngine.UI" Private="false" />
<Reference Include="Unity.Addressables" Private="false" />
<Reference Include="Unity.ResourceManager" Private="false" />
<Reference Include="KSPLogging" Private="false" />
<Reference Include="BepInEx.ConfigurationManager" Private="false" Publicize="true">
<HintPath>..\ThirdParty\ConfigurationManager\ConfigurationManager.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<PackageReference Include="BepInEx.BaseLib" Version="5.4.21" Publicize="true"/>
<PackageReference Include="HarmonyX" Version="2.10.1"/>
<PackageReference Include="BepInEx.PluginInfoProps" Version="2.1.0" PrivateAssets="all"/>
<PackageReference Include="Microsoft.CodeAnalysis.CSharp" Version="4.5.0"/>
<PackageReference Include="Newtonsoft.Json" Version="12.0.1"/>
<PackageReference Include="UnityEngine.Modules" Version="2020.3.33"/>
<PackageReference Include="BepInEx.AssemblyPublicizer.MSBuild" Version="0.4.0" PrivateAssets="all"/>
</ItemGroup>
</Project>

does that even work without the lang version specified?
oh
Damnn
ooh nice
Someone should remake configmanager with UITK /hj
i just wanted to move the SpaceWarp version into it at first
since i wanted the patcher to have the same version
but... if i'm already here... might as well

also this file
which is why the HintPaths disappeared
it now just knows to look in external_dlls

you see enough nice projects and pick up a thing or two
there are so many overlapping/similar properties and files to set them etc

it gives me anxiety how little standardized it feels
in .NET
its kinda hard to find documentation too
yeah
there's https://learn.microsoft.com/en-us/dotnet/core/project-sdk/msbuild-props and https://learn.microsoft.com/en-us/visualstudio/msbuild/msbuild-reserved-and-well-known-properties?view=vs-2022 and https://learn.microsoft.com/en-us/visualstudio/msbuild/common-msbuild-project-properties?view=vs-2022
Learn about the MSBuild reserved and well-known properties, predefined properties that store information about the project file and the MSBuild binaries.
and that's just for properties, not even items

I head sleep now
I should too, I'm like 6 hours ahead of your time zone 
@wicked wyvern https://github.com/jan-bures/SpaceWarp/pull/1
looks cool
awesome, thanks
yeah yeah
just tested that UITK works even without the markup being loaded through a bundle
thats good right??
yep
YAY
WOO
5head
where is some of the uitk code?
i wanna read through some of it
uh oh
did SpaceWarp switch from referencing Unity dlls in 0.4 to using its nuget package in 1.0 by any chance
because that kinda broke my test project after I updated the SpaceWarp dependency
is there any way to force the project use the referenced .dlls instead of a dependency of a dependecy?
I can just stick with the 0.4 nuget package for testing purposes, since I don't use any 1.0 APIs anyway
but it complicates things just a little
nice, so all my methods seem to work fine for rendering
this is the method that creates that UI with just C#
<ui:UXML xmlns:ui="UnityEngine.UIElements" xmlns:uie="UnityEditor.UIElements"
xsi="http://www.w3.org/2001/XMLSchema-instance" engine="UnityEngine.UIElements" editor="UnityEditor.UIElements"
noNamespaceSchemaLocation="../UIElementsSchema/UIElements.xsd" editor-extension-mode="False">
<ui:VisualElement style="flex-grow: 1;">
<ui:Label text="This is a Label" display-tooltip-when-elided="true"/>
<ui:Button text="This is a Button" display-tooltip-when-elided="true" name="button"/>
<ui:Toggle label="Display the counter?" name="toggle"/>
<ui:TextField picking-mode="Ignore" label="Text Field" text="filler text" name="input-message" />
</ui:VisualElement>
</ui:UXML>
and this is the equivalent UXML
now that I know it's all working well, time for bed
and in the morning, I'm making waffles time to finish up the KSP2UITK library and then finally make some actual UI with it
🥳
it should just do that, i think
what dependency are you trying to fix
I'm referencing custom versions (the ones from the UITK package) of UnityEngine.UIElements.dll and a few other related assemblies
And when I add a nuget reference to Unity, they don't get picked up, UIDocument and other types can't be found and can't build
Same when I switched SpaceWarp nuget package from 0.4 to 1.0.1
And when I removed it, UITK stuff was working again
pin please
I just got into the org I'm not about to f around and find out 
Alright, really time to sleep now, the sun is up
Sorry I been away this whole week, got Covid 🤒
Aw that sucks, hope you're doing better
Starting to feel better now 😄
Damn that sucks, glad your feeling better
Damn ewy, I just looked at your curseforge page and that is impressive
😄 Thanks
I been doing Minecraft modding for way over 10 years now 😄
Here are some numbers
That is hella impressive
Thank you!
One of the main reasons I wanted to mod KSP2 is because I am kinda burned out on modding MC right now and wanted to try something else
Thats completely fair
But I also quickly found out that it was way more fun to work on Space Warp instead of my own mods 😛
Been doing java for 15 years now and I have not really got tired of it.
But I much more prefer C# over it
who wouldn't 👀
there are definitely worse languages than Java but that doesn't mean I like it tbh
I am mostly tired of the JVM itself
understandable
The lang itself it pretty nice.
Why does it actually exist
A Java Virtual Machine and Bytecode-to-IL Converter for .NET - GitHub - ikvm-revived/ikvm: A Java Virtual Machine and Bytecode-to-IL Converter for .NET
It's latest release was on february seventh
goddam

This is real nightmare fuel
Is it?
Nope it is
using java.util;
That is cursed
🤮
Should I add this to space warp so people can make java mods for KSP2?
For legal reasons thats a joke
Imagine you go to a github repository for a KSP2 mod and it's written in fucking Java
Nononono
import cli.System.IO.*;
public class ShowDir{
public static void main(String[] args){
String[] files = Directory.GetFiles(".");
for(String file : files){
System.out.println(file);
}
}
}
Kotlin plz
"Your scientists were so preoccupied with whether they could, they didn’t stop to think if they should."
I can't find much IKVM documentation
wtf
…

cf has a rewards program right? if you don't mind me asking, how many points do you normally get for download counts like that?
I know that nexus generally pays fairly little, but I've never gotten to ask anyone on curse
So around $0.50 per 1000 downloads ish
Ohh yes it definitely is just passive income at this point.
I just do general maintenance work like critical bug fixes etc
@sacred jasper how is it going with the GUI skin? I haven't been able to keep track of development recently
We've paused that on work of implementing a different UI framework into KSP2
#1085537097714245662
Something more modern than IMGUI but relatively easy to use
Yep
sweet
@wicked wyvern can confirm and/or give an example
Will be able to be helpful in ~an hour
Connection is almost nonexistent at this point in the train ride
Just got to my computer
had to first say hi to the ratties and doggo 
two at least, they need a companion 👀
keeping a single rat is cruel tbh
I think the same is true for all pets really
@sacred jasper we need donate button on github readme 
what
unless they hate each other
How would I split money and such?
You really need to come up with a well thought out thorough plan for that kind of thing
You want to remove as much possible abuse as you can to avoid bad feelings
Opencollective is built for that kind of thing
Yeah, if this were an individual project, I'd slap my kofi link in there and be done
but nope
it's okay you can just put my donation link and have that be the only one
that way everyone's happy
That looks interesting, but not necessary for this
We can go about without having donations and stuff lol
@wicked wyvern I was gonna add the open mods folder button, then I just realized its gonna be changed w/ UITK so
oh yeah, good call to just wait for that
honestly all my next plans are dependent on it
by lines of code written 
I'm not elon musk
@timber cedar getting called out
look in #🟣space-warp-dev
xd
Also someone (Sinon) removed all the braces from all the if and foreach statements. This just ends up looking like shit. This is not python. We have braces for a reason. 😅 So I added them all back.
THANK YOU @mossy kraken
:D
😄
braces < indentation
Did you see my comment about not liking my programming language then @mossy kraken lol
if the language is designed around it then sure
but not in C-like syntax languages ffs

I did 😄
But if it is its own language I prob like it.
I like python. But I can't mix python and C#. I need my own style for both of em
So I don't like mixing the two
balance in all things
Its either all indents or all braces
what indentation, you can just do
if (true)
doSomething();
that's just nasty
Don't look at the thunderkit code base
One line if statement 🤩
i write in apple basic so idk
if true then doSomething()
or
if true
doSomething
we should just make spacewarp a one liner
or
if true
{
doSomething()
doSomethingElse()
}
bottom one is best
verbose and readable > minimalistic

Too hard to read the title right?
maybe yeah
Whitespace is an esoteric programming language developed by Edwin Brady and Chris Morris at the University of Durham (also developers of the Kaya and Idris programming languages). It was released on 1 April 2003 (April Fool's Day). Its name is a reference to whitespace characters. Unlike most programming languages, which ignore or assign little ...
not that difficult to find 
Should add a whitespace interface to space warp
yes
Or a white space implementation of CIL
white space os
Shakespeare first pls
I had some other stuff to do but I'm here now
it's nowhere near finished so nope
https://github.com/jan-bures/KSP2UITK but you can get the lib here
I'm not adding a release for now (and the two pre-releases don't work fully), I want to finish making an API first
but you can download and compile the stuff in master
and it will work

oh damn, I've never actually been in Austria, other than passing through it
even though it's one of our neighboring countries
weird
skiing is 😎 there
i think you biker
you should go mountain biking
in austria
I don't speak freedom units
when I'm done with all this UI stuff, the next thing I want to do it add more templates to the SpaceWarp.Template package
so far it only has one with some basic examples of doing stuff like IMGUI, app bar buttons, using SW's API extensions, etc
I'd like to have at least three
empty project, basic project (the current one), part mod project
sounds good
oh I forgot to mention
I pushed my testing UITK mod to GitHub just for you 😛
is still waiting for UITK stuff
For space warp specifically
sorry, I've been spending the evening with mod channels shenanigans, I'll start working on it right away
#1088988819266740224 message



