Exemplo n.º 1
0
        public ShadowEgo()
        {
            Transform
            .Create(this)
            .SetPosition(250, 250)
            .SetSpeed(150f / 0.375f)
            .SetOrientation(-Vector2.UnitX)
            .SetUpdateZWithPosition(true)
            .SetCalculateEffectiveSpeedFn(CalculateSpeed)
            .SetScale(0.5f);

            Sprite
            .Create(this)
            .SetEnableNormalMap(true)
            .SetImage("characters/ego/sprite", 9, 4);

            SpriteTransformAnimation
            .Create(this)
            .SetSetFrameFn(SetFrame);

            SpriteData
            .Create(this)
            .SetOrientationFlip(false)
            .SetOffset(-40, -310);

            Scripts
            .Create(this);

            Lightning
            .Create(this)
            .SetLightColor(new Vector3(1.5f, 0.25f, 0.25f));

            Visible = true;
            Enabled = true;
        }
Exemplo n.º 2
0
        public Therapist()
        {
            Transform
            .Create(this)
            .SetPosition(440, 200)
            .SetZ(2)
            .SetAbsolute(true);

            Text
            .Create(this)
            .SetColor(Color.OrangeRed)
            .SetFont(content.fonts.pixeloperator_outline_BMF)
            .SetWidth(300);

            Sprite
            .Create(this)
            .SetImage(content.rooms.office.therapist, 5, 1);

            SpriteTransformAnimation
            .Create(this)
            .SetSetFrameFn(SetFrame);

            SpriteData
            .Create(this)
            .SetOffset(-87, 45);

            Scripts
            .Create(this);
        }
Exemplo n.º 3
0
        public Ryan()
        {
            Transform
            .Create(this)
            .SetPosition(290, 170)
            .SetAbsolute(true);

            Text
            .Create(this)
            .SetColor(Color.White)
            .SetFont(content.fonts.pixeloperator_outline_BMF)
            .SetWidth(300);

            Sprite
            .Create(this)
            .SetImage(content.rooms.office.ryan, 20, 1, 19)
            .SetFrame(FRAMENEUTRAL);

            SpriteTransformAnimation
            .Create(this)
            .SetSetFrameFn(SetFrame);

            SpriteData
            .Create(this)
            .SetOffset(-29, 50);

            Scripts
            .Create(this);

            State     = RyanState.Neutral;
            DrawOrder = PRIORITY;
        }
Exemplo n.º 4
0
        public Drone()
        {
            Sprite
            .Create(this)
            .SetGetPositionFn(GetSpritePosition)
            .SetImage(content.rooms.basement.drone, 5, 4);

            SpriteTransformAnimation
            .Create(this)
            .SetSetFrameFn(SetFrame);

            CameraLocked
            .Create(this)
            .SetEnabled(false);

            Transform
            .Create(this)
            .SetPosition(INITIAL_POSITION)
            .SetDirection(Directions4.Down)
            .SetUpdateZWithPosition(false)
            .SetZ(INITIAL_Z);

            SpriteData
            .Create(this)
            .SetOffset(-42, -16);

            HotspotSprite
            .Create(this)
            .SetCaption(Basement_Res.drone)
            .SetPixelPerfect(false);

            Interaction
            .Create(this)
            .SetDirection(Directions8.Down)
            .SetGetInteractionsFn(GetInteractions);

            Scripts
            .Create(this);

            DroneDisplacement
            .Create(this);

            Flying  = false;
            Enabled = false;
            Visible = false;
        }
Exemplo n.º 5
0
        public Mouse()
        {
            Transform
            .Create(this)
            .SetPosition(STARTPOSITION)
            .SetSpeed(120)
            .SetOrientation(-Vector2.UnitX)
            .SetUpdateZWithPosition(true)
            .SetScale(1.0f);

            Sprite
            .Create(this)
            .SetEnableNormalMap(false)
            .SetImage(content.characters.mouse.sprite, 9, 7);

            SpriteTransformAnimation
            .Create(this)
            .SetSetFrameFn(SetFrame);

            SpriteCustomAnimation
            .Create(this)
            .SetGetFramesAction(GetCustomAnimationFrames);

            SpriteData
            .Create(this)
            .SetOrientationFlip(false)
            .SetOffset(-7, -13);

            Navigation
            .Create(this)
            .SetApplyScale(false)
            .SetApplyColoring(false)
            .SetRestrictPosition(true)
            .SetScale(1.0f);

            Scripts
            .Create(this);

            CameraLocked
            .Create(this)
            .SetEnabled(false);

            Visible = false;
            Enabled = false;
        }
Exemplo n.º 6
0
        public RyanLying()
        {
            Sprite
            .Create(this)
            .SetImage(content.rooms.basement.ryanlying, 8);

            Transform
            .Create(this)
            .SetPosition(259, 178)
            .SetScale(1.25f)
            .SetZ(263);

            Scripts
            .Create(this);

            SpriteTransformAnimation
            .Create(this)
            .SetSetFrameFn(SetFrame);

            State = RyanLyingState.EyesClosed;
        }
Exemplo n.º 7
0
        public Ryan(Inventory inventory)
        {
            Inventory = inventory;

            CameraLocked
            .Create(this);

            Transform
            .Create(this)
            .SetPosition(350, 250)
            .SetSpeed(120)
            .SetOrientation(-Vector2.UnitY)
            .SetUpdateZWithPosition(true)
            .SetScale(1.0f);

            Sprite
            .Create(this)
            .SetEnableNormalMap(false)
            .SetImage(content.characters.ryan.sprite_blood, 13, 8, 0);

            SpriteTransformAnimation
            .Create(this)
            .SetSetFrameFn(SetFrame);

            SpriteCustomAnimation
            .Create(this)
            .SetGetFramesAction(GetCustomAnimationFrames);

            SpriteData
            .Create(this)
            .SetOrientationFlip(false)
            .SetOffset(-76, -143);

            Text
            .Create(this)
            .SetFont(content.fonts.pixeloperator_outline_BMF)
            .SetWidth(300)
            .SetConstrain(true)
            .SetConstrainingRectangle(new Rectangle(0, 0, Game.VIRTUAL_WIDTH, Game.VIRTUAL_HEIGHT))
            .SetAlign(Alignment.Bottom);

            Navigation
            .Create(this)
            .SetApplyScale(true)
            .SetApplyColoring(true)
            .SetRestrictPosition(true)
            .SetScale(1.75f);

            Scripts
            .Create(this);

            Lightning
            .Create(this)
            .SetLightPosition(new Vector3(new Vector2(51, 61), 0))
            .SetLightColor(new Vector3(1.25f, 0.6f, 0.6f));

            BloodDropEmitter
            .Create(this);

            Score
            .Create(this);

            RandomCountdown
            .Create(this)
            .SetDuration(7)
            .SetMinUpdates(300)
            .SetMaxUpdates(500);
        }