@@ -163,16 +163,38 @@ end;
163163{$H+}
164164
165165(*
166- ## TRSPrayerForm Selected
166+ ## TRSPrayerForm. Selected
167167```pascal
168168property TRSPrayerForm.Selected(prayers: TRSPrayerSet);
169+ property TRSPrayerForm.Selected: TRSPrayerSet;
169170```
170- Set's the defined prayers as the set of selected prayers.
171- Useful for saving user settings between sessions. Selected prayers from a previous
172- session could be saved and then reset on the next session by setting them
173- with the procedure upon building the form.
171+ Get/Set the defined prayers as a set of selected prayers.
174172
175- Example:
173+ Useful for saving user settings between sessions.
174+
175+ Selected prayers from a previous session could be saved and then reset on the
176+ next session by setting them with the procedure upon building the form.
177+
178+ Getting example:
179+ ```pascal
180+ {$I WaspLib/osrs.simba}
181+
182+ var
183+ form: TScriptForm;
184+ tab: TTabSheet;
185+ prayerForm: TRSPrayerForm;
186+
187+ begin
188+ form.Setup('Script settings');
189+ tab := TLazTabSheet.Create(form.PageControl);
190+ prayerForm.Setup(tab, 50, 50);
191+ prayerForm.SetAllowedPrayers([ERSPrayer.EAGLE_EYE, ERSPrayer.RIGOUR]);
192+ form.Run();
193+ WriteLn(prayerForm.Selected);
194+ end.
195+ ```
196+
197+ Setting example:
176198```pascal
177199{$I WaspLib/osrs.simba}
178200
@@ -206,32 +228,6 @@ begin
206228 Self._Select(prayer);
207229end;
208230
209- (*
210- ## TRSPrayerForm Selected
211- ```pascal
212- property TRSPrayerForm.Selected(prayers: TRSPrayerSet);
213- ```
214- Get's the currently selected prayers.
215-
216- Example:
217- ```pascal
218- {$I WaspLib/osrs.simba}
219-
220- var
221- form: TScriptForm;
222- tab: TTabSheet;
223- prayerForm: TRSPrayerForm;
224-
225- begin
226- form.Setup('Script settings');
227- tab := TLazTabSheet.Create(form.PageControl);
228- prayerForm.Setup(tab, 50, 50);
229- prayerForm.SetAllowedPrayers([ERSPrayer.EAGLE_EYE, ERSPrayer.RIGOUR]);
230- form.Run();
231- WriteLn(prayerForm.Selected);
232- end.
233- ```
234- *)
235231property TRSPrayerForm.Selected: TRSPrayerSet;
236232begin
237233 Result := Self.SelectedPrayers;
0 commit comments