Hard Light Productions Forums

Modding, Mission Design, and Coding => The Scripting Workshop => Topic started by: taylor on February 11, 2008, 08:04:53 pm

Title: Request for RTT testing script
Post by: taylor on February 11, 2008, 08:04:53 pm
I need a script for testing out the RTT bug(s), based on the newer scripting system, in order to try and figure out what's going on there.  If anyone can provide one or more (preferably more rather than one) test cases then I'll try and work out the problem for the next Xt build.
Title: Re: Request for RTT testing script
Post by: WMCoolmon on February 12, 2008, 02:05:09 am
Here's the one I usually use. This is a variant of the one that I gave you previously on the internal, but updated for the stable branch. I also moved the RTT stuff to be drawn first, since IIRC you mentioned that that was an issue.

[attachment deleted by ninja]
Title: Re: Request for RTT testing script
Post by: Nuke on February 12, 2008, 02:08:17 am
well theres my cockpits thing, but it will take me some time to build an archive of all the proper ships ect that it currently requires. theres a partial list of some of the things ive noticed here:

http://www.hard-light.net/forums/index.php/topic,51538.msg1048188.html#msg1048188

give me an hour or so and il have a demo.

www.game-warden.com/nukemod-cos/downloads/cockpit test.rar (http://www.game-warden.com/nukemod-cos/downloads/cockpit test.rar)

maybe i can also provide something along the lines of crate pong as well (that is if i can get it to work) :D
Title: Re: Request for RTT testing script
Post by: taylor on February 22, 2008, 08:15:30 pm
The scripting code doesn't work in a 64-bit build, which seriously hampers my ability to test this stuff out, but I managed to track down the problem in this case using Windows builds running with Wine.

I confirmed that the RTT code works perfectly, so that wasn't the cause of the problem.  It turns out to be a culling issue.  The calls to drawRectangle() in the script end up turning on culling (not a scripting related problem, just the result of bad drawing code) and the RTT texture simply gets culled away.  It still draws fine as far as the game is concerned, but the hardware will cull it out.  I made some changes to gr_set_cull() so that we can restore the original cull state rather than just forcing it on/off blindly.  I'll have to do some testing to make sure this change doesn't break anything else, but I think this should solve the remaining RTT issues (along with the other code in the Xt builds).

I'll make a new test build tomorrow so that you can confirm it all works for you Nuke, and then we can consider this fixed.
Title: Re: Request for RTT testing script
Post by: Nuke on February 25, 2008, 08:03:48 pm
cool