Page 1 of 7

Simple property requests (something that exists but has no way to read/write it)

Posted: Tue May 09, 2017 9:41 pm
by Rseding91
This is a centralized place to post simple property requests for things that already exist in the game but the API doesn't provide support to read (and sometimes write).

If you could please post the requests in the following format that would work great to track completion:

Example:
turret_range - the range of a turret entity prototype
Then as I add them I'll edit your posts and add strike-through to indicate I've finished it (as to not add clutter with a lot of replies).

NOTE: this is not meant for things like "add a method that returns the result of mining an entity (the items in the entity and the item that was the entity) so we don't need to calculate it" - those kinds of requests will get moved to the standard mod interface requests or just deleted from here. This is meant as a simple way to see what's still missing property wise that the game already has but just isn't in the API.

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Tue May 09, 2017 10:59 pm
by Nexela
luaEntityPrototype.circuit_wire_max_distance - The max distance of the circuit wire

luaEntityPrototype.maximum_wire_distance - The maximum wire distance for electrical poles

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Wed May 10, 2017 9:33 pm
by justarandomgeek
LuaEntity.color - for type=lamp, read color chosen by circuit network signals

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Wed May 10, 2017 9:53 pm
by justarandomgeek
LuaRailSignalControlBehavior.close_signal - if "Close signal" is selected
LuaRailSignalControlBehavior.circuit_condition - Closed condition
LuaRailSignalControlBehavior.read_signal - if "Read signal" is selected
LuaRailSignalControlBehavior.closed_output_signal - red output signal
LuaRailSignalControlBehavior.reserved_output_signal - orange output signal
LuaRailSignalControlBehavior.open_output_signal - green output signal

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Thu May 11, 2017 4:34 am
by zanven
LuaTrainStopControlBehavior.enable_disable_value - current value of the circuit network condition for enable_disable (number)

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Thu May 11, 2017 11:20 am
by Earendel
These are the ones from the other thread:

resource.normal
resource.infinite_depletion_amount
resource.minable.required_fluid
resource.minable.fluid_amount

gun.attack_parameters.gun_center_shift
gun.attack_parameters.gun_barrel_length

ammo.ammo_type ... created_effect -> created_effects
ammo.ammo_type ... target_effect -> target_effects

car.effectivity
car.consumption
car.weight
car.friction
car.braking_power
car.tank_driving
car.rotation_speed
car.turret_rotation_speed -- or car.turret.rotation_speed
car.turret_animation -- since this is just to check if it actually has a turret, car.has_turret might be better
car.guns
car.animation.layers[].animation_speed -- I know this is a long shot

*.icon
*.icon[] -- getting layers of icons
*.icon[].tint -- can then get the tint of an icon layer, useful to add correctly coloured effects

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Thu May 11, 2017 5:58 pm
by Helfima
luaEntityPrototype.mining_speed - Mining speed of the miner
luaEntityPrototype.mining_power - Mining power of the miner

luaEntityPrototype.energy_usage - The energy usage of the assembler

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Thu May 11, 2017 6:38 pm
by Rseding91
zanven wrote:LuaTrainStopControlBehavior.enable_disable_value - current value of the circuit network condition for enable_disable (number)
That's available through the circuit_condition on the behavior.

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Thu May 11, 2017 6:42 pm
by steinio
LuaSurface -> darkness (currently read-only)

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Thu May 11, 2017 7:04 pm
by Rseding91
steinio wrote:LuaSurface -> darkness (currently read-only)
Darkness is a factor of daytime right now. There are plans to re-work daytime to support darkness independently but right now that's how it is.

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Fri May 12, 2017 7:30 pm
by sparr
LuaEntity properties for all of the optional type-specific parameters to LuaSurface.create_entity. (please reply if you want me to enumerate them)

This is to facilitate cloning existing entities.

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Fri May 12, 2017 8:22 pm
by Rseding91
sparr wrote:LuaEntity properties for all of the optional type-specific parameters to LuaSurface.create_entity. (please reply if you want me to enumerate them)

This is to facilitate cloning existing entities.
They already exist or can't be changed once an entity is created.

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Fri May 12, 2017 8:30 pm
by sparr
Rseding91 wrote:
sparr wrote:LuaEntity properties for all of the optional type-specific parameters to LuaSurface.create_entity. (please reply if you want me to enumerate them)

This is to facilitate cloning existing entities.
They already exist
I can't find projectile speed or container red bar location as existing properties. I haven't looked for all the rest yet.
Rseding91 wrote: or can't be changed once an entity is created.
The ones that can't be changed once an entity is created, I want to pass to create_entity to make a new entity, not write to an existing entity. They would be [R]eadonly properties.

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Fri May 12, 2017 11:24 pm
by Rseding91

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Sun May 14, 2017 6:03 am
by gheift
Access to the flamethrower internal fluid buffer, not the fluidbox.

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Sun May 14, 2017 3:49 pm
by 321freddy
For use with gun turrets:
LuaEntityPrototype.attack_parameters
Or if not possible: LuaEntityPrototype.ammo_category

LuaBurner.fuel_category

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Sun May 14, 2017 4:21 pm
by sparr
I am reversing my suggestion leading to the creation of this thread. I no longer believe it to be a good idea.

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Mon May 15, 2017 11:37 am
by Earendel
logistic-robot/construction-robot prototype:
speed
speed_multiplier_when_out_of_energy
max_payload_size
energy_per_move
energy_per_tick
max_energy
min_to_charge
max_to_charge

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Mon May 15, 2017 5:29 pm
by sparr
Should I enumerate the luaentity properties needed for surface.create_entity here one-per-line for easy response/strikethrough?

Re: Simple property requests (something that exists but has no way to read/write it)

Posted: Mon May 15, 2017 6:29 pm
by Rseding91
sparr wrote:Should I enumerate the luaentity properties needed for surface.create_entity here one-per-line for easy response/strikethrough?
Sure.