Page 1 of 1

Custom Era problem [Solved]

Posted: Tue Oct 21, 2014 10:39 am
by 15Cyber
I'm trying to add a new era for the Stock map of Mygeeto, but every time the game crashes when I start the level. I need help finding my mistake :(

Here is my BFront2:
Hidden/Spoiler:
[code]Opened logfile BFront2.log 2014-10-21 1232
shell_interface: Entered
shell_interface: gPlatformStr, gOnlineServiceStr, gLangStr, gLangEnum: PC GameSpy english 0
ifs_era_handler - Entered
ifs_era_handler - Exited
shell_interface: No custom_gc_0.lvl
shell_interface: No custom_gc_1.lvl
shell_interface: No custom_gc_2.lvl
shell_interface: No custom_gc_3.lvl
shell_interface: No custom_gc_4.lvl
shell_interface: No custom_gc_5.lvl
shell_interface: No custom_gc_6.lvl
shell_interface: Found custom_gc_7.lvl
custom_gc_7: Entered
ifs_freeform_init_egc.lua
ifs_freeform_start_egc.lua
custom_gc_7: Taking control of custom_GetGCButtonList()...
custom_gc_7: Taking control of custom_PressedGCButton()...
custom_gc_7: Exited
shell_interface: No custom_gc_8.lvl
shell_interface: No custom_gc_9.lvl
shell_interface: Found custom_gc_10.lvl
custom_gc_10: Entered
custom_gc_10: No custom_gc_11.lvl. Will stop searching for any more cGC scripts.
custom_gc_10: Exited
custom_EraButtonList(): Finished building era button table Known eras buttons: 28
custom_GetGMapEras(): Finished building era table Known eras: 28
custom_GetGMapModes(): Finished building game mode table Known Modes: 39
custom_GetMPGameModeList(): Finished building game mode list table List Length: 40
custom_SetMovieLocation()
custom_gc_7: custom_GetGCButtonList(): Entered
custom_GetGCButtonList()
custom_gc_7: custom_GetGCButtonList(): Exited
custom_SetMovieLocation()
custom_GetFreeformBattleModeList(): Finished building freeform battle mode list Known Modes: 39
ingame stream movies\crawl.mvs
shell_interface: Opening movie: movies\shell.mvs
shell_interface: Leaving
Mission Checker: Entered addme
Mission Checker: addme: Now listening in on AddDownloadableContent() calls
Mission Checker: Exited addme
Found ..\..\addon\BFX\data\_LVL_PC\mission.lvl. Adding BFX's missions
Found ..\..\addon\BFX\data\_LVL_PC\mission.lvl. Adding BFX's missions
Found ..\..\addon\BDT\data\_LVL_PC\SIDE\dark.lvl. Adding DT's missions
Found ..\..\addon\BFX\data\_LVL_PC\mission.lvl. Adding BFX's missions
Found ..\..\addon\BDT\data\_LVL_PC\SIDE\dark.lvl. Adding DT's missions
prev = none iLastPage = nil
prev = texture iLastPage = 1
prev = texture iLastPage = 2
prev = texture iLastPage = 3
ifs_legal.Exit

Message Severity: 2
C:\Battlefront2\main\Battlefront2\Source\GameMovie.cpp(399)
Unable to find open movie segment shell_main

ifs_saveop_DoOps LoadFileList
ifs_saveop_DoOps LoadFileList
ifs_saveop_DoOps LoadProfile
ifs_saveop_DoOps LoadProfile
ifs_sp_campaign: Input_Accept(): Entered: _tab_instant
missionlist_ExpandMapList()
ifs_missionselect_pcMulti_fnSetMapPreview(): Defaulting index to 1
ifs_missionselect_pcMulti_fnSetMapPreview(): Stored movie name, file: preview-loop MOVIES\pre-movie
custom_CheckChangeMovies(): Update(): Time to change movies
ifs_missionselect_pcMulti_ChangeMovieFile(): MovieFile: nil
ifs_missionselect_pcMulti_ChangeMovieFile(): Closed any open movie
ifs_missionselect_pcMulti_ChangeMovieFile(): Opening movie: MOVIES\pre-movie.mvs
ifs_missionselect_pcMulti_ChangeMovieFile(): Finished opening movie
ifs_missionselect_pcMulti_fnSetMapPreview(): Stored movie name, file: preview-loop MOVIES\pre-movie
custom_CheckChangeMovies(): Update(): Time to change movies
ifs_missionselect_pcMulti_ChangeMovieFile(): MovieFile: nil
ifs_missionselect_pcMulti_ChangeMovieFile(): Same as last movie
Checkbox for check_era25 clicked
this.CurButton = check_era25
cur_button = nil
this.CurButton = check_mode1
cur_button = nil
custom_AddMapNew()
custom_printTable(): table: 0563468C
The key, value is: change table: 05A559DC
The key, value is: era_g 1
The key, value is: mode_con_e 1
The key is mapluafile, the formated value is: myg1<A>_<B>
The key, value is: bSelected 1
The key, value is: era_t 1
The key, value is: era_c 1
The key, value is: mode_ctf_c 1
The key, value is: mode_con_t 1
The key, value is: era_e 1
The key, value is: movieName preview-loop
The key, value is: mode_con_z 1
The key, value is: movieFile MOVIES\pre-movie
The key, value is: mode_con_c 1
The key, value is: era_z 1
The key, value is: mode_con_g 1
The key, value is: mode_c_c 1
The key, value is: mode_ctf_g 1
custom_printTable(): Returning
custom_printTable(): table: 05636B8C
The key, value is: key mode_con
The key, value is: subst con
The key, value is: showstr modename.name.con
The key, value is: descstr modename.description.con
The key, value is: icon mode_icon_con
custom_printTable(): Returning
gMapEras.key = era_y Era = era_y subst = y
this.CurButton = _map_add
cur_button = nil
custom_AddMapNew()
custom_printTable(): table: 0563468C
The key, value is: change table: 05A559DC
The key, value is: era_g 1
The key, value is: mode_con_e 1
The key is mapluafile, the formated value is: myg1<A>_<B>
The key, value is: bSelected 1
The key, value is: era_t 1
The key, value is: era_c 1
The key, value is: mode_ctf_c 1
The key, value is: mode_con_t 1
The key, value is: era_e 1
The key, value is: movieName preview-loop
The key, value is: mode_con_z 1
The key, value is: movieFile MOVIES\pre-movie
The key, value is: mode_con_c 1
The key, value is: era_z 1
The key, value is: mode_con_g 1
The key, value is: mode_c_c 1
The key, value is: mode_ctf_g 1
custom_printTable(): Returning
custom_printTable(): table: 05636B8C
The key, value is: key mode_con
The key, value is: subst con
The key, value is: showstr modename.name.con
The key, value is: descstr modename.description.con
The key, value is: icon mode_icon_con
custom_printTable(): Returning
gMapEras.key = era_y Era = era_y subst = y
this.CurButton = _map_add
cur_button = nil
custom_AddMapNew()
custom_printTable(): table: 0563468C
The key, value is: change table: 05A559DC
The key, value is: era_g 1
The key, value is: mode_con_e 1
The key is mapluafile, the formated value is: myg1<A>_<B>
The key, value is: bSelected 1
The key, value is: era_t 1
The key, value is: era_c 1
The key, value is: mode_ctf_c 1
The key, value is: mode_con_t 1
The key, value is: era_e 1
The key, value is: movieName preview-loop
The key, value is: mode_con_z 1
The key, value is: movieFile MOVIES\pre-movie
The key, value is: mode_con_c 1
The key, value is: era_z 1
The key, value is: mode_con_g 1
The key, value is: mode_c_c 1
The key, value is: mode_ctf_g 1
custom_printTable(): Returning
custom_printTable(): table: 05636B8C
The key, value is: key mode_con
The key, value is: subst con
The key, value is: showstr modename.name.con
The key, value is: descstr modename.description.con
The key, value is: icon mode_icon_con
custom_printTable(): Returning
gMapEras.key = era_y Era = era_y subst = y
this.CurButton = _map_add
cur_button = nil
custom_AddMapNew()
custom_printTable(): table: 0563468C
The key, value is: change table: 05A559DC
The key, value is: era_g 1
The key, value is: mode_con_e 1
The key is mapluafile, the formated value is: myg1<A>_<B>
The key, value is: bSelected 1
The key, value is: era_t 1
The key, value is: era_c 1
The key, value is: mode_ctf_c 1
The key, value is: mode_con_t 1
The key, value is: era_e 1
The key, value is: movieName preview-loop
The key, value is: mode_con_z 1
The key, value is: movieFile MOVIES\pre-movie
The key, value is: mode_con_c 1
The key, value is: era_z 1
The key, value is: mode_con_g 1
The key, value is: mode_c_c 1
The key, value is: mode_ctf_g 1
custom_printTable(): Returning
custom_printTable(): table: 05636B8C
The key, value is: key mode_con
The key, value is: subst con
The key, value is: showstr modename.name.con
The key, value is: descstr modename.description.con
The key, value is: icon mode_icon_con
custom_printTable(): Returning
gMapEras.key = era_y Era = era_y subst = y
this.CurButton = _map_add
cur_button = nil
custom_AddMapNew()
custom_printTable(): table: 0583ECE8
The key, value is: change table: 05A559DC
The key, value is: era_z 1
The key, value is: mode_con_e 1
The key is mapluafile, the formated value is: myg1<A>_<B>
The key, value is: bSelected 1
The key, value is: era_t 1
The key, value is: era_c 1
The key, value is: era_y 1
The key, value is: mode_con_t 1
The key, value is: era_e 1
The key, value is: mode_con_z 1
The key, value is: mode_con_y 1
The key, value is: era_g 1
The key, value is: mode_con_g 1
The key, value is: mode_con_c 1
The key, value is: isModLevel 1
custom_printTable(): Returning
custom_printTable(): table: 05636B8C
The key, value is: key mode_con
The key, value is: subst con
The key, value is: showstr modename.name.con
The key, value is: descstr modename.description.con
The key, value is: icon mode_icon_con
custom_printTable(): Returning
gMapEras.key = era_y Era = era_y subst = y
Adding map: myg1y_con idx: 1
Adding map: myg1y_con idx: 2
this.CurButton = _map_add
cur_button = nil
this.CurButton = Launch
cur_button = nil

Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LoadUtil.cpp(1019)
Unable to find level chunk in MISSION.lvl


Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LuaHelper.cpp(112)
OpenScript(myg1y_con): script (14c4934d) not found

Message Severity: 5
C:\Battlefront2\main\Battlefront2\Source\GameState.cpp(1283)
Could not open MISSION\myg1y_con.lvl
[/code]

Re: Custom Era problem

Posted: Tue Oct 21, 2014 12:17 pm
by AQT
Did you create a .req file for your new lua? Did you list this .req file name in your mission.req file?

Re: Custom Era problem

Posted: Tue Oct 21, 2014 12:29 pm
by 15Cyber
Yes, Here is My mission.req :
Hidden/Spoiler:
[code]ucft
{
REQN
{
"config"
"ingame_movies"
}

REQN
{
"script"
"setup_teams"
"gametype_conquest"
"gametype_capture"
"Objective"
"MultiObjectiveContainer"
"ObjectiveCTF"
"ObjectiveAssault"
"ObjectiveSpaceAssault"
"ObjectiveConquest"
"ObjectiveTDM"
"ObjectiveOneFlagCTF"
"SoundEvent_ctf"
"ObjectiveGoto"
"LinkedShields"
"LinkedDestroyables"
"LinkedTurrets"
"Ambush"
"PlayMovieWithTransition"
}

REQN
{
"lvl"
"BVPg_con"
"BVPc_con"
''BVPy_con''
''myg1y_con''
}
}[/code]

And my addme.LUA file :
Hidden/Spoiler:
[code]--Search through the missionlist to find a map that matches mapName,
--then insert the new flags into said entry.
--Use this when you know the map already exists, but this content patch is just
--adding new gamemodes (otherwise you should just add whole new entries to the missionlist)
function AddNewGameModes(missionList, mapName, newFlags)
for i, mission in missionList do
if mission.mapluafile == mapName then
for flag, value in pairs(newFlags) do
mission[flag] = value
end
end
end
end

--insert the new gamemodes or maps here for pre-existing maps:
AddNewGameModes(mp_missionselect_listbox_contents,
"myg1%s_%s",
{era_y = 1, mode_con_y = 1,})

--insert totally new maps here:
local sp_n = 0
local mp_n = 0
sp_n = table.getn(sp_missionselect_listbox_contents)

sp_missionselect_listbox_contents[sp_n+1] = { isModLevel = 1, mapluafile = "BVP%s_%s", era_g = 1, era_c = 1, era_y = 1, mode_con_g = 1, mode_con_c = 1, mode_con_y = 1,}


sp_missionselect_listbox_contents[sp_n+1] = { isModLevel = 1, mapluafile = "myg1%s_%s", era_g = 1, era_c = 1, era_y = 1, mode_con_g = 1, mode_con_c = 1, mode_con_y = 1,}

-- associate this mission name with the current downloadable content directory
-- (this tells the engine which maps are downloaded, so you need to include all new mission lua's here)
-- first arg: mapluafile from above
-- second arg: mission script name
-- third arg: level memory modifier. the arg to LuaScript.cpp: DEFAULT_MODEL_MEMORY_PLUS(x)

AddDownloadableContent("BVP","BVPg_con",4)
AddDownloadableContent("BVP","BVPc_con",4)
AddDownloadableContent("BVP","BVPy_con",4)
AddDownloadableContent("MYG1","myg1y_con",4)

-- all done
newEntry = nil
n = nil

-- Now load our core.lvl into the shell to add our localize keys
ReadDataFile("..\\..\\addon\\BVP\\data\\_LVL_PC\\core.lvl")
[/code]

Re: Custom Era problem

Posted: Tue Oct 21, 2014 1:10 pm
by Firefang
I don't think you can put two apostrophes ' ' instead of quotation marks ". Your two custom era scripts listed in your mission.req have that problem.

Re: Custom Era problem

Posted: Tue Oct 21, 2014 3:18 pm
by 15Cyber
Firefang wrote:I don't think you can put two apostrophes ' ' instead of quotation marks ". Your two custom era scripts listed in your mission.req have that problem.

thank you it works! :thumbs: you have eagle eyes, my friend :bowdown: