Case Hosting
3 nodes
On this page 3
Capture Case
FunctionDraws one of the case's screens with no display, and gives back the picture.
Signature
CaptureCase -> Pixel Image
crimeCase: CrimeProject
screen: Case Screen
width: Integer
height: IntegerPixelImage CaptureCase(
CrimeProject crimeCase,
CaseScreen screen = CaseScreen.Menu,
int width = 1280,
int height = 800)Parameters
| name | type | default | description |
|---|---|---|---|
| crimeCase | CrimeProject | — | A case, from CaseAuthoring.OpenCase. |
| screen | Case Screen | Menu | Which screen to draw. |
| width | Integer | 1280 | Surface width in pixels. |
| height | Integer | 800 | Surface height in pixels. |
Returns
| result | Pixel Image |
Remarks
Settled before it is read: the host is pumped until nothing is animating, so the frame is the screen at rest rather than a frame caught part-way into a fade. The splash is the exception and is held mid-card on purpose, because a splash at rest is a splash that has already finished.
- Ships with
- Divooka ExploreDivooka Compute
- Graph kinds
- Events Routine StateMachineState
- Declared by
- Case Hosting
- Package
- Crime Engine
Capture Case To File
FunctionDraws one of the case's screens and writes it to a file.
Signature
CaptureCaseToFile -> Text
crimeCase: CrimeProject
imagePath: Text
screen: Case Screen
width: Integer
height: Integerstring CaptureCaseToFile(
CrimeProject crimeCase,
string imagePath,
CaseScreen screen = CaseScreen.Menu,
int width = 1280,
int height = 800)Parameters
| name | type | default | description |
|---|---|---|---|
| crimeCase | CrimeProject | — | A case, from CaseAuthoring.OpenCase. |
| imagePath | Text | — | Where to write the PNG. |
| screen | Case Screen | Menu | Which screen to draw. |
| width | Integer | 1280 | Surface width in pixels. |
| height | Integer | 800 | Surface height in pixels. |
Returns
| result | Text |
- Ships with
- Divooka ExploreDivooka Compute
- Graph kinds
- Events Routine StateMachineState
- Declared by
- Case Hosting
- Package
- Crime Engine
Play Case
FunctionOpens a case in a window and plays it, returning when the window closes.
Signature
PlayCase
crimeCase: CrimeProject
openAt: Case Screen
fullScreen: Truth
width: Integer
height: Integervoid PlayCase(
CrimeProject crimeCase,
CaseScreen openAt = CaseScreen.Menu,
bool fullScreen = false,
int width = 1280,
int height = 800)Parameters
| name | type | default | description |
|---|---|---|---|
| crimeCase | CrimeProject | — | A case, from CaseAuthoring.OpenCase. |
| openAt | Case Screen | Menu | Which screen to open on. |
| fullScreen | Truth | False | Whether to open full screen. |
| width | Integer | 1280 | Window width, which a full-screen host replaces immediately. |
| height | Integer | 800 | Window height. |
Remarks
Blocks for as long as somebody is playing, which is what a window is. A graph that wants a picture rather than a session wants CaseHosting.CaptureCase.
- Ships with
- Divooka ExploreDivooka Compute
- Graph kinds
- Events Routine StateMachineState
- Declared by
- Case Hosting
- Package
- Crime Engine