org.sourceforge.jvb3d.Model
Class HudObject

java.lang.Object
  extended by javax.media.j3d.SceneGraphObject
      extended by javax.media.j3d.Node
          extended by javax.media.j3d.Group
              extended by javax.media.j3d.BranchGroup
                  extended by org.sourceforge.jvb3d.Model.DynamicObject
                      extended by org.sourceforge.jvb3d.Model.HudObject
All Implemented Interfaces:
java.io.Externalizable, java.io.Serializable, IChatControl, IMakesTurn

public class HudObject
extends DynamicObject
implements IChatControl

Author:
spootnick Obiekt dynamiczny reprezentujący dynamiczny tekst (zwłaszcza wiadmości z chat-a)
See Also:
Serialized Form

Field Summary
protected  int currentLine
           
protected  int fontSize
           
protected  MyText2D inputLine
           
protected  java.lang.String inputMark
           
protected  MyText2D[] lines
           
protected  boolean[] newLines
           
protected  int nLines
           
protected  float scaleFactor
           
protected  java.lang.String textToSubmit
           
 
Fields inherited from class org.sourceforge.jvb3d.Model.DynamicObject
appearance, baseTtl, isServer, staticWorld, transform, transformGroup, ttl
 
Fields inherited from class javax.media.j3d.BranchGroup
ALLOW_DETACH
 
Fields inherited from class javax.media.j3d.Group
ALLOW_CHILDREN_EXTEND, ALLOW_CHILDREN_READ, ALLOW_CHILDREN_WRITE, ALLOW_COLLISION_BOUNDS_READ, ALLOW_COLLISION_BOUNDS_WRITE
 
Fields inherited from class javax.media.j3d.Node
ALLOW_AUTO_COMPUTE_BOUNDS_READ, ALLOW_AUTO_COMPUTE_BOUNDS_WRITE, ALLOW_BOUNDS_READ, ALLOW_BOUNDS_WRITE, ALLOW_COLLIDABLE_READ, ALLOW_COLLIDABLE_WRITE, ALLOW_LOCAL_TO_VWORLD_READ, ALLOW_PICKABLE_READ, ALLOW_PICKABLE_WRITE, ENABLE_COLLISION_REPORTING, ENABLE_PICK_REPORTING
 
Constructor Summary
HudObject()
           
 
Method Summary
 void append(java.lang.String s)
          Dokleja łańcuch do aktualnie edytowanej linii
 void beginEdit(java.lang.String inputMark)
          Powoduje rozpoczęcie edycji nowej lini tekstu
 void delete(int nChars)
          Usuwa określoną ilość znaków
 float getCharacterHeight()
          Zwraca wysokość liter jaką będą miały w scenie
 void readExternal(java.io.ObjectInput arg0)
           
 void submitLine(java.lang.String source)
          Podowuje zakończenie edycji aktualnej lini i dodanie jej do zawartości obiektu
 void writeExternal(java.io.ObjectOutput arg0)
           
 
Methods inherited from class org.sourceforge.jvb3d.Model.DynamicObject
getTransform, isAlive, nextTurn, setTransform, setWorld
 
Methods inherited from class javax.media.j3d.BranchGroup
cloneNode, compile, detach, pickAll, pickAllSorted, pickAny, pickClosest
 
Methods inherited from class javax.media.j3d.Group
addChild, getAllChildren, getAlternateCollisionTarget, getChild, getCollisionBounds, indexOfChild, insertChild, moveTo, numChildren, removeAllChildren, removeChild, removeChild, setAlternateCollisionTarget, setChild, setCollisionBounds
 
Methods inherited from class javax.media.j3d.Node
cloneTree, cloneTree, cloneTree, cloneTree, cloneTree, cloneTree, duplicateNode, getBounds, getBoundsAutoCompute, getCollidable, getLocalToVworld, getLocalToVworld, getParent, getPickable, setBounds, setBoundsAutoCompute, setCollidable, setPickable
 
Methods inherited from class javax.media.j3d.SceneGraphObject
clearCapability, clearCapabilityIsFrequent, duplicateSceneGraphObject, getCapability, getCapabilityIsFrequent, getUserData, isCompiled, isLive, setCapability, setCapabilityIsFrequent, setUserData, updateNodeReferences
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

lines

protected MyText2D[] lines

inputLine

protected MyText2D inputLine

newLines

protected boolean[] newLines

fontSize

protected int fontSize

scaleFactor

protected float scaleFactor

nLines

protected int nLines

currentLine

protected int currentLine

textToSubmit

protected java.lang.String textToSubmit

inputMark

protected java.lang.String inputMark
Constructor Detail

HudObject

public HudObject()
Method Detail

getCharacterHeight

public float getCharacterHeight()
Zwraca wysokość liter jaką będą miały w scenie

Returns:
wysokość liter na chacie

submitLine

public void submitLine(java.lang.String source)
Description copied from interface: IChatControl
Podowuje zakończenie edycji aktualnej lini i dodanie jej do zawartości obiektu

Specified by:
submitLine in interface IChatControl
Parameters:
source - nazwa która będzie użyta jako źródło tekstu
See Also:
IChatControl.submitLine(String)

append

public void append(java.lang.String s)
Description copied from interface: IChatControl
Dokleja łańcuch do aktualnie edytowanej linii

Specified by:
append in interface IChatControl
See Also:
IChatControl.append(String)

delete

public void delete(int nChars)
Description copied from interface: IChatControl
Usuwa określoną ilość znaków

Specified by:
delete in interface IChatControl
Parameters:
nChars - ilość znaków do usunięcia
See Also:
IChatControl.delete(int)

beginEdit

public void beginEdit(java.lang.String inputMark)
Description copied from interface: IChatControl
Powoduje rozpoczęcie edycji nowej lini tekstu

Specified by:
beginEdit in interface IChatControl
Parameters:
inputMark - znak zachęty
See Also:
IChatControl.beginEdit(String)

writeExternal

public void writeExternal(java.io.ObjectOutput arg0)
                   throws java.io.IOException
Specified by:
writeExternal in interface java.io.Externalizable
Overrides:
writeExternal in class DynamicObject
Throws:
java.io.IOException
See Also:
Externalizable.writeExternal(java.io.ObjectOutput)

readExternal

public void readExternal(java.io.ObjectInput arg0)
                  throws java.io.IOException,
                         java.lang.ClassNotFoundException
Specified by:
readExternal in interface java.io.Externalizable
Overrides:
readExternal in class DynamicObject
Throws:
java.io.IOException
java.lang.ClassNotFoundException
See Also:
Externalizable.readExternal(java.io.ObjectInput)


Copyright © 2004-2005 Akademia Górniczo-Hutnicza w Krakowie. All Rights Reserved.