M&B: Bannerlord 1.2.7
The horns sound, the ravens gather.
Loading...
Searching...
No Matches
TaleWorlds.TwoDimension.TwoDimensionContext Class Reference

Public Member Functions

 TwoDimensionContext (ITwoDimensionPlatform platform, ITwoDimensionResourceContext resourceContext, ResourceDepot resourceDepot)
 
void PlaySound (string soundName)
 
void CreateSoundEvent (string soundName)
 
void StopAndRemoveSoundEvent (string soundName)
 
void PlaySoundEvent (string soundName)
 
void Draw (float x, float y, Material material, DrawObject2D drawObject2D, int layer=0)
 
void Draw (Text text, TextMaterial material, float x, float y, float width, float height)
 
void BeginDebugPanel (string panelTitle)
 
void EndDebugPanel ()
 
void DrawDebugText (string text)
 
bool DrawDebugTreeNode (string text)
 
void PopDebugTreeNode ()
 
void DrawCheckbox (string label, ref bool isChecked)
 
bool IsDebugItemHovered ()
 
Texture LoadTexture (string name)
 
void SetCircualMask (Vector2 position, float radius, float smoothingRadius)
 
void ClearCircualMask ()
 
void DrawSprite (Sprite sprite, SimpleMaterial material, float x, float y, float scale, float width, float height, bool horizontalFlip, bool verticalFlip)
 
void SetScissor (int x, int y, int width, int height)
 
void SetScissor (ScissorTestInfo scissor)
 
void ResetScissor ()
 
void PushScissor (int x, int y, int width, int height)
 
void PopScissor ()
 

Properties

float Width [get]
 
float Height [get]
 
ITwoDimensionPlatform Platform [get]
 
ITwoDimensionResourceContext ResourceContext [get]
 
ResourceDepot ResourceDepot [get]
 
bool ScissorTestEnabled [get]
 
bool CircularMaskEnabled [get]
 
Vector2 CircularMaskCenter [get]
 
float CircularMaskRadius [get]
 
float CircularMaskSmoothingRadius [get]
 
ScissorTestInfo CurrentScissor [get]
 
bool IsDebugModeEnabled [get]
 

Constructor & Destructor Documentation

◆ TwoDimensionContext()

TaleWorlds.TwoDimension.TwoDimensionContext.TwoDimensionContext ( ITwoDimensionPlatform  platform,
ITwoDimensionResourceContext  resourceContext,
ResourceDepot  resourceDepot 
)

Member Function Documentation

◆ PlaySound()

void TaleWorlds.TwoDimension.TwoDimensionContext.PlaySound ( string  soundName)

◆ CreateSoundEvent()

void TaleWorlds.TwoDimension.TwoDimensionContext.CreateSoundEvent ( string  soundName)

◆ StopAndRemoveSoundEvent()

void TaleWorlds.TwoDimension.TwoDimensionContext.StopAndRemoveSoundEvent ( string  soundName)

◆ PlaySoundEvent()

void TaleWorlds.TwoDimension.TwoDimensionContext.PlaySoundEvent ( string  soundName)

◆ Draw() [1/2]

void TaleWorlds.TwoDimension.TwoDimensionContext.Draw ( float  x,
float  y,
Material  material,
DrawObject2D  drawObject2D,
int  layer = 0 
)

◆ Draw() [2/2]

void TaleWorlds.TwoDimension.TwoDimensionContext.Draw ( Text  text,
TextMaterial  material,
float  x,
float  y,
float  width,
float  height 
)

◆ BeginDebugPanel()

void TaleWorlds.TwoDimension.TwoDimensionContext.BeginDebugPanel ( string  panelTitle)

◆ EndDebugPanel()

void TaleWorlds.TwoDimension.TwoDimensionContext.EndDebugPanel ( )

◆ DrawDebugText()

void TaleWorlds.TwoDimension.TwoDimensionContext.DrawDebugText ( string  text)

◆ DrawDebugTreeNode()

bool TaleWorlds.TwoDimension.TwoDimensionContext.DrawDebugTreeNode ( string  text)

◆ PopDebugTreeNode()

void TaleWorlds.TwoDimension.TwoDimensionContext.PopDebugTreeNode ( )

◆ DrawCheckbox()

void TaleWorlds.TwoDimension.TwoDimensionContext.DrawCheckbox ( string  label,
ref bool  isChecked 
)

◆ IsDebugItemHovered()

bool TaleWorlds.TwoDimension.TwoDimensionContext.IsDebugItemHovered ( )

◆ LoadTexture()

Texture TaleWorlds.TwoDimension.TwoDimensionContext.LoadTexture ( string  name)

◆ SetCircualMask()

void TaleWorlds.TwoDimension.TwoDimensionContext.SetCircualMask ( Vector2  position,
float  radius,
float  smoothingRadius 
)

◆ ClearCircualMask()

void TaleWorlds.TwoDimension.TwoDimensionContext.ClearCircualMask ( )

◆ DrawSprite()

void TaleWorlds.TwoDimension.TwoDimensionContext.DrawSprite ( Sprite  sprite,
SimpleMaterial  material,
float  x,
float  y,
float  scale,
float  width,
float  height,
bool  horizontalFlip,
bool  verticalFlip 
)

◆ SetScissor() [1/2]

void TaleWorlds.TwoDimension.TwoDimensionContext.SetScissor ( int  x,
int  y,
int  width,
int  height 
)

◆ SetScissor() [2/2]

void TaleWorlds.TwoDimension.TwoDimensionContext.SetScissor ( ScissorTestInfo  scissor)

◆ ResetScissor()

void TaleWorlds.TwoDimension.TwoDimensionContext.ResetScissor ( )

◆ PushScissor()

void TaleWorlds.TwoDimension.TwoDimensionContext.PushScissor ( int  x,
int  y,
int  width,
int  height 
)

◆ PopScissor()

void TaleWorlds.TwoDimension.TwoDimensionContext.PopScissor ( )

Property Documentation

◆ Width

float TaleWorlds.TwoDimension.TwoDimensionContext.Width
get

◆ Height

float TaleWorlds.TwoDimension.TwoDimensionContext.Height
get

◆ Platform

ITwoDimensionPlatform TaleWorlds.TwoDimension.TwoDimensionContext.Platform
get

◆ ResourceContext

ITwoDimensionResourceContext TaleWorlds.TwoDimension.TwoDimensionContext.ResourceContext
get

◆ ResourceDepot

ResourceDepot TaleWorlds.TwoDimension.TwoDimensionContext.ResourceDepot
get

◆ ScissorTestEnabled

bool TaleWorlds.TwoDimension.TwoDimensionContext.ScissorTestEnabled
get

◆ CircularMaskEnabled

bool TaleWorlds.TwoDimension.TwoDimensionContext.CircularMaskEnabled
get

◆ CircularMaskCenter

Vector2 TaleWorlds.TwoDimension.TwoDimensionContext.CircularMaskCenter
get

◆ CircularMaskRadius

float TaleWorlds.TwoDimension.TwoDimensionContext.CircularMaskRadius
get

◆ CircularMaskSmoothingRadius

float TaleWorlds.TwoDimension.TwoDimensionContext.CircularMaskSmoothingRadius
get

◆ CurrentScissor

ScissorTestInfo TaleWorlds.TwoDimension.TwoDimensionContext.CurrentScissor
get

◆ IsDebugModeEnabled

bool TaleWorlds.TwoDimension.TwoDimensionContext.IsDebugModeEnabled
get