player control||doc135328

September 20, 2022

PlayerControl

Introduction

PlayerControl (player controller) is the most important class for players to control the behavior of entity objects in the game. It realizes the function of obtaining input data from the player and converting them into game actions, which essentially represents the player's willingness to operate.


Properties

Entity entity

The client entity controlled by the current player controller

boolean enable

Can the current player controller control the entity


Function

void attach (  Entity entity  )

Sets the entity object controlled by the current player controller

boolean jump (  )

make the control entity jump