Difference between revisions of "MDE Scripting: GetActivePlayer"
From Nomad DB
Line 4: | Line 4: | ||
|- | |- | ||
!Module | !Module | ||
− | |[[ | + | |[[MDE Scripting: Game Library#Game|Game]] |
|- | |- | ||
!Library | !Library | ||
− | |[[ | + | |[[MDE Scripting: Game Library|Game]] |
|- | |- | ||
!Game | !Game | ||
− | |[[ | + | |[[MDE Scripting|Mafia: Definitive Edition]] |
|} | |} | ||
Line 16: | Line 16: | ||
==Description== | ==Description== | ||
Returns the [[MDE Scripting: Entities#Player|Player]] entity. | Returns the [[MDE Scripting: Entities#Player|Player]] entity. | ||
− | |||
Line 25: | Line 24: | ||
!Description | !Description | ||
|- | |- | ||
− | |1 | + | | style="font-weight: bold; text-align:center;" | 1 |
|[[MDE Scripting: Entities|Entity]] ''(C_SceneObjectLuaWrapper => player_archetype-2-)'' | |[[MDE Scripting: Entities|Entity]] ''(C_SceneObjectLuaWrapper => player_archetype-2-)'' | ||
|[[MDE Scripting: Entities#Player|Player]] entity | |[[MDE Scripting: Entities#Player|Player]] entity | ||
|} | |} | ||
− | |||
Line 36: | Line 34: | ||
local Player = game.game:GetActivePlayer() -- Player returns the player | local Player = game.game:GetActivePlayer() -- Player returns the player | ||
</syntaxhighlight> | </syntaxhighlight> | ||
− | |||
Revision as of 20:40, 17 October 2020
Syntax | game.game:GetActivePlayer()
|
---|---|
Module | Game |
Library | Game |
Game | Mafia: Definitive Edition |
Description
Returns the Player entity.
Returns
# | Type | Description |
---|---|---|
1 | Entity (C_SceneObjectLuaWrapper => player_archetype-2-) | Player entity |
Examples
local Player = game.game:GetActivePlayer() -- Player returns the player
Aliases
local Player = getp() -- Player returns the player