diff --git a/RoloLudo.package/DicePool.class/instance/printOn..st b/RoloLudo.package/DicePool.class/instance/printOn..st new file mode 100644 index 0000000..ed0a77c --- /dev/null +++ b/RoloLudo.package/DicePool.class/instance/printOn..st @@ -0,0 +1,5 @@ +accessing +printOn: aStream + super initialize. + aStream + nextPutAll: self dice printString \ No newline at end of file diff --git a/RoloLudo.package/DicePool.class/instance/uiDiceFor..st b/RoloLudo.package/DicePool.class/instance/uiDiceFor..st new file mode 100644 index 0000000..23453f7 --- /dev/null +++ b/RoloLudo.package/DicePool.class/instance/uiDiceFor..st @@ -0,0 +1,12 @@ +accessing +uiDiceFor: aView + + | response currentRoll | + response := '' writeStream. + currentRoll := self roll. + response + nextPutAll: 'Rolls: ', currentRoll printString; cr; + nextPutAll: 'Sums: ', currentRoll sum asString. + ^ aView text + title: 'Dice'; + text: [ response contents ] \ No newline at end of file