Jump to content
Sign in to follow this  
m7600

Why are there separate xml files and directories for actors and simulation templates?

Recommended Posts

Why are there separate .xml files and directories for actors and simulation templates? Consider for example the storehouse for any civ. It requires an .xml file for the actor, and another .xml file for the simulation template. My question is, why was this designed this way? Forgive my ignorance, but wouldn't it be more practical to have only one .xml file for this instead of two?

Share this post


Link to post
Share on other sites

I don't know for sure what is the original idea behind it so I won't make assumptions (I believe @Wijitmaker might know)

What I can tell you is this. From an artist pov it makes it easier for me to separate concerns about gameplay and cosmetics. Actors can get really complicated with a lot of variants and stuff. 

  • Like 1
  • Thanks 1

Share this post


Link to post
Share on other sites

As someone who has a decent understanding of the simulation templates but a very limited knowledge of how art files are organized, I'm glad the two are separate. Smaller files are easier to keep nicely clean and tidy. Besides, it allows different templates to use the same actor, hence less duplication, and if you want to use a different actor, you only have to change a single line in your template.

  • Like 3
  • Thanks 1

Share this post


Link to post
Share on other sites
6 minutes ago, Stan` said:

I don't know for sure what is the original idea behind it so I won't make assumptions (I believe @Wijitmaker might know)

What I can tell you is this. From an artist pov it makes it easier for me to separate concerns about gameplay and cosmetics. Actors can get really complicated with a lot of variants and stuff. 

Thanks Stan and Nescio. I should say that I'm very grateful for how Pyrogenesis has been designed, it's very mod-friendly and it certainly is a joy to work with. I just didn't understand the reason for this specific issue about actors and simulations. But I absolutely love how the engine was designed in general.
 

2 minutes ago, Nescio said:

Besides, it allows different templates to use the same actor, hence less duplication, and if you want to use a different actor, you only have to change a single line in your template.

This makes a lot of sense, I hadn't thought about it in that way.

  • Like 1

Share this post


Link to post
Share on other sites

Basically the art files are for how things look, the audio files for how things sound, the simulation code for how things work, and the simulation templates for things that matter, where everything comes together.

  • Like 1

Share this post


Link to post
Share on other sites
3 minutes ago, Nescio said:

Basically the art files are for how things look, the audio files for how things sound, the simulation code for how things work, and the simulation templates for things that matter, where everything comes together.

It's a good concept, now that I see it spelled out. Better to have different files for different functions.

  • Like 1

Share this post


Link to post
Share on other sites
On 6/18/2020 at 9:30 PM, m7600 said:

My question is, why was this designed this way?

There is code loading actor from actor xml.

There is code loading entity from entity xml.

An actor is something completly different of a simulation entity. You can display an actor independantly of the simulation code for example.

There is also code loading gui thing from gui xml and many other things.

  • Like 1

Share this post


Link to post
Share on other sites
On 6/18/2020 at 1:00 PM, Nescio said:

Basically the art files are for how things look, the audio files for how things sound, the simulation code for how things work, and the simulation templates for things that matter, where everything comes together.

Yes, this is the answer.  Kind of like Actor is the physical manifestation, the Entity is the inherent essence.

Back in the day, we had something called "actor editor" which was a stand alone WYSIWYG editor that would assist in the creation and editing of the actors.  I'm not sure what happened to it?  It used to read and create and edit the actor files and format them in the correct way so that non-programming people would feel comfortable with xml files. 

https://trac.wildfiregames.com/wiki/Actors

https://trac.wildfiregames.com/wiki/Actor_Editor

Entities separated because they were the logic of what defines an object.  I always dreamed of having an entity editor that would be like a massive table that unified all of the entity xmls in one single view for easy editing and graphical assistance in helping your eye see the highs and lows of values across all entities.  Kind of a massive spreadsheet.  We had plans to make a crude simulation tool as well.  No graphics, but it would run a theoretical battle between X number of unit A vs. X number of unit B.  It would quickly crunch the outcome of which unit A or B would come out on top.  These were just tools that were going to assist with balancing.

https://trac.wildfiregames.com/wiki/Entity

 

 

 

  • Like 2
  • Thanks 1

Share this post


Link to post
Share on other sites

@Wijitmaker Thank you very much, that was very informative.

1 hour ago, Wijitmaker said:

so that non-programming people would feel comfortable with xml files. 

I celebrate this kind of mentality, I think it really helps a project grow. It is evident that this engine and game have been made with that mentality, very modification-friendly. IMHO, any feature that makes things easier for a non-programming person is always a really good thing.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...