Task dossier

Cyberball Task

T000034T000034-cyberballDraftWeb preview availableUpdated Jun 20, 2026

Three-player virtual ball-toss paradigm for social inclusion and ostracism.

Cyberball Task flow diagram
Cyberball Task flow diagram
Preview path
This task ships with a matched HTML companion so the browser preview can stay aligned to the canonical local repository.
Quick start
Clone locally, then follow the README for install and run instructions.
git clone https://github.com/TaskBeacon/T000034-cyberball.git
cd T000034-cyberball
# Follow the README for local setup and run steps

Cyberball Task

Maturity: draft

FieldValue
NameCyberball Task
Versionv0.1.1-dev
URL / Repositoryhttps://github.com/TaskBeacon/T000034-cyberball
Short DescriptionThree-player virtual ball-toss paradigm for social inclusion and ostracism.
Created ByTaskBeacon
Date Updated2026-02-19
PsyFlow Version0.1.9
PsychoPy Version2025.1.1
ModalityBehavior
LanguageEnglish
Voice Nameen-US-AriaNeural (voice disabled by default)

1. Task Overview

This task implements Cyberball as a three-player virtual ball game based on Williams & Jarvis (2006), with one participant and two avatars. Experimental manipulation is block-level social context:

  • inclusion: avatars continue to involve the participant in toss circulation.
  • exclusion: participant is initially included, then avatars toss only to each other.

Each toss event is logged as one auditable trial to satisfy PsyFlow/TAPS trial-level runtime contracts.

2. Task Flow

Task Flow

Block-Level Flow

StepDescription
1. Block setupSelect current condition (inclusion or exclusion) and reset controller state.
2. Toss loopRun trial_per_block toss events using shared ball-holder state.
3. Block summaryShow block feedback with participant receive/turn counts.
4. CompletionShow final summary and save trial log CSV.

Trial-Level Flow

StepDescription
avatar_turnIf an avatar holds the ball, show waiting scene for randomized delay and choose next holder by condition policy.
participant_decisionIf participant holds the ball, capture f/j decision with timeout fallback policy.
toss_animationAnimate ball transfer to target holder and log toss outcome fields.

Controller Logic

ComponentDescription
Toss policyInclusion uses probabilistic avatar-to-participant passing; exclusion switches to avatar-only passing after initial receives.
Block stateTracks toss count and participant receives per block and globally.
Timeout fallbackOn missed participant decision, target is selected by configured fallback policy.

Runtime Context Phases

Phase LabelMeaning
avatar_turnAvatar holds ball and decision latency is simulated.
participant_decisionParticipant response window (f/j) when ball is at participant node.

3. Configuration Summary

a. Subject Info

FieldMeaning
subject_id3-digit participant identifier.

b. Window Settings

ParameterValue
size[1280, 720]
unitspix
screen0
bg_colorblack
fullscreenfalse
monitor_width_cm35.5
monitor_distance_cm60

c. Stimuli

Stimulus GroupDescription
participant_node, left_node, right_nodeThree-player scene nodes (participant bottom, avatars top-left/top-right).
participant_label, left_label, right_labelPlayer identity labels anchored to each node.
ballShared ball rendered and moved between holder nodes.
avatar_wait_prompt, participant_prompt, status_linePhase prompt and block-condition status overlays.
instruction_text, block_break, good_byeEntry, transition, and exit screens.

d. Timing

StageDuration
avatar decision delayuniform range from avatar_decision_delay
participant decisionparticipant_timeout
toss animationtoss_animation_duration
post-toss gapinter_toss_interval

4. Methods (for academic publication)

Participants engaged in a virtual three-player ball-toss task designed to manipulate perceived social inclusion versus ostracism. One block implemented inclusion dynamics and one block implemented exclusion dynamics. During participant-held ball states, participants selected toss targets via key responses (f/j), while avatar-held states followed condition-specific toss policies.

The implementation records one trial per toss event with explicit holder transitions, decision outcomes, timeout handling, and trigger-aligned phase context. This trialization preserves the continuous interaction character of Cyberball while enabling auditable event-level behavioral analysis.