Jump to content


Photo

new faction base


Best Answer Echo, 23 August 2020 - 11:55 AM

It's difficult to figure out what the problem is here (especially if it only works for the AI), so I explain what I would do when implementing a new base:

Save your base as castle_elvesne (for saving, it is important that you save it under the "Bases" tab so it will assign the correct ending (.bse) to the file. Save the same file again as castle_elves (also make sure the "Bases" tab is selected).

Repeat these steps for the camp file.

 

Go to the CastleFlag object, and put this in:

CastleToUnpackForFaction = Elves castle_elves ROHAN_FLAG_CASTLE_UNPACK_COST

Then, add this to the CastleFlagNE unpack thing:

CastleToUnpackForFaction = Elves castle_elvesne ROHAN_FLAG_CASTLE_UNPACK_COST

Locate the CampFlag object, add:

CastleToUnpackForFaction  = Elves  camp_elves 2000

And finally, the CampFlagNE object:

CastleToUnpackForFaction  = Elves  camp_elvesne ROHAN_FLAG_CAMP_UNPACK_COST

That should be enough to unpack the flag for you in-game if you select a starting position where the "entrance" on the camp faces northeast (as in your picture). Try if it works in-game when you select a position that faces northeast, then do the same for the other orientations. Make sure that the folder structure is this: "bases\castle_elvesne\castle_elvesne.bse". I hope this helps.. I really can't help you figuring out what the problem might be, because it sounds strange that it only unpacks for the AI and without plots.. I've not seen that before.

 

 

Optional: As you mentioned, case-sensitivity is important. You can save a file as castle_elvesne and then implement it this way. You can later decide to hex-edit the file and change the internal name to Castle_ElvesNE, but that is entirely optional and will require you to change the capitalization on the flag objects. So for now, just leave it as castle_elvesne.

Go to the full post


  • Please log in to reply
8 replies to this topic

#1 amit5530

amit5530
  • Members
  • 114 posts
  • Location:Israel

Posted 22 August 2020 - 07:54 PM

well i don't know what exactly was the solution for this problem, but i have fixed it somehow..

 

Hi everyone i have followed the tutorial from the site about adding new faction into the game.
 
I have created the following bases:
camp_elvesNE
castle_elvesNE
farm_elves
 
I have followed the tutorial step by step, but when the game start, i have no base when selecting the elves faction
 
I have tried replacing all camp_elvesNE to Camp_Rohan
and the castle_elvesNE into Caste_Rohan
 
yet still no base appear when i select the elves faction.
 
any ideas what am i missing?

 
when i play against the elves faction, the AI does have a base(although only the Keep and the camp floor)

there is a Screenshot attached at the end of the post that show the AI does have an elven base
 
 
from playertemplate.ini:
 

Spoiler

 
victorysystem.ini
Spoiler

 
 
civilianbuildings.ini:

Object CastleFlag
.
.
.
	Behavior = CastleBehavior ModuleTag_castle
		SidesAllowed = Gondor FROM_PLAYER FROM_AI FROM_SCRIPT
		SidesAllowed = Rohan FROM_PLAYER FROM_AI FROM_SCRIPT
		SidesAllowed = Mordor FROM_PLAYER FROM_AI FROM_SCRIPT
		SidesAllowed = Isengard FROM_PLAYER FROM_AI FROM_SCRIPT
		SidesAllowed = Elves FROM_PLAYER FROM_AI FROM_SCRIPT
		UseSecondaryBuildList = Yes  ; NOTE: Castles and lumber mills use Secondary Build lists. Only Camps use Primary Build lists.
	  
		UseTheNewCastleSystemInsteadOfTheClunkyBuildList = Yes
  		CastleToUnpackForFaction  = Gondor  Castle_Gondor GONDOR_FLAG_CASTLE_UNPACK_COST
  		CastleToUnpackForFaction  = Rohan  Castle_Rohan  ROHAN_FLAG_CASTLE_UNPACK_COST
  		CastleToUnpackForFaction  = Mordor  Castle_Mordor MORDOR_FLAG_CASTLE_UNPACK_COST 
  		CastleToUnpackForFaction  = Isengard  Castle_Isengard ISENGARD_FLAG_CASTLE_UNPACK_COST
		CastleToUnpackForFaction  = Elves Castle_Rohan ROHAN_FLAG_CASTLE_UNPACK_COST

Attached Thumbnails

  • sselves2.png

Edited by amit5530, 22 August 2020 - 09:29 PM.


#2 amit5530

amit5530
  • Members
  • 114 posts
  • Location:Israel

Posted 22 August 2020 - 08:53 PM

I am aware of the case-sensitive names for base files (that is why i mentioned i tried checking if the Camp_Rohan / Castle_Rohan was working) 

I have also edited the topic with additional information, the AI does have a base but only the keep itself, not the camp floor nor the camp build plots



#3 Echo

Echo

    T3A:Online

  • T3A Staff
  • 1,069 posts
  • Location:Germany
  • Projects:Lot3A
  •  ~~
  • Division:BFME
  • Job:T3A Moderator
  • Donated

Posted 23 August 2020 - 11:55 AM   Best Answer

It's difficult to figure out what the problem is here (especially if it only works for the AI), so I explain what I would do when implementing a new base:

Save your base as castle_elvesne (for saving, it is important that you save it under the "Bases" tab so it will assign the correct ending (.bse) to the file. Save the same file again as castle_elves (also make sure the "Bases" tab is selected).

Repeat these steps for the camp file.

 

Go to the CastleFlag object, and put this in:

CastleToUnpackForFaction = Elves castle_elves ROHAN_FLAG_CASTLE_UNPACK_COST

Then, add this to the CastleFlagNE unpack thing:

CastleToUnpackForFaction = Elves castle_elvesne ROHAN_FLAG_CASTLE_UNPACK_COST

Locate the CampFlag object, add:

CastleToUnpackForFaction  = Elves  camp_elves 2000

And finally, the CampFlagNE object:

CastleToUnpackForFaction  = Elves  camp_elvesne ROHAN_FLAG_CAMP_UNPACK_COST

That should be enough to unpack the flag for you in-game if you select a starting position where the "entrance" on the camp faces northeast (as in your picture). Try if it works in-game when you select a position that faces northeast, then do the same for the other orientations. Make sure that the folder structure is this: "bases\castle_elvesne\castle_elvesne.bse". I hope this helps.. I really can't help you figuring out what the problem might be, because it sounds strange that it only unpacks for the AI and without plots.. I've not seen that before.

 

 

Optional: As you mentioned, case-sensitivity is important. You can save a file as castle_elvesne and then implement it this way. You can later decide to hex-edit the file and change the internal name to Castle_ElvesNE, but that is entirely optional and will require you to change the capitalization on the flag objects. So for now, just leave it as castle_elvesne.


Edited by Echo, 23 August 2020 - 11:59 AM.

26285.png


#4 amit5530

amit5530
  • Members
  • 114 posts
  • Location:Israel

Posted 23 August 2020 - 01:01 PM

Hi Echo thank you for your reply

 

I have done as you said, now i got another weird problem, maybe you are familiar with it.

 

when i stat the game as elves, i don't see my castle floor or the caste keep, but after i recruited soldiers and cleared the fog, the castle floor and the keep is there.

 

any ideas what have i done wrong? 

Attached Thumbnails

  • elves1.png
  • elevs2.png


#5 Echo

Echo

    T3A:Online

  • T3A Staff
  • 1,069 posts
  • Location:Germany
  • Projects:Lot3A
  •  ~~
  • Division:BFME
  • Job:T3A Moderator
  • Donated

Posted 23 August 2020 - 04:34 PM

Try giving the camp/castle keep a VisionRange and ShroudClearingRange, that should fix it.


26285.png


#6 amit5530

amit5530
  • Members
  • 114 posts
  • Location:Israel

Posted 23 August 2020 - 11:10 PM

Yeah that did the job, thanks

 

another question

 

I am trying to scale the elves build plot, tried scaling it by code( the line scale = 0.7, also tried it = 0.4 nothing changed)

 

and also via the world builder, where i scaled the defense build plots to 0.6 but still no changes in game

 

any idea what could be the reason? are some objects can't be rescaled?

Object ElvenBaseDefenceFoundation
 
	SelectPortrait = BPECamp_Plot
  ; *** ART Parameters ***

	Scale = 0.7
  
	Draw = W3DScriptedModelDraw ModuleTag_Draw2
	    DefaultModelConditionState
			Model = OBBFoundationX
		End
		ModelConditionState = WORLD_BUILDER
  			Model = RBWatchTowM
  		End
		
	End
   Draw = W3DFloorDraw ModuleTag_Draw
      ModelName = EBFoundationX
  End


#7 Echo

Echo

    T3A:Online

  • T3A Staff
  • 1,069 posts
  • Location:Germany
  • Projects:Lot3A
  •  ~~
  • Division:BFME
  • Job:T3A Moderator
  • Donated

Posted 24 August 2020 - 05:10 AM

As far as I know (correct me if I'm wrong @everyone), the scale only scales the model inside the W3DScriptedModelDraw module, and does not affect the W3DFloorDraw module. At least I've not yet successfully scaled a floor. In case of the foundations, if I remember correctly, the model in the W3DScriptedModelDraw is a dummy and invisible/transparent, and it's only there so you can hover and click on the foundation in-game (because models in W3DFloorDraw can not be clicked on). So in short, I know of no way to scale a foundation properly, other than scaling it manually in a 3D-modelling program (mostly used are 3dsmax + RenX, Blender might work for you as well but I've never tried it).

 

To summarize:

 

W3DScriptedModelDraw

- clickable

- scalable

- flashes when being clicked on

- does not allow shadow to be cast on (if I remember correctly)

 

W3DFloorDraw

- not clickable

- not scalable

- ignores object flash if the main model in W3DScriptedModelDraw is clicked

- allows shadow to be cast on


26285.png


#8 amit5530

amit5530
  • Members
  • 114 posts
  • Location:Israel

Posted 24 August 2020 - 03:46 PM

I thought it might be the reason, once again Echo thanks you so much for the informative answer



#9 Echo

Echo

    T3A:Online

  • T3A Staff
  • 1,069 posts
  • Location:Germany
  • Projects:Lot3A
  •  ~~
  • Division:BFME
  • Job:T3A Moderator
  • Donated

Posted 25 August 2020 - 08:06 PM

No problem, trying to help where I can. :good:


26285.png





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users