News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu
avatar_lachlank

Retro Game Asset Studio BETA

Started by lachlank, 03:12, 05 May 12

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

lachlank

Hello all, with some renewed interest in all things retro programming, I decided to revisit my cross-platform sprite editor Amsprite, and add some features and do some refactoring.


My long term goal is to create a general purpose tool, that can target any combination of retro platform (CPC, Spectrum, C64 etc) and language (assembler, basic, C etc) for creation of sprites, tile bitmaps, loading screens, sfx, music and tilemaps. Ideally the tool will be 100% .Net managed code so that it is portable across all platforms (via MONO). I have got this somewhat up and running enough to demo a beta here. At present it doesn't do much more than Amsprite used to, although I have tested it with C64 sprites and output. I have rebranded as Retro Game Asset Studio to reflect the fact that is it target-platform agnostic, and not just a sprite editor.

Here is what I have added over and above the last version of Amsprite:

       
  • Support for compiled sprite output (as per CPCWiki article algorithm)
  • Support for transparency mask bytes inline with sprite data
  • Support for outputting "align 256" directive before sprite data
  • Support for drawing lines/ellipses
  • Support for simultaneously editing multiple sprites in a grid
  • Support for "onion skinning" other sprites
  • Support for zooming editor via Ctrl + Mouse wheel
There is obviously a lot more work to do to make it complete, sound emulation and tracking is currently rudimentary and for the CPC only. I have only just made a start outputting c64 sprites, these are quite different to CPC.

Anybody out there care to test it out and offer any early feedback? Or any proficient .Net devs interested in helping?


You'll need .Net 3.5 installed to run it. [attachurl=1]

Lachlan

ervin

Intriguing!

I'll be taking a look at this shortly!
:)

Executioner

Is .NOT still alive?

lachlank

Quote from: Executioner on 01:47, 06 May 12
Is .NOT still alive?


.NOT? Am I missing something here?

arnoldemu

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Devilmarkus

This is .NOT .NETT!
When you put your ear on a hot stove, you can smell how stupid you are ...

Amstrad CPC games in your webbrowser

JavaCPC Desktop Full Release

Executioner

I just didn't realise anyone was still using .NET seriously. I installed Visual Studio Express 2010 and it took me until last month to get my Windows 7 laptop stable again. It still hangs for minutes at a time occassionally. Sworn off Microsoft a looooong time ago, hence .NOT.

lachlank

The .Net languages are awesome (C# and VB.Net), once you get used to them with LINQ (Language Integrated Query), generics, anonymous classes/functions etc it would be very hard to go back to any other language. Also, the base class library is massive and covers virtually anything you could want to do (this is of course a blessing and a curse). Yes, they come with a lot of baggage from MS, and yes Visual Studio (in its many guises) can be unstable and bloated.


However in terms of sheer power and what you can do in a small(ish) amount of code, I think they can't be touched. I may be biased in that I have been using them for a while now at my day job, but I have programmed in a LOT of programming languages over the last 25 years, and these are by far the best IMHO.


As far as usage, you only have to look at IT job ads to see the demand for .Net developers.


I am by no means an MS fanboi, but the languages themselves are very well designed. You don't even need MS, with the MONO implementation.


Sales pitch over. Haters gonna hate.




Bryce

I prefer QT :)

Bryce.

arnoldemu

Quote from: Executioner on 10:19, 08 May 12
I just didn't realise anyone was still using .NET seriously. I installed Visual Studio Express 2010 and it took me until last month to get my Windows 7 laptop stable again. It still hangs for minutes at a time occassionally. Sworn off Microsoft a looooong time ago, hence .NOT.
there are various things you can do to make it better, often involving turning things off and installing all it's service packs.

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Gryzor

[grammar]
*its*
[/heil]

Executioner

Quote from: lachlank on 11:47, 08 May 12
The .Net languages are awesome (C# and VB.Net)

Not so sure about VB. I've used the old versions a lot and was quite unimpressed with the language itself, but C# is a different story. It was developed by the same guy who did Delphi, and is basically a copy of Java with a few slight changes, and I have to agree it is a very good language and introduced a bit of new functionality, most of which is now available in newer versions of Java.

Quote
As far as usage, you only have to look at IT job ads to see the demand for .Net developers.

I think you get quite a different picture depending on where you look. 90% of the financial industry has completely dropped .NET and Microsoft now. Stupid little things like not having an accurate clock don't do much to help the MS case. In Australia and NZ there is still a lot of Love for Microsoft. I've even heard people consider buying a Windows phone.

Heck, most of the problems I run into developing WinAPE are down to the Windows API, and I've spent countless hours trying to get around bugs in it. MS support amounts to basically nothing unless you're a big company with a huge support contract.

Quote
Sales pitch over. Haters gonna hate.

As I said earlier, I actually do like C#. VB is totally another matter and can be blamed for most of the crap so-called developers in the world. Thing is I can't justify paying Microsoft big money for their support or for their development platforms only to be stuck half the time trying to work around shortcomings in their proprietary code for which I don't have the source code. Z80 assembler appeals to me more, I wish I could do all my development using it.

lachlank

Quote from: Executioner on 23:28, 08 May 12
Not so sure about VB. I've used the old versions a lot and was quite unimpressed with the language itself, but C# is a different story. It was developed by the same guy who did Delphi, and is basically a copy of Java with a few slight changes, and I have to agree it is a very good language and introduced a bit of new functionality, most of which is now available in newer versions of Java.


There is a lot of misinformation out there about VB; it is perceived as worse than c#, which is not the case. The two languages as they now exist are functionally identical, in fact many tools exist which perform a trivial line-for-line transformation from one to the other. I use VB at work, and often use c# at home just to stay current in both, there really is no difference. The VB.Net of today (version 10) really bears very little resemblance to old VB (say, VB6). I have (unsuccessfully) lobbied MS to consolidate the two languages by making keywords etc interchangeable, or else dropping one or the other (VB presumably would be dropped as less common). Maintaining two near-identical languages seems stupid to me. But that is an example of the strange decisions MS makes.
Quote from: Executioner on 23:28, 08 May 12

Heck, most of the problems I run into developing WinAPE are down to the Windows API, and I've spent countless hours trying to get around bugs in it. MS support amounts to basically nothing unless you're a big company with a huge support contract.


You won't get any argument from me re. the Windows API, so much legacy junk in there. .Net abstracts a lot of it away, but as so much of it is a layer over win32 APIs there are a ton of queer little quirks.

Quote from: Executioner on 23:28, 08 May 12
As I said earlier, I actually do like C#. VB is totally another matter and can be blamed for most of the crap so-called developers in the world. Thing is I can't justify paying Microsoft big money for their support or for their development platforms only to be stuck half the time trying to work around shortcomings in their proprietary code for which I don't have the source code. Z80 assembler appeals to me more, I wish I could do all my development using it.


Things have changed... As I said, VB.net is no longer the red-headed step child (although that perception still remains, sadly). You can now step through the MS (reference) source for the .Net libraries in the Visual Studio debugger, which is a godsend. The Express versions of Visual Studio are free, and contain most features the average developer would need. The pro version has no registration or activation required if you are of the unscrupulous persuasion.


Also, I don't think you can blame a language for creating bad programmers... Ignorant programmers, perhaps. Most programmers I have worked with have no idea about what is going on in the background of their programs in terms of memory, pointers, etc, having grown up in an era when the compiler/runtime takes care of all this. I constantly see errors because programmers don't realise they are dealing with pointer variables, all modern languages "hide" this from you - c#, Java, etc.


I enjoy dabbling in z80 for the challenge, and ,as you say, if there is a bug I know it is mine (or WinAPEs? ;)). But to get work done fast you can't beat the modern languages/IDEs.


PS I will gladly disown MS if you just add Undo to the WinAPE assembler!


Lachlan


endangermice

#13
I'm actively using C# at work and have been doing for the past eight years. It is a very good language but since I do multimedia I do spend a lot of time dropping into C++ which does give me a lot of control over the system that C# can't touch all that well and for Film and TV performance is critical!

I have to agree with Executioner there are a lot of problems with the Windows API and various bugs which simply aren't going to be fixed - you should see the code we've had to kludge together in order to allow our video player to refresh the screen properly - its a right mess in there and I really hate messy code but there's nothing we can do because of some fundamental problems with certain elements of the Windows API.

Having experienced WPF recently I can honestly say I wish Microsoft hadn't bothered. I think it's an extremely complicated, klugdy platform with virtually no error checking causing you to frequently spend hours trying to figure out why something simply isn't working, you can't even debug the terrible XAML code which leads to enormous frustration. We've completely abandoned it as a presentation platform and have gone back to Windows Forms which doesn't quite have the same performance but is a far more elegant solution. QT is a platform I'd love to use but that would constitute a complete UI rewrite of what is an Incredibly complex video encoding and delivery automation system and in a fast paced environment, regrettably - we simply don't have the time.

.Net is a really good platform and when it's teamed up with C++ - together they extremely flexible. Visual Basic is indeed functionally identical to C# but I feel it's a very messy language and lacks the elegance C# which encourages much better program structure. It also has limited interopability with C++ and the languages are fundamentally different in suntax making it far harder to switch between the two. To be honest if I were Microsoft I'd dump VB altogether and get people of learn C# it's really not that hard and it will make them better programmers.

Having said that I'm loving getting back into Z80 asm it's a much simpler world where I don't constantly have to think about making every bit of code completely dynamic and reusable. In assembly land it's all about optimisation and I find the challenge difficult but genuinely rewarding! It also causes you to think about how low level data manipulation might be able to help you in higher languages. C++ and C# are both perfectly capable of activities such as bit shifting which can be extremely useful at times!
For all the latest Starquake remake news check out my website - www.endangermice.co.uk

endangermice

#14
Hey I've just been checking out AMSprite and I have to say it's absolutely superb. I was writing some of my own tools to save out sprite data etc. but this seems to do the trick beautifully! It does have a few bugs, mostly to do with the level data which for me seems to be corrupting itself! I'm going to test out Asset Studio BETA and see how it's doing.

If you need any help with the coding etc. I'd be happy to lend a hand. Unlike my rudimentary Z80 skills, I have 8 years experience in .Net, and have been using it since version 1.1 so  if you ever need any help to develop this I'm sure I could offer some assistance here and there!


Update.... Just tested Retro Game Asset Studio and it looks like all the bugs I found in AmSprite have been fixed - great work!
For all the latest Starquake remake news check out my website - www.endangermice.co.uk

Sykobee (Briggsy)

This looks like a good tool, will be checking it out soon. Good luck with your plans :-)

endangermice

#16
Hey I'm afraid I've found a bug when saving out a previously loaded project. The exact exception is: Value cannot be null, and here's the stack (shortened):

System.ArgumentNullException: Value cannot be null.
   at System.Threading.Monitor.Enter(Object obj)
   at RGAS.SpriteSet.get_formatter()
   at RGAS.SpriteSet.get__formatterTypeString()
   at WriteSpriteSetToXml(XmlWriterDelegator , Object , XmlObjectSerializerWriteContext , ClassDataContract )
   at System.Runtime.Serialization.ClassDataContract.WriteXmlValue(XmlWriterDelegator xmlWriter, Object obj, XmlObjectSerializerWriteContext context)
   at System.Runtime.Serialization.XmlObjectSerializerWriteContext.WriteDataContractValue(DataContract dataContract, XmlWriterDelegator xmlWriter, Object obj, RuntimeTypeHandle declaredTypeHandle)
   at System.Runtime.Serialization.XmlObjectSerializerWriteContext.SerializeWithoutXsiType(DataContract dataContract, XmlWriterDelegator xmlWriter, Object obj, RuntimeTypeHandle declaredTypeHandle)
   at System.Runtime.Serialization.DataContractSerializer.InternalWriteObjectContent(XmlWriterDelegator writer, Object graph)
   at System.Runtime.Serialization.DataContractSerializer.InternalWriteObject(XmlWriterDelegator writer, Object graph)
   at System.Runtime.Serialization.XmlObjectSerializer.WriteObjectHandleExceptions(XmlWriterDelegator writer, Object graph)
   at System.Runtime.Serialization.DataContractSerializer.WriteObject(XmlWriter writer, Object graph)
   at RGAS.SpriteSet.toXML()

It looks like a problem with your serialisation code possibly within the WriteSpriteSetToXML method. I notice you've threaded the routine, so it could be a syncronisation issue though without seeing the code I can't really say. 

I've attached the project I was working on, hope this helps - it's a shame I've been finding this utility extremely useful already :)

Cheers,

Damien.
For all the latest Starquake remake news check out my website - www.endangermice.co.uk

lachlank

Quote from: endangermice on 19:33, 10 July 12
Hey I'm afraid I've found a bug when saving out a previously loaded project. The exact exception is: Value cannot be null, and here's the stack (shortened):

I've attached the project I was working on, hope this helps - it's a shame I've been finding this utility extremely useful already :)

Cheers,

Damien.


Hi, thanks for the positive feedback. That's a bummer that you had this error, unfortunately I can't easily see what caused it as the project has changed quite a bit since I uploaded the original RGAS beta that you used to create this file. I would have to drag this old version from source control to debug it.


I've attached the latest version for you to try, this is near to complete as far as functionality is concerned, just needs more testing. It should load and save OK (has for me, anyway). The loading/saving is a bit of a pig as I have been lazy and just used the in-built XML serialization of classes; it can be quite fussy. The downside is that if I change class names or hierarchy, it will break the "file format". Hence you won't be able to load your file into this version. Also I dabbled with changing the name to "8-bit Asset Studio" so the file extension is currently .8bas. I'll probably change that back again to .rgas.


There is now basic support for editing Spectrum and C64 sprites, which works OK (not that I know much about these platforms, I just implemented based on what info I could find on the web). Spectrum is pretty simple, C64 on the other hand has a bunch of mind-bending "modes". It should be easy to add other platforms now as I have refactored everything to the point where you just need to override a few key methods.


There is also now support for sprite rotation (which I am not happy with yet, as far as interpolation) and image importing is now much better (with various dithering options).


If you want a copy of the source to play with (or for if you get more errors), send me an email lachlankeown at gmail and I'll add you to source control (is hosted at xp-dev.com SVN repository). Is all in VB.Net but as you rightly pointed out in an earlier post if you can write c# then you can write vb (I agree that MS should drop one or the other). If you have 8 years experience with .Net you will have no trouble reading the code. I also cut my teeth with .Net 1.1, what a horrible experience that was in hindsight (no generics, LINQ, anon functions etc).


I have yet more plans for RGAS, when time allows. For instance, I would like a scrolling level editor, and would also like to develop the tracker/sfx module. I built a crude tracker into Amsprite (which was actually a hell of a lot of work to make in purely managed code), but it needs finishing. Not sure how much work it would be to include a C64 version. If you are interested in helping with these or any other features I am more than happy.


Basically I want a one-stop-shop for anyone who wakes up one day thinking "I want to create a home brew game for an 8 bit computer". At the moment it is a nightmare starting out, with all the individual tools floating around. I would also like to add something like a sample code repository to RGAS. Also useful would be a "compile" button that generates an example program with your sprites, compiles it, and launches with an appropriate emulator. That would be cool.


Anyway try this latest version and see how it goes. Just remember, the file format may not be set in stone (but 99% sure it should be).


Cheers


Lachlan


[attachurl=2]

endangermice

#18
Hey no worries - I suspect you've fixed the bug in a later version, no need to go back and debug the old one - if it still persists in the latest version then it will be easy enough to track down.


.Net has definitely moved on in a big way since 1.1. I love the generics, for one it allowed us to dispose of that terrible ArrayList and have C++ style templating (well almost!)! I'm not as keen on Linq - it does make all sorts of queries very easy but.... I have found that in some instances it can create horrendous memory leaks and can be quite a bit slower that say for example a standard for loop. Having said that, the software we write is basically a server farm for video encoding and delivery which literally produces thousands of objects every minute so does tend to push these new technologies very hard!


VB.Net is something I have come across from time to time so I'm sure I'll be able to adjust to it easily enough - the .Net languages do have a lot in common - well a unified library for one so converting between languages isn't usually that hard and I could always write some dlls in C# for you - you're code wouldn't know the difference - the beauty of .net!


I did write a game in VB6 with a mate just for kicks a few years ago - so I suspect the structure will be familiar. We had to write some very interesting interop routines for DirectX8 which was quite a challenge as I remember - but we got it all working - I think I still have the source somewhere....


I'd love to take a look at the source - will PM you and provide you with details. I can't promise how much time I can spend unfortunately since I have a pretty hectic schedule (including having to finish the remake below very soon!) but if i can help - I will. I'm very good on level editors having written several in the past, one most recently for my upcoming XNA remake of Starquake (which is based on the CPC original) - if anyone's interested I may post a demo, once my blog is up. For now some videos of the current WIP courtesy of YouTube (I know shameless plug ;) )  - the video is a bit jerky (I blame the recording software!), the real thing is smooth as silk - I guarantee. Being a video guy everything have to be in smooth sync! I do have to say I absolutely love the idea of your project, a tool like this would have been amazing back in the day, but even now I think it's something I will find invaluable!



Starquake Remake Clip 1 (01/08/2011)

Starquake Remake Clip 2 (02/08/2011)

Starquake Remake Clip 3 (02/08/2011)

Starquake Remake Clip 4 (03/08/2011)

Starquake Remake Clip 5 (04/08/2011)
For all the latest Starquake remake news check out my website - www.endangermice.co.uk

lachlank

Quote from: endangermice on 23:21, 10 July 12
I'd love to take a look at the source - will PM you and provide you with details. I can't promise how much time I can spend unfortunately since I have a pretty hectic schedule (including having to finish the remake below very soon!) but if i can help - I will. I'm very good on level editors having written several in the past, one most recently for my upcoming XNA remake of Starquake (which is based on the CPC original) - if anyone's interested I may post a demo, once my blog is up. For now some videos of the current WIP courtesy of YouTube (I know shameless plug ;) )  - the video is a bit jerky (I blame the recording software!), the real thing is smooth as silk - I guarantee. Being a video guy everything have to be in smooth sync! I do have to say I absolutely love the idea of your project, a tool like this would have been amazing back in the day, but even now I think it's something I will find invaluable!


Starquake remake looks very nice - whoever did the graphics did a great job. Used to like this game back in the day, although I never had the patience to get far into it.


Unfortunately I don't have much time to devote to this project either, having 2 young boys and various other projects on the go also. Plus, being a labour of love, I don't expect to ever see any financial reward. It would be great to have the time to muck around with z80 programming and building tools like this all day.


Quote from: endangermice on 00:13, 07 July 12
Having experienced WPF recently I can honestly say I wish Microsoft hadn't bothered. I think it's an extremely complicated, klugdy platform with virtually no error checking causing you to frequently spend hours trying to figure out why something simply isn't working, you can't even debug the terrible XAML code which leads to enormous frustration. We've completely abandoned it as a presentation platform and have gone back to Windows Forms which doesn't quite have the same performance but is a far more elegant solution.


Couldn't agree more. I've tried to get into WPF, but just can't. Was starting to think I was a bit thick, but now just think it is really poorly designed. As you say, debugging XAML is nigh on impossible. Examples for doing anything outside the most basic are non-existent. At work, we looked into rewriting a Windows Forms control in WPF, but in the end it was just too hard, so we accept the performance hit of using GDI+. Luckily as CPUs improve they have made GDI+ look better and better! I actually enjoy using Windows Forms (now that I know its quirks) and wish MS had just updated it with better controls and a hardware accelerated backend. Now we have Metro for Windows 8 which is just more WPF/Silverlight/XAML type garbage. N00b developers seem to love this stuff for some reason that I can't understand.


I managed to write a WPF frontend for my MAME arcade cabinet which is about the biggest project I would attempt with WPF. For small apps like this it seems to work well, although is mainly just an exercise in trial and error as the documentation and intellisense is so crap.


Anyway that's enough ranting about MS. Send me your details and I will add you to source control so you can have a look.


Lachlan

endangermice


Excellent - it sounds like we're both comming from similar angles - I don't have any children yet, but I suspect that will change in the not too distant future! Right now I'm kept busy with my multimedia development day job as well as running a growing photography company and a web design company too!

I'm off to Prague for a few days tomorrow (better half's birthday) so I'll be out of contact relaxing for a few days but when I'm back i'd love to take a look at the source. From the looks of it you're using DirectShow which is one of my specialist areas so if you have any problems with this I'm sure I can help!

Thanks for the Starquake compliments, I actually did the graphics myself, I did art a number of years ago and like to try and keep it up. This is one reason why the remake has been taking so long, drawing all of the graphics and doing all of the code takes up a lot of time and I've been really busy with other projects recently so haven't given it much time at all - I'm going to be returning to it soon though - I must get it finished! Like your project this is also a labour or love - I might be able to get it released in to the Live arcade with permission from the author but although it was a fairly popular game back in the day, I can't imagine millions of people buying it!

I think it would be really cool just to polish up what you have already written. I've found it incredibly useful - it makes developing games for 8 bit systems an absolute dream and means I don't have to sit around writing all of these tools myself, always a bonus!

I felt the same as you with WPF. If I spent extended time with it I could begin to use it more fluidly perhaps, but the nature of my job is that one day I'll be doing UI another it will be some low level DirectShow stuff or maybe some even lower level C++ work. We only have a small team so I can't dedicate myself to a single aspect of development task, we tend to be all over the product! Even if I was a sadist and decided to dedicate my life to GUI, I still wouldn't choose WPF it is as you say poorly designed and far too over complicated. Turbo charged GDI+ would have been a far better way to go. Have you noticed how all Windows OSs including Windows 7 (not sure about 8, we did install the preview but then needed the drive for something else) still use GDI to render the start menu etc. - what does that tell you? My experience with WPF sounds very similar to yours - doing some of the simplest things seemed almost impossible and I too spend far too much time trawling the net for answers which often weren't satisfactory!

QT is reported to be extremely good, some of the bells and whistles of WPH but with a more forms style programming model. I haven't looked at it yet but may well do one day if I have a compelling need for a whizzy GUI.


Anyway I'm off for a few days but will PM you when I get back - looking forward to seeing the source. If you need help with XML, I have a lot of experience in this too, our app is WCF services based with an XML API so I have had a lot of fun munging it into all sorts of fun formats! I hardly ever use the serialization in its native form since as you have no doubt found it can be a bit of a pig and often it's quicker just to do the process manually using the XML writer.

For all the latest Starquake remake news check out my website - www.endangermice.co.uk

lachlank

Quote from: endangermice on 00:33, 12 July 12
Thanks for the Starquake compliments, I actually did the graphics myself, I did art a number of years ago and like to try and keep it up.


Damn, you are one of those lucky b%*^&ds who can program and draw - a rare breed. I am very jealous.


Hear from you when you get back.


Lachlan

Gryzor

Quote from: lachlank on 00:39, 12 July 12

Damn, you are one of those lucky b%*^&ds who can program and draw - a rare breed. I am very jealous.



^^This. I can do neither. Damn you people.

lachlank

Have now created a wiki page for RGAS which has the full Windows installer for those who want to try it out.

Retro Game Asset Studio - CPCWiki - The Ultimate Amstrad CPC Community &

Lachlan

Ynot.zer0

absolutely awesome news!!!  I was wondering what I was going to be doing for the next 2 days, whilst stuck in a hotel in Saudi..... I'll shall give it a thorough test-drive and provide you with any feedback.  The wiki page list of features has made me want to try this out!  does it come with a "sample" app?... okay, I suppose I'll find out after it's finished installing  :laugh:

Powered by SMFPacks Menu Editor Mod