[ACS] Loading files at compile-time, with ACC?

Discuss all aspects related to modding Zandronum here.
Post Reply
User avatar
TDRR
Forum Regular
Posts: 218
Joined: Thu Jun 28, 2018 9:13 pm
Location: Venezuela
Contact:

[ACS] Loading files at compile-time, with ACC?

#1

Post by TDRR » Fri Nov 27, 2020 3:06 am

I've been wondering, how would loading (and parsing) a file be handled in ACS? I don't mean literally grabbing a random file from whatever place in the .pk3 or your disk (unless some insane out of bounds memory access bug is found that's not happening), I mean attached at compile-time.

I thought about putting it in a string var, but there's the issue that it can only be 32kb max (which isn't much of a problem and if you REALLY need there's workarounds for that) and you just can't represent everything (all newlines appear to get decimated and nothing can be read of them, who knows what else doesn't work), you could also paste the hex instead which would work but then the memory usage is doubled and you can only have 16kb per string.

So, what would be the best way to handle it in pure vanilla ZDoom-enhanced ACC, in your opinion? (anyone who recommends GDCC will get an imaginary slap on the face)

If you're wondering if this is stupid and pointless, well, kinda yes but at the same time, it would be super nice to support files exported by other programs with minimal work from the modder to put them into a way they can be read by ACS. Imagine writing custom collision code in ACS with support for .obj meshes! Well, maybe not that complicated but you get the idea.
One thing I have asked from the Lord, that I shall seek: That I may dwell in the house of the Lord all the days of my life, to behold the beauty of the Lord and to meditate in His temple. (Psalm 27:4, NASB)
My Discord tag is @tdrr, and it's my preferred contact method. I also check PMs here from time to time.

Post Reply