Problem with rep_fly_gunship_sc.odf and two new questions

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Guepard

Problem with rep_fly_gunship_sc.odf and two new questions

Post by Guepard »

I am doing a not space map.

Why if I put
ReadDataFile("dc:SIDE\\rep.lvl",
"rep_fly_gunship_sc")
the game crashes while the map is loading?

I copy assets/sides/rep to Data_XXX/Sides/ and munge rep. I don't modify de rep_fly_gunship_sc.odf.




For don't do another post I use this post for another two questions
-I edited two ATTE but how can I put the two edited ATTE in the same map with diferents skins?

-In multiplayer my map runs good for the person who makes the game, but the game crashes to the another people after charge the map.
Where can be the problem?
Last edited by Guepard on Mon May 21, 2007 12:53 pm, edited 2 times in total.
The_Emperor
Supreme Galactic Ruler
Posts: 2118
Joined: Sat Dec 10, 2005 6:30 am
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Waaaaay over there.

RE: Problem with rep_fly_gunship_sc.odf

Post by The_Emperor »

post the rest of the LUA
Guepard

Post by Guepard »

Thanks for help me. The rare thing is that if I put "rep_fly_gunship_sc" in ReadDataFile("SIDE\\rep.lvl", the map runs good.
The Lua:
Hidden/Spoiler:
-- load the gametype script
ScriptCB_DoFile("ObjectiveConquest")
ScriptCB_DoFile("setup_teams")

-- REP Attacking (attacker is always #1)
REP = 1;
CIS = 2;
-- These variables do not change
ATT = REP;
DEF = CIS;


function ScriptPostLoad()


--This defines the CPs. These need to happen first
cp1 = CommandPost:New{name = "cp1"}
cp2 = CommandPost:New{name = "cp2"}
cp3 = CommandPost:New{name = "cp3"}
cp4 = CommandPost:New{name = "cp4"}
cp5 = CommandPost:New{name = "cp5"}
cp6 = CommandPost:New{name = "cp6"}
cp7 = CommandPost:New{name = "cp7"}



--This sets up the actual objective. This needs to happen after cp's are defined
conquest = ObjectiveConquest:New{teamATT = ATT, teamDEF = DEF,
textATT = "game.modes.con",
textDEF = "game.modes.con2",
multiplayerRules = true}

--This adds the CPs to the objective. This needs to happen after the objective is set up
conquest:AddCommandPost(cp1)
conquest:AddCommandPost(cp2)
conquest:AddCommandPost(cp3)
conquest:AddCommandPost(cp4)

conquest:Start()
SetUberMode(1);
EnableSPHeroRules()

end


---------------------------------------------------------------------------
-- FUNCTION: ScriptInit
-- PURPOSE: This function is only run once
-- INPUT:
-- OUTPUT:
-- NOTES: The name, 'ScriptInit' is a chosen convention, and each
-- mission script must contain a version of this function, as
-- it is called from C to start the mission.
---------------------------------------------------------------------------
function ScriptInit()

ReadDataFile("ingame.lvl")


SetMaxFlyHeight(120)
SetMaxPlayerFlyHeight (120)

SetMemoryPoolSize ("ClothData",20)
SetMemoryPoolSize ("Combo",50) -- should be ~ 2x number of jedi classes
SetMemoryPoolSize ("Combo::State",650) -- should be ~12x #Combo
SetMemoryPoolSize ("Combo::Transition",650) -- should be a bit bigger than #Combo::State
SetMemoryPoolSize ("Combo::Condition",650) -- should be a bit bigger than #Combo::State
SetMemoryPoolSize ("Combo::Attack",550) -- should be ~8-12x #Combo
SetMemoryPoolSize ("Combo::DamageSample",6000) -- should be ~8-12x #Combo::Attack
SetMemoryPoolSize ("Combo::Deflect",100) -- should be ~1x #combo

ReadDataFile("sound\\yav.lvl;yav1cw")
ReadDataFile("SIDE\\rep.lvl",
"rep_inf_ep3_rifleman",
"rep_inf_ep3_rocketeer",
"rep_inf_ep3_engineer",
"rep_inf_ep3_sniper",
"rep_inf_ep3_officer",
"rep_inf_ep3_jettrooper",
"rep_hover_fightertank",
"rep_hero_anakin",
"rep_hover_barcspeeder")


ReadDataFile("SIDE\\cis.lvl",
"cis_inf_rifleman",
"cis_inf_rocketeer",
"cis_inf_engineer",
"cis_inf_sniper",
"cis_inf_officer",
"cis_inf_droideka",
"cis_hero_darthmaul",
"cis_hover_aat")

ReadDataFile("dc:SIDE\\rep.lvl",
"rep_fly_gunship_sc")


ReadDataFile("SIDE\\tur.lvl",
"tur_bldg_laser",
"tur_bldg_tower")

SetupTeams{
rep = {
team = REP,
units = 120,
reinforcements = 1500,
soldier = { "rep_inf_ep3_rifleman",54, 150},
assault = { "rep_inf_ep3_rocketeer",6, 24},
engineer = { "rep_inf_ep3_engineer",6, 24},
sniper = { "rep_inf_ep3_sniper",6, 24},
officer = {"rep_inf_ep3_officer",6, 24},
special = { "rep_inf_ep3_jettrooper",6, 24},
},


cis = {
team = CIS,
units = 120,
reinforcements = 1500,
soldier = { "cis_inf_rifleman",54, 150},
assault = { "cis_inf_rocketeer",6, 24},
engineer = { "cis_inf_engineer",6, 24},
sniper = { "cis_inf_sniper",6, 24},
officer = {"cis_inf_officer",6, 24},
special = { "cis_inf_droideka",6, 24},
}
}

SetHeroClass(CIS, "cis_hero_darthmaul")
SetHeroClass(REP, "rep_hero_anakin")


-- Level Stats
-- ClearWalkers()
AddWalkerType(0, 40) -- special -> droidekas
AddWalkerType(1, 0) -- 1x2 (1 pair of legs)
AddWalkerType(2, 0) -- 2x2 (2 pairs of legs)
AddWalkerType(3, 0) -- 3x2 (3 pairs of legs)
local weaponCnt = 1024
SetMemoryPoolSize("Aimer", 75)
SetMemoryPoolSize("AmmoCounter", weaponCnt)
SetMemoryPoolSize("BaseHint", 1024)
SetMemoryPoolSize("EnergyBar", weaponCnt)
SetMemoryPoolSize("EntityCloth", 32)
SetMemoryPoolSize("EntityFlyer", 512)
SetMemoryPoolSize("EntityHover", 32)
SetMemoryPoolSize("EntityLight", 200)
SetMemoryPoolSize("EntitySoundStream", 4)
SetMemoryPoolSize("EntitySoundStatic", 32)
SetMemoryPoolSize("MountedTurret", 32)
SetMemoryPoolSize("Navigator", 128)
SetMemoryPoolSize("Obstacle", 1024)
SetMemoryPoolSize("PathNode", 1024)
SetMemoryPoolSize("SoundSpaceRegion", 64)
SetMemoryPoolSize("TreeGridStack", 1024)
SetMemoryPoolSize("UnitAgent", 128)
SetMemoryPoolSize("UnitController", 128)
SetMemoryPoolSize("Weapon", weaponCnt)

SetMemoryPoolSize("CommandFlyer", 2)



SetSpawnDelay(10.0, 0.25)
--ReadDataFile("dc:GBF\\GBF.lvl", "GBF_conquest")
ReadDataFile("dc:GBF\\GBF.lvl", "GBF_conquest")
SetDenseEnvironment("false")




-- Sound

SetSoundEffect("ScopeDisplayZoomIn", "binocularzoomin")
SetSoundEffect("ScopeDisplayZoomOut", "binocularzoomout")

voiceSlow = OpenAudioStream("sound\\global.lvl", "rep_unit_vo_slow")
AudioStreamAppendSegments("sound\\global.lvl", "cis_unit_vo_slow", voiceSlow)
AudioStreamAppendSegments("sound\\global.lvl", "global_vo_slow", voiceSlow)

voiceQuick = OpenAudioStream("sound\\global.lvl", "rep_unit_vo_quick")
AudioStreamAppendSegments("sound\\global.lvl", "cis_unit_vo_quick", voiceQuick)

OpenAudioStream("sound\\global.lvl", "cw_music")
-- OpenAudioStream("sound\\global.lvl", "global_vo_quick")
-- OpenAudioStream("sound\\global.lvl", "global_vo_slow")
OpenAudioStream("sound\\yav.lvl", "yav1")
OpenAudioStream("sound\\yav.lvl", "yav1")
OpenAudioStream("sound\\yav.lvl", "yav1_emt")

SetBleedingVoiceOver(REP, REP, "rep_off_com_report_us_overwhelmed", 1)
SetBleedingVoiceOver(REP, CIS, "rep_off_com_report_enemy_losing", 1)
SetBleedingVoiceOver(CIS, REP, "cis_off_com_report_enemy_losing", 1)
SetBleedingVoiceOver(CIS, CIS, "cis_off_com_report_us_overwhelmed", 1)

SetOutOfBoundsVoiceOver(2, "cisleaving")
SetOutOfBoundsVoiceOver(1, "repleaving")

SetAmbientMusic(REP, 1.0, "rep_yav_amb_start", 0,1)
SetAmbientMusic(REP, 0.8, "rep_yav_amb_middle", 1,1)
SetAmbientMusic(REP, 0.2, "rep_yav_amb_end", 2,1)
SetAmbientMusic(CIS, 1.0, "cis_yav_amb_start", 0,1)
SetAmbientMusic(CIS, 0.8, "cis_yav_amb_middle", 1,1)
SetAmbientMusic(CIS, 0.2, "cis_yav_amb_end", 2,1)

SetVictoryMusic(REP, "rep_yav_amb_victory")
SetDefeatMusic (REP, "rep_yav_amb_defeat")
SetVictoryMusic(CIS, "cis_yav_amb_victory")
SetDefeatMusic (CIS, "cis_yav_amb_defeat")

SetSoundEffect("ScopeDisplayZoomIn", "binocularzoomin")
SetSoundEffect("ScopeDisplayZoomOut", "binocularzoomout")
--SetSoundEffect("BirdScatter", "birdsFlySeq1")
--SetSoundEffect("WeaponUnableSelect", "com_weap_inf_weaponchange_null")
--SetSoundEffect("WeaponModeUnableSelect", "com_weap_inf_modechange_null")
SetSoundEffect("SpawnDisplayUnitChange", "shell_select_unit")
SetSoundEffect("SpawnDisplayUnitAccept", "shell_menu_enter")
SetSoundEffect("SpawnDisplaySpawnPointChange", "shell_select_change")
SetSoundEffect("SpawnDisplaySpawnPointAccept", "shell_menu_enter")
SetSoundEffect("SpawnDisplayBack", "shell_menu_exit")


--OpeningSateliteShot
AddCameraShot(0.908386, -0.209095, -0.352873, -0.081226, -45.922508, -19.114113, 77.022636);

AddCameraShot(-0.481173, 0.024248, -0.875181, -0.044103, 14.767292, -30.602322, -144.506851);
AddCameraShot(0.999914, -0.012495, -0.004416, -0.000055, 1.143253, -33.602314, -76.884430);
AddCameraShot(0.839161, 0.012048, -0.543698, 0.007806, 19.152437, -49.802273, 24.337317);
AddCameraShot(0.467324, 0.006709, -0.883972, 0.012691, 11.825212, -49.802273, -7.000720);
AddCameraShot(0.861797, 0.001786, -0.507253, 0.001051, -11.986043, -59.702248, 23.263165);
AddCameraShot(0.628546, -0.042609, -0.774831, -0.052525, 20.429928, -48.302277, 9.771714);
AddCameraShot(0.765213, -0.051873, 0.640215, 0.043400, 57.692474, -48.302277, 16.540724);
AddCameraShot(0.264032, -0.015285, -0.962782, -0.055734, -16.681797, -42.902290, 129.553268);
AddCameraShot(-0.382320, 0.022132, -0.922222, -0.053386, 20.670977, -42.902290, 135.513001);
end
The_Emperor
Supreme Galactic Ruler
Posts: 2118
Joined: Sat Dec 10, 2005 6:30 am
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Waaaaay over there.

Post by The_Emperor »

hmm yeah LUA looks ok to me...

What did you change to the rep_fly_gunship_sc if you didn't change the odf? The skin?

Are you sure you copied all files you need for the gunship to your new rep folder? You didn't forget to copy the weapons or something like that?

There must be something wrong with your new gunship if the normal one works....
MercuryNoodles
Jedi
Jedi
Posts: 1003
Joined: Sun Mar 12, 2006 7:16 pm
Projects :: Space - Boarding Action
xbox live or psn: No gamertag set

Post by MercuryNoodles »

SetMemoryPoolSize("CommandFlyer", 2)

Add that to your memory pools, using whatever value you want. (that's straight out of my own lua, so you can ignore the "2". :P ) That should clear up the error.
Guepard

Post by Guepard »

I don't change anything of odf. I copy the folder assets/sides/REP to data_GBF/sides/
MercuryNoodles
Jedi
Jedi
Posts: 1003
Joined: Sun Mar 12, 2006 7:16 pm
Projects :: Space - Boarding Action
xbox live or psn: No gamertag set

Post by MercuryNoodles »

The gunship is a mobile CP, so it needs that. If you have a problem after adding the memory pool, then something else is also a problem.
Guepard

Post by Guepard »

But if I put
ReadDataFile("SIDE\\rep.lvl",
"rep_inf_ep3_rifleman",
"rep_inf_ep3_rocketeer",
"rep_inf_ep3_engineer",
"rep_inf_ep3_sniper",
"rep_inf_ep3_officer",
"rep_inf_ep3_jettrooper",
"rep_hover_fightertank",
"rep_hero_anakin",
"rep_fly_gunship_sc"
"rep_hover_barcspeeder")

the map runs good.


EDIT
I munged rep but it is not new because is the same rep of assets/sides/rep. How can I see the error log?

I only kwown the PC_MungeLog.txt but I don't known the error log



New question:
How can I put two edited ATTE with diferents skins?
Last edited by Guepard on Fri May 18, 2007 4:07 am, edited 1 time in total.
{JT}Tim
Private Recruit
Posts: 29
Joined: Sun Mar 12, 2006 10:57 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set

Post by {JT}Tim »

how many gunships are you using?
Guepard

Post by Guepard »

Only one.

EDIT
It is impossible, the BF2_modtools.exe says to me Inset CD 1, but I have DVD XD.

Another question: In multiplayer my map runs good for the person who makes the game, but the game crashes to the another people after charge the map.
Where can be the problem?
User avatar
trainmaster611
Sith Lord
Sith Lord
Posts: 1779
Joined: Thu Aug 24, 2006 5:22 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Building a railway to Coruscant
Contact:

Post by trainmaster611 »

To make two different ATTE's is kind of complicated :? You basically have to make a copy of rep_walk_atte.odf and all of the attatched files to My Documents. There add "2" to the end of everyone of the files (such as rep_walk_atte2). This basically creates a new vehicle for you. Move the files back to data_ABC/sides/rep and into their corresponding folders. Then go into the rep_walk_atte2.odf folder and change the texture line to the name of your new TGA file.

Sorry if that was too complicated to translate :?

*Briefly Edited By Qdin*
Guepard

Post by Guepard »

I don't put anything in the folder build.

I do two diferents ATTE and it is very easly, you can use rep_walk_atte_nospawn.odf XDDDDD, but the problem is the skin. I try changing GeometryName = "rep_walk_atte2.msh" and coping rep_walk_atte.msh.option--> rep_walk_atte2.msh.option and I edited changing
-bump Rep_walk_sixleg2

I create a rep_walk_sixleg2.tga, rep_walk_sixleg_bump2.tga,rep_walk_sixleg_bump2...

but the two ATTE use the rep_walk_sixleg.tga.

EDIT
You are not understanding my problem XD.
The two ATTE runs good in the map, but I don't known how to put two skins, the two ATTE use the same skin. How can I put two diferents skins?

THE TWO ATTE RUNS GOOD, the problem is not how to make two attes, THE PROBLEM IS HOW TO PUT TWO DIFERENT SKINS FOR EACH ATTE.
The_Emperor
Supreme Galactic Ruler
Posts: 2118
Joined: Sat Dec 10, 2005 6:30 am
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Waaaaay over there.

Post by The_Emperor »

You'd neet to make 2 mshs, each calling for different skins, and 2 odfs, each calling for different mshs
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Adding 2 ATTE walkers with different textures to your map

Post by AceMastermind »

They use the same texture because they both use the same mesh.

Copy the mesh and rename it.

Copy the ODF and rename it.

Change the name of the called mesh in your renamed ODF to what your new ATTE mesh name is.

Add the name of your new walker ODF into the lvl req file in your side.

Then create a new class req file for your new walker and place it in your req folder.

Open the renamed mesh file with a hex editor and just overwrite (not delete) at least 1 letter in the tga name that is called in the mesh.(press ctrl+F to search for tga in your hex editor)

Rename your custom texture file exactly what you called it when you hex edited it.

Launch ZE and change the name of the walker to spawn for the vehicle spawn to your new walker ODF name, save and close ZE.

Add the new walker name to the side that it loads from in the LUA.

Add it to the walker type section in the LUA and/or commandwalker memory pool if necessary.

Close/save LUA, then munge default common and your side containing the new walker in the side drop down menu.

Go play!
Guepard

Post by Guepard »

Ok, I need a hex editor. vERY VERY VERY thanks.
Caleb1117
2008 Most Original Avatar
Posts: 3096
Joined: Sun Aug 20, 2006 5:55 pm
Projects :: No Mod project currently.
xbox live or psn: No gamertag set
Location: X-Fire: caleb1117 ಠ_ಠ

Post by Caleb1117 »

A good hex editor that both teancum, and now I use is frhed.
Guepard

Post by Guepard »

VERY THANKS, I EDITED AN IT RUNS

VERY VERY THANKS!
Master Fionwë
Rebel Colonel
Rebel Colonel
Posts: 598
Joined: Wed May 30, 2007 3:33 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: At RCTC
Contact:

Post by Master Fionwë »

You know, I was wondering how the heck guys did that in some maps, with the two vehicles with different skins. That's nice to know. Make sure that all the weapons are present in the side for the laat, because I encountered the same problem with my atte. I was missing the weapons, and so the game crashed everytime I went into a map with the atte.


EDIT
I just thought of another way to get two attes with different skins, place one in the rep side, and the other in the cis side, then replace the skin with the one you want to use in either rep or cis, and then you have two different looking attes.
t551
General
General
Posts: 791
Joined: Sat Jul 16, 2005 3:23 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set

Post by t551 »

I don't think that would work (Maybe I'm wrong) but the way Fred's been talking about it, the game puts assets into an "assets pool" as it loads them, and the later mesh would probably replace the first in the pool as it was loaded later.
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Clarifying why you need to hex edit one mesh

Post by AceMastermind »

Master Fionwë wrote:I just thought of another way to get two attes with different skins, place one in the rep side, and the other in the cis side, then replace the skin with the one you want to use in either rep or cis, and then you have two different looking attes.
But they would still be using the same mesh, thus calling for the same texture, you would still need to copy and rename the files for one of the ATTEs and then hex edit the .msh file for one of the ATTEs to call for a custom texture.
Post Reply