C# Class SunsetHigh.Hero

Hero extends from Character, and is used for the main character
Inheritance: Character
Mostrar archivo Open project: ErraticUnicorn/MOSH Class Usage Examples

Public Methods

Method Description
converse ( Character c ) : void
dialogueCancel ( ) : void
dialogueChoiceMove ( Direction dir ) : void
dialogueConfirm ( ) : void
draw ( SpriteBatch sb ) : void
getFollowerID ( ) : PersonID
getHealth ( ) : int
getReputation ( Clique clique ) : int
getSaveStructure ( ) : HeroSave

Used for saving purposes

hasFollower ( ) : bool
isPickpocketing ( ) : bool
isTalking ( ) : bool
loadContent ( Microsoft.Xna.Framework.Content.ContentManager content ) : void
loadSaveStructure ( HeroSave data ) : void

Used for loading purposes

move ( Direction dir, float elapsed, bool collide = true ) : bool
reset ( ) : void
setFollower ( PersonID follower ) : void
setHealth ( int health ) : void
setHealthBarVisible ( bool visible ) : void
setReputation ( Clique clique, int repPoints ) : void
shiftHealth ( int dhp ) : void
shiftReputation ( Clique clique, int repPoints ) : void
shoot ( ) : void

Causes the Hero to create a projectile and fire it in the direction he is facing; Hero is then responsible for updating and drawing this projectile

startPickpocket ( Character character ) : void

Begins the pickpocketing minigame with the given character as the target

stopFollower ( ) : void
stopPickpocket ( ) : System.Item

Stops the pickpocketing minigame and checks for success. If successful, an Item is returned; if not, Item.Nothing is returned

talkToSelf ( ) : void
update ( float elapsed ) : void

Private Methods

Method Description
Hero ( ) : System

Initializes a Hero at the origin which will match the dimensions of its texture (when loaded)

Hero ( int x, int y ) : System

Initalizes a Hero at the given positon which will match the dimensions of its texture (when loaded)

Hero ( int x, int y, int w, int h ) : System

Initializes a Hero at the given position with the given dimensions

heroBulletCollideEvent ( IInteractable collider ) : void

Method Details

converse() public method

public converse ( Character c ) : void
c Character
return void

dialogueCancel() public method

public dialogueCancel ( ) : void
return void

dialogueChoiceMove() public method

public dialogueChoiceMove ( Direction dir ) : void
dir Direction
return void

dialogueConfirm() public method

public dialogueConfirm ( ) : void
return void

draw() public method

public draw ( SpriteBatch sb ) : void
sb Microsoft.Xna.Framework.Graphics.SpriteBatch
return void

getFollowerID() public method

public getFollowerID ( ) : PersonID
return PersonID

getHealth() public method

public getHealth ( ) : int
return int

getReputation() public method

public getReputation ( Clique clique ) : int
clique Clique
return int

getSaveStructure() public method

Used for saving purposes
public getSaveStructure ( ) : HeroSave
return HeroSave

hasFollower() public method

public hasFollower ( ) : bool
return bool

isPickpocketing() public method

public isPickpocketing ( ) : bool
return bool

isTalking() public method

public isTalking ( ) : bool
return bool

loadContent() public method

public loadContent ( Microsoft.Xna.Framework.Content.ContentManager content ) : void
content Microsoft.Xna.Framework.Content.ContentManager
return void

loadSaveStructure() public method

Used for loading purposes
public loadSaveStructure ( HeroSave data ) : void
data HeroSave The save data for the Hero
return void

move() public method

public move ( Direction dir, float elapsed, bool collide = true ) : bool
dir Direction
elapsed float
collide bool
return bool

reset() public method

public reset ( ) : void
return void

setFollower() public method

public setFollower ( PersonID follower ) : void
follower PersonID
return void

setHealth() public method

public setHealth ( int health ) : void
health int
return void

setHealthBarVisible() public method

public setHealthBarVisible ( bool visible ) : void
visible bool
return void

setReputation() public method

public setReputation ( Clique clique, int repPoints ) : void
clique Clique
repPoints int
return void

shiftHealth() public method

public shiftHealth ( int dhp ) : void
dhp int
return void

shiftReputation() public method

public shiftReputation ( Clique clique, int repPoints ) : void
clique Clique
repPoints int
return void

shoot() public method

Causes the Hero to create a projectile and fire it in the direction he is facing; Hero is then responsible for updating and drawing this projectile
public shoot ( ) : void
return void

startPickpocket() public method

Begins the pickpocketing minigame with the given character as the target
public startPickpocket ( Character character ) : void
character Character The targeted Character
return void

stopFollower() public method

public stopFollower ( ) : void
return void

stopPickpocket() public method

Stops the pickpocketing minigame and checks for success. If successful, an Item is returned; if not, Item.Nothing is returned
public stopPickpocket ( ) : System.Item
return System.Item

talkToSelf() public method

public talkToSelf ( ) : void
return void

update() public method

public update ( float elapsed ) : void
elapsed float
return void