Staredit Network > Forums > SC1 UMS Theory and Ideas > Topic: Chaotic Terrain Animation
Chaotic Terrain Animation
Dec 26 2011, 12:21 am
By: Cinolt  

Dec 26 2011, 12:21 am Cinolt Post #1



1)
2)Chaotic Terrain
3)???
4)Profit: badapple.scx
badapple_nosound.scx
(it moves)

The animation is only noticeable by analyzing the difference in frames because of the noise ratio; a screenshot would be pointless.



None.

Dec 26 2011, 12:33 am Lanthanide Post #2



Since OP doesn't actually explain anything useful, this map is a rendering of the music video using the chaotic terrain effect. Although on my computer (W7 64 bit) it mainly just looks like scrambled pixels with a few white pixels that change as well. I couldn't really make out what the shapes were, just that shapes were changing. Also you have to play the game in multiplayer, it uses Center View actions which behave differently in SP.



None.

Dec 26 2011, 12:57 am Dem0n Post #3

ᕕ( ᐛ )ᕗ

How do I use this "chaotic terrain" thing? Is it just placing a p20 scarab in the map? By the way, the link in the chaotic terrain thread is invalid (not sure if I need to download this).




Dec 26 2011, 2:39 am Roy Post #4

An artist's depiction of an Extended Unit Death

Quote from name:Dem0nS1ayer
How do I use this "chaotic terrain" thing? Is it just placing a p20 scarab in the map? By the way, the link in the chaotic terrain thread is invalid (not sure if I need to download this).
Quote from name:yoonkwun
Nothing new, just decided to map out what terrain looks like before and after the Player 20 Map Revealer/Interceptor/Scarab trick for each tileset.
Yup. Just place the unit.




Dec 26 2011, 4:34 pm Sacrieur Post #5

Still Napping

Fascinating.

But I found it difficult to follow, there was bad contrast, but really neat nonetheless =3



None.

Dec 26 2011, 9:41 pm Cinolt Post #6



Added some trigger optimizations, which allowed me to render the entire video with sound in only 4MB.
badapple2.scx
badapple3.scx Christmas version (displays in red and green, might be a little easier to see).

If only I could get the maps to work with TinyMap :(



None.

Dec 26 2011, 11:21 pm O)FaRTy1billion[MM] Post #7

👻 👾 👽 💪

Quote from name:yoonkwun
If only I could get the maps to work with TinyMap :(
Why wont it? Is it because it changes the terrain (except if it is vr4 reference being replaced that shouldn't matter ...)



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!

Dec 27 2011, 12:21 am Cinolt Post #8



Quote from O)FaRTy1billion[MM]
Quote from name:yoonkwun
If only I could get the maps to work with TinyMap :(
Why wont it? Is it because it changes the terrain (except if it is vr4 reference being replaced that shouldn't matter ...)

"One or more unknown files were found in the MPQ.
Please update your listfile in the Option window and try again."

SFmpqapi related snippet:
Code
MPQHANDLE mpq=MpqOpenArchiveForUpdate(argv[3],MOAU_CREATE_ALWAYS,2);
MpqAddFileFromBuffer(mpq,(void *)buf,size,"staredit\\scenario.chk",MAFA_COMPRESS);
MpqAddWaveToArchive(mpq,"wav",wavstr,0,MAWA_QUALITY_LOW);
MpqCloseUpdatedArchive(mpq,0);


I tried adding only the scenario.chk but still got the same error.



None.

Dec 27 2011, 9:06 am O)FaRTy1billion[MM] Post #9

👻 👾 👽 💪

It just means that no listfile is present

Use MOAU_MAINTAIN_LISTFILE



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!

Dec 27 2011, 9:42 am Lanthanide Post #10



Can't you ignore the absense of the list file? Assume scenario.chk is in there and scan through the trigger list to find all the .wav files and use that to guess the names of the other files, and if there's nothing left after that, proceed.



None.

Dec 27 2011, 5:30 pm Cinolt Post #11



Quote from O)FaRTy1billion[MM]
It just means that no listfile is present

Use MOAU_MAINTAIN_LISTFILE

Now TinyMap will compress it, however it doesn't seem to recognize the Preserve Trigger flag. Please add support for this in the near future (I got <50% compression ratios :P)



None.

Dec 27 2011, 6:14 pm Azrael Post #12



I thought it was cool. Going to try the new versions now.




Dec 28 2011, 5:41 am Heinermann Post #13

SDE, BWAPI owner, hacker.

I am not sure if I am seeing it right, but it's a bunch of garbage and only one pixel changes. Also crashes with BWAPI.
And for some reason I can't save Starcraft screenshots.

EDIT: The crash with BWAPI is the fault of BWAPI.
Code
//////////////////////////////////////////////////
TIME: Wed Dec 28 00:37:36 2011

VERSION: 1.16.1.1
BWAPI:
 REVISION: 4000
 BUILD: DEBUG
 ERROR: None
 LOCATION: Single Player
MAP: Bad Apple
    badapple2.scx

EXCEPTION: 0xC0000005    EXCEPTION_ACCESS_VIOLATION
FAULT:     0x1007DF7D    BWAPId.dll
REGISTERS:
 EDI: 0018F464
 ESI: 0018F20C
 EBX: 00000000
 EDX: 00000001
 ECX: 00000001
 EAX: 0092FC08
 EBP: 0018F214
 EIP: 1007DF7D
 ESP: 0018F20C
STACK:
 BWAPId.dll        0x1007DF7D    BWAPI::UnitImpl::canAccess
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\unitimpl.cpp:168
 BWAPId.dll        0x100290BB    BWAPI::GameImpl::computePrimaryUnitSets
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\gameinternals.cpp:2411
 BWAPId.dll        0x1002B9C7    BWAPI::GameImpl::updateUnits
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\gameinternals.cpp:2754
 BWAPId.dll        0x1001F0F5    BWAPI::GameImpl::update
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\gameinternals.cpp:288
 BWAPId.dll        0x1008E67D    _nextFrameHook
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\detours.cpp:289
 Starcraft_MultiInstance.exe  0x004D9753    GameLoop_State
 Starcraft_MultiInstance.exe  0x004D9908    GameLoop_Top
 Starcraft_MultiInstance.exe  0x004D9A6F    BeginGame
 Starcraft_MultiInstance.exe  0x004E07FA    preLoadGame
 Starcraft_MultiInstance.exe  0x004E0B20    WinMain(x,x,x,x)
 Starcraft_MultiInstance.exe  0x00404DA5    start
 kernel32.dll      0x7641339A    BaseThreadInitThunk
 ntdll.dll         0x77929ED2    RtlInitializeExceptionChain
 ntdll.dll         0x77929EA5    RtlInitializeExceptionChain

//////////////////////////////////////////////////
TIME: Wed Dec 28 00:38:09 2011

VERSION: 1.16.1.1
BWAPI:
 REVISION: 4000
 BUILD: RELEASE
 ERROR: None
 LOCATION: Single Player
MAP: Bad Apple
    badapple.scx

EXCEPTION: 0xC0000005    EXCEPTION_ACCESS_VIOLATION
FAULT:     0x100471B0    BWAPI.dll
REGISTERS:
 EDI: 00000140
 ESI: 000000F0
 EBX: 00000000
 EDX: 00000001
 ECX: 00000001
 EAX: 026727A0
 EBP: 0018ED54
 EIP: 100471B0
 ESP: 0018ED50
STACK:
 BWAPI.dll         0x100471B0    BWAPI::UnitImpl::canAccess
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\unitimpl.cpp:168
 BWAPI.dll         0x10057AA9    BWAPI::GameImpl::computePrimaryUnitSets
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\gameinternals.cpp:2411
 BWAPI.dll         0x1005F4D7    BWAPI::GameImpl::updateUnits
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\gameinternals.cpp:2754
 BWAPI.dll         0x100602CD    BWAPI::GameImpl::update
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\gameinternals.cpp:288
 BWAPI.dll         0x1003F5DD    _nextFrameHook
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\detours.cpp:289
 Starcraft_MultiInstance.exe  0x004D9753    GameLoop_State
 Starcraft_MultiInstance.exe  0x004D9908    GameLoop_Top
 Starcraft_MultiInstance.exe  0x004D9A6F    BeginGame
 Starcraft_MultiInstance.exe  0x004E07FA    preLoadGame
 Starcraft_MultiInstance.exe  0x004E0B20    WinMain(x,x,x,x)
 Starcraft_MultiInstance.exe  0x00404DA5    start
 kernel32.dll      0x7641339A    BaseThreadInitThunk
 ntdll.dll         0x77929ED2    RtlInitializeExceptionChain
 ntdll.dll         0x77929EA5    RtlInitializeExceptionChain

//////////////////////////////////////////////////
TIME: Wed Dec 28 00:40:07 2011

VERSION: 1.16.1.1
BWAPI:
 REVISION: 4000
 BUILD: RELEASE
 ERROR: None
 LOCATION: Single Player
MAP: Bad Apple
    badapple2.scx

EXCEPTION: 0xC0000005    EXCEPTION_ACCESS_VIOLATION
FAULT:     0x100471B0    BWAPI.dll
REGISTERS:
 EDI: 00000140
 ESI: 000000F0
 EBX: 00000000
 EDX: 00000001
 ECX: 00000001
 EAX: 008B27A0
 EBP: 0018ED54
 EIP: 100471B0
 ESP: 0018ED50
STACK:
 BWAPI.dll         0x100471B0    BWAPI::UnitImpl::canAccess
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\unitimpl.cpp:168
 BWAPI.dll         0x10057AA9    BWAPI::GameImpl::computePrimaryUnitSets
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\gameinternals.cpp:2411
 BWAPI.dll         0x1005F4D7    BWAPI::GameImpl::updateUnits
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\gameinternals.cpp:2754
 BWAPI.dll         0x100602CD    BWAPI::GameImpl::update
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\bwapi\gameinternals.cpp:288
 BWAPI.dll         0x1003F5DD    _nextFrameHook
                                    c:\projects\bwapi\trunk\bwapi\bwapi\source\detours.cpp:289
 Starcraft_MultiInstance.exe  0x004D9753    GameLoop_State
 Starcraft_MultiInstance.exe  0x004D9908    GameLoop_Top
 Starcraft_MultiInstance.exe  0x004D9A6F    BeginGame
 Starcraft_MultiInstance.exe  0x004E07FA    preLoadGame
 Starcraft_MultiInstance.exe  0x004E0B20    WinMain(x,x,x,x)
 Starcraft_MultiInstance.exe  0x00404DA5    start
 kernel32.dll      0x7641339A    BaseThreadInitThunk
 ntdll.dll         0x77929ED2    RtlInitializeExceptionChain
 ntdll.dll         0x77929EA5    RtlInitializeExceptionChain


EDIT: Just fixed the BWAPI issue, now I can take a screenshot.


This is how it looks with and without BWAPI (minus christmas lights).

Post has been edited 2 time(s), last time on Dec 28 2011, 2:12 pm by Heinermann.




Dec 28 2011, 9:47 am O)FaRTy1billion[MM] Post #14

👻 👾 👽 💪

Quote from name:yoonkwun
Quote from O)FaRTy1billion[MM]
It just means that no listfile is present

Use MOAU_MAINTAIN_LISTFILE

Now TinyMap will compress it, however it doesn't seem to recognize the Preserve Trigger flag. Please add support for this in the near future (I got <50% compression ratios :P)
lol sorry. I should just release the newest version. It supports that.



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!

Dec 28 2011, 5:53 pm Cinolt Post #15



Quote from Heinermann
I am not sure if I am seeing it right, but it's a bunch of garbage and only one pixel changes. Also crashes with BWAPI.
And for some reason I can't save Starcraft screenshots.
...

I'm not sure why that would happen, the only people I've encountered for whom it didn't work were Mac users. The screen shot is how it's supposed to look, however more than one pixel (around 1200) are supposed to change.

Only thing I could suggest is to reinstall a completely pristine copy of StarCraft.



None.

Dec 28 2011, 6:52 pm TF- Post #16

🤙🏾

I'm familiar with the video but the only part I could recognize was the apple falling, how the hell does this work anyway?



🤙🏾

Dec 28 2011, 11:03 pm Heinermann Post #17

SDE, BWAPI owner, hacker.

Quote from name:yoonkwun
Quote from Heinermann
I am not sure if I am seeing it right, but it's a bunch of garbage and only one pixel changes. Also crashes with BWAPI.
And for some reason I can't save Starcraft screenshots.
...

I'm not sure why that would happen, the only people I've encountered for whom it didn't work were Mac users. The screen shot is how it's supposed to look, however more than one pixel (around 1200) are supposed to change.

Only thing I could suggest is to reinstall a completely pristine copy of StarCraft.
I don't mean only one pixel, I meant one pixel per tile, is that how it's supposed to be?
A re-install would not change this behaviour.




Dec 28 2011, 11:29 pm Cinolt Post #18



Quote from Heinermann
I don't mean only one pixel, I meant one pixel per tile, is that how it's supposed to be?

Yes, unfortunately. There's actually an average of eight pixels (out of 32*32=1024) per tile to be precise. I find it's best if you watch the video beforehand and when playing the map look at the entire picture, only looking for differences between the frames.

There are ways to decrease the noise ratio slightly, though I'll save that for another day.



None.

Dec 30 2011, 12:36 am Heinermann Post #19

SDE, BWAPI owner, hacker.

There should be a better way.

EDIT: I looked at it and noticed you are only setting resource amounts.
I am not sure what the exact specs are, but you can change a lot more than just that.

Known to change to exactly what you want at any precise moment:
  • 0x008 hitPoints; - Limited to percentage of unit (also works on invincible units).
  • 0x028 position; - Unit's current position, 16-bit value for x followed by y.
  • 0x04C playerID; - Give unit to other player.
  • 0x04D orderID; - Give unit order (Order, Script)
  • 0x058 orderTargetPos; - Give unit order (16-bit x followed by y)
  • 0x060 shieldPoints; - unit must have shields (also works on invincible units)
  • 0x0A2 energy; - unit must have energy
  • 0x0C8 inHangerCount; - the number of units in a Carrier's hangar
  • 0xD0 resourceCount; - you are using this
  • 0xDC statusFlags; - Can change this using disable/enable or setting invincibility state
  • 0x13C, 0x140, 0x144, 0x148 unitFinderIndex positions; - changes if unit's position changes in relation to other units

Possible side-effects or additional:
  • 0x010 moveToPos; - Possibly with order or patrol script?
  • 0x018 nextMovementWaypoint; - Possibly with order or patrol script?
  • 0x01C nextTargetWaypoint; - Possibly with order or patrol script?
  • 0x020 movementFlags; - Possibly with order or patrol script?
  • 0x021 currentDirection1; - Order/patrol script.
  • 0x023 velocityDirection1; - Order/patrol script.
  • 0x04E orderState; - not entirely known, but changes with orders
  • 0x04F orderSignal; - same as above
  • 0x054 mainOrderTimer; - same as above
  • 0x068 previousPlayerUnit; - changes when player owner changes
  • 0x06C nextPlayerUnit; - changes when player owner changes
  • 0x07C AutoTargetUnit; - set when a unit has come near an enemy unit
  • 0x096 cloaked; - set to 1 if cloaked, not sure if that includes arbiters
  • 0x0A7 buildingOverlayState; - 0 means a building has the most fire/blood, a higher value indicates it has less
  • 0x0C0 addon; - set when a building has an addon
  • 0x0C0 powerup; - set when a worker is holding a powerup
  • 0x0CE isCarryingSomething; - set to 1 when the worker is holding anything
  • 0x0E3 recentOrderTimer; - changes when unit is given an order
  • 0x0E4 visibilityStatus; - flags for unit visibility when it is cloaked or burrowed
  • 0x0F0, 0x0F4 - prev/nextBurrowedUnit; - only applies when the current unit is burrowed and another is created/destroyed
  • 0x0F8, 0x0FC - prev/nextPsiProvider; - only applies when the current unit is a pylon and another is created/destroyed
  • 0x107 isBeingHealed; - 1 if unit is being healed by a medic

Can look for more here.

Next: Super Mario Bros. World 1-1 and Doom?

Post has been edited 2 time(s), last time on Dec 31 2011, 12:46 am by Heinermann.




Jan 1 2012, 4:58 am Cinolt Post #20



There is indeed a lot more than just setting resources, which is what I meant by decreasing the noise ratio.

However unit resources is the only data manipulable through CTA that is 1) can be set to any arbitrary value 2) requires only one action, and one location and 3) isolated in memory (setting resources only affects that part of memory, as compared to something like Move Unit).

I may write about it in greater detail some other time.

However, I recently got a MacBook that currently can't play StarCraft, so development from me is going to be currently stalled, until I decide to get a proper Mac-Windows dual-booting package (wine from MacPorts doesn't work :().

I decided to fully open source my programs I used to make this for anybody (Heinermann) to work on further if they (Heinermann) want to, and for learning(/stealing) purposes.

This is a straight raw upload from my old comp, so feel free to ask any questions about it.

cta.cpp: .cta + map.scx + *.png + wav -> out.scx
ctac.c: tileset files -> .cta
ts2tga.c: tileset files -> .tga image file (irrelevant to CTA)
notes

In any case this will probably be the last major contribution you will see from me in a while. I still check back on here occasionally so I'll respond to any questions.

Post has been edited 1 time(s), last time on Jan 1 2012, 6:54 pm by yoonkwun.



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[06:51 pm]
Vrael -- It is, and I could definitely use a company with a commitment to flexibility, quality, and customer satisfaction to provide effective solutions to dampness and humidity in my urban environment.
[06:50 pm]
NudeRaider -- Vrael
Vrael shouted: Idk, I was looking more for a dehumidifer company which maybe stands out as a beacon of relief amidst damp and unpredictable climates of bustling metropolises. Not sure Amazon qualifies
sounds like moisture control is often a pressing concern in your city
[06:50 pm]
Vrael -- Maybe here on the StarEdit Network I could look through the Forums for some Introductions to people who care about the Topics of Dehumidifiers and Carpet Cleaning?
[06:49 pm]
Vrael -- Perhaps even here I on the StarEdit Network I could look for some Introductions.
[06:48 pm]
Vrael -- On this Topic, I could definitely use some Introductions.
[06:48 pm]
Vrael -- Perhaps that utilizes cutting-edge technology and eco-friendly cleaning products?
[06:47 pm]
Vrael -- Do you know anyone with a deep understanding of the unique characteristics of your carpets, ensuring they receive the specialized care they deserve?
[06:45 pm]
NudeRaider -- Vrael
Vrael shouted: I've also recently becoming interested in Carpet Cleaning, but I'd like to find someone with a reputation for unparalleled quality and attention to detail.
beats me, but I'd make sure to pick the epitome of excellence and nothing less.
[06:41 pm]
Vrael -- It seems like I may need Introductions to multiple companies for the Topics that I care deeply about, even as early as Today, 6:03 am.
[06:38 pm]
Vrael -- I need a go-to solution and someone who understands that Carpets are more than just decorative elements in my home.
Please log in to shout.


Members Online: Moose