You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Similar to the name factory method #431 , a machine factory should be able to take a method which makes the initial state for a new machine.
So by example, consider a Roller Coaster Tycoon (hereafter RCT) clone. One of the issues with RCT is that you need a semi-constant stream of new customers, which might be implemented as instances of a machine. So, a name factory #431 for those customers might label them Customer ${n++}, for the developer to tell them apart (and ostensibly give different incrementing labels to the other entities in the system, like staff, rides, animals, props, furniture, garbage, and so forth,) and the data factory might give them actual names, appearance characteristics, preferences, and so forth, for purposes of gameplay
The text was updated successfully, but these errors were encountered:
Similar to the name factory method #431 , a machine factory should be able to take a method which makes the initial state for a new machine.
So by example, consider a
Roller Coaster Tycoon
(hereafter RCT) clone. One of the issues with RCT is that you need a semi-constant stream of new customers, which might be implemented as instances of a machine. So, a name factory #431 for those customers might label themCustomer ${n++}
, for the developer to tell them apart (and ostensibly give different incrementing labels to the other entities in the system, like staff, rides, animals, props, furniture, garbage, and so forth,) and the data factory might give them actual names, appearance characteristics, preferences, and so forth, for purposes of gameplayThe text was updated successfully, but these errors were encountered: