Prototypes properties ingame. (JA data-to-control thread)

Place to post guides, observations, things related to modding that are not mods themselves.
Post Reply
User avatar
ArderBlackard
Long Handed Inserter
Long Handed Inserter
Posts: 74
Joined: Thu May 05, 2016 12:41 pm
Contact:

Prototypes properties ingame. (JA data-to-control thread)

Post by ArderBlackard »

Hello guys.
I'm a newbie to Factorio modding (luckily not to programming). I have digged through a numerous threads about "how to get the data.raw prototypes in control.lua script", and as far as I understood there is currently no way to read most of the prototypes properties during the game (e.g. in control.lua). Particulary I'm interested in vehicles parameters, but this includes many other objects stuff like animations parameters, different properties and so on. It's easy to understand why many of those properties cannot be exposed for writing (many of them are immutable even in C++ code), but why not provide them as read-only? Why can it hurt to expose all the prototypes as read-only tables, to make possible for a mod to get for example properties of all the ammo types in the game?
Perhaps it sounds more like a modding interface request, but I'm not sure, maybe this idea was already discussed and dismissed by the developers (and I've skipped it while searching the forum). So I would be grateful if anyone can enlighten me with this question. Thanks in advance!
Gib dich hin bis du Glück bist

Rseding91
Factorio Staff
Factorio Staff
Posts: 13239
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Prototypes properties ingame. (JA data-to-control thread)

Post by Rseding91 »

Adding read support takes a lot of time to ensure both it's done correct and tested to stay working.

If you've got some list of things you're looking for I can probably add in those.
If you want to get ahold of me I'm almost always on Discord.

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3700
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: Prototypes properties ingame. (JA data-to-control thread)

Post by DaveMcW »

Rseding91 wrote:Adding read support takes a lot of time.
That is a game design bug. :P

User avatar
ArderBlackard
Long Handed Inserter
Long Handed Inserter
Posts: 74
Joined: Thu May 05, 2016 12:41 pm
Contact:

Re: Prototypes properties ingame. (JA data-to-control thread)

Post by ArderBlackard »

Rseding91 wrote:If you've got some list of things you're looking for I can probably add in those.
Thanks a lot for the quick answer!
So it can be done by request. Then for now I'd better continue studying the provided API to decide exactly which parameters could be helpful for my ideas. :)
Gib dich hin bis du Glück bist

Rseding91
Factorio Staff
Factorio Staff
Posts: 13239
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Prototypes properties ingame. (JA data-to-control thread)

Post by Rseding91 »

DaveMcW wrote:
Rseding91 wrote:Adding read support takes a lot of time.
That is a game design bug. :P
Everything takes time. Even now replying to these posts takes time that I could be spending programming :P
If you want to get ahold of me I'm almost always on Discord.

Sean Mirrsen
Long Handed Inserter
Long Handed Inserter
Posts: 86
Joined: Wed Apr 27, 2016 6:30 pm
Contact:

Re: Prototypes properties ingame. (JA data-to-control thread)

Post by Sean Mirrsen »

Rseding91 wrote:
DaveMcW wrote:
Rseding91 wrote:Adding read support takes a lot of time.
That is a game design bug. :P
Everything takes time. Even now replying to these posts takes time that I could be spending programming :P
That's a life design bug. :P

You should have automated the posting process long ago. Just takes a whole heap of processor units, smart robot arms, and lubricant. Never skimp on lubricant.

Post Reply

Return to “Modding discussion”