Staredit Network > Forums > Modding Discussion > Topic: Problems with Current Modding Tools
Problems with Current Modding Tools
Mar 4 2015, 3:49 am
By: Sand Wraith
Pages: < 1 « 2 3 4 5 623 >
 

Oct 26 2015, 5:26 am Sand Wraith Post #61

she/her

Okay, try this: http://puu.sh/kXWFL/3bdf4188ee.zip

The included *.grp has the corruption present, and I produced it from the *.bmp




Oct 27 2015, 2:12 am poiuy_qwert Post #62

PyMS and ProTRG developer

Quote from Sand Wraith
Okay, try this: http://puu.sh/kXWFL/3bdf4188ee.zip

The included *.grp has the corruption present, and I produced it from the *.bmp

Thanks, fixed!




Oct 29 2015, 8:08 am Neiv Post #63



Nice to see more progress being made with the tools =)

I tried to to compile one of my iscripts with PyICE command line interface and ran into some problems:
1) turn1cwise is mistakenly named as turnlcwise :P
2) While IceCC accepts coordinates at least in range [-128 .. 255], PyICE only accepts [-128 .. 127]. Not really a bug, but makes switching iscript compilers more annoying, especially since IceCC defaults to using [0 .. 255] range when decompiling iscript.
3) The iscript compilation fails anyways with the following error:
Code
> C:\ohjelmia\python27\python PyICE.pyw -c ..\..\modit\sm\scripts\iscript.txt ..\..\modit\sm\scripts\iscript.bin
Loading weapons.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\weapons.dat', flingy.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\flingy.dat', images.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\sprites.dat', sprites.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\images.dat', sdxdata.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\sfxdata.dat', stat_txt.tbl 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\rez\stat_txt.tbl', images.tbl 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\images.tbl', and sfxdata.tbl 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\sfxdata.tbl'
C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\rez\stat_txt.tbl
C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\sfxdata.tbl
- Loading finished successfully
Interpreting file '..\..\modit\sm\scripts\iscript.txt'...
len 0 <type 'list'> -1
- '..\..\modit\sm\scripts\iscript.txt' read successfully
Compiling file '..\..\modit\sm\scripts\iscript.txt' to iscript.bin '..\..\modit\sm\scripts\iscript.bin'...
Traceback (most recent call last):
 File "PyICE.pyw", line 2208, in <module>
   main()
 File "PyICE.pyw", line 2196, in main
   bin.compile(args[1])
AttributeError: 'builtin_function_or_method' object has no attribute 'compile'




None.

Oct 29 2015, 2:44 pm poiuy_qwert Post #64

PyMS and ProTRG developer

Quote from Neiv
Nice to see more progress being made with the tools =)
Agreed :P

Quote from Neiv
I tried to to compile one of my iscripts with PyICE command line interface and ran into some problems:
1) turn1cwise is mistakenly named as turnlcwise :P
Lol nice catch. Luckily there was support from the beginning for multiple names for commands, so I've added turn1cwise to the name list with higher priority so both names will compile fine but turn1cwise will be the one you get with new decompiles.

Quote from Neiv
2) While IceCC accepts coordinates at least in range [-128 .. 255], PyICE only accepts [-128 .. 127]. Not really a bug, but makes switching iscript compilers more annoying, especially since IceCC defaults to using [0 .. 255] range when decompiling iscript.
Hmm not sure how or if i'm going to handle this case :/ I'll have to think about it

Quote from Neiv
3) The iscript compilation fails anyways with the following error:
Code
> C:\ohjelmia\python27\python PyICE.pyw -c ..\..\modit\sm\scripts\iscript.txt ..\..\modit\sm\scripts\iscript.bin
Loading weapons.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\weapons.dat', flingy.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\flingy.dat', images.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\sprites.dat', sprites.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\images.dat', sdxdata.dat 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\sfxdata.dat', stat_txt.tbl 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\rez\stat_txt.tbl', images.tbl 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\images.tbl', and sfxdata.tbl 'C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\sfxdata.tbl'
C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\rez\stat_txt.tbl
C:\Pelei\Scbw\Ohjelmia\PyMS\Libs\MPQ\arr\sfxdata.tbl
- Loading finished successfully
Interpreting file '..\..\modit\sm\scripts\iscript.txt'...
len 0 <type 'list'> -1
- '..\..\modit\sm\scripts\iscript.txt' read successfully
Compiling file '..\..\modit\sm\scripts\iscript.txt' to iscript.bin '..\..\modit\sm\scripts\iscript.bin'...
Traceback (most recent call last):
 File "PyICE.pyw", line 2208, in <module>
   main()
 File "PyICE.pyw", line 2196, in main
   bin.compile(args[1])
AttributeError: 'builtin_function_or_method' object has no attribute 'compile'
Fixed.


Thanks!




Oct 29 2015, 6:23 pm Neiv Post #65



Alright, got PyICE to compile my script :P
But "engset" is handled incorrectly, emitting 2 bytes of parameters even though it should be only a single byte.



None.

Oct 30 2015, 4:04 am poiuy_qwert Post #66

PyMS and ProTRG developer

Quote from Neiv
Alright, got PyICE to compile my script :P
But "engset" is handled incorrectly, emitting 2 bytes of parameters even though it should be only a single byte.
Ouch. Fixed, thanks a lot for the reports!




Nov 8 2015, 2:57 pm Neiv Post #67



PyGRP may encode a single 0x0 pixel as part of a larger chunk of non-repeating pixels. Then bw doesn't treat it as transparent pixel, but it draws the 0x0 black/space pixel instead.



None.

Nov 8 2015, 5:03 pm poiuy_qwert Post #68

PyMS and ProTRG developer

Quote from Neiv
PyGRP may encode a single 0x0 pixel as part of a larger chunk of non-repeating pixels. Then bw doesn't treat it as transparent pixel, but it draws the 0x0 black/space pixel instead.
Interesting. This is caused by part of an optimization I added which makes PyGRP produce the highest compression. I had no idea that starcraft treated "transparent" pixels different than "index 0" pixels. I wonder how the pixel data is stored in memory if index 0 doesn't inherently mean transparent. Anyway, fixed thansk!

I'm assuming this mistake is what made you think of making https://gfycat.com/TestyDentalCalf ? Thats pretty sweet. I'm assuming you just changed the Transparent Index option to make index 0 stay solid?

Thanks!




Nov 8 2015, 6:14 pm Neiv Post #69



Hehe, I actually got the idea of using index 0 color in sprites yesterday night, as there was star.spk discussion in the shoutbox :)

My plan was to add a new color to bexpl.pcx which remapped always to 0 and use that in the sprite. But as the remap palettes have a lot of these almost-transparent colors, they made the index 0 errors stand out more than they would have otherwise.

It was really strange to understand what was going on, as the converting the grp back to bmp gives a correct image D:
But yeah, turns out that the space trick could also have been done with a modified grp converter instead of remap palettes.

And bw actually just keeps the grps in memory, decoding them directly to the framebuffer every time it needs to draw an image. So it apparently just moves the write position forwards when it encounters transparency and copies to the framebuffer otherwise.



None.

Nov 8 2015, 7:34 pm poiuy_qwert Post #70

PyMS and ProTRG developer

Quote from Neiv
Hehe, I actually got the idea of using index 0 color in sprites yesterday night, as there was star.spk discussion in the shoutbox :)

My plan was to add a new color to bexpl.pcx which remapped always to 0 and use that in the sprite. But as the remap palettes have a lot of these almost-transparent colors, they made the index 0 errors stand out more than they would have otherwise.
Ah, cool. I still need to make a special palette editor, hmmm...

Quote from Neiv
It was really strange to understand what was going on, as the converting the grp back to bmp gives a correct image D:
But yeah, turns out that the space trick could also have been done with a modified grp converter instead of remap palettes.
Lol :P And you shouldn't need to modify anything, PyGRP has an option in the GUI to change the Transparent Index it uses to process stuff.

Quote from Neiv
And bw actually just keeps the grps in memory, decoding them directly to the framebuffer every time it needs to draw an image. So it apparently just moves the write position forwards when it encounters transparency and copies to the framebuffer otherwise.
Ah of course, that makes sense.




Nov 24 2015, 4:02 am Corbo Post #71

ALL PRAISE YOUR SUPREME LORD CORBO

I'll just post these as I go.

You'll know when I am done posting stuff because I'll edit this post to say I am done for the night. If you post questions, either here or in the shoutbox I'll probably just edit this post instead of making a new reply. K? K.

This happens when I just try to run PyMAP. Nothing else.


This happens when I try to open ANY MPQ. Only WinMPQ succeeded in opening them, though, not even mpqviewer could open them.



This happens when I try to import a new star. I might have broken it on purpose, though :P, I tried to import a really big bmp which wasn't 256 colors.


But still, you need better error handling ;o

EDIT2:
Also seems that whenever you save a file it keeps it... open? It gave me an error while trying to overwrite a previous star.spk file that PySPK had generated. A 0 byte one because it had errored but I cannot overwrite it because it says it's still in use.


EDIT3:

Cool:


Here's the deal though. It's not rendering quite well. It flickers sometimes when you move in the parallax. (move screen) it makes big chunks disappear when you mouse hover and also chunks of it disappear when units pass over it.

Chunk disappeared when I moved screen:


Chunks disappeared when I mouse hover:


Chunks disappeared when units went over it lololol:


Actually don't have that last one, I took the image at the wrong time, only the thruster's overlay affected the rendering.

EDIT4:
LOLOLOL



Trying to save this errored and returned a 0byte, uneditable spk. Couldn't even overwrite or delete until I closed PySPK.

Post has been edited 5 time(s), last time on Nov 24 2015, 4:36 am by Corbo.



fuck you all

Nov 24 2015, 4:40 am O)FaRTy1billion[MM] Post #72

👻 👾 👽 💪

based on the overlays and the stars appearing on top of black player colors, I think spk must be drawn last.
And the cursor erasing chunks of the huge one, that must be because it's only redrawing the stars that are behind the cursor which does not include the big one.. I bet if you moved the cursor over the center of the sun it would redraw it and fix the holes. But it should be broken up in to smaller images that are tiled together to prevent it... maybe an image limit is more necessary than I first said.



TinyMap2 - Latest in map compression! ( 7/09/14 - New build! )
EUD Action Enabler - Lightweight EUD/EPD support! (ChaosLauncher/MPQDraft support!)
EUDDB - topic - Help out by adding your EUDs! Or Submit reference files in the References tab!
MapSketch - New image->map generator!
EUDTrig - topic - Quickly and easily convert offsets to EUDs! (extended players supported)
SC2 Map Texture Mask Importer/Exporter - Edit texture placement in an image editor!
\:farty\: This page has been viewed [img]http://farty1billion.dyndns.org/Clicky.php?img.gif[/img] times!

Nov 24 2015, 5:04 am poiuy_qwert Post #73

PyMS and ProTRG developer

Quote from Corbo
This happens when I just try to run PyMAP. Nothing else.
This is because PyMS doesn't actually support vanilla DAT files, only BroodWar dat files. You probably have your MPQ's in the wrong order so it's loading from StarDat. Also note that PyMAP is in heavy development, I've only been testing it with a few blizzard ums maps. Also I don't really think its feasible to make it performant using this GUI engine, but I would love to hear how it performs on other peoples systems.

Quote from Corbo
This happens when I try to open ANY MPQ. Only WinMPQ succeeded in opening them, though, not even mpqviewer could open them.
This is doubly weird because PyMPQ uses SFmpq just like WinMPQ, and the issue before this seems to indicate PyMAP was loading StarDat just fine. You sure you didn't have the mpq's open in another program when you tried with PyMPQ?

Quote from Corbo
This happens when I try to import a new star. I might have broken it on purpose, though :P, I tried to import a really big bmp which wasn't 256 colors.


But still, you need better error handling ;o
Fixed. That was a bug in the error popup that was going to tell you your file was wrong. I would say that even with a bug in error handling, it was still good error handling, you got a copyable traceback and the program didn't crash, thus not losing any work you may have done :)

Quote from Corbo
EDIT2:
Also seems that whenever you save a file it keeps it... open? It gave me an error while trying to overwrite a previous star.spk file that PySPK had generated. A 0 byte one because it had errored but I cannot overwrite it because it says it's still in use.
It doesn't seem possible that a save file is kept open since I switched to using atomic writing. I write to a temporary file somewhere in your temp directory then when that "succeeds" I copy the file to where you actually saved it, so I never actually have the final file open. You sure something else didn't have it open?

Also, was there no actual error reported when you got the 0 byte file? What happened? Can I get steps to reproduce it?

Quote from O)FaRTy1billion[MM]
based on the overlays and the stars appearing on top of black player colors, I think spk must be drawn last.
And the cursor erasing chunks of the huge one, that must be because it's only redrawing the stars that are behind the cursor which does not include the big one.. I bet if you moved the cursor over the center of the sun it would redraw it and fix the holes. But it should be broken up in to smaller images that are tiled together to prevent it... maybe an image limit is more necessary than I first said.
Interesting... And disappointing :(

Post has been edited 1 time(s), last time on Nov 24 2015, 5:09 am by poiuy_qwert.




Nov 24 2015, 5:27 am Corbo Post #74

ALL PRAISE YOUR SUPREME LORD CORBO

Quote from poiuy_qwert

Also, was there no actual error reported when you got the 0 byte file? What happened? Can I get steps to reproduce it?

Sure thing:

Try using the image I am going to be attaching. It's a 256-color bitmap that's 512x512. You said you fixed this error already, but if you hadn't the output of that error would actually be a 0 byte spk file.

And that file won't be able to be editer, overwritten or even deleted via windows explorer. That is, until you completely close PySPK



fuck you all

Nov 24 2015, 11:37 am Neiv Post #75



PySPK doesn't even work for me. Crashes on startup with following message
Quote
Traceback (most recent call last):
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 1220, in <module>
main()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 1165, in main
gui = PySPK()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 671, in __init__
e = self.open_files()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 725, in open_files
platformwpe.load_file(self.mpqhandler.get_file(self.settings['platformwpe']))
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\Libs\PAL.py", line 49, in load_file
data = file.read()
AttributeError: BadFile instance has no attribute 'read'

Having PyMPQ require exclusive access to file is really annoying, making it pretty much unusable for me. I can't use it to extract files from stardat/broodat/patch_rt.mpq while Starcraft or even Scmdraft is running. Winmpq is not ideal either, as editing a mpq fails silently when it can't get exclusive access to a file, but at least it allows reading files without having to close all other programs.



None.

Nov 24 2015, 7:32 pm poiuy_qwert Post #76

PyMS and ProTRG developer

Quote from Neiv
PySPK doesn't even work for me. Crashes on startup with following message
Quote
Traceback (most recent call last):
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 1220, in <module>
main()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 1165, in main
gui = PySPK()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 671, in __init__
e = self.open_files()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 725, in open_files
platformwpe.load_file(self.mpqhandler.get_file(self.settings['platformwpe']))
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\Libs\PAL.py", line 49, in load_file
data = file.read()
AttributeError: BadFile instance has no attribute 'read'
Hmm i'm not 100% what that is, but it seems to be that it can't find the file in the MPQ's (or MPQ folder) and is not handling it properly. Will look into it, but for now you could try adjusting your MPQ settings.

Quote from Neiv
Having PyMPQ require exclusive access to file is really annoying, making it pretty much unusable for me. I can't use it to extract files from stardat/broodat/patch_rt.mpq while Starcraft or even Scmdraft is running. Winmpq is not ideal either, as editing a mpq fails silently when it can't get exclusive access to a file, but at least it allows reading files without having to close all other programs.
I'm using SFmpq, just like WinMPQ, so not sure why it would be different. I was looking to see if there was a way to open the MPQ with a readonly flag, but I didn't see any at a glance. I'll look into it though.




Nov 24 2015, 8:55 pm Neiv Post #77



Quote from poiuy_qwert
Quote from Neiv
PySPK doesn't even work for me. Crashes on startup with following message
Quote
Traceback (most recent call last):
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 1220, in <module>
main()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 1165, in main
gui = PySPK()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 671, in __init__
e = self.open_files()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 725, in open_files
platformwpe.load_file(self.mpqhandler.get_file(self.settings['platformwpe']))
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\Libs\PAL.py", line 49, in load_file
data = file.read()
AttributeError: BadFile instance has no attribute 'read'
Hmm i'm not 100% what that is, but it seems to be that it can't find the file in the MPQ's (or MPQ folder) and is not handling it properly. Will look into it, but for now you could try adjusting your MPQ settings.

Right.. I have this hackish setup which causes the tools to not find Bw's mpqs automatically. But PySPK is the only one of them which just closes itself, others let me access the settings and add the .mpqs from there.



None.

Nov 25 2015, 5:07 am poiuy_qwert Post #78

PyMS and ProTRG developer

Quote from poiuy_qwert
Quote from Neiv
Having PyMPQ require exclusive access to file is really annoying, making it pretty much unusable for me. I can't use it to extract files from stardat/broodat/patch_rt.mpq while Starcraft or even Scmdraft is running. Winmpq is not ideal either, as editing a mpq fails silently when it can't get exclusive access to a file, but at least it allows reading files without having to close all other programs.
I'm using SFmpq, just like WinMPQ, so not sure why it would be different. I was looking to see if there was a way to open the MPQ with a readonly flag, but I didn't see any at a glance. I'll look into it though.
Found the flag, should be fixed.

Quote from Neiv
Quote from poiuy_qwert
Quote from Neiv
PySPK doesn't even work for me. Crashes on startup with following message
Quote
Traceback (most recent call last):
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 1220, in <module>
main()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 1165, in main
gui = PySPK()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 671, in __init__
e = self.open_files()
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\PySPK.pyw", line 725, in open_files
platformwpe.load_file(self.mpqhandler.get_file(self.settings['platformwpe']))
File "C:\Pelei\Scbw\Ohjelmia\PyMS\toka\Libs\PAL.py", line 49, in load_file
data = file.read()
AttributeError: BadFile instance has no attribute 'read'
Hmm i'm not 100% what that is, but it seems to be that it can't find the file in the MPQ's (or MPQ folder) and is not handling it properly. Will look into it, but for now you could try adjusting your MPQ settings.

Right.. I have this hackish setup which causes the tools to not find Bw's mpqs automatically. But PySPK is the only one of them which just closes itself, others let me access the settings and add the .mpqs from there.
Fixed




Dec 3 2015, 6:06 am Sand Wraith Post #79

she/her


http://i.imgur.com/2yEvrdz.png

I have highlighted a division in PyTBL that cannot be adjusted to the left/right. It would be great to have this function.




Dec 3 2015, 6:14 am Corbo Post #80

ALL PRAISE YOUR SUPREME LORD CORBO

That's PyTBL?

My god PQ. I'd have thought you had string preview or at least a proper list with color formats and other codes with how they'd look. You're slacking in PyTBL :P

I'll break that one next.



fuck you all

Options
Pages: < 1 « 2 3 4 5 623 >
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[2024-5-06. : 5:02 am]
Oh_Man -- whereas just "press X to get 50 health back" is pretty mindless
[2024-5-06. : 5:02 am]
Oh_Man -- because it adds anotherr level of player decision-making where u dont wanna walk too far away from the medic or u lose healing value
[2024-5-06. : 5:01 am]
Oh_Man -- initially I thought it was weird why is he still using the basic pre-EUD medic healing system, but it's actually genius
[2024-5-06. : 3:04 am]
Ultraviolet -- Vrael
Vrael shouted: I almost had a heart attack just thinking about calculating all the offsets it would take to do that kind of stuff
With the modern EUD editors, I don't think they're calculating nearly as many offsets as you might imagine. Still some fancy ass work that I'm sure took a ton of effort
[2024-5-06. : 12:51 am]
Oh_Man -- definitely EUD
[2024-5-05. : 9:35 pm]
Vrael -- I almost had a heart attack just thinking about calculating all the offsets it would take to do that kind of stuff
[2024-5-05. : 9:35 pm]
Vrael -- that is insane
[2024-5-05. : 9:35 pm]
Vrael -- damn is that all EUD effects?
[2024-5-04. : 10:53 pm]
Oh_Man -- https://youtu.be/MHOZptE-_-c are yall seeing this map? it's insane
[2024-5-04. : 1:05 am]
Vrael -- I won't stand for people going around saying things like im not a total madman
Please log in to shout.


Members Online: Roy, C(a)HeK