Click or drag to resize

Weapon2D Class

Base class for making weapons.
Inheritance Hierarchy

Namespace:  NeoAxis
Assembly:  NeoAxis.CoreExtension (in NeoAxis.CoreExtension.dll) Version: 2022.1.1.0 (2022.1.1.0)
Syntax
C#
public class Weapon2D : Sprite, IGameFrameworkItem2D, 
	InteractiveObject

The Weapon2D type exposes the following members.

Constructors
  NameDescription
Public methodWeapon2D
Initializes a new instance of the Weapon2D class
Top
Properties
  NameDescription
Public propertyAlwaysDisplayAdditionalInfo
Whether to display initial position and direction of a bullet.
Public propertyAnimate
Whether to enable default animation method of the weapon.
Public propertyAnyData
The user data of the component.
(Inherited from Component.)
Public propertyBaseType
Gets the base type of the object.
(Inherited from Component.)
Public propertyBulletSpeed
The initial speed of the bullet.
Public propertyBulletTransform
The initial position, rotation and scale of the bullet.
Public propertyBulletType
The type of the bullet.
Public propertyCanBeSelected
Whether the object is selectable in the scene view.
(Inherited from ObjectInSpace.)
Public propertyCanBeSelectedInHierarchy (Inherited from ObjectInSpace.)
Public propertyCastShadows
Whether to cast shadows on the other surfaces.
(Inherited from MeshInSpace.)
Public propertyCloneSupport
Whether the object supports cloning.
(Inherited from Component.)
Public propertyColor
The base color and opacity multiplier.
(Inherited from MeshInSpace.)
Public propertyComponents
Gets the collection of the child components.
(Inherited from Component.)
Public propertyCreatedByBaseType
Whether the object is created using a base type.
(Inherited from Component.)
Public propertyCutVolumes (Inherited from MeshInSpace.)
Public propertyDisplayInEditor
Whether to show the object in the editor.
(Inherited from Component.)
Public propertyDisposed
Whether the object is disposed.
(Inherited from Component.)
Public propertyEditorDocumentConfiguration
Gets or sets the configuration data of the object's settings in the editor.
(Inherited from Component.)
Public propertyEditorReadOnly
Whether the object is read only in the editor.
(Inherited from Component.)
Public propertyEditorReadOnlyInHierarchy
Whether the object is read-only in the editor with respect to parent objects.
(Inherited from Component.)
Public propertyEnabled
Whether the component is enabled. See also EnabledInHierarchy property.
(Inherited from Component.)
Public propertyEnabledInHierarchy
Determines whether the object is attached to a hierarchy of the components and enabled. The object will be enabled only when all parents are enabled, and the property Enabled is enabled.
(Inherited from Component.)
Public propertyEnabledInHierarchyAndIsNotResource
Determines when the object is attached to a hierarchy of the components, is enabled and the object if not part of a resource (it is usual object instance). The object will be enabled only when all parents are enabled, and the property Enabled is enabled.
(Inherited from Component.)
Public propertyEnabledSelectionByCursor (Inherited from ObjectInSpace.)
Public propertyEventAnimation
Public propertyEventAnimationUpdateMethod
Public propertyFireAnimation
Fire animation of the weapon.
Public propertyFireSound
The sound that is played when a shot occurs.
Public propertyFiring
Public propertyFiringBeginSound
The sound that is played when the firing begins.
Public propertyFiringCurrentTime
Public propertyFiringFireTime
The time of the bullet creation during firing cycle.
Public propertyFiringTotalTime
Total time of one firing cycle.
Public propertyHierarchyController
Gets the object hierarchy control controller.
(Inherited from Component.)
Public propertyIdleAnimation
Animation of weapon at rest.
Public propertyMesh
The mesh used by the mesh object.
(Inherited from MeshInSpace.)
Public propertyMeshOutput (Inherited from Sprite.)
Public propertyModifiableMesh (Inherited from MeshInSpace.)
Public propertyModifiableMeshCreatedByObject (Inherited from MeshInSpace.)
Public propertyMotionBlurFactor
The multiplier of the motion blur effect.
(Inherited from MeshInSpace.)
Public propertyName
The name of the component.
(Inherited from Component.)
Public propertyOccluder
Whether to object should be used as an occluder for occlusion culling.
(Inherited from MeshInSpace.)
Public propertyPaintLayersReplace (Inherited from MeshInSpace.)
Public propertyParent
Gets the parent object.
(Inherited from Component.)
Public propertyParentRoot
Gets the parent root object.
(Inherited from Component.)
Public propertyParentScene (Inherited from ObjectInSpace.)
Public propertyReceiveDecals
Whether it is possible to apply decals on the surface.
(Inherited from MeshInSpace.)
Public propertyRemainingLifetime
The lifetime of the component during the simulation.
(Inherited from ObjectInSpace.)
Public propertyRemoveFromParentQueued
Whether the object is placed in the detach queue from the parent.
(Inherited from Component.)
Public propertyReplaceMaterial
Replaces all geometries of the mesh by another material.
(Inherited from MeshInSpace.)
Public propertyReplaceMaterialSelectively
Replaces selected geometries of the mesh by another material.
(Inherited from MeshInSpace.)
Public propertySaveSupport
Whether the object supports saving to a file.
(Inherited from Component.)
Public propertyScreenLabel
Sets the display of the on-screen label of the object in the scene editor.
(Inherited from Component.)
Public propertySpaceBounds (Inherited from ObjectInSpace.)
Public propertySpaceBoundsOverride (Inherited from ObjectInSpace.)
Public propertySpecialEffects
Specifies settings for special object effects, such as an outline effect.
(Inherited from MeshInSpace.)
Public propertyTransform
The position, rotation and scale of the object.
(Inherited from ObjectInSpace.)
Public propertyTransformV
Simplier form of Transform.Value.
(Inherited from ObjectInSpace.)
Public propertyTypeSettingsPrivateObjects
Object settings when used as a type.
(Inherited from Component.)
Public propertyUV
UV texture coordinates.
(Inherited from Sprite.)
Public propertyVisibilityDistanceFactor
The factor of maximum visibility distance. The maximum distance is calculated based on the size of the object on the screen.
(Inherited from MeshInSpace.)
Public propertyVisible
Whether the object is visible in the scene.
(Inherited from ObjectInSpace.)
Public propertyVisibleInHierarchy (Inherited from ObjectInSpace.)
Top
Methods
  NameDescription
Public methodAddComponent
Adds a component as a child.
(Inherited from Component.)
Public methodCheckSelectionByRay (Inherited from ObjectInSpace.)
Public methodClone
Creates a copy of the object.
(Inherited from Component.)
Public methodCreateComponent(Type, Int32, Boolean, Boolean)
Creates a child component.
(Inherited from Component.)
Public methodCreateComponent(MetadataTypeInfo, Int32, Boolean, Boolean)
Creates a child component.
(Inherited from Component.)
Public methodCreateComponentT(Int32, Boolean, Boolean)
Creates a child component.
(Inherited from Component.)
Public methodDispose
Detaches the object from the hierarchy and deletes the object data.
(Inherited from Component.)
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodEventAnimationBegin
Public methodEventAnimationEnd
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodFindParent(Type)
Finds the parent of the specified type.
(Inherited from Component.)
Public methodFindParent(MetadataTypeInfo)
Finds the parent of the specified type.
(Inherited from Component.)
Public methodFindParentT
Finds the parent of the specified type.
(Inherited from Component.)
Public methodFindThisOrParent(Type)
Finds the parent or self of the specified type.
(Inherited from Component.)
Public methodFindThisOrParent(MetadataTypeInfo)
Finds the parent or self of the specified type.
(Inherited from Component.)
Public methodFindThisOrParentT
Finds the parent or self of the specified type.
(Inherited from Component.)
Public methodFiringBegin
Public methodFiringEnd
Public methodGetAllParents
Gets all parents of the component.
(Inherited from Component.)
Public methodGetAnimationController
Public methodGetBulletWorldInitialTransform
Public methodGetComponent(String, Boolean)
Finds a child component by name.
(Inherited from Component.)
Public methodGetComponent(Type, Boolean, Boolean)
Finds a child component of the specified type.
(Inherited from Component.)
Public methodGetComponent(MetadataTypeInfo, Boolean, Boolean)
Finds a child component of the specified type.
(Inherited from Component.)
Public methodGetComponentT(Boolean, Boolean)
Finds a child component of the specified type.
(Inherited from Component.)
Public methodGetComponentByNameWithIndex
Finds a child component by name and number in the case when there are several components with the specified name.
(Inherited from Component.)
Public methodGetComponentByPath
Finds a child component by path.
(Inherited from Component.)
Public methodGetComponents(Boolean, Boolean, Boolean, Boolean)
Finds child components.
(Inherited from Component.)
Public methodGetComponents(Boolean, Boolean, Boolean, Boolean, ActionComponent)
Finds child components.
(Inherited from Component.)
Public methodGetComponents(Type, Boolean, Boolean, Boolean, Boolean)
Finds child components of the specified type.
(Inherited from Component.)
Public methodGetComponents(MetadataTypeInfo, Boolean, Boolean, Boolean, Boolean)
Finds child components of the specified type.
(Inherited from Component.)
Public methodGetComponentsT(Boolean, Boolean, Boolean, Boolean, ActionT)
Finds child components of the specified type.
(Inherited from Component.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetPathFromParent
Returns the path to the object from the parent.
(Inherited from Component.)
Public methodGetPathFromRoot
Returns the object's access path from the root object.
(Inherited from Component.)
Public methodGetProvidedType
Returns a type when the object is used as a type.
(Inherited from Component.)
Public methodGetScreenLabelInfo (Inherited from Component.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodIsMethodInvoking (Inherited from Component.)
Public methodLookAt(ObjectInSpace) (Inherited from ObjectInSpace.)
Public methodLookAt(Vector3) (Inherited from ObjectInSpace.)
Public methodLookAt(ObjectInSpace, Vector3) (Inherited from ObjectInSpace.)
Public methodLookAt(Vector3, Vector3) (Inherited from ObjectInSpace.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodMetadataGetMemberBySignature
Returns the object metadata member by name.
(Inherited from Component.)
Public methodMetadataGetMembers
Returns the object metadata members.
(Inherited from Component.)
Public methodMethodInvoke
Calls a method by name.
(Inherited from Component.)
Public methodMethodInvokeCancel (Inherited from Component.)
Public methodMethodInvokeCancelAll (Inherited from Component.)
Public methodModifiableMeshCreate (Inherited from MeshInSpace.)
Public methodModifiableMeshDestroy (Inherited from MeshInSpace.)
Public methodNewObjectSetDefaultConfiguration (Overrides ComponentNewObjectSetDefaultConfiguration(Boolean).)
Public methodNewObjectSetDefaultConfigurationUpdate
Called during object creation in the editor. Designed to configure the initial state.
(Inherited from Component.)
Public methodObjectInteractionEnter
Public methodObjectInteractionExit
Public methodObjectInteractionGetInfo
Public methodObjectInteractionInputMessage
Public methodObjectInteractionUpdate
Protected methodOnAddedToParent
Called when a component is added to the parent.
(Inherited from Component.)
Protected methodOnCanFire
Protected methodOnCheckSelectionByRay (Inherited from MeshInSpace.)
Protected methodOnClone
Called when the object is cloned.
(Inherited from Component.)
Protected methodOnComponentAdded
Called when a child component is added.
(Inherited from Component.)
Protected methodOnComponentRemoved
Called when a child component is removed.
(Inherited from Component.)
Protected methodOnDisabled
Called when the object is detached from a hierarchy of the components or is disabled. See also EnabledInHierarchy property.
(Inherited from Component.)
Protected methodOnDisabledInSimulation
Called when the object is detached from a hierarchy of the components or is disabled. The method is called only in simulation application. See also EnabledInHierarchy property.
(Inherited from Component.)
Protected methodOnDispose
Called when the object is disposed.
(Inherited from Component.)
Protected methodOnEditorGetTextInfoCenterBottomCorner (Inherited from Component.)
Protected methodOnEnabled
Called when the object is attached to a hierarchy of the components and is enabled. See also EnabledInHierarchy property.
(Inherited from Component.)
Protected methodOnEnabledChanged
Called when value of Enabled property is changed.
(Inherited from Component.)
Protected methodOnEnabledInHierarchyChanged (Inherited from MeshInSpace.)
Protected methodOnEnabledInSimulation
Called when the object is attached to a hierarchy of the components and is enabled. The method is called only in simulation application. See also EnabledInHierarchy property.
(Inherited from Component.)
Protected methodOnEnabledSelectionByCursor (Inherited from ObjectInSpace.)
Protected methodOnFire
Protected methodOnGetRenderSceneData (Overrides MeshInSpaceOnGetRenderSceneData(ViewportRenderingContext, GetRenderSceneDataMode, SceneGetObjectsInSpaceItem).)
Protected methodOnLifetimeEnd (Inherited from ObjectInSpace.)
Protected methodOnLoad
Called during object loading.
(Inherited from Component.)
Protected methodOnMetadataGetMemberBySignature
Called when the object metadata member is received by name.
(Inherited from Component.)
Protected methodOnMetadataGetMembers
Called upon receipt of the object's metadata members.
(Inherited from Component.)
Protected methodOnMetadataGetMembersFilter (Overrides ComponentOnMetadataGetMembersFilter(MetadataGetMembersContext, MetadataMember, Boolean).)
Protected methodOnOcclusionCullingDataContains (Inherited from MeshInSpace.)
Protected methodOnOcclusionCullingDataGet (Inherited from MeshInSpace.)
Protected methodOnPreloadResources
Called when preloading the resources used by the object.
(Inherited from Component.)
Protected methodOnRemovedFromParent
Called when a component is removed from the parent.
(Inherited from Component.)
Protected methodOnSave
Called during object saving.
(Inherited from Component.)
Protected methodOnSimulationStep (Overrides ObjectInSpaceOnSimulationStep.)
Protected methodOnSpaceBoundsChanged (Inherited from ObjectInSpace.)
Protected methodOnSpaceBoundsUpdate (Inherited from MeshInSpace.)
Protected methodOnSpaceBoundsUpdateIncludeChildren (Overrides ObjectInSpaceOnSpaceBoundsUpdateIncludeChildren.)
Protected methodOnTransformChanged (Inherited from ObjectInSpace.)
Protected methodOnTransformUpdating (Inherited from ObjectInSpace.)
Protected methodOnUpdate (Overrides MeshInSpaceOnUpdate(Single).)
Public methodPaintLayersNeedUpdate (Inherited from MeshInSpace.)
Public methodPerformCanFire
Public methodPerformFire
Public methodPreloadResources
Preload resources used by the object.
(Inherited from Component.)
Public methodPropertyGet(String, Object, Boolean)
Gets the value of a property by name.
(Inherited from Component.)
Public methodPropertySet
Sets the value of a property by name.
(Inherited from Component.)
Public methodRayCast (Inherited from MeshInSpace.)
Public methodRemoveAllComponents
Removes all child components.
(Inherited from Component.)
Public methodRemoveComponent
Removes a child component.
(Inherited from Component.)
Public methodRemoveFromParent
Detaches the object from its parent.
(Inherited from Component.)
Public methodSetPosition(Vector3) (Inherited from ObjectInSpace.)
Public methodSetPosition(Double, Double, Double) (Inherited from ObjectInSpace.)
Public methodSetRotation(Angles) (Inherited from ObjectInSpace.)
Public methodSetRotation(Quaternion) (Inherited from ObjectInSpace.)
Public methodSetRotation(Double, Double, Double) (Inherited from ObjectInSpace.)
Public methodSetScale(Double) (Inherited from ObjectInSpace.)
Public methodSetScale(Vector3) (Inherited from ObjectInSpace.)
Public methodSetScale(Double, Double, Double) (Inherited from ObjectInSpace.)
Public methodSetTransparentRenderingAddOffsetWhenSortByDistance (Inherited from MeshInSpace.)
Public methodSoundPlay
Public methodSpaceBoundsUpdate (Inherited from ObjectInSpace.)
Public methodToString
Returns the name and type of the object as a string.
(Inherited from Component.)
Public methodTypeSettingsIsPublic
Checks whether the object provided as a type is public.
(Inherited from Component.)
Public methodTypeSettingsIsPublicMember
Checks whether the member is set up as public.
(Inherited from Component.)
Top
Events
  NameDescription
Public eventAddedToParent
Occurs when a component is added to the parent.
(Inherited from Component.)
Public eventAlwaysDisplayAdditionalInfoChanged
Occurs when the AlwaysDisplayAdditionalInfo property value changes.
Public eventAnimateChanged
Occurs when the Animate property value changes.
Public eventBulletSpeedChanged
Occurs when the BulletSpeed property value changes.
Public eventBulletTransformChanged
Occurs when the BulletTransform property value changes.
Public eventBulletTypeChanged
Occurs when the BulletType property value changes.
Public eventCanBeSelectedChanged
Occurs when the CanBeSelected property value changes.
(Inherited from ObjectInSpace.)
Public eventCanFire
Public eventCastShadowsChanged
Occurs when the CastShadows property value changes.
(Inherited from MeshInSpace.)
Public eventCloneEvent
Occurs when object is cloned.
(Inherited from Component.)
Public eventCloneSupportChanged
Occurs after changing value of CloneSupport property.
(Inherited from Component.)
Public eventColorChanged
Occurs when the Color property value changes.
(Inherited from MeshInSpace.)
Public eventComponentAdded
Occurs when a child component is added.
(Inherited from Component.)
Public eventComponentRemoved
Occurs when a child component is removed.
(Inherited from Component.)
Public eventComponentsChanged
Occurs when the set of children is changed.
(Inherited from Component.)
Public eventDisabledEvent
Occurs when the object is disabled from a hierarchy of the components or is disabled. See also EnabledInHierarchy property.
(Inherited from Component.)
Public eventDisabledInSimulation
Occurs when the object is detached from a hierarchy of the components or is disabled. The method is called only in simulation application. See also EnabledInHierarchy property.
(Inherited from Component.)
Public eventDisplayInEditorChanged
Occurs when value of DisplayInEditor property is changed.
(Inherited from Component.)
Public eventDisposeEvent
Occurs when the object is disposed.
(Inherited from Component.)
Public eventEnabledChanged
Occurs when the Enabled property value changes.
(Inherited from Component.)
Public eventEnabledEvent
Occurs when the object is attached to a hierarchy of the components and is enabled. See also EnabledInHierarchy property.
(Inherited from Component.)
Public eventEnabledInHierarchyChanged
Occurs when the EnabledInHierarchy property value changes.
(Inherited from Component.)
Public eventEnabledInSimulation
Occurs when the object is attached to a hierarchy of the components and is enabled. The method is called only in simulation application. See also EnabledInHierarchy property.
(Inherited from Component.)
Public eventFire
Public eventFireAnimationChanged
Occurs when the FireAnimation property value changes.
Public eventFireSoundChanged
Occurs when the FireSound property value changes.
Public eventFiringBeginEvent
Public eventFiringBeginSoundChanged
Occurs when the FiringBeginSound property value changes.
Public eventFiringEndEvent
Public eventFiringFireTimeChanged
Occurs when the FiringFireTime property value changes.
Public eventFiringTotalTimeChanged
Occurs when the FiringTotalTime property value changes.
Public eventGetBulletWorldInitialTransformEvent
Public eventGetRenderSceneData (Inherited from ObjectInSpace.)
Public eventGetRenderSceneDataAddToFrameData (Inherited from MeshInSpace.)
Public eventGetRenderSceneDataBefore (Inherited from ObjectInSpace.)
Public eventIdleAnimationChanged
Occurs when the IdleAnimation property value changes.
Public eventLifetimeEnd (Inherited from ObjectInSpace.)
Public eventLoadEvent
Occurs during object loading.
(Inherited from Component.)
Public eventMeshChanged
Occurs when the Mesh property value changes.
(Inherited from MeshInSpace.)
Public eventMeshOutputOverride (Inherited from MeshInSpace.)
Public eventMetadataGetMemberBySignatureEvent
Occurs when the object metadata member is received by name.
(Inherited from Component.)
Public eventMetadataGetMembersEvent
Occurs upon receipt of the object's metadata members.
(Inherited from Component.)
Public eventMetadataGetMembersFilterEvent
Occurs when filtering receive members of the object metadata.
(Inherited from Component.)
Public eventMotionBlurFactorChanged
Occurs when the MotionBlurFactor property value changes.
(Inherited from MeshInSpace.)
Public eventNameChanged
Occurs when component name is changed.
(Inherited from Component.)
Public eventOccluderChanged
Occurs when the Occluder property value changes.
(Inherited from MeshInSpace.)
Public eventPreloadResourcesEvent
Occurs when preloading the resources used by the object.
(Inherited from Component.)
Public eventReceiveDecalsChanged
Occurs when the ReceiveDecals property value changes.
(Inherited from MeshInSpace.)
Public eventRemainingLifetimeChanged
Occurs when the RemainingLifetime property value changes.
(Inherited from ObjectInSpace.)
Public eventRemovedFromParent
Occurs when a component is removed from the parent.
(Inherited from Component.)
Public eventReplaceMaterialChanged
Occurs when the ReplaceMaterial property value changes.
(Inherited from MeshInSpace.)
Public eventReplaceMaterialSelectivelyChanged (Inherited from MeshInSpace.)
Public eventSaveEvent
Occurs during object saving.
(Inherited from Component.)
Public eventSaveSupportChanged
Occurs after changing value of SaveSupport property.
(Inherited from Component.)
Public eventScreenLabelChanged
Occurs when the ScreenLabel property value changes.
(Inherited from Component.)
Public eventSimulationStep
Occurs during the simulation step.
(Inherited from Component.)
Public eventSpaceBoundsChanged
Occurs when the SpaceBounds property value changes.
(Inherited from ObjectInSpace.)
Public eventSpaceBoundsUpdateEvent (Inherited from ObjectInSpace.)
Public eventSpaceBoundsUpdateIncludeChildrenEvent (Inherited from ObjectInSpace.)
Public eventSpecialEffectsChanged
Occurs when the SpecialEffects property value changes.
(Inherited from MeshInSpace.)
Public eventTransformChanged
Occurs when the Transform property value changes.
(Inherited from ObjectInSpace.)
Public eventTransformUpdatingEvent (Inherited from ObjectInSpace.)
Public eventUpdateEvent
Occurs during the update process of all objects.
(Inherited from Component.)
Public eventUVChanged
Occurs when the UV property value changes.
(Inherited from Sprite.)
Public eventVisibilityDistanceFactorChanged
Occurs when the VisibilityDistanceFactor property value changes.
(Inherited from MeshInSpace.)
Public eventVisibleChanged
Occurs when the Visible property value changes.
(Inherited from ObjectInSpace.)
Top
Extension Methods
See Also