Giter Site home page Giter Site logo

crauzer / lol2gltf Goto Github PK

View Code? Open in Web Editor NEW
123.0 8.0 20.0 8.99 MB

Convert between League of Legends mesh formats and the glTF runtime format

License: GNU General Public License v3.0

C# 54.68% HTML 35.39% CSS 3.85% Batchfile 0.23% PowerShell 3.30% Shell 2.54%
gltf leagueoflegends

lol2gltf's Introduction

Metrics

lol2gltf's People

Contributors

coman3 avatar crauzer avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lol2gltf's Issues

Converting a previously modded skn into gtfl returns an error.

I'm trying to edit an already modded file, but whenever I try to convert it, it returns with the following error:

Error: System.NotFiniteNumberException: value at SharpGLTF.Memory.FloatingAccessor.set_Item(Int32 rowIndex, Int32 subIndex, Single value) at LeagueToolkit.IO.Extensions.Utils.GltfUtils.SanitizeVertexNormalMemoryAccessor(MemoryAccessor[] memoryAccessors) at LeagueToolkit.IO.SimpleSkinFile.SimpleSkinGltfExtensions.CreateGltfMesh(ModelRoot root, SkinnedMesh skinnedMesh, Byte[] influenceLookup, IReadOnlyDictionary2 materials) at LeagueToolkit.IO.SimpleSkinFile.SimpleSkinGltfExtensions.ToGltf(SkinnedMesh skinnedMesh, IEnumerable1 textures) at lol2gltf.Pages.SkinnedMesh.ConvertToGltf(String gltfPath) in D:\a\lol2gltf\lol2gltf\lol2gltf\Pages\SkinnedMesh.razor:line 335 at lol2gltf.Pages.SkinnedMesh.Submit() in D:\a\lol2gltf\lol2gltf\lol2gltf\Pages\SkinnedMesh.razor:line 304

I can convert other skn files normally, so the program IS working.

Skn & skl without animations

i'm using lol2gltf cli but it's forcing me to add animations folder while i just need a rigged body like Obsidian do
$ lol2gltf skn2gltf-rigged -s skin.skl -m skin.skn -o skin.glb
no need to add --animations

Broken animations

I successfully exported the Renekton skin, but now there are issues with some of the animations when I imported them into blender. Someting i've noticed is that they are the same animations that also used to crash version 2.0.0 when being loaded in the UI verison #11 before it was fixed in 3.0.0 beta 4.

the "attack_1" animation works completely fine.
renecbug3

the "idle_1" animation looks... interesting
renecbug4

SKL and ANM conversion without SKN?

Good day.
I have SKL and ANM files, they are from a different game (Telltale games), but they might be similar to the files used by lol2, as they use both SKL for skeleton and ANM for animation.

The game does not use SKN files though.

Here are some example files: https://drive.google.com/file/d/1dcJN3m26HvVDyZIrbmR0RaQZRe4gWIDJ/view?usp=sharing

Of course, if these are not similar to the lol2 format, there is no point in even trying to do anything with them, but if they are, is it possible to attempt to do the conversion without the mesh (SKN) file?

Make animation naming better?

for eg adding the animation files teemo_skin18_attack1.anm, makes the animation name within the model the same as the file name aka "teemo_skin18_attack1.anm" kind of annoying.
could this be fixed? for eg only name it from "teemo_skin18_attack1.anm" to ---> "attack1" . pretty simple string.Replace()

Command-line API process hangs after finishing

I tried running the following command from my windows git-bash terminal:

./lol2gltf.exe skn2gltf-rigged --skn "assets\characters\aatrox\skins\base\aatrox.skn" --skeleton "assets\characters\aatrox\skins\base\aatrox.skl" -o aatrox.gltf --material-textures "Body:assets\characters\aatrox\skins\base\aatrox_base_tx_cm.dds" "Wings:assets\characters\aatrox\skins\base\2x_aatrox_wings_tx_cm.dds" "Sword:assets\characters\aatrox\skins\base\2x_aatrox_base_sword_tx_cm.dds" --animations-folder "assets\characters\aatrox\skins\base\animations"

output:

Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_channel_windup
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ground_q1_to_unsheathrun
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_sheath_run01
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_skin01_recall
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_spell3_dash_to_walk
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_spell3_ult
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_spell4
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_stunned
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_towerattack
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_attack1
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_attack2
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_idle
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_idlein
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_into
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_out
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_out_to_passive_idle
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_q1
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_q2
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_q3
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_run
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_spell_dash
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_spell_dash_to_run
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_taunt
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_taunt_loop
Warning: Found an animation that's potentially not compatible with the provided skeleton - aatrox_ult_towera

Afterward, the program just hangs there, and nothing comes out, neither are there any raised exceptions. How should I be using this instead?

EDIT: just realized it is outputting a file. But the process still just hangs aftwerwards. Ideally, I'd like to call this process over and over again many times.

Some characters wont convert

Tried converting Veigar base and tried curling Veigar but after converting nothing would show up in the directed files. Didn't include any animations during conversion. Any help is appreciated thank you

3.0.0 crashing when trying to export with .skl

I was trying to export a skin with the UI version of 3.0.0 beta 5, but it keeps crashing if I export with .skl.
Note: I have tested this on multiple skins and it only happens on some of them.

renecbug

Kog Maw Skin 37

Error: System.NotSupportedException: Reading legacy animations is not supported at CommunityToolkit.Diagnostics.ThrowHelper.ThrowNotSupportedException(String message) at LeagueToolkit.Core.Animation.UncompressedAnimationAsset.ReadLegacy(BinaryReader br) at LeagueToolkit.Core.Animation.UncompressedAnimationAsset..ctor(Stream stream) at LeagueToolkit.Core.Animation.AnimationAsset.Load(Stream stream) at lol2gltf.Pages.SkinnedMesh.AddAnimations(IEnumerable`1 animationFiles) in D:\a\lol2gltf\lol2gltf\lol2gltf\Pages\SkinnedMesh.razor:line 275 at lol2gltf.Pages.SkinnedMesh.AddAnimations() in D:\a\lol2gltf\lol2gltf\lol2gltf\Pages\SkinnedMesh.razor:line 261

How to extract map geo

I'm using the 3.0.2 version of lol2gltf, how do I exctract map geo files? I can only exctract champions models

Can't convert Nami base skin

I have used Obsidian to extract Nami's base skin and tried to convert it to glTF but it failed with some long. I then tried the older version, 2.0.1, and it worked.
image(14)

Lol2GltfGUI unable to load/convert certain Rengar animations.

Upon attempting to load the specific animations "Rengar_attack4.anm, Rengar_spell2.anm, Rengar_channel.anm", the GUI version of Lol2Gltf appears to crash. Closing almost instantly after one of these files are loaded alongside the skl and skn files in the application.
Oddly enough, I have managed to convert the entirety of Aurelion Sol's mesh and animations with very little issue. So this came as a surprise.

I then attempted to use the non-GUI version of Lol2gltf in an attempt to circumvent this issue. However, still able to convert the other files, the non-GUI version appeared to throw out this error message and producing no results. (See attached)
cmd_pik8L7JlGA

I am somewhat unsure if I have made a mistake somewhere or if these particular animations appear to be janky with the current version of the program, albiet this appears to occur on previous versions as well. I am also unsure if this is specific to Rengar or can occur on other potential models. Please let me know if there is a potential workaround or if this will be in the works for being fixed.

Lots of Legacy Animation Errors

On a bunch of different heroes (e.g. Amumu, Rammus, and some others) I get this error when trying to import the animations:

Error: System.NotSupportedException: Reading legacy animations is not supported at CommunityToolkit.Diagnostics.ThrowHelper.ThrowNotSupportedException(String message) at LeagueToolkit.Core.Animation.UncompressedAnimationAsset.ReadLegacy(BinaryReader br) at LeagueToolkit.Core.Animation.UncompressedAnimationAsset..ctor(Stream stream) at LeagueToolkit.Core.Animation.AnimationAsset.Load(Stream stream) at lol2gltf.Pages.SkinnedMesh.AddAnimations(IEnumerable`1 animationFiles) in D:\a\lol2gltf\lol2gltf\lol2gltf\Pages\SkinnedMesh.razor:line 275 at lol2gltf.Pages.SkinnedMesh.AddAnimations() in D:\a\lol2gltf\lol2gltf\lol2gltf\Pages\SkinnedMesh.razor:line 261

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.