PlayerModels are the most commonly used subtype of Model frame. They expand on the Model type by adding functions to quickly set the model to represent a particular player or creature, by unitID or creature ID.
These models are used by the stock UI for "paper doll" frames, to display a player's character, minion, vanity pets and mounts. They're also used by unit frame mods, to provide animated portraits or full-body "action figure" displays of characters and monsters.
Defined Methods
- PlayerModel:AdvanceTime() - This function is not yet documented
- PlayerModel:ClearFog() - This function is not yet documented
- PlayerModel:ClearModel() - This function is not yet documented
- PlayerModel:GetCameraDistance() - This function is not yet documented
- PlayerModel:GetCameraFacing() - This function is not yet documented
- PlayerModel:GetCameraPosition() - This function is not yet documented
- PlayerModel:GetCameraTarget() - This function is not yet documented
- PlayerModel:GetDoBlend() - This function is not yet documented
- PlayerModel:GetFacing() - This function is not yet documented
- PlayerModel:GetFogColor() - This function is not yet documented
- PlayerModel:GetFogFar() - This function is not yet documented
- PlayerModel:GetFogNear() - This function is not yet documented
- PlayerModel:GetLight() - This function is not yet documented
- PlayerModel:GetModel() - This function is not yet documented
- PlayerModel:GetModelScale() - This function is not yet documented
- PlayerModel:GetPosition() - This function is not yet documented
- PlayerModel:GetWorldScale() - This function is not yet documented
- PlayerModel:HasCustomCamera() - This function is not yet documented
- PlayerModel:RefreshCamera() - This function is not yet documented
- PlayerModel:ReplaceIconTexture() - This function is not yet documented
- PlayerModel:SetAnimation() - This function is not yet documented
- PlayerModel:SetBarberShopAlternateForm() - This function is not yet documented
- PlayerModel:SetCamDistanceScale() - This function is not yet documented
- PlayerModel:SetCamera() - This function is not yet documented
- PlayerModel:SetCameraDistance() - This function is not yet documented
- PlayerModel:SetCameraFacing() - This function is not yet documented
- PlayerModel:SetCameraPosition() - This function is not yet documented
- PlayerModel:SetCameraTarget() - This function is not yet documented
- PlayerModel:SetCustomCamera() - This function is not yet documented
- PlayerModel:SetDisplayInfo() - This function is not yet documented
- PlayerModel:SetDoBlend() - This function is not yet documented
- PlayerModel:SetFacing() - This function is not yet documented
- PlayerModel:SetFogColor() - This function is not yet documented
- PlayerModel:SetFogFar() - This function is not yet documented
- PlayerModel:SetFogNear() - This function is not yet documented
- PlayerModel:SetGlow() - This function is not yet documented
- PlayerModel:SetLight() - This function is not yet documented
- PlayerModel:SetModel() - This function is not yet documented
- PlayerModel:SetModelScale() - This function is not yet documented
- PlayerModel:SetPortraitZoom() - This function is not yet documented
- PlayerModel:SetPosition() - This function is not yet documented
- PlayerModel:SetSequence() - This function is not yet documented
- PlayerModel:SetSequenceTime() - This function is not yet documented
- PlayerModel:SetUnit("unit") - Sets the model to display the 3D model of a specific unit
Inherited Methods
- PlayerModel:GetPropagateKeyboardInput() - This function is not yet documented
- PlayerModel:IsForbidden() - This function is not yet documented
- PlayerModel:RegisterUnitEvent() - This function is not yet documented
- PlayerModel:SetDontSavePosition() - This function is not yet documented
- PlayerModel:SetPropagateKeyboardInput() - This function is not yet documented
- PlayerModel:SetShown() - This function is not yet documented
- PlayerModel:SetSize(width, height) - Sets the size of the region to the specified values
- PlayerModel:SetToplevel(enable) - Sets whether the frame should automatically come to the front when clicked
- PlayerModel:SetUserPlaced(enable) - Flags the frame for automatic saving and restoration of position and dimensions
- PlayerModel:SetWidth(width) - Sets the region's width
- PlayerModel:Show() - Shows the region
- PlayerModel:StartMoving() - Begins repositioning the frame via mouse movement
- PlayerModel:StartSizing() - Begins resizing the frame via mouse movement
- PlayerModel:StopAnimating() - Stops any active animations involving the region or its children
- PlayerModel:StopMovingOrSizing() - Ends movement or resizing of the frame initiated with [[docs/widgets/Frame/StartMoving|`:StartMoving()`]] or [[docs/widgets/Frame/StartSizing|`:StartSizing()`]]
- PlayerModel:UnregisterAllEvents() - Unregisters the frame from any [[docs/events|events]] for which it is registered
- PlayerModel:UnregisterEvent("event") - Unregisters the frame for an event
Script Handlers
- OnAnimFinished(self) - Run when the model's animation finishes
- OnAttributeChanged(self, "name", value) - Run when a frame attribute is changed
- OnChar(self, "text") - Run for each text character typed in the frame
- OnDisable(self) - Run when the frame is disabled
- OnDragStart(self, "button") - Run when the mouse is dragged starting in the frame
- OnDragStop(self) - Run when the mouse button is released after a drag started in the frame
- OnEnable(self) - Run when the frame is enabled
- OnEnter(self, motion) - Run when the mouse cursor enters the frame's interactive area
- OnEvent(self, "event", ...) - Run whenever an [[docs/events|event]] fires for which the frame is registered
- OnHide(self) - Run when the frame's visbility changes to hidden
- OnKeyDown(self, "key") - Run when a keyboard key is pressed if the frame is keyboard enabled
- OnKeyUp(self, "key") - Run when a keyboard key is released if the frame is keyboard enabled
- OnLeave(self, motion) - Run when the mouse cursor leaves the frame's interactive area
- OnLoad(self) - Run when the frame is created
- OnMouseDown(self, "button") - Run when a mouse button is pressed while the cursor is over the frame
- OnMouseUp(self, "button") - Run when the mouse button is released following a mouse down action in the frame
- OnMouseWheel(self, delta) - Run when the frame receives a mouse wheel scrolling action
- OnReceiveDrag(self) - Run when the mouse button is released after dragging into the frame
- OnShow(self) - Run when the frame becomes visible
- OnSizeChanged(self, width, height) - Run when a frame's size changes
- OnUpdate(self, elapsed) - Run each time the screen is drawn by the game engine
- OnUpdateModel(self) - Run when a model changes or animates