Jump to content

micjck2

Members
  • Posts

    1
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

micjck2's Achievements

Poring

Poring (1/15)

0

Reputation

  1. string folder = "C:/Users/medakas/data/sprite/¸ó½ºÅÍ/"; // Your folder that contains the .act files DirectoryInfo d = new DirectoryInfo(folder); // Loading the folder foreach (var file in d.GetFiles("*.act")) { // Iterate each of the files Act act1 = new Act(file.FullName); // Loading the file as an Act data type act1.AnimationExecute(4, action => {action.Frames = new List<Frame> { new Frame() };}); // Removing the 4th layer/Dying Frames Animation act1.Save(act1.LoadedPath); // Saving The Edited/Transform act } I am trying to remove the dying animation of monsters of .act files. It works properly if I execute the script of the current open .act file -> means open an act file then run the script runner act.AnimationExecute(4, action => { action.Frames = new List<Frame> { new Frame() }; }); Script Runner have a built in "act" variable which refers to the currently open windows in Act Editor. This works just fine but it is troublesome. ----------------------------------------- In the first code block above, This remove the dying animation of the act files just fine, but the translate or position of the sprite got chaotic e.g. sometimes mobs are flying, sometimes in the ground, sometimes their body is in half. The possible solution in my mind would be a proper loading of an Act File using the script runner which includes: frames, layers, and actions, retaining their original just altering 1 part. Any tips on implementing a script to all of the act files which does not reset the layers positions and any other settings.
×
×
  • Create New...