78 lines
2.0 KiB
Plaintext
Executable File
78 lines
2.0 KiB
Plaintext
Executable File
----
|
|
-- File:: rpf6_build.rbs
|
|
-- Description:: Build RPF6 file for testing.
|
|
--
|
|
-- Author:: David Muir <david.muir@rockstarnorth.com>
|
|
-- Date:: 27 September 2010
|
|
--
|
|
|
|
-----------------------------------------------------------------------------
|
|
-- Uses
|
|
-----------------------------------------------------------------------------
|
|
-- None
|
|
|
|
-----------------------------------------------------------------------------
|
|
-- File Globals
|
|
-----------------------------------------------------------------------------
|
|
local compress = false
|
|
local temp_dir = "c:\\temp\\"
|
|
local mount_point = "pack:/"
|
|
|
|
-----------------------------------------------------------------------------
|
|
-- Functions
|
|
-----------------------------------------------------------------------------
|
|
|
|
--
|
|
-- Parse any unit test option command line parameters.
|
|
--
|
|
function set_parameters( )
|
|
|
|
in_compress = get_param( "compress" )
|
|
if ( in_compress ~= nil ) then
|
|
compress = ( "true" == in_compress )
|
|
end
|
|
|
|
print( "Test Parameters" )
|
|
if ( compress ) then
|
|
print( "compress = true" )
|
|
else
|
|
print( "compress = false" )
|
|
end
|
|
end
|
|
|
|
--
|
|
-- Build test RPF6 file.
|
|
--
|
|
function build_rpf( filename )
|
|
|
|
-- Build
|
|
local build_start = os.clock()
|
|
if ( compress ) then
|
|
start_pack()
|
|
else
|
|
start_uncompressed_pack()
|
|
end
|
|
|
|
add_to_pack( "x:\\gta5\\build\\dev\\ps3\\textures\\axistut.ctd" )
|
|
add_to_pack( "x:\\gta5\\build\\dev\\ps3\\textures\\binoculars.ctd" )
|
|
add_to_pack( "x:\\gta5\\build\\dev\\common\\data\\scenarios.xml" )
|
|
add_to_pack( "x:\\gta5\\build\\dev\\common\\data\\stockshake.txt" )
|
|
save_pack( "x:\\testrpf7.rpf" )
|
|
close_pack()
|
|
local build_duration = ( os.clock() - build_start )
|
|
|
|
return build_duration
|
|
end
|
|
|
|
|
|
-----------------------------------------------------------------------------
|
|
-- Entry-Point
|
|
-----------------------------------------------------------------------------
|
|
|
|
set_parameters()
|
|
create_leadingpath( temp_dir .. "blah.txt" )
|
|
|
|
build_rpf( rpf_filename )
|
|
|
|
-- rpf6_build.rbs
|