Endless Paradigm

Full Version: VSMX File Format
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4
Okay, I've gone to the effort and done it for you - hope that helps:

Javascript Code
rain = new Actor( "rain" );
offset = 0.000000;
camera = new Camera( "camera" );
rideau_pluie = new Actor( "Rideau_pluie" );
pluie = new Actor( "pluie_middle" );
reflet = new Actor( "reflet" );
flowater = new Actor( "flux" );
ruisselle = new Actor( "ruissel" );
updateRain = function(/*localvars=8*/) {
	offset = offset - 0.0250000;
	rain.uv_offset = < 0, offset >;
	ruisselle.uv_offset = < 0, offset * 0.200000 >;
	flowater.uv_offset = < 0, offset * 1.40000 >;
	pluie.uv_offset = < 0, offset >;
	rideau_pluie.uv_offset = < 0, offset * 0.550000 >;
	reflet.uv_offset = < 0, offset * 0.320000 >;
	__var1 = offset * 0.500000;
	__var2 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000;
	__var1 = offset * 0.400000 + 555.500;
	__var3 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000 * 0.500000;
	__var1 = offset * 0.300000 + 888.800;
	__var4 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000;
	camera.position = < 7.07100 + __var2, -(1.00000) + __var3, -(25.3310) + __var4 >;
	__var1 = offset * 0.200000;
	__var5 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000;
	__var1 = offset * 0.180000 + 555.500;
	__var6 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000 * 0.700000;
	__var1 = offset * 0.150000 + 888.800;
	__var7 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000;
	camera.direction = < 0.0850000 + __var5 * 0.100000, -(0.0180000) + __var6 * 0.100000, 0.850000 + __var7 * 0.100000 >;
	return null;
};
updateRain();
System.timer[0] = new IntervalTimer( 1.00000 / 60.0000, updateRain );
num_splotch = 60;
splotchs = new Array();
frames = new Array();
computeLight = function(/*localvars=8*/ __var1, __var2, __var3) {
	__var4 = __var1 - 3.20000;
	__var5 = __var2 + 5.60000;
	__var6 = __var3 + 7.60000;
	__var7 = Math.sqrt( __var4 * __var4 + __var5 * __var5 + __var6 * __var6 ) / 10.0000;
	return Math.pow( Math.max( 0.000000, 1.00000 - __var7 ), 1.40000 );
	return null;
};
randomizeSplotch = function(/*localvars=7*/ __var1) {
	__var2 = 0;
	__var3 = -(5.50000);
	__var4 = 0;
	__var5 = Math.random();
	if( __var5 < 0.700000 ) {
		__var2 = 1.50000 + Math.random() * 8.50000;
		__var4 = -(12.0000) + Math.random() * 12.0000;
	} else {
		if( __var5 < 0.950000 ) {
			__var2 = 1.70000 + Math.random() * 0.500000;
			__var4 = -(12.0000) + Math.random() * 12.0000;
		} else {
			__var2 = 1.98000 + Math.random() * 0.100000 - 0.0500000;
			__var4 = -(9.06000) + Math.random() * 0.100000 - 0.0500000;
		}
	}
	__var1.position = < __var2, __var3, __var4 >;
	__var6 = 0.700000 + Math.random() * 0.300000;
	__var1.scale = < __var6, __var6, __var6 >;
	__var1.setColor( < 1.00000, 1.00000, 1.00000, computeLight( __var2, __var3, __var4 ) >, 0.000000 );
	return null;
};
for(i = 0; i < num_splotch; i++) {
	splotchs.push( new Actor( "splotch" + i ) );
	frames.push( Math.floor( Math.random() * 8.00000 ) );
	randomizeSplotch( splotchs[i] );
}
updateSplotches = function(/*localvars=2*/) {
	for(__var1 = 0; __var1 < num_splotch; __var1++) {
		frames[__var1]++;
		if( frames[__var1] == 8 ) {
			randomizeSplotch( splotchs[__var1] );
			frames[__var1] = 0;
		}
		splotchs[__var1].uv_offset = < frames[__var1] / 8.00000, 0 >;
	}
	System.printPerf();
	return null;
};
System.timer[1] = new IntervalTimer( 1.00000 / 30.0000, updateSplotches );


Here's an updated rcomage.exe with a few bugs fixed too:

ZiNgA BuRgA Wrote: [ -> ]Okay, I've gone to the effort and done it for you - hope that helps:

Javascript Code
rain = new Actor( "rain" );
offset = 0.000000;
camera = new Camera( "camera" );
rideau_pluie = new Actor( "Rideau_pluie" );
pluie = new Actor( "pluie_middle" );
reflet = new Actor( "reflet" );
flowater = new Actor( "flux" );
ruisselle = new Actor( "ruissel" );
updateRain = function(/*localvars=8*/) {
	offset = offset - 0.0250000;
	rain.uv_offset = < 0, offset >;
	ruisselle.uv_offset = < 0, offset * 0.200000 >;
	flowater.uv_offset = < 0, offset * 1.40000 >;
	pluie.uv_offset = < 0, offset >;
	rideau_pluie.uv_offset = < 0, offset * 0.550000 >;
	reflet.uv_offset = < 0, offset * 0.320000 >;
	__var1 = offset * 0.500000;
	__var2 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000;
	__var1 = offset * 0.400000 + 555.500;
	__var3 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000 * 0.500000;
	__var1 = offset * 0.300000 + 888.800;
	__var4 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000;
	camera.position = < 7.07100 + __var2, -(1.00000) + __var3, -(25.3310) + __var4 >;
	__var1 = offset * 0.200000;
	__var5 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000;
	__var1 = offset * 0.180000 + 555.500;
	__var6 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000 * 0.700000;
	__var1 = offset * 0.150000 + 888.800;
	__var7 = Math.sin( __var1 ) * 0.300000 + Math.sin( __var1 * 2.30000 ) * 0.150000 + Math.sin( __var1 * 5.00000 ) * 0.00700000;
	camera.direction = < 0.0850000 + __var5 * 0.100000, -(0.0180000) + __var6 * 0.100000, 0.850000 + __var7 * 0.100000 >;
	return null;
};
updateRain();
System.timer[0] = new IntervalTimer( 1.00000 / 60.0000, updateRain );
num_splotch = 60;
splotchs = new Array();
frames = new Array();
computeLight = function(/*localvars=8*/ __var1, __var2, __var3) {
	__var4 = __var1 - 3.20000;
	__var5 = __var2 + 5.60000;
	__var6 = __var3 + 7.60000;
	__var7 = Math.sqrt( __var4 * __var4 + __var5 * __var5 + __var6 * __var6 ) / 10.0000;
	return Math.pow( Math.max( 0.000000, 1.00000 - __var7 ), 1.40000 );
	return null;
};
randomizeSplotch = function(/*localvars=7*/ __var1) {
	__var2 = 0;
	__var3 = -(5.50000);
	__var4 = 0;
	__var5 = Math.random();
	if( __var5 < 0.700000 ) {
		__var2 = 1.50000 + Math.random() * 8.50000;
		__var4 = -(12.0000) + Math.random() * 12.0000;
	} else {
		if( __var5 < 0.950000 ) {
			__var2 = 1.70000 + Math.random() * 0.500000;
			__var4 = -(12.0000) + Math.random() * 12.0000;
		} else {
			__var2 = 1.98000 + Math.random() * 0.100000 - 0.0500000;
			__var4 = -(9.06000) + Math.random() * 0.100000 - 0.0500000;
		}
	}
	__var1.position = < __var2, __var3, __var4 >;
	__var6 = 0.700000 + Math.random() * 0.300000;
	__var1.scale = < __var6, __var6, __var6 >;
	__var1.setColor( < 1.00000, 1.00000, 1.00000, computeLight( __var2, __var3, __var4 ) >, 0.000000 );
	return null;
};
for(i = 0; i < num_splotch; i++) {
	splotchs.push( new Actor( "splotch" + i ) );
	frames.push( Math.floor( Math.random() * 8.00000 ) );
	randomizeSplotch( splotchs[i] );
}
updateSplotches = function(/*localvars=2*/) {
	for(__var1 = 0; __var1 < num_splotch; __var1++) {
		frames[__var1]++;
		if( frames[__var1] == 8 ) {
			randomizeSplotch( splotchs[__var1] );
			frames[__var1] = 0;
		}
		splotchs[__var1].uv_offset = < frames[__var1] / 8.00000, 0 >;
	}
	System.printPerf();
	return null;
};
System.timer[1] = new IntervalTimer( 1.00000 / 30.0000, updateSplotches );


Here's an updated rcomage.exe with a few bugs fixed too:


Thanks mr ZiNgA!
ZiNgA BuRgA Wrote: [ -> ]Here's an updated rcomage.exe with a few bugs fixed too:

thanks for that ;)
i was apple to make a VSMX decompiler...and it use the mnemonics used by the PSP processor ...
and it just translate the mnemonics just like Assembely, so you have to use the Javascript keywords to make your own effort (Manually) ... and it's 100% grantee ... and to prove it, anyone want send me your VSMX and i will translate it for you, for free!...

thanks
Pages: 1 2 3 4
Reference URL's