(SOLVED!) Replacing Sprites from Sourcefile - Alter Sourcefile Path?

Started by Ali, Mon 04/03/2013 10:31:35

Previous topic - Next topic

Ali

I know this issue has come up many times before... but as I start to update animations for Nelly 2, I'm reminded of what a ridiculous waste of time it is to manually replace hundreds of frames of animation over and over again. (I seem to remember it was a major factor in pushing Theo away from AGS towards a custom engine for The Journey Down, so it is a big issue).

Can anyone suggest something I can do to make it more efficient? Is there a way to create an editor plugin which acts like an action in photoshop and repeats the reloading process for a selection of sprites?

I'm afraid I don't have the programming knowledge to just deal with this myself, but I would like to help if someone could suggest a possible solution?

Demicrusaius

For 300 sprites per character it should take only 40 minutes or so to replace them all. It doesn't seem too bad considering the tedium of some of the stuff we do. But if you know what views you need, maybe it would be better to quick import all of the sprites into a new folder, rebuild the views and then delete all the old sprites without having to replace them one at a time?
It is better to light one small candle than to curse the darkness.

Calin Leafshade

I actually raised a feature request in the tracker for this a few months ago.

It should be relatively easy to implement, i just haven't gotten around to it yet.

Crimson Wizard

#3
Quote from: Demicrusaius on Mon 04/03/2013 10:54:56
For 300 sprites per character it should take only 40 minutes or so to replace them all.
Or have a feature that does the same in 30 seconds.  :angry:
BTW, it is usually not the required time, but the tedious routine that stops people from doing things like that.

People invented computers for doing boring work for them. And here we have an example when people must do boring work for computer...

Ali

Hey Calin, what can I say to make you get round to it sooner? I must say, King Cat is looking awfully dignified today.

Quote from: Demicrusaius on Mon 04/03/2013 10:54:56
For 300 sprites per character it should take only 40 minutes or so to replace them all.

I'm surprised you think 40 minutes is a reasonable amount of time to spend on something that should happen automatically! Bear in mind that when rendering sprites rather than drawing them, you often want to test out small changes, with the possibility of changing your mind. Spending an hour trying out a slightly different walk cycle is not very efficient!

EDIT: Crimson Wizard said it better than I did!

Snarky

Hear hear!

The sane way would be to just use the file system, so that you could update a series of sprites just by overwriting the files.

Calin Leafshade

That would require checking all the files every build for changes which might be problematic on a large project.

I will make an explicit option for now and the design team will have to consider the possibility of using the file system ala wintermute over the sprite cache currently used.

Ali

Does that mean this is something you might be able to implement in the not-too-distant future? I will make a paper crown and post it to you...

Crimson Wizard

BTW, Calin, what version will you work in?
I keep worrying about AGS releases; there's 3.2.1, there's 3.2.2 prepared by tzachs, which was never officially released, only posted as beta; there's Draconian edition, and God knows how many other personal hacks; there's the github repo we've marked as 3.3.0 already (for Gemini Rue release on Linux)... we need to start cleaning things up, the sooner the better.

Calin Leafshade

#9
https://dl.dropbox.com/u/27247158/AGSWithReloadFromSource.zip

Give that a try.

As with other automated imports it uses the same transparency options as the previous import (top-left pixel and all that) and always uses an alpha channel if one is available and the game is 32bit.

This was compiled from the git version but the changes are very modest and could be dropped straight into the stable version.

Crimson Wizard

Quote from: Calin Leafshade on Mon 04/03/2013 12:56:51
This was compiled from the git version.
o_0.
If it is what I think it is, you better make a backup of your project before using that. :P
Well, not implying anything, but just in case.

Calin Leafshade

The editor itself received very few changes from the svn version.

But just to be sure I will patch the changes into the svn version for a more stable solution.

Crimson Wizard

#12
Quote from: Calin Leafshade on Mon 04/03/2013 13:01:41
The editor itself received very few changes from the svn version.
Editor - yes, but AGS.Native (which shares quite some code with engine)............

On other hand, we could use Ali as beta tester in exchange of our services :D.

Calin Leafshade

The acwin and ags.native (since i couldnt get ags.native to build) files are the 3.2.1 stock files so that shouldn't be an issue.

Crimson Wizard

#14
Quote from: Calin Leafshade on Mon 04/03/2013 13:06:17
The acwin and ags.native (since i couldnt get ags.native to build) files are the 3.2.1 stock files so that shouldn't be an issue.
Ah, it should be ok then, I think. The git version is made of tzach's version with very small fix to make AGS.Native compile with it.
But why cannot you build Ags.Native? Is there any error, or you don't have full MSVS version?
BTW, for that reason I am now commiting compiled library to Editor/References.

Calin Leafshade

I got a linking error

    error LNK2001: unresolved external symbol __forceCRTManifestCUR


I assume it's a problem with library versions being used or something.

I am using Visual Studio 2008 professional.

Crimson Wizard

I tested import, it works! but it has an annoying incapability to continue updating multiple sprites if at least one sprite without source file was met. It just shows error and stops. I think it should be able to proceed with operation.

Calin Leafshade

I agree but I'll need to implement some kind of custom dialog box for that which i will do at a later date.

This version will likely do what Ali requires for the moment.

Ali

Yes! It seems to work! Thanks for the quick response guys.

However I'm a little frightened by the beta warnings and the fact that, once saved, this project won't work in the stable version I normally use.

Excuse my ignorance of Gits and SVNs... but would I be unwise to continue developing a project I don't want to risk in this version of the editor?



Calin Leafshade

#19
That version of the editor would probably be fine but for your peace of mind I have made one using the old svn version.

https://dl.dropbox.com/u/27247158/AGS3.2.1WithSpriteReload.zip

This is basically identical to the one you currently use with the reload from source thing added and so there is no risk to your project.

SMF spam blocked by CleanTalk