EN
randint(3V)vcsLib manualrandint(3V)
Name

randint

A random number from the cartridge.

Synopsis
#include "vcsLib.h"

int randint(void);
Description

Every implementation uses its own generator, so you can’t rely on it to replay a game. For that you need a generator of your own with a seed.

On the bus

It doesn’t put anything on the bus.

Example
int die = randint() % 6;
Compatibility

● complete ◐ works with differences ○ exists but does nothing – missing ? no data

ImplementationBy versionNotes
Stella● 7.0● master
Gopher2600● 2022-2023● 2025-04● v0.51.0● v0.53.0● master
Test7800● 2025● v0.8.0 – v0.9.0
PlusCart and UnoCart● 2.3.15 – 2.3.28● git 2025-11● 2.3.32
Chameleon Cart● 2025-10-23
Chameleon Cart, alternative firmware● 2026-11-28
Newbroo Wild Cart and Decker? 2026
VCSIDE ACE adapter– 2026-11
vcsLib · December 2026Utilitiesrandint(3V)