Author Topic: SCI Companion V3 - alpha build notes/bugs/feature requests  (Read 393389 times)

0 Members and 4 Guests are viewing this topic.

Offline Cloudee1

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #585 on: February 01, 2016, 07:18:13 PM »
Not to mention that booleans don't even have to reside in the main script at all anymore with the whole Bvariables thing.
Halloween Competition Brass Lantern Prop Competition Groundhog Day Competition

Offline troflip

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #586 on: February 01, 2016, 07:24:36 PM »
Sure they do. Bset, Bclear, Btest all refer to storage in the main script.
Check out my website: http://icefallgames.com
Groundhog Day Competition

Offline Collector

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #587 on: February 01, 2016, 08:15:09 PM »
There's always the XMas Card interpreter possibility...

Gumby might want to play around with this http://sciprogramming.com/community/index.php?topic=1548.msg8307#msg8307
KQII Remake Pic

Offline gumby

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #588 on: February 01, 2016, 10:44:19 PM »
Oh yes, not much I can do with the heap.  The main issue is the sheer number of global variables used to track the state of objects in the game.

Any many of them boolean values? You can store 16 of them in one global variable location, saving a lot of space. Sierra did this.

I did consider this at one point, but it wouldn't help much as I recall.  Another aspect of the problem is the way that the logic is structured.  Any input is valid in any room at any point in the game, and there is a lot of nested procedure calls.  I put each procedure in a single script and unload them whenever possible, but when I'm a dozen procedures deep (therefore not able to unload the parent procedures until I return from the current one) and each one is a healthy size, that coupled with the size of the Main script just kills the heap.

It's not impossible for me to move forward, just incredibly painful.  One of my tricks is to store stuff in text resources, for example large arrays of data.  Sure once the values change I need to keep track of the new value in the Main script, but at least all unmodified data can benefit from not being in memory.  I did some really crazy stuff to keep the heap size down.

There's always the XMas Card interpreter possibility...

Gumby might want to play around with this http://sciprogramming.com/community/index.php?topic=1548.msg8307#msg8307

I may look into this, sounds interesting.  Thanks for link Collector.
« Last Edit: February 01, 2016, 10:48:55 PM by gumby »
In the Great Underground Empire (Zork port in development)
Winter Break 2012 Rope Prop Competition

Offline lskovlun

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #589 on: February 02, 2016, 05:25:49 AM »
There's always the XMas Card interpreter possibility...
Or QfG2? I imagine Gumby already has a bunch of 16 color graphics (some of which we've seen)...

Offline troflip

Check out my website: http://icefallgames.com
Groundhog Day Competition

Offline gumby

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #591 on: February 15, 2016, 03:31:45 PM »
Holy cow I just started poking around with the newest version of Companion, my first taste of creating games with SCI 1.1.  I'm blown away, this is amazing work Troflip!  Utterly speechless  :o
In the Great Underground Empire (Zork port in development)
Winter Break 2012 Rope Prop Competition

Offline Kawa

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #592 on: February 15, 2016, 03:37:26 PM »
I just found a typo in the help files. In Compiler/differences.html, heading "and/or operators are now prefix".
Quote
In SCI Studio syntax, and and or behaved differently than all other oeprators in that they were infix instead of prefix.

Offline troflip

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #593 on: February 15, 2016, 04:08:19 PM »
Glad you like it gumby!

Kawa, thanks for letting me know about the typo. I'll have to do an update of the docs on the scicompanion.com site at some point, because I've found a number of small doc bugs (mostly around there still being bits of old syntax in the docs).
Check out my website: http://icefallgames.com
Groundhog Day Competition

Offline Kawa

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #594 on: February 15, 2016, 04:27:02 PM »
In other news, I was looking in the docs for a refresher on for loops so I could make this:

Because Graph doesn't respect remapped colors but DrawCel does.

And then I packed it up and put it in storage because the regular windows have two or three different colors and that'd complicate things too much.

Offline MusicallyInspired

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #595 on: February 16, 2016, 01:45:44 AM »
I tried fooling around with KQ6CD for fun (the one included with the KQ collection) by changing audio resources to different sound effects (tried all 16/8 bit and 11025/22050 Hz combinations). Once the new sound overrides an old one every sound after that gets corrupted and when these corrupted sounds try to play in game it's just a bunch of garbled noise. The new sounds I put it in work fine, though. Apologies if this has been brought up before.

Also, Companion doesn't notice an issue because it's getting files from "audiocache". When I delete that folder it finally looks in resource.sfx where it's supposed to and lists all the audio sounds after the new one as corrupt.

EDIT: Slight correction, it doesn't corrupt anything until I rebuild resources. In Companion, if I don't rebuild, it shows my new sound under "audio cache" in red and the old one is greyed out, says "unused", and is in "resource.sfx". However, when I play the game, it's still using the old sound, not my new one. So it's not unused at all. Only when I rebuild resources does the new sound work....and then a bunch of other sounds after its entry get corrupted.
« Last Edit: February 18, 2016, 01:28:13 PM by MusicallyInspired »
Brass Lantern Prop Competition

Offline MusicallyInspired

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #596 on: February 18, 2016, 01:28:18 PM »
I'm running into some decompilation issues. Changes I made to a KQ6 room script weren't working and kept popping up errors of not being able to recognize certain globals or something. So I deleted the source (since it was of an older decompilation anyway) and re-decompiled with 3.0.1.7. I guess it automatically decompiles to Sierra Script now, which is cool. It'd be nice to have an option, but whatever not a big deal, and I know you can cross-convert between languages.

Anyway, I attempted to make changes again to the same room script (750) but it still pops up errors for not recognizing global variables. The names are correct, and they exist, but it doesn't recognize them. So I figured I have to compile the Main script first. I do that and discover that there are many procedures, variables, and instances (probably others) that have no names and are completely blank. I have no idea what to call them so Main is un-compileable. Any idea why that would be? If I try to guess names it gets passed most of them, but then complains that certain procedures are already declared (not the ones I guessed). Should I work with an older decompilation perhaps?
« Last Edit: February 18, 2016, 01:58:28 PM by MusicallyInspired »
Brass Lantern Prop Competition

Offline troflip

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #597 on: February 18, 2016, 02:02:53 PM »
I guess it automatically decompiles to Sierra Script now, which is cool. It'd be nice to have an option, but whatever not a big deal, and I know you can cross-convert between languages.

Game->PRoperties->Script Language. Set this before decompiling. It defaults to Sierra syntax for Sierra games (which don't have any game.ini settings file by default)

Anyway, I attempted to make changes again to the same room script (750) but it still pops up errors for not recognizing global variables. The names are correct, and they exist, but it doesn't recognize them. So I figured I have to compile the Main script first.

I just tried this with KQ6-CD and didn't have any issues. Both script 750 and Main compiled fine.

Can you post your Main.sc?

A few notes:
- you'll need to decompile everything several times (I did it three times, but twice might be enough), because the decompiler keeps picking up better variable names for globals based on their usage. For example, if no yet-decompiled script has used global75 in a descriptive way yet, and then we decompile a script that does, we give it a name. Then, Main (and anyone else who uses global75) needs to be re-decompiled. I know it's not ideal... I should have some button that does "Decompile until there are no more changes to global var and proc names".
- Decompiling generates .sco files. That should be all that's required to have other scripts reference global variables correctly... i.e. you shouldn't need to recompile Main in order to be able to compile script 750.

Also, the script browsing info stuff (goto definition, etc) isn't working again. Was that taken out again? I thought it was reimplemented. Sorry, I haven't used this in a while.

Is "Enable browse info" checked in Tools->Preferences?

(Note if you're making patches for games, you'll probably want to uncheck "Compile modified scripts before run", since that can cause scripts other than the ones you're explicitly compiling to be compiled... a problem if there are any errors in the decompiled code).
« Last Edit: February 18, 2016, 02:13:12 PM by troflip »
Check out my website: http://icefallgames.com
Groundhog Day Competition

Offline MusicallyInspired

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #598 on: February 18, 2016, 02:06:58 PM »
My mistake, the script info stuff does work, it just didn't work for variables that weren't declared (obviously); the ones it kept erroring out on during compile. I'm decompiling a couple more times and I'll report back.

EDIT: It worked. :) Can compile easily now. Sorry for the bother. What do you think of my audio issue, though? Should I try the "Repackage Audio" function or is that the same thing as what I've done?
« Last Edit: February 18, 2016, 02:25:36 PM by MusicallyInspired »
Brass Lantern Prop Competition

Offline troflip

Re: SCI Companion V3 - alpha build notes/bugs/feature requests
« Reply #599 on: February 18, 2016, 02:34:01 PM »
I hope to look into the audio issue soon, I'm not sure what's going on there yet... I thought it had something to do with 65535.map being a patch file, but it doesn't seem to.
« Last Edit: February 18, 2016, 02:36:27 PM by troflip »
Check out my website: http://icefallgames.com
Groundhog Day Competition


SMF 2.0.19 | SMF © 2021, Simple Machines
Simple Audio Video Embedder

Page created in 0.036 seconds with 23 queries.