December 1, 200223 yr Below is a code generated for a CallLibObj by FSRegen. I adjusted it by including a section after the mif(11) for density settings. Initially everything was fine and the density settings worked well. All of a sudden yesterday things began to go wrong with the 3d objects! The objects started to disappear at certain angles when one rotated around them (why this did not happen earlier I do not understand). Interestingly this happens when the density setting is set at Dense or lower. Only one object is at Very Dense setting and when Very Dense setting is set in FS then all is well and no object disappearances...Even stranger is that my own aircraft also disappears at certain angles!and even stranger, one of the Beta Testers reports no issues. Could it be that my FS is corrupted...???Here is the code,; --- Created by FsRegen v0.31bmif (0)Area( 5 %1 %2 1 )RotatedCall( :symbol 0 0 %5 )Jump( :endsymbl ):symbolRefPoint( 7 : 0.5 %1 %2 )Points( 0-44 0 -50-44 0 532240 0 532240 0 -501098 0 2)Poly( a 0 1 2 3 )Poly( a 0 4 3 )Return:endsymblEndAmifendArea( 5 %1 %2 22 )perspectivecall( :OBJ )shadowcall( :OBJ )jump( : ):OBJmif( %11 )refpoint( 2 :END %4 %1 %2 E= %11 v1= %10 %13 %14 V2= 4589 )melserefpoint( 7 :END %4 %1 %2 v1= %10 %13 %14 V2= 4589 )mifendmif( %12 )IfVarRange( : 0346 %12 2 ) mifendrotatedcall( :ROT 0 0 %5 )return:ROTcallLibobj( 0 B8902082 4F960B67 1DF0BE98 E2742DB9 ):ENDreturnEndAThanksShez Shez Ansari Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"
December 1, 200223 yr I had weird problems with disappearing scenery. I increased the V2= value and it fixed the problem. Bill Sieffert
December 2, 200223 yr Author Thanks. I will try that.Shez Shez Ansari Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"
December 2, 200223 yr Commercial Member Most of the times increasing the v2 value should work.But I also noticed an error in your source. From the density check you jump right away to the end of file ( : ), while you should jump to the Return command first ( :END ), SCASM doesn't complain about this, but it can cause FS the lock up.ArnoMember Netherlands 2000 Scenery Team[a href=http://home.wanadoo.nl/arno.gerretsen]http://home.wanadoo.nl/arno.gerretsen/banner.jpg[/a] Arno If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done. FSDeveloper.com | Former Microsoft FS MVP | Blog
December 2, 200223 yr Author Hi Arn,You mean in the IfVar variable?eg. mif( %12 )IfVarRange( :END 0346 %12 2 ) mifendShez Shez Ansari Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"
December 2, 200223 yr Commercial Member Yep, that one.But the dissapearing from a certain angle must be the v2 value.ArnoMember Netherlands 2000 Scenery Team[a href=http://home.wanadoo.nl/arno.gerretsen]http://home.wanadoo.nl/arno.gerretsen/banner.jpg[/a] Arno If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done. FSDeveloper.com | Former Microsoft FS MVP | Blog
December 2, 200223 yr Author Unfortunately, tried to increase the value of V2 to 50,000 but no joy.Very strange...it is almost like my FS is corrupted or something.Shez Shez Ansari Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"
December 2, 200223 yr Commercial Member I don't know if FS likes such big v2 values :), have you also tried increasing it but 100 or so?Also, you must change it in the api I think, because I think the v2 is hard coded in FsRegen api's (not sure about that btw).ArnoMember Netherlands 2000 Scenery Team[a href=http://home.wanadoo.nl/arno.gerretsen]http://home.wanadoo.nl/arno.gerretsen/banner.jpg[/a] Arno If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done. FSDeveloper.com | Former Microsoft FS MVP | Blog
December 2, 200223 yr Author Yeah that was an extreme case :( Actually I did change the V2 in the API. I see one interesting parameter %13 %14 seem to be coded as V2.Let's try this again...Shez Shez Ansari Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"
December 2, 200223 yr Author No that does not work. :-( I am really at a loss here. If I reduce the density settings of a couple of objects to Normal so that all objects are either Normal or below, the scenery works fine. As soon as I introduce an object with a higher density then things go wrong. I actually don't think that this is V2 issue.Thanks Arno for your help.Shez Shez Ansari Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"
December 2, 200223 yr >I am really at a loss here. If I reduce the density settings >of a couple of objects to Normal so that all objects are >Hi Shez,Please use IfVarRange( : 346 %12 5 ) just after the Area(). Firstly you will skip both the object and its shadow in one go. Secondly there is a typo (2 instead of 5) which causes your objects not to appear. Think about it and you will see that FS is doing precisely what you are telling it to do!Kind Regards,Luis
December 2, 200223 yr Author Hey Hey thanks Luis, it appears to work! Whew! I will do some more testing to confirm too. :7Thanks again all for your help.Shez Shez Ansari Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"
December 5, 200223 yr Hi ShezYup, Luis has put you on the right lines with the main problem - it was the syntax of your IfVarRange() command.But there is also an error in the RefPoint()'s and the v2 value is probably too large, not too small. v2 is meant to represent the radius of a sphere that encloses the object, measured from the RefPoint() location, and it prevents the object being culled too soon as it moves off screen. But if the value is too large, FS will waste time trying to display the object when it really is off screen! And you have duplicated the v2 parameter by using '%13 %14' as well as 'v2= ...'. So make v2 smaller (about 1.5 x the actual 'radius' seems to work well) and delete the references to '%13 %14'.Kind RegardsGerrish
December 5, 200223 yr Author Thanks GG,What would the actual radius be? I was using 4259?Shez Shez Ansari Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"
December 5, 200223 yr Hi ShezThe radius depends on the size and shape of the object ...Looking at your original calling code, the 'Airport symbol' section suggests that the radius might be as high as 2250 scale units (1125 meters), but this looks odd. Is there a big ground polygon or something that causes this, or is it just a mistake?If the true radius really is this big, then the v2 value you have been using may not be too large after all, although you might get away with half the value.CheersGerrish
Create an account or sign in to comment