Skip to content

Commit

Permalink
docs: Add mssing nav
Browse files Browse the repository at this point in the history
  • Loading branch information
Panakotta00 committed Sep 6, 2024
1 parent 92bc344 commit e726b29
Show file tree
Hide file tree
Showing 2 changed files with 137 additions and 37 deletions.
143 changes: 137 additions & 6 deletions docs/modules/ROOT/nav.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,20 @@
*** xref:lua/guide/UsingReflection.adoc[7. Using Reflection]
*** xref:lua/guide/InterComputerCommunication.adoc[8. Inter Computer Communication]
** xref:lua/BasicTypes.adoc[Basic Types]
** xref:lua/api/index.adoc[APIs]
*** xref:lua/api/Component.adoc[Component API]
*** xref:lua/api/Computer.adoc[Computer API]
*** xref:lua/api/Event.adoc[Event API]
*** xref:lua/api/FileSystem.adoc[FileSystem API]
** APIs
// FINLuaDocumentationBegin *** //
*** xref:lua/api/Component.adoc[Component]
*** xref:lua/api/Computer.adoc[Computer]
*** xref:lua/api/Debug.adoc[Debug]
*** xref:lua/api/Event.adoc[Event]
*** xref:lua/api/FileSystem.adoc[FileSystem]
*** xref:lua/api/FutureModule.adoc[FutureModule]
*** xref:lua/api/ModuleSystem.adoc[ModuleSystem]
*** xref:lua/api/ReflectionSystemBaseModule.adoc[ReflectionSystemBaseModule]
*** xref:lua/api/ReflectionSystemClassModule.adoc[ReflectionSystemClassModule]
*** xref:lua/api/ReflectionSystemObjectModule.adoc[ReflectionSystemObjectModule]
*** xref:lua/api/ReflectionSystemStructModule.adoc[ReflectionSystemStructModule]
// FINLuaDocumentationEnd //
** xref:lua/examples/index.adoc[Examples]
*** xref:lua/examples/multiThreading.adoc[Multi Threading]
*** xref:lua/examples/paint.adoc[Paint]
Expand All @@ -59,6 +68,128 @@
*** xref:lua/examples/PCIDevices.adoc[PCI-Devices]
*** xref:lua/examples/InternetCard.adoc[Internet-Card]
* xref:NetworkTrace.adoc[Network Trace]
* xref:Reflection.adoc[Reflection]
* Reflection
// FINReflectionDocumentationBegin ** //
** Classes
*** xref:reflection/classes/Actor.adoc[Actor]
*** xref:reflection/classes/ActorComponent.adoc[ActorComponent]
*** xref:reflection/classes/ArrayProperty.adoc[ArrayProperty]
*** xref:reflection/classes/BigGaugeModule.adoc[BigGaugeModule]
*** xref:reflection/classes/Buildable.adoc[Buildable]
*** xref:reflection/classes/BuzzerModule.adoc[BuzzerModule]
*** xref:reflection/classes/CircuitBridge.adoc[CircuitBridge]
*** xref:reflection/classes/CircuitSwitch.adoc[CircuitSwitch]
*** xref:reflection/classes/CircuitSwitchPriority.adoc[CircuitSwitchPriority]
*** xref:reflection/classes/Class.adoc[Class]
*** xref:reflection/classes/ClassProperty.adoc[ClassProperty]
*** xref:reflection/classes/CodeableMerger.adoc[CodeableMerger]
*** xref:reflection/classes/CodeableSplitter.adoc[CodeableSplitter]
*** xref:reflection/classes/ComputerCase.adoc[ComputerCase]
*** xref:reflection/classes/DockingStation.adoc[DockingStation]
*** xref:reflection/classes/Door.adoc[Door]
*** xref:reflection/classes/EncoderModule.adoc[EncoderModule]
*** xref:reflection/classes/FINAdvancedNetworkConnectionComponent.adoc[FINAdvancedNetworkConnectionComponent]
*** xref:reflection/classes/FINComputerGPU.adoc[FINComputerGPU]
*** xref:reflection/classes/FINComputerGPUT2.adoc[FINComputerGPUT2]
*** xref:reflection/classes/FINInternetCard.adoc[FINInternetCard]
*** xref:reflection/classes/FINMediaSubsystem.adoc[FINMediaSubsystem]
*** xref:reflection/classes/FINModularIndicatorPoleModule.adoc[FINModularIndicatorPoleModule]
*** xref:reflection/classes/Factory.adoc[Factory]
*** xref:reflection/classes/FactoryConnection.adoc[FactoryConnection]
*** xref:reflection/classes/Function.adoc[Function]
*** xref:reflection/classes/GPUT1.adoc[GPUT1]
*** xref:reflection/classes/GaugeModule.adoc[GaugeModule]
*** xref:reflection/classes/IndicatorModule.adoc[IndicatorModule]
*** xref:reflection/classes/IndicatorPole.adoc[IndicatorPole]
*** xref:reflection/classes/Inventory.adoc[Inventory]
*** xref:reflection/classes/ItemCategory.adoc[ItemCategory]
*** xref:reflection/classes/ItemType.adoc[ItemType]
*** xref:reflection/classes/LargeControlPanel.adoc[LargeControlPanel]
*** xref:reflection/classes/LargeMicroDisplayModule.adoc[LargeMicroDisplayModule]
*** xref:reflection/classes/LargeVerticalControlPanel.adoc[LargeVerticalControlPanel]
*** xref:reflection/classes/LightSource.adoc[LightSource]
*** xref:reflection/classes/LightsControlPanel.adoc[LightsControlPanel]
*** xref:reflection/classes/Manufacturer.adoc[Manufacturer]
*** xref:reflection/classes/MicroDisplayModule.adoc[MicroDisplayModule]
*** xref:reflection/classes/ModularIndicatorPole.adoc[ModularIndicatorPole]
*** xref:reflection/classes/ModularIndicatorPoleModule.adoc[ModularIndicatorPoleModule]
*** xref:reflection/classes/ModuleButton.adoc[ModuleButton]
*** xref:reflection/classes/ModulePanel.adoc[ModulePanel]
*** xref:reflection/classes/ModulePotentiometer.adoc[ModulePotentiometer]
*** xref:reflection/classes/ModuleStopButton.adoc[ModuleStopButton]
*** xref:reflection/classes/ModuleSwitch.adoc[ModuleSwitch]
*** xref:reflection/classes/ModuleTextDisplay.adoc[ModuleTextDisplay]
*** xref:reflection/classes/MushroomPushbuttonModule.adoc[MushroomPushbuttonModule]
*** xref:reflection/classes/NetworkCard.adoc[NetworkCard]
*** xref:reflection/classes/NetworkRouter.adoc[NetworkRouter]
*** xref:reflection/classes/Object.adoc[Object]
*** xref:reflection/classes/ObjectProperty.adoc[ObjectProperty]
*** xref:reflection/classes/PipeConnection.adoc[PipeConnection]
*** xref:reflection/classes/PipeConnectionBase.adoc[PipeConnectionBase]
*** xref:reflection/classes/PipeHyperStart.adoc[PipeHyperStart]
*** xref:reflection/classes/PipeReservoir.adoc[PipeReservoir]
*** xref:reflection/classes/PipelinePump.adoc[PipelinePump]
*** xref:reflection/classes/PotWDisplayModule.adoc[PotWDisplayModule]
*** xref:reflection/classes/PotentiometerModule.adoc[PotentiometerModule]
*** xref:reflection/classes/PowerCircuit.adoc[PowerCircuit]
*** xref:reflection/classes/PowerConnection.adoc[PowerConnection]
*** xref:reflection/classes/PowerInfo.adoc[PowerInfo]
*** xref:reflection/classes/PowerStorage.adoc[PowerStorage]
*** xref:reflection/classes/Property.adoc[Property]
*** xref:reflection/classes/PushbuttonModule.adoc[PushbuttonModule]
*** xref:reflection/classes/RailroadSignal.adoc[RailroadSignal]
*** xref:reflection/classes/RailroadStation.adoc[RailroadStation]
*** xref:reflection/classes/RailroadSwitchControl.adoc[RailroadSwitchControl]
*** xref:reflection/classes/RailroadTrack.adoc[RailroadTrack]
*** xref:reflection/classes/RailroadTrackConnection.adoc[RailroadTrackConnection]
*** xref:reflection/classes/RailroadVehicle.adoc[RailroadVehicle]
*** xref:reflection/classes/RailroadVehicleMovement.adoc[RailroadVehicleMovement]
*** xref:reflection/classes/Recipe.adoc[Recipe]
*** xref:reflection/classes/ReflectionBase.adoc[ReflectionBase]
*** xref:reflection/classes/ResourceSink.adoc[ResourceSink]
*** xref:reflection/classes/Screen.adoc[Screen]
*** xref:reflection/classes/SignBase.adoc[SignBase]
*** xref:reflection/classes/SignType.adoc[SignType]
*** xref:reflection/classes/Signal.adoc[Signal]
*** xref:reflection/classes/SizeableModulePanel.adoc[SizeableModulePanel]
*** xref:reflection/classes/SpeakerPole.adoc[SpeakerPole]
*** xref:reflection/classes/Speakers_C.adoc[Speakers_C]
*** xref:reflection/classes/SquareMicroDisplayModule.adoc[SquareMicroDisplayModule]
*** xref:reflection/classes/Struct.adoc[Struct]
*** xref:reflection/classes/StructProperty.adoc[StructProperty]
*** xref:reflection/classes/SwitchModule2Position.adoc[SwitchModule2Position]
*** xref:reflection/classes/SwitchModule3Position.adoc[SwitchModule3Position]
*** xref:reflection/classes/TargetList.adoc[TargetList]
*** xref:reflection/classes/TimeTable.adoc[TimeTable]
*** xref:reflection/classes/TraceProperty.adoc[TraceProperty]
*** xref:reflection/classes/Train.adoc[Train]
*** xref:reflection/classes/TrainPlatform.adoc[TrainPlatform]
*** xref:reflection/classes/TrainPlatformCargo.adoc[TrainPlatformCargo]
*** xref:reflection/classes/Vehicle.adoc[Vehicle]
*** xref:reflection/classes/VehicleScanner.adoc[VehicleScanner]
*** xref:reflection/classes/WheeledVehicle.adoc[WheeledVehicle]
*** xref:reflection/classes/WidgetSign.adoc[WidgetSign]
** Structs
*** xref:reflection/structs/Color.adoc[Color]
*** xref:reflection/structs/Future.adoc[Future]
*** xref:reflection/structs/GPUT1Buffer.adoc[GPUT1Buffer]
*** xref:reflection/structs/GPUT2DrawCallBox.adoc[GPUT2DrawCallBox]
*** xref:reflection/structs/IconData.adoc[IconData]
*** xref:reflection/structs/Item.adoc[Item]
*** xref:reflection/structs/ItemAmount.adoc[ItemAmount]
*** xref:reflection/structs/ItemStack.adoc[ItemStack]
*** xref:reflection/structs/LogEntry.adoc[LogEntry]
*** xref:reflection/structs/Margin.adoc[Margin]
*** xref:reflection/structs/PrefabSignData.adoc[PrefabSignData]
*** xref:reflection/structs/RailroadSignalBlock.adoc[RailroadSignalBlock]
*** xref:reflection/structs/Rotator.adoc[Rotator]
*** xref:reflection/structs/TargetPoint.adoc[TargetPoint]
*** xref:reflection/structs/TimeTableStop.adoc[TimeTableStop]
*** xref:reflection/structs/TrackGraph.adoc[TrackGraph]
*** xref:reflection/structs/TrainDockingRuleSet.adoc[TrainDockingRuleSet]
*** xref:reflection/structs/Vector.adoc[Vector]
*** xref:reflection/structs/Vector2D.adoc[Vector2D]
*** xref:reflection/structs/Vector4.adoc[Vector4]
// FINReflectionDocumentationEnd //
* xref:ModIntegration.adoc[Mod Integration]
* xref:credits.adoc[Credits]
31 changes: 0 additions & 31 deletions docs/modules/ROOT/pages/lua/BasicTypes.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -13,37 +13,6 @@ A value of such a type is also known as `Instance` or `Reference` to a object.

You can access these functions and properties like you do in normal tables (a period `.` or array operator `[]`).

=== Additional Fields
Is a Instance additionally a network Component, which is not directly class, then it has some additional fields:

==== Nick `nick`
The `nick` field is a string field you can read and write to.
It allows you to access the nick of a component which you could also set with the network manager.
One of the main purposes is to read additional data like configurations settings per component from it.

[source,lua]
----
local comp = component.proxy(component.findComponent("machine")[1])
local fields = {}
for key, value in string.gmatch(comp.nick, "(%w+)=([^%s]+)") do
fields[key] = value
end
-- if there is now a component with the nick "machine setting1=42 setting2=meep"
-- then the fields table will look like {"setting1"="42", "setting2"="meep"}
----

==== ID `id`
The `id` is a read-only string field allowing you to read the UUID of the component.
Mainly intended allowing you to print or display the ID of a component.
For comparing/identifying components,
use the default way of comparing/identifying instances with the hash functions and properties.

[source,lua]
----
local comp = component.proxy(component.findComponent("machine")[1])
print(comp.id) -- prints the ID of the component with a nick group "machine"
----

=== Properties
Properties can be used just normally.
Tho read-only properties will cause a error when you try to assign a value to them
Expand Down

0 comments on commit e726b29

Please sign in to comment.