main n
BIN
.DS_Store
vendored
Normal file
|
@ -14,7 +14,14 @@
|
|||
|
||||
#---------------------------------- Content ---------------------------------#
|
||||
|
||||
#begin MonstersAnimations.png
|
||||
#begin ButtonFont.spritefont
|
||||
/importer:FontDescriptionImporter
|
||||
/processor:FontDescriptionProcessor
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:TextureFormat=Compressed
|
||||
/build:ButtonFont.spritefont
|
||||
|
||||
#begin checkboxs_off.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
|
@ -24,7 +31,31 @@
|
|||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:MonstersAnimations.png
|
||||
/build:checkboxs_off.png
|
||||
|
||||
#begin checkboxs_off-on.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:checkboxs_off-on.png
|
||||
|
||||
#begin checkboxs_on.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:checkboxs_on.png
|
||||
|
||||
#begin deathAnimation.png
|
||||
/importer:TextureImporter
|
||||
|
@ -38,18 +69,43 @@
|
|||
/processorParam:TextureFormat=Color
|
||||
/build:deathAnimation.png
|
||||
|
||||
#begin ButtonFont.spritefont
|
||||
/importer:FontDescriptionImporter
|
||||
/processor:FontDescriptionProcessor
|
||||
#begin deathBackground.jpg
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:TextureFormat=Compressed
|
||||
/build:ButtonFont.spritefont
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:deathBackground.jpg
|
||||
|
||||
|
||||
#begin DoomTestSong.mp3
|
||||
/importer:Mp3Importer
|
||||
/processor:SoundEffectProcessor
|
||||
/processorParam:Quality=Best
|
||||
/build:DoomTestSong.mp3
|
||||
/build:sounds/DoomTestSong.mp3
|
||||
|
||||
#begin doors.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:doors.png
|
||||
|
||||
#begin Font_12.spritefont
|
||||
/importer:FontDescriptionImporter
|
||||
/processor:FontDescriptionProcessor
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:TextureFormat=Compressed
|
||||
/build:Font_12.spritefont
|
||||
|
||||
#begin Font_25.spritefont
|
||||
/importer:FontDescriptionImporter
|
||||
|
@ -84,19 +140,6 @@
|
|||
/processorParam:TextureFormat=Color
|
||||
/build:menuFon.jpg
|
||||
|
||||
#begin MonstersAnimations.png
|
||||
#begin menuFon.jpg
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:menuFon.jpg
|
||||
|
||||
#begin MenuFon2.jpg
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
|
@ -121,6 +164,157 @@
|
|||
/processorParam:TextureFormat=Color
|
||||
/build:menuFon3.jpg
|
||||
|
||||
#begin MonstersAnimations.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:MonstersAnimations.png
|
||||
|
||||
#begin optionsBackground.jpg
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:optionsBackground.jpg
|
||||
|
||||
#begin PC_Computer_Dangerous_Dave_In_The_Haunted_Mansion_Death_Sequences.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:PC_Computer_Dangerous_Dave_In_The_Haunted_Mansion_Death_Sequences.png
|
||||
|
||||
#begin PixelFont.spritefont
|
||||
/importer:FontDescriptionImporter
|
||||
/processor:FontDescriptionProcessor
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:TextureFormat=Compressed
|
||||
/build:PixelFont.spritefont
|
||||
|
||||
#begin playerAnimation.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:playerAnimation.png
|
||||
|
||||
#begin slider.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:slider.png
|
||||
|
||||
#begin sliderBackground.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:sliderBackground.png
|
||||
|
||||
#begin sounds/DoomTestSong.mp3
|
||||
/importer:Mp3Importer
|
||||
/processor:SoundEffectProcessor
|
||||
/processorParam:Quality=Best
|
||||
/build:sounds/DoomTestSong.mp3
|
||||
|
||||
#begin sounds/shotgun_shot.mp3
|
||||
/importer:Mp3Importer
|
||||
/processor:SoundEffectProcessor
|
||||
/processorParam:Quality=Best
|
||||
/build:sounds/shotgun_shot.mp3
|
||||
|
||||
#begin SmokeAnimation2.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:SmokeAnimation2.png
|
||||
|
||||
#begin textboxbackground1-1.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:textboxbackground1-1.png
|
||||
|
||||
#begin textboxbackground2,5-1.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:textboxbackground2,5-1.png
|
||||
|
||||
#begin textboxbackground2-1.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:textboxbackground2-1.png
|
||||
|
||||
#begin textboxbackground6-1.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
/processorParam:ColorKeyColor=255,0,255,255
|
||||
/processorParam:ColorKeyEnabled=True
|
||||
/processorParam:GenerateMipmaps=False
|
||||
/processorParam:PremultiplyAlpha=True
|
||||
/processorParam:ResizeToPowerOfTwo=False
|
||||
/processorParam:MakeSquare=False
|
||||
/processorParam:TextureFormat=Color
|
||||
/build:textboxbackground6-1.png
|
||||
|
||||
#begin tiles.png
|
||||
/importer:TextureImporter
|
||||
/processor:TextureProcessor
|
||||
|
|
4
DangerousD/Content/Door.tsx
Normal file
|
@ -0,0 +1,4 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<tileset version="1.10" tiledversion="1.10.2" name="Door" tilewidth="32" tileheight="48" tilecount="2" columns="2">
|
||||
<image source="door.png" width="64" height="48"/>
|
||||
</tileset>
|
64
DangerousD/Content/Font_12.spritefont
Normal file
|
@ -0,0 +1,64 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
This file contains an xml description of a font, and will be read by the XNA
|
||||
Framework Content Pipeline. Follow the comments to customize the appearance
|
||||
of the font in your game, and to change the characters which are available to draw
|
||||
with.
|
||||
-->
|
||||
<XnaContent xmlns:Graphics="Microsoft.Xna.Framework.Content.Pipeline.Graphics">
|
||||
<Asset Type="Graphics:FontDescription">
|
||||
|
||||
<!--
|
||||
Modify this string to change the font that will be imported.
|
||||
-->
|
||||
<FontName>Arial</FontName>
|
||||
|
||||
<!--
|
||||
Size is a float value, measured in points. Modify this value to change
|
||||
the size of the font.
|
||||
-->
|
||||
<Size>12</Size>
|
||||
|
||||
<!--
|
||||
Spacing is a float value, measured in pixels. Modify this value to change
|
||||
the amount of spacing in between characters.
|
||||
-->
|
||||
<Spacing>0</Spacing>
|
||||
|
||||
<!--
|
||||
UseKerning controls the layout of the font. If this value is true, kerning information
|
||||
will be used when placing characters.
|
||||
-->
|
||||
<UseKerning>true</UseKerning>
|
||||
|
||||
<!--
|
||||
Style controls the style of the font. Valid entries are "Regular", "Bold", "Italic",
|
||||
and "Bold, Italic", and are case sensitive.
|
||||
-->
|
||||
<Style>Regular</Style>
|
||||
|
||||
<!--
|
||||
If you uncomment this line, the default character will be substituted if you draw
|
||||
or measure text that contains characters which were not included in the font.
|
||||
-->
|
||||
<!-- <DefaultCharacter>*</DefaultCharacter> -->
|
||||
|
||||
<!--
|
||||
CharacterRegions control what letters are available in the font. Every
|
||||
character from Start to End will be built and made available for drawing. The
|
||||
default range is from 32, (ASCII space), to 126, ('~'), covering the basic Latin
|
||||
character set. The characters are ordered according to the Unicode standard.
|
||||
See the documentation for more information.
|
||||
-->
|
||||
<CharacterRegions>
|
||||
<CharacterRegion>
|
||||
<Start> </Start>
|
||||
<End>~</End>
|
||||
</CharacterRegion>
|
||||
<CharacterRegion>
|
||||
<Start>а</Start>
|
||||
<End>я</End>
|
||||
</CharacterRegion>
|
||||
</CharacterRegions>
|
||||
</Asset>
|
||||
</XnaContent>
|
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 22 KiB |
64
DangerousD/Content/PixelFont.spritefont
Normal file
|
@ -0,0 +1,64 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
This file contains an xml description of a font, and will be read by the XNA
|
||||
Framework Content Pipeline. Follow the comments to customize the appearance
|
||||
of the font in your game, and to change the characters which are available to draw
|
||||
with.
|
||||
-->
|
||||
<XnaContent xmlns:Graphics="Microsoft.Xna.Framework.Content.Pipeline.Graphics">
|
||||
<Asset Type="Graphics:FontDescription">
|
||||
|
||||
<!--
|
||||
Modify this string to change the font that will be imported.
|
||||
-->
|
||||
<FontName>PublicPixel-z84yD.ttf</FontName>
|
||||
|
||||
<!--
|
||||
Size is a float value, measured in points. Modify this value to change
|
||||
the size of the font.
|
||||
-->
|
||||
<Size>12</Size>
|
||||
|
||||
<!--
|
||||
Spacing is a float value, measured in pixels. Modify this value to change
|
||||
the amount of spacing in between characters.
|
||||
-->
|
||||
<Spacing>0</Spacing>
|
||||
|
||||
<!--
|
||||
UseKerning controls the layout of the font. If this value is true, kerning information
|
||||
will be used when placing characters.
|
||||
-->
|
||||
<UseKerning>true</UseKerning>
|
||||
|
||||
<!--
|
||||
Style controls the style of the font. Valid entries are "Regular", "Bold", "Italic",
|
||||
and "Bold, Italic", and are case sensitive.
|
||||
-->
|
||||
<Style>Regular</Style>
|
||||
|
||||
<!--
|
||||
If you uncomment this line, the default character will be substituted if you draw
|
||||
or measure text that contains characters which were not included in the font.
|
||||
-->
|
||||
<!-- <DefaultCharacter>*</DefaultCharacter> -->
|
||||
|
||||
<!--
|
||||
CharacterRegions control what letters are available in the font. Every
|
||||
character from Start to End will be built and made available for drawing. The
|
||||
default range is from 32, (ASCII space), to 126, ('~'), covering the basic Latin
|
||||
character set. The characters are ordered according to the Unicode standard.
|
||||
See the documentation for more information.
|
||||
-->
|
||||
<CharacterRegions>
|
||||
<CharacterRegion>
|
||||
<Start> </Start>
|
||||
<End>~</End>
|
||||
</CharacterRegion>
|
||||
<CharacterRegion>
|
||||
<Start>а</Start>
|
||||
<End>я</End>
|
||||
</CharacterRegion>
|
||||
</CharacterRegions>
|
||||
</Asset>
|
||||
</XnaContent>
|
BIN
DangerousD/Content/PublicPixel-z84yD.ttf
Normal file
BIN
DangerousD/Content/SmokeAnimation2.png
Normal file
After Width: | Height: | Size: 20 KiB |
BIN
DangerousD/Content/animation1.png
Normal file
After Width: | Height: | Size: 39 KiB |
1
DangerousD/Content/animations/GibsMoveLeftBottom
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"GibsMoveLeftBottom","textureName":"MonstersAnimations","startSpriteRectangle":{"X":70,"Y":724,"Width":14,"Height":11},"frameSecond":[{"Item1":0,"Item2":6}],"textureFrameInterval":1,"framesCount":2,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/GibsMoveLeftTop
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"GibsMoveLeftTop","textureName":"MonstersAnimations","startSpriteRectangle":{"X":2,"Y":721,"Width":14,"Height":12},"frameSecond":[{"Item1":0,"Item2":8}],"textureFrameInterval":1,"framesCount":2,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/GibsMoveRightBottom
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"GibsMoveRightBottom","textureName":"MonstersAnimations","startSpriteRectangle":{"X":106,"Y":722,"Width":13,"Height":12},"frameSecond":[{"Item1":0,"Item2":6}],"textureFrameInterval":1,"framesCount":2,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/GibsMoveRightTop
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"GibsMoveRightTop","textureName":"MonstersAnimations","startSpriteRectangle":{"X":37,"Y":721,"Width":14,"Height":13},"frameSecond":[{"Item1":0,"Item2":6}],"textureFrameInterval":1,"framesCount":2,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/GibsNotMove
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"GibsNotMove","textureName":"MonstersAnimations","startSpriteRectangle":{"X":137,"Y":731,"Width":16,"Height":5},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":1,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/HunchmanAttackLeft
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"HunchmanAttackLeft","textureName":"MonstersAnimations","startSpriteRectangle":{"X":112,"Y":124,"Width":27,"Height":24},"frameSecond":[{"Item1":0,"Item2":8}],"textureFrameInterval":1,"framesCount":3,"isCycle":true,"offset":"4, 0"}
|
1
DangerousD/Content/animations/HunchmanAttackRight
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"HunchmanAttackRight","textureName":"MonstersAnimations","startSpriteRectangle":{"X":102,"Y":99,"Width":31,"Height":24},"frameSecond":[{"Item1":0,"Item2":8}],"textureFrameInterval":1,"framesCount":3,"isCycle":true,"offset":"8, 0"}
|
1
DangerousD/Content/animations/HunchmanMoveLeft
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"HunchmanMoveLeft","textureName":"MonstersAnimations","startSpriteRectangle":{"X":1,"Y":124,"Width":24,"Height":24},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":4,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/HunchmanMoveRight
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"HunchmanMoveRight","textureName":"MonstersAnimations","startSpriteRectangle":{"X":1,"Y":100,"Width":24,"Height":23},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":4,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeJumpLeftBottom
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeJumpLeftBottom","textureName":"MonstersAnimations","startSpriteRectangle":{"X":176,"Y":157,"Width":24,"Height":16},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":1,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeJumpLeftTop
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeJumpLeftTop","textureName":"MonstersAnimations","startSpriteRectangle":{"X":151,"Y":157,"Width":24,"Height":16},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":1,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeJumpRightBottom
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeJumpRightBottom","textureName":"MonstersAnimations","startSpriteRectangle":{"X":176,"Y":174,"Width":24,"Height":16},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":1,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeJumpRightTop
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeJumpRightTop","textureName":"MonstersAnimations","startSpriteRectangle":{"X":151,"Y":174,"Width":24,"Height":16},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":1,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeMoveLeftBottom
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeMoveLeftBottom","textureName":"MonstersAnimations","startSpriteRectangle":{"X":1,"Y":182,"Width":24,"Height":8},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":2,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeMoveLeftTop
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeMoveLeftTop","textureName":"MonstersAnimations","startSpriteRectangle":{"X":51,"Y":182,"Width":24,"Height":8},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":2,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeMoveRightBottom
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeMoveRightBottom","textureName":"MonstersAnimations","startSpriteRectangle":{"X":1,"Y":165,"Width":24,"Height":8},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":2,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeMoveRightTop
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeMoveRightTop","textureName":"MonstersAnimations","startSpriteRectangle":{"X":51,"Y":165,"Width":24,"Height":8},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":2,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeReadyJumpLeftBottom
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeReadyJumpLeftBottom","textureName":"MonstersAnimations","startSpriteRectangle":{"X":101,"Y":157,"Width":24,"Height":16},"frameSecond":[{"Item1":0,"Item2":30}],"textureFrameInterval":1,"framesCount":1,"isCycle":false,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeReadyJumpLeftTop
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeReadyJumpLeftTop","textureName":"MonstersAnimations","startSpriteRectangle":{"X":126,"Y":157,"Width":24,"Height":16},"frameSecond":[{"Item1":0,"Item2":30}],"textureFrameInterval":1,"framesCount":1,"isCycle":false,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeReadyJumpRightBottom
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeReadyJumpRightBottom","textureName":"MonstersAnimations","startSpriteRectangle":{"X":101,"Y":174,"Width":24,"Height":16},"frameSecond":[{"Item1":0,"Item2":30}],"textureFrameInterval":1,"framesCount":1,"isCycle":false,"offset":"0, 0"}
|
1
DangerousD/Content/animations/SlimeReadyJumpRightTop
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"SlimeReadyJumpRightTop","textureName":"MonstersAnimations","startSpriteRectangle":{"X":126,"Y":174,"Width":24,"Height":16},"frameSecond":[{"Item1":0,"Item2":30}],"textureFrameInterval":1,"framesCount":1,"isCycle":false,"offset":"0, 0"}
|
|
@ -1 +1 @@
|
|||
{"id":"WolfMoveLeft","textureName":"MonstersAnimations","startSpriteRectangle":{"X":1,"Y":292,"Width":32,"Height":32},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":4,"isCycle":true,"offset":"0, 0"}
|
||||
{"id":"WolfMoveLeft","textureName":"MonstersAnimations","startSpriteRectangle":{"X":1,"Y":291,"Width":32,"Height":32},"frameSecond":[{"Item1":0,"Item2":10}],"textureFrameInterval":1,"framesCount":4,"isCycle":true,"offset":"0, 0"}
|
||||
|
|
1
DangerousD/Content/animations/playerJumpLeft
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"playerJumpLeft","textureName":"playerAnimation","startSpriteRectangle":{"X":101,"Y":34,"Width":24,"Height":32},"frameSecond":[{"Item1":0,"Item2":12}],"textureFrameInterval":1,"framesCount":3,"isCycle":false,"offset":"0, 0"}
|
1
DangerousD/Content/animations/playerJumpRight
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"playerJumpRight","textureName":"playerAnimation","startSpriteRectangle":{"X":126,"Y":1,"Width":24,"Height":32},"frameSecond":[{"Item1":0,"Item2":12}],"textureFrameInterval":1,"framesCount":3,"isCycle":false,"offset":"0, 0"}
|
20
DangerousD/Content/animations/playerMoveLeft
Normal file
|
@ -0,0 +1,20 @@
|
|||
{
|
||||
"id": "playerMoveLeft",
|
||||
"textureName": "playerAnimation",
|
||||
"startSpriteRectangle": {
|
||||
"X": 26,
|
||||
"Y": 34,
|
||||
"Width": 24,
|
||||
"Height": 32
|
||||
},
|
||||
"frameSecond": [
|
||||
{
|
||||
"Item1": 0,
|
||||
"Item2": 8
|
||||
}
|
||||
],
|
||||
"textureFrameInterval": 1,
|
||||
"framesCount": 4,
|
||||
"isCycle": true,
|
||||
"offset": "0, 0"
|
||||
}
|
20
DangerousD/Content/animations/playerMoveRight
Normal file
|
@ -0,0 +1,20 @@
|
|||
{
|
||||
"id": "playerMoveRight",
|
||||
"textureName": "playerAnimation",
|
||||
"startSpriteRectangle": {
|
||||
"X": 26,
|
||||
"Y": 1,
|
||||
"Width": 24,
|
||||
"Height": 32
|
||||
},
|
||||
"frameSecond": [
|
||||
{
|
||||
"Item1": 0,
|
||||
"Item2": 8
|
||||
}
|
||||
],
|
||||
"textureFrameInterval": 1,
|
||||
"framesCount": 4,
|
||||
"isCycle": true,
|
||||
"offset": "0, 0"
|
||||
}
|
1
DangerousD/Content/animations/playerReload
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"playerReload","textureName":"playerAnimation","startSpriteRectangle":{"X":101,"Y":67,"Width":24,"Height":32},"frameSecond":[{"Item1":0,"Item2":12}],"textureFrameInterval":1,"framesCount":2,"isCycle":false,"offset":"0, 0"}
|
1
DangerousD/Content/animations/playerRightStay
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"playerRightStay","textureName":"playerAnimation","startSpriteRectangle":{"X":1,"Y":1,"Width":24,"Height":32},"frameSecond":[{"Item1":0,"Item2":12}],"textureFrameInterval":1,"framesCount":1,"isCycle":true,"offset":"0, 0"}
|
24
DangerousD/Content/animations/playerShootLeft
Normal file
|
@ -0,0 +1,24 @@
|
|||
{
|
||||
"id": "playerShootLeft",
|
||||
"textureName": "playerAnimation",
|
||||
"startSpriteRectangle": {
|
||||
"X": 201,
|
||||
"Y": 34,
|
||||
"Width": 32,
|
||||
"Height": 32
|
||||
},
|
||||
"frameSecond": [
|
||||
{
|
||||
"Item1": 0,
|
||||
"Item2": 3
|
||||
},
|
||||
{
|
||||
"Item1": 1,
|
||||
"Item2": 20
|
||||
}
|
||||
],
|
||||
"textureFrameInterval": 1,
|
||||
"framesCount": 2,
|
||||
"isCycle": false,
|
||||
"offset": "4, 0"
|
||||
}
|
24
DangerousD/Content/animations/playerShootRight
Normal file
|
@ -0,0 +1,24 @@
|
|||
{
|
||||
"id": "playerShootRight",
|
||||
"textureName": "playerAnimation",
|
||||
"startSpriteRectangle": {
|
||||
"X": 201,
|
||||
"Y": 1,
|
||||
"Width": 32,
|
||||
"Height": 32
|
||||
},
|
||||
"frameSecond": [
|
||||
{
|
||||
"Item1": 0,
|
||||
"Item2": 3
|
||||
},
|
||||
{
|
||||
"Item1": 1,
|
||||
"Item2": 20
|
||||
}
|
||||
],
|
||||
"textureFrameInterval": 1,
|
||||
"framesCount": 2,
|
||||
"isCycle": false,
|
||||
"offset": "4, 0"
|
||||
}
|
1
DangerousD/Content/animations/playerShootUpLeft
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"playerShootUpLeft","textureName":"playerAnimation","startSpriteRectangle":{"X":267,"Y":34,"Width":24,"Height":32},"frameSecond":[{"Item1":0,"Item2":12}],"textureFrameInterval":1,"framesCount":1,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/playerShootUpRight
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"playerShootUpRight","textureName":"playerAnimation","startSpriteRectangle":{"X":267,"Y":1,"Width":24,"Height":32},"frameSecond":[{"Item1":0,"Item2":12}],"textureFrameInterval":1,"framesCount":1,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/playerStayLeft
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"playerStayLeft","textureName":"playerAnimation","startSpriteRectangle":{"X":1,"Y":34,"Width":24,"Height":32},"frameSecond":[{"Item1":0,"Item2":12}],"textureFrameInterval":1,"framesCount":1,"isCycle":true,"offset":"0, 0"}
|
1
DangerousD/Content/animations/smokeAfterShoot
Normal file
|
@ -0,0 +1 @@
|
|||
{"id":"smokeAfterShoot","textureName":"smokeAnimation2","startSpriteRectangle":{"X":0,"Y":0,"Width":64,"Height":64},"frameSecond":[{"Item1":0,"Item2":3}],"textureFrameInterval":1,"framesCount":10,"isCycle":false,"offset":"0, 0"}
|
162
DangerousD/Content/boss.tmx
Normal file
|
@ -0,0 +1,162 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<map version="1.10" tiledversion="1.10.2" orientation="orthogonal" renderorder="right-down" width="200" height="200" tilewidth="16" tileheight="16" infinite="1" nextlayerid="4" nextobjectid="3">
|
||||
<tileset firstgid="1" source="../../../../../Desktop/DangerousD map/map.tsx"/>
|
||||
<layer id="1" name="Слой тайлов 1" class="StopTile" width="200" height="200">
|
||||
<data encoding="csv">
|
||||
<chunk x="-16" y="-32" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,799,799,799,799,799,799,799,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="0" y="-32" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
799,799,799,799,799,799,799,799,799,799,799,799,799,799,799,799,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="-32" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
799,799,799,799,799,799,799,799,799,799,799,799,799,799,799,799,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="32" y="-32" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
799,799,799,799,799,799,799,799,799,799,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="-16" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,799,799,799,799,799,799,799,799
|
||||
</chunk>
|
||||
<chunk x="0" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
799,799,799,799,799,799,799,799,799,799,799,799,799,799,799,799
|
||||
</chunk>
|
||||
<chunk x="16" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
799,799,799,799,799,799,799,799,799,799,799,799,799,799,799,799
|
||||
</chunk>
|
||||
<chunk x="32" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,799,0,0,0,0,0,
|
||||
799,799,799,799,799,799,799,799,799,799,799,0,0,0,0,0
|
||||
</chunk>
|
||||
</data>
|
||||
</layer>
|
||||
<objectgroup id="2" name="Слой объектов 1" class="LivingEntities">
|
||||
<object id="1" name="DEBUGUS" type="Player" x="293.333" y="-126.667">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
<objectgroup id="3" name="Слой объектов 2" class="LivingEntities.Monsters">
|
||||
<object id="2" type="SilasMaster" x="82.6667" y="-186.667">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
</map>
|
BIN
DangerousD/Content/checkboxs_off-on.png
Normal file
After Width: | Height: | Size: 9.1 KiB |
BIN
DangerousD/Content/checkboxs_off.png
Normal file
After Width: | Height: | Size: 7.8 KiB |
BIN
DangerousD/Content/checkboxs_on.png
Normal file
After Width: | Height: | Size: 9.7 KiB |
BIN
DangerousD/Content/deathBackground.jpg
Normal file
After Width: | Height: | Size: 396 KiB |
373
DangerousD/Content/debug.tmx
Normal file
|
@ -0,0 +1,373 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<map version="1.10" tiledversion="1.10.2" orientation="orthogonal" renderorder="left-up" width="200" height="200" tilewidth="16" tileheight="16" infinite="1" nextlayerid="8" nextobjectid="49">
|
||||
<tileset firstgid="1" source="../Documents/Github_repos/DangerousD/DangerousD/Content/map.tsx"/>
|
||||
<layer id="3" name="Слой тайлов 3" class="Tile" width="200" height="200">
|
||||
<data encoding="csv">
|
||||
<chunk x="0" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570
|
||||
</chunk>
|
||||
<chunk x="16" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570
|
||||
</chunk>
|
||||
<chunk x="0" y="0" width="16" height="16">
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="0" width="16" height="16">
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
</data>
|
||||
</layer>
|
||||
<layer id="1" name="Collidable" class="StopTile" width="200" height="200">
|
||||
<data encoding="csv">
|
||||
<chunk x="-32" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,50,50,50,50,50,
|
||||
0,0,0,0,0,0,0,0,0,0,0,50,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,50,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,49,49,49,49,49,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="-16" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
50,50,50,50,50,50,50,50,50,50,50,50,50,50,50,50,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="0" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
371,371,371,371,371,371,371,371,371,371,371,371,371,371,371,371,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
371,371,371,371,371,371,371,371,371,371,371,371,371,371,371,371,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="32" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,49,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,49,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="48" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,49,0,0,0,
|
||||
49,49,49,49,49,49,49,49,49,49,49,49,49,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
</data>
|
||||
</layer>
|
||||
<objectgroup id="7" name="Player" class="LivingEntities">
|
||||
<object id="42" name="DEBUGUS" type="Player" x="236.506" y="-54.4681">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
<objectgroup id="6" name="Zombies" class="LivingEntities.Monsters.Zombie">
|
||||
<object id="17" x="568" y="130">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="18" x="614" y="126">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="19" x="656" y="137">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="20" x="688" y="124">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="21" x="739" y="128">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="22" x="754" y="127">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="23" x="777" y="125">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="24" x="803" y="127">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="25" x="834" y="128">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="26" x="867" y="124">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="27" x="876" y="123">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="28" x="909" y="114">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="29" x="933" y="108">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="30" x="931" y="65">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="31" x="880" y="74">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="32" x="829" y="76">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="33" x="804" y="78">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="34" x="772" y="78">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="35" x="740" y="77">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="36" x="713" y="73">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="37" x="684" y="73">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="38" x="659" y="75">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="39" x="632" y="82">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="40" x="612" y="89">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="41" x="604" y="92">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
<layer id="2" name="Слой тайлов 2" class="Tile" width="200" height="200">
|
||||
<data encoding="csv">
|
||||
<chunk x="0" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370
|
||||
</chunk>
|
||||
<chunk x="0" y="0" width="16" height="16">
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
369,370,0,0,0,0,0,0,0,0,369,370,0,0,0,0,
|
||||
382,383,0,0,0,0,0,0,0,0,382,383,0,0,0,0,
|
||||
395,396,0,0,0,0,0,0,0,0,395,396,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="0" width="16" height="16">
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,369,370,0,0,0,0,0,0,0,0,369,370,
|
||||
0,0,0,0,382,383,0,0,0,0,0,0,0,0,382,383,
|
||||
0,0,0,0,395,396,0,0,0,0,0,0,0,0,395,396,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
</data>
|
||||
</layer>
|
||||
<objectgroup id="5" name="Various enemies" class="LivingEntities.Monsters">
|
||||
<object id="7" type="SilasMaster" x="126" y="-25">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="8" type="Frank" x="425" y="60">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="10" type="FrankBalls" x="413" y="50">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="11" type="FrankBalls" x="439" y="52">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="12" type="FlameSkull" x="649" y="-17">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="13" type="Slime" x="-178" y="118">
|
||||
<point/>
|
||||
</object>
|
||||
<object id="15" type="Spider" x="-94" y="109.333">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
</map>
|
BIN
DangerousD/Content/doors.png
Normal file
After Width: | Height: | Size: 472 B |
|
@ -1,7 +1,13 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<map version="1.10" tiledversion="1.10.2" orientation="orthogonal" renderorder="left-up" width="30" height="20" tilewidth="16" tileheight="16" infinite="1" nextlayerid="11" nextobjectid="49">
|
||||
<tileset firstgid="1" source="map.tsx"/>
|
||||
<layer id="1" name="Collision" class="StopTile" width="30" height="20" locked="1" offsetx="-352.033" offsety="192.098">
|
||||
<map version="1.10" tiledversion="1.10.2" orientation="orthogonal" renderorder="left-up" width="30" height="20" tilewidth="16" tileheight="16" infinite="1" nextlayerid="15" nextobjectid="80">
|
||||
<tileset firstgid="1" name="map" tilewidth="16" tileheight="16" tilecount="871" columns="13">
|
||||
<image source="tiles.BMP" width="208" height="1072"/>
|
||||
</tileset>
|
||||
<tileset firstgid="872" name="Door" tilewidth="32" tileheight="48" tilecount="2" columns="2">
|
||||
<image source="doors.png" width="64" height="48"/>
|
||||
</tileset>
|
||||
<tileset firstgid="874" source="../../../../../Desktop/deathAnimation.tsx"/>
|
||||
<layer id="1" name="Collidable" class="StopTile" width="30" height="20" visible="0" offsetx="-352.033" offsety="192.098">
|
||||
<data encoding="csv">
|
||||
<chunk x="0" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
|
@ -31,13 +37,13 @@
|
|||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,272,0,272,0,0,0,0,0,0,0,0,0,0,
|
||||
52,52,52,52,0,52,52,52,52,52,52,52,52,52,52,52,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
272,0,0,0,0,0,0,0,272,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="32" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
|
@ -130,19 +136,19 @@
|
|||
0,0,0,0,0,0,0,0,0,0,13,75,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="0" width="16" height="16">
|
||||
52,0,0,0,52,0,0,0,52,52,52,52,52,52,52,52,
|
||||
52,0,0,0,0,0,0,0,52,52,52,52,52,52,52,52,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
52,52,0,0,52,0,0,52,52,52,52,52,52,52,52,52,
|
||||
0,272,0,0,0,0,0,272,0,0,0,0,0,0,0,0,
|
||||
52,52,0,0,0,0,0,52,52,52,52,52,52,52,52,52,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
52,52,52,0,52,0,52,52,52,52,52,52,52,52,52,52,
|
||||
0,0,272,0,0,0,272,0,0,0,0,0,0,0,0,0,
|
||||
52,52,52,0,0,0,52,52,52,52,52,52,52,52,52,52,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
|
@ -202,7 +208,7 @@
|
|||
0,0,0,75,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="-16" y="16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,46,0,0,66,67,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,66,67,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,66,67,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,66,67,0,
|
||||
0,0,0,0,0,0,76,76,76,76,76,76,76,76,76,76,
|
||||
|
@ -311,137 +317,7 @@
|
|||
</chunk>
|
||||
</data>
|
||||
</layer>
|
||||
<layer id="4" name="Background 2" class="Tile" width="30" height="20" visible="0" locked="1">
|
||||
<data encoding="csv">
|
||||
<chunk x="0" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,149,152,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,150,153,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,151,154,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,149,152,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,150,153,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,151,154,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,149,152,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="32" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,79,80,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,92,93,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,105,106,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,149,152,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,150,153,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,151,154,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,149,152,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="-16" y="16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,149,152,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,150,153,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,151,154,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="0" y="16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,149,152,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,150,153,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,151,154,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="16" width="16" height="16">
|
||||
0,0,0,0,150,153,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,151,154,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="32" y="16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,150,153,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,151,154,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,149,152,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,150,153,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,151,154,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,149,152,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,150,153,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,151,154,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
</data>
|
||||
</layer>
|
||||
<layer id="6" name="Ladders" class="Platform" width="30" height="20" locked="1">
|
||||
<layer id="6" name="Ladders" class="Platform" width="30" height="20" visible="0" offsetx="-1" offsety="0">
|
||||
<data encoding="csv">
|
||||
<chunk x="-16" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
|
@ -460,13 +336,31 @@
|
|||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,147,199,148,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="0" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,696,697,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,696,697,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="32" y="0" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,147,199,199,148,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
|
@ -478,6 +372,24 @@
|
|||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,147,199,148,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="-32" y="16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,46,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="-16" y="16" width="16" height="16">
|
||||
0,0,0,0,0,0,147,199,148,0,0,0,0,0,0,0,
|
||||
|
@ -496,6 +408,42 @@
|
|||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="0" y="16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,696,697,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,696,697,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="32" y="16" width="16" height="16">
|
||||
0,0,0,147,199,148,0,0,0,0,0,0,0,0,0,0,
|
||||
|
@ -517,7 +465,7 @@
|
|||
</chunk>
|
||||
</data>
|
||||
</layer>
|
||||
<layer id="3" name="Backgrond" class="Tile" width="30" height="20" visible="0" locked="1" offsetx="-256.033" offsety="256.098">
|
||||
<layer id="3" name="Backgrond" class="Tile" width="30" height="20" offsetx="-256.033" offsety="256.098">
|
||||
<data encoding="csv">
|
||||
<chunk x="-16" y="-16" width="16" height="16">
|
||||
29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,
|
||||
|
@ -543,13 +491,13 @@
|
|||
29,29,29,29,0,0,157,157,167,157,157,157,157,157,260,157,
|
||||
29,29,29,29,0,0,157,157,180,157,254,255,157,157,260,157,
|
||||
29,29,29,29,0,0,157,157,193,157,267,268,157,157,260,157,
|
||||
29,29,29,29,0,0,204,204,204,204,280,281,204,272,260,272,
|
||||
29,29,29,29,0,0,204,204,204,204,280,281,204,0,260,0,
|
||||
29,29,29,29,0,0,147,199,148,0,0,0,0,0,260,0,
|
||||
29,29,29,29,0,0,147,199,148,144,144,144,144,144,260,144,
|
||||
29,29,29,29,0,0,147,199,148,157,157,157,157,157,260,157,
|
||||
29,29,29,29,0,0,147,199,148,157,157,157,157,157,260,157,
|
||||
29,29,29,29,0,0,147,199,148,157,157,157,157,157,260,157,
|
||||
29,29,29,29,0,0,147,199,148,204,272,157,157,157,260,157,
|
||||
29,29,29,29,0,0,147,199,148,204,0,157,157,157,260,157,
|
||||
29,29,29,29,0,0,147,199,148,0,0,157,157,157,260,157,
|
||||
29,29,29,29,0,0,147,199,148,144,144,157,157,157,260,157,
|
||||
29,29,29,29,0,0,147,199,148,157,157,157,157,157,260,157,
|
||||
|
@ -559,15 +507,15 @@
|
|||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,
|
||||
157,157,157,178,179,157,157,157,157,157,157,157,157,157,157,157,
|
||||
157,157,157,191,192,157,157,252,253,157,157,157,157,157,157,258,
|
||||
157,157,157,157,157,157,157,265,266,157,157,157,696,697,157,271,
|
||||
204,204,204,204,204,204,204,278,279,204,204,204,709,710,204,284,
|
||||
157,157,157,191,192,157,157,149,152,157,157,157,157,157,157,258,
|
||||
157,157,157,157,157,157,157,150,153,157,157,157,696,697,157,271,
|
||||
204,204,204,204,204,204,204,151,154,204,204,204,709,710,204,284,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,
|
||||
157,157,157,157,157,157,157,157,157,157,157,157,157,157,157,157,
|
||||
157,157,157,157,157,157,258,157,157,157,252,253,157,157,157,157,
|
||||
157,157,157,157,157,157,271,157,157,157,265,266,157,696,697,157,
|
||||
157,157,272,204,204,204,284,204,204,204,278,279,204,709,710,204,
|
||||
157,157,157,157,157,157,258,157,157,157,149,152,157,157,157,157,
|
||||
157,157,157,157,157,157,271,157,157,157,150,153,157,0,0,157,
|
||||
157,157,0,204,204,204,284,204,204,204,151,154,204,709,710,204,
|
||||
157,157,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
157,157,144,144,144,144,144,144,144,144,144,144,144,144,144,144,
|
||||
157,157,157,157,157,157,157,157,157,157,157,167,157,157,209,210,
|
||||
|
@ -589,25 +537,25 @@
|
|||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,
|
||||
211,212,157,157,157,157,157,157,157,157,157,157,157,157,157,157,
|
||||
224,225,157,157,252,253,157,248,249,157,157,258,157,157,157,157
|
||||
224,225,157,157,149,152,157,248,249,157,157,258,157,157,157,157
|
||||
</chunk>
|
||||
<chunk x="48" y="-16" width="16" height="16">
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,144,144,144,144,144,621,622,144,144,144,0,0,0,
|
||||
157,157,157,157,157,157,157,157,634,635,157,157,157,0,0,0,
|
||||
157,248,249,157,157,157,272,157,647,648,157,272,157,0,0,0,
|
||||
144,144,144,144,144,144,144,144,79,80,144,144,144,0,0,0,
|
||||
157,157,157,157,157,157,157,157,92,93,157,157,157,0,0,0,
|
||||
157,248,249,157,157,157,272,157,105,106,157,272,157,0,0,0,
|
||||
157,250,251,157,157,157,145,147,199,200,148,145,157,0,0,0,
|
||||
204,239,240,204,204,204,204,160,199,200,161,204,204,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,144,144,144,144,144,144,144,144,144,144,0,0,0,
|
||||
178,179,157,157,157,157,157,243,157,157,157,157,157,0,0,0,
|
||||
191,192,157,157,157,157,157,256,257,157,252,253,157,0,0,0,
|
||||
157,157,157,157,157,157,157,269,270,157,265,266,157,0,0,0,
|
||||
204,204,204,204,204,204,204,282,283,204,278,279,204,0,0,0,
|
||||
191,192,157,157,157,157,157,256,257,157,149,152,157,0,0,0,
|
||||
157,157,157,157,157,157,157,269,270,157,150,153,157,0,0,0,
|
||||
204,204,204,204,204,204,204,282,283,204,151,154,204,0,0,0,
|
||||
0,0,0,147,199,148,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,147,199,148,144,144,144,144,144,144,144,0,0,0,
|
||||
157,157,157,147,199,148,157,243,157,157,157,157,157,0,0,0,
|
||||
254,255,157,147,199,148,157,256,257,157,252,253,157,0,0,0
|
||||
254,255,157,147,199,148,157,256,257,157,149,152,157,0,0,0
|
||||
</chunk>
|
||||
<chunk x="-16" y="0" width="16" height="16">
|
||||
29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,
|
||||
|
@ -622,20 +570,20 @@
|
|||
29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,
|
||||
29,29,29,19,20,21,22,0,0,29,29,29,29,29,29,29,
|
||||
29,30,31,32,33,34,35,0,0,29,29,29,29,29,29,29,
|
||||
29,43,44,45,46,47,48,0,0,29,29,29,29,29,29,29,
|
||||
29,43,44,45,0,47,48,0,0,29,29,29,29,29,29,29,
|
||||
64,65,18,58,59,60,18,0,0,29,29,29,29,29,29,29,
|
||||
77,78,18,71,72,73,18,0,0,68,56,56,55,56,56,69,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="0" y="0" width="16" height="16">
|
||||
29,29,29,29,0,0,147,199,148,157,157,157,157,157,260,157,
|
||||
29,29,29,29,0,0,160,200,161,204,204,272,157,157,260,157,
|
||||
29,29,29,29,0,0,160,200,161,204,204,0,157,157,260,157,
|
||||
29,29,29,29,0,0,0,0,0,0,0,0,157,157,260,157,
|
||||
29,29,29,29,0,0,144,144,144,144,144,144,157,157,260,157,
|
||||
29,29,29,29,0,0,157,167,157,157,157,157,157,157,260,157,
|
||||
29,29,29,29,0,0,157,180,157,252,253,157,157,157,260,157,
|
||||
29,29,29,29,0,0,157,193,157,265,266,157,157,157,260,157,
|
||||
6,29,29,29,0,0,204,204,204,278,279,204,272,157,260,157,
|
||||
29,29,29,29,0,0,157,180,157,149,152,157,157,157,260,157,
|
||||
29,29,29,29,0,0,157,193,157,150,153,157,157,157,260,157,
|
||||
6,29,29,29,0,0,204,204,204,151,154,204,0,157,260,157,
|
||||
29,29,29,29,0,0,0,0,0,0,0,0,0,157,260,157,
|
||||
29,29,29,29,0,0,144,144,144,144,144,144,144,157,260,157,
|
||||
29,29,29,29,0,0,157,157,157,157,157,157,157,219,220,221,
|
||||
|
@ -646,26 +594,26 @@
|
|||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="16" y="0" width="16" height="16">
|
||||
157,157,157,157,267,268,157,696,697,157,157,193,157,157,235,236,
|
||||
157,272,204,204,280,281,204,709,710,204,204,204,204,204,204,204,
|
||||
157,157,157,157,267,268,157,0,0,157,157,193,157,157,235,236,
|
||||
157,0,204,204,280,281,204,709,710,204,204,204,204,204,204,204,
|
||||
157,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
157,144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,
|
||||
157,157,157,178,179,157,157,157,157,157,157,157,157,157,157,157,
|
||||
157,157,157,191,192,157,248,249,157,157,157,157,157,157,157,157,
|
||||
157,157,157,157,157,157,250,251,157,217,261,262,263,264,217,157,
|
||||
272,204,204,204,204,204,239,240,204,230,274,275,276,277,230,204,
|
||||
0,204,204,204,204,204,239,240,204,230,274,275,276,277,230,204,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,
|
||||
157,157,157,157,157,157,157,157,243,157,157,209,210,211,212,157,
|
||||
157,252,253,157,157,258,157,157,256,257,157,222,223,224,225,157,
|
||||
218,265,266,157,157,271,157,157,269,270,157,235,236,237,238,157,
|
||||
231,278,279,204,204,284,204,204,282,283,204,204,204,204,204,204,
|
||||
157,149,152,157,157,258,157,157,256,257,157,222,223,224,225,157,
|
||||
218,150,153,157,157,271,157,157,269,270,157,235,236,237,238,157,
|
||||
231,151,154,204,204,284,204,204,282,283,204,204,204,204,204,204,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="32" y="0" width="16" height="16">
|
||||
237,238,157,157,265,266,157,250,251,157,157,271,157,157,157,157,
|
||||
204,204,204,204,278,279,204,239,240,204,204,284,204,204,204,204,
|
||||
237,238,157,157,150,153,157,250,251,157,157,271,157,157,157,157,
|
||||
204,204,204,204,151,154,204,239,240,204,204,284,204,204,204,204,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,
|
||||
157,157,157,157,157,157,157,157,157,243,157,157,209,210,211,212,
|
||||
|
@ -676,32 +624,32 @@
|
|||
144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,144,
|
||||
157,157,178,179,157,157,157,157,157,157,157,157,157,157,157,157,
|
||||
157,157,191,192,157,157,157,157,258,157,157,157,248,249,157,157,
|
||||
157,157,157,157,157,696,697,157,271,157,157,157,250,251,157,157,
|
||||
157,157,157,157,157,0,0,157,271,157,157,157,250,251,157,157,
|
||||
204,204,204,204,204,709,710,204,284,204,204,204,239,240,204,204,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
<chunk x="48" y="0" width="16" height="16">
|
||||
267,268,157,147,199,148,157,269,270,157,265,266,218,0,0,0,
|
||||
280,281,204,160,200,161,204,282,283,204,278,279,231,0,0,0,
|
||||
267,268,157,147,199,148,157,269,270,157,150,153,218,0,0,0,
|
||||
280,281,204,160,200,161,204,282,283,204,151,154,231,0,0,0,
|
||||
0,0,0,147,199,148,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,147,199,148,144,144,144,144,144,144,144,0,0,0,
|
||||
157,157,157,147,199,148,157,157,157,157,157,157,157,0,0,0,
|
||||
157,157,157,147,199,148,157,157,157,157,252,253,157,0,0,0,
|
||||
157,157,157,147,199,148,157,217,157,157,265,266,157,0,0,0,
|
||||
204,204,204,160,200,161,204,230,204,204,278,279,204,0,0,0,
|
||||
157,157,157,147,199,148,157,157,157,157,149,152,157,0,0,0,
|
||||
157,157,157,147,199,148,157,217,157,157,150,153,157,0,0,0,
|
||||
204,204,204,160,200,161,204,230,204,204,151,154,204,0,0,0,
|
||||
0,0,0,147,199,148,0,0,0,0,0,0,0,0,0,0,
|
||||
144,144,144,147,199,148,144,144,144,144,144,144,144,0,0,0,
|
||||
157,157,159,160,200,161,162,157,157,157,157,157,157,0,0,0,
|
||||
157,171,172,173,199,174,175,176,157,157,252,253,157,0,0,0,
|
||||
183,184,185,186,199,187,188,189,190,157,265,266,157,0,0,0,
|
||||
196,197,198,199,199,200,201,202,203,204,278,279,204,0,0,0,
|
||||
157,171,172,173,199,174,175,176,157,157,149,152,157,0,0,0,
|
||||
183,184,185,186,199,187,188,189,190,157,150,153,157,0,0,0,
|
||||
196,197,198,199,199,200,201,202,203,204,151,154,204,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
|
||||
</chunk>
|
||||
</data>
|
||||
</layer>
|
||||
<objectgroup id="8" name="Zombies" class="LivingEntities.Monsters.Zombie" locked="1">
|
||||
<objectgroup id="8" name="Zombies" class="LivingEntities.Monsters.Zombie">
|
||||
<object id="26" x="265" y="469.5">
|
||||
<point/>
|
||||
</object>
|
||||
|
@ -752,8 +700,20 @@
|
|||
</object>
|
||||
</objectgroup>
|
||||
<objectgroup id="10" name="Player" class="LivingEntities.Player">
|
||||
<object id="47" x="-260" y="461.333">
|
||||
<object id="47" x="-500" y="461.333">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
<objectgroup id="12" name="Doors" class="Entities.Door">
|
||||
<object id="69" gid="873" x="640" y="64" width="32" height="48"/>
|
||||
<object id="70" gid="872" x="672" y="192" width="32" height="48"/>
|
||||
<object id="71" gid="872" x="672" y="288" width="32" height="48"/>
|
||||
<object id="72" gid="872" x="672" y="480" width="32" height="48"/>
|
||||
<object id="73" gid="872" x="672" y="384" width="32" height="48"/>
|
||||
<object id="74" gid="872" x="320" y="288" width="32" height="48"/>
|
||||
<object id="75" gid="872" x="160" y="192" width="32" height="48"/>
|
||||
<object id="76" gid="872" x="112" y="96" width="32" height="48"/>
|
||||
<object id="77" gid="872" x="16" y="480" width="32" height="48"/>
|
||||
<object id="78" gid="872" x="-112" y="384" width="32" height="48"/>
|
||||
</objectgroup>
|
||||
</map>
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
<<<<<<< HEAD
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<map version="1.10" tiledversion="1.10.2" orientation="orthogonal" renderorder="left-up" width="200" height="200" tilewidth="16" tileheight="16" infinite="1" nextlayerid="5" nextobjectid="5">
|
||||
<tileset firstgid="1" source="../Desktop/DangerousD map/map.tsx"/>
|
||||
|
@ -57,3 +58,80 @@
|
|||
</object>
|
||||
</objectgroup>
|
||||
</map>
|
||||
=======
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<map version="1.10" tiledversion="1.10.2" orientation="orthogonal" renderorder="left-up" width="200" height="200" tilewidth="16" tileheight="16" infinite="1" nextlayerid="5" nextobjectid="5">
|
||||
<tileset firstgid="1" source="../Desktop/DangerousD map/map.tsx"/>
|
||||
<layer id="1" name="Слой тайлов 1" class="StopTile" width="200" height="200">
|
||||
<data encoding="csv">
|
||||
<chunk x="-16" y="0" width="16" height="16">
|
||||
294,294,294,294,294,294,294,294,294,294,294,294,294,294,294,294,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
||||
294,294,294,294,294,294,294,294,294,294,294,294,294,294,294,294
|
||||
</chunk>
|
||||
<chunk x="0" y="0" width="16" height="16">
|
||||
294,294,294,294,294,321,321,321,321,321,321,321,321,321,321,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,321,321,321,321,321,321,321,321,321,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,321,
|
||||
294,294,294,294,321,321,321,321,321,321,321,321,321,321,321,321
|
||||
</chunk>
|
||||
</data>
|
||||
</layer>
|
||||
<objectgroup id="755" name="Zombies" class="LivingEntities.Player" locked="1">
|
||||
<object id="26" x="-50" y="100">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
<objectgroup id="2" name="Слой объектов 1" class="LivingEntities.Monsters.FlameSkull">
|
||||
<object id="1" x="1" y="100">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
<objectgroup id="3" name="Слой объектов 2" class="LivingEntities.Monsters.FrankBalls">
|
||||
<object id="2" x="1" y="100">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
<objectgroup id="4" name="Слой объектов 3" class="LivingEntities.Monsters.Frank">
|
||||
<object id="3" x="-56" y="100">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
<objectgroup id="5" name="Zombies" class="LivingEntities.Monsters.Spider">
|
||||
<object id="4" x="-80" y="100">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
<objectgroup id="2" name="Слой объектов 1" class="LivingEntities.Monsters.Slime">
|
||||
<object id="5" x="1" y="100">
|
||||
<point/>
|
||||
</object>
|
||||
</objectgroup>
|
||||
|
||||
</map>
|
||||
>>>>>>> main
|
||||
|
|
Before Width: | Height: | Size: 197 KiB After Width: | Height: | Size: 7.5 MiB |
BIN
DangerousD/Content/optionsBackground.jpg
Normal file
After Width: | Height: | Size: 252 KiB |
BIN
DangerousD/Content/playerAnimation.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
DangerousD/Content/slider.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
DangerousD/Content/sliderBackground.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
DangerousD/Content/smokeAnimation.png
Normal file
After Width: | Height: | Size: 3.3 KiB |
BIN
DangerousD/Content/sounds/shotgun_shot.mp3
Normal file
BIN
DangerousD/Content/textboxbackground1-1.png
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
DangerousD/Content/textboxbackground2,5-1.png
Normal file
After Width: | Height: | Size: 5.3 KiB |
BIN
DangerousD/Content/textboxbackground2-1.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
DangerousD/Content/textboxbackground6-1.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
DangerousD/Content/tiles.BMP
Normal file
After Width: | Height: | Size: 653 KiB |
|
@ -1,8 +1,14 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Linq;
|
||||
using System.Xml;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Content;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using Microsoft.Xna.Framework.Input;
|
||||
using MonogameLibrary.UI.Base;
|
||||
using MonogameLibrary.UI.Elements;
|
||||
|
||||
namespace DangerousD.GameCore.GUI;
|
||||
|
||||
|
@ -10,6 +16,10 @@ public abstract class AbstractGui : IDrawableObject
|
|||
{
|
||||
protected UIManager Manager = new();
|
||||
protected List<DrawableUIElement> Elements = new();
|
||||
private List<DrawableUIElement> ActiveElements;
|
||||
protected DrawableUIElement SelectedElement;
|
||||
private bool isStartedPrint = false;
|
||||
private bool isPressed = false;
|
||||
|
||||
public AbstractGui()
|
||||
{
|
||||
|
@ -20,8 +30,17 @@ public abstract class AbstractGui : IDrawableObject
|
|||
public virtual void Initialize()
|
||||
{
|
||||
Manager.Initialize(AppManager.Instance.GraphicsDevice);
|
||||
this.graphicsDevice = graphicsDevice;
|
||||
CreateUI();
|
||||
ActiveElements = new List<DrawableUIElement>();
|
||||
foreach (var element in Elements)
|
||||
{
|
||||
if (CheckOnBadElements(element))
|
||||
{
|
||||
ActiveElements.Add(element);
|
||||
}
|
||||
}
|
||||
if (ActiveElements.Count > 0) { SelectedElement = ActiveElements.First(); }
|
||||
|
||||
}
|
||||
|
||||
public virtual void LoadContent()
|
||||
|
@ -31,11 +50,163 @@ public abstract class AbstractGui : IDrawableObject
|
|||
|
||||
public virtual void Update(GameTime gameTime)
|
||||
{
|
||||
Manager.Update();
|
||||
string state = AppManager.Instance.InputManager.currentControlsState;
|
||||
|
||||
|
||||
|
||||
if (ActiveElements.Count != 0)
|
||||
{
|
||||
if (state == "Gamepad")
|
||||
{
|
||||
GamePadState gamePadState = GamePad.GetState(0);
|
||||
GamepadInput(gamePadState);
|
||||
}
|
||||
else if (state == "Keyboard" || state == "Mouse")
|
||||
{
|
||||
KeyboardState keyBoardState = Keyboard.GetState();
|
||||
KeyBoardInput(keyBoardState);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Manager.Update(gameTime);
|
||||
|
||||
if (SelectedElement is not null)
|
||||
{
|
||||
if (SelectedElement is Button)
|
||||
{
|
||||
(SelectedElement as Button).hoverState = MonogameLibrary.UI.Enums.HoverState.Hovering;
|
||||
}
|
||||
if (SelectedElement is ButtonText)
|
||||
{
|
||||
(SelectedElement as ButtonText).hoverState = MonogameLibrary.UI.Enums.HoverState.Hovering;
|
||||
}
|
||||
if (SelectedElement is TextBox)
|
||||
{
|
||||
TextBox box = (TextBox)SelectedElement;
|
||||
box.hoverState = MonogameLibrary.UI.Enums.HoverState.Hovering;
|
||||
if (isStartedPrint)
|
||||
{
|
||||
box.SelectIt();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Draw(SpriteBatch spriteBatch)
|
||||
{
|
||||
Manager.Draw(spriteBatch);
|
||||
}
|
||||
protected virtual void GamepadInput(GamePadState gamePadState)
|
||||
{
|
||||
if (gamePadState.DPad.Up == ButtonState.Pressed && !isPressed)
|
||||
{
|
||||
isPressed = true;
|
||||
ChangeSelectedElement(-1);
|
||||
Debug.WriteLine("switch");
|
||||
}
|
||||
else if (gamePadState.DPad.Down == ButtonState.Pressed && !isPressed)
|
||||
{
|
||||
isPressed = true;
|
||||
ChangeSelectedElement(1);
|
||||
}
|
||||
else if (gamePadState.Buttons.A == ButtonState.Pressed && !isPressed)
|
||||
{
|
||||
isPressed = true;
|
||||
if (SelectedElement is Button)
|
||||
{
|
||||
Button button = SelectedElement as Button;
|
||||
button.CallLeftBtnEvent();
|
||||
}
|
||||
else if (SelectedElement is TextBox)
|
||||
{
|
||||
TextBox textBox = SelectedElement as TextBox;
|
||||
isStartedPrint = true;
|
||||
}
|
||||
}
|
||||
else if (isPressed && (gamePadState.Buttons.A == ButtonState.Released &&
|
||||
gamePadState.DPad.Down == ButtonState.Released &&
|
||||
gamePadState.DPad.Up == ButtonState.Released))
|
||||
{
|
||||
isPressed = false;
|
||||
}
|
||||
}
|
||||
protected virtual void KeyBoardInput(KeyboardState keyboardState)
|
||||
{
|
||||
if (keyboardState.IsKeyDown(Keys.Up) && !isPressed)
|
||||
{
|
||||
isPressed = true;
|
||||
isStartedPrint = false;
|
||||
ChangeSelectedElement(-1);
|
||||
}
|
||||
else if (keyboardState.IsKeyDown(Keys.Down) && !isPressed)
|
||||
{
|
||||
isPressed = true;
|
||||
isStartedPrint = false;
|
||||
ChangeSelectedElement(1);
|
||||
}
|
||||
else if (keyboardState.IsKeyDown(Keys.Enter) && !isPressed)
|
||||
{
|
||||
isPressed = true;
|
||||
if (SelectedElement is Button)
|
||||
{
|
||||
Button button = SelectedElement as Button;
|
||||
button.CallLeftBtnEvent();
|
||||
}
|
||||
else if (SelectedElement is TextBox)
|
||||
{
|
||||
TextBox textBox = SelectedElement as TextBox;
|
||||
isStartedPrint = true;
|
||||
}
|
||||
}
|
||||
else if (isPressed && (keyboardState.IsKeyUp(Keys.Enter) &&
|
||||
keyboardState.IsKeyUp(Keys.Down) &&
|
||||
keyboardState.IsKeyUp(Keys.Up)))
|
||||
{
|
||||
isPressed = false;
|
||||
}
|
||||
}
|
||||
private void ChangeSelectedElement(int x) // Меняет выбранный элемент
|
||||
{
|
||||
for (int i = 0; i < ActiveElements.Count; i++)
|
||||
{
|
||||
if (ActiveElements[i] == SelectedElement)
|
||||
{
|
||||
if (i + x >= ActiveElements.Count)
|
||||
{
|
||||
SelectedElement = ActiveElements.First();
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (i + x < 0)
|
||||
{
|
||||
SelectedElement = ActiveElements.Last();
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
SelectedElement = ActiveElements[i + x];
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
private bool CheckOnBadElements(DrawableUIElement element)
|
||||
{
|
||||
if (element is Button)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else if (element is ButtonText)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else if (element is TextBox)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else return false;
|
||||
}
|
||||
}
|
45
DangerousD/GameCore/GUI/DeathGUI.cs
Normal file
|
@ -0,0 +1,45 @@
|
|||
using DangerousD.GameCore.Managers;
|
||||
using Microsoft.Xna.Framework;
|
||||
using MonogameLibrary.UI.Base;
|
||||
using MonogameLibrary.UI.Elements;
|
||||
using System.Diagnostics;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace DangerousD.GameCore.GUI;
|
||||
|
||||
internal class DeathGUI : AbstractGui
|
||||
{
|
||||
protected override void CreateUI()
|
||||
{
|
||||
int wigth = AppManager.Instance.inGameResolution.X;
|
||||
int height = AppManager.Instance.inGameResolution.Y;
|
||||
float scaler = AppManager.Instance.resolution.Y / (float)AppManager.Instance.inGameHUDHelperResolution.Y;
|
||||
var menuBackground = new DrawableUIElement(Manager) { rectangle = new Rectangle(0, 0, wigth, height), textureName = "deathBackground" };
|
||||
Elements.Add(menuBackground);
|
||||
menuBackground.LoadTexture(AppManager.Instance.Content);
|
||||
Elements.Add(new Label(Manager) { rectangle = new Rectangle((wigth - 50) / 2, (height - 50) / 2 - 80, 50, 50), text = "You died", mainColor = Color.Transparent, scale = 0.7f, fontName = "ButtonFont", fontColor = Color.White });
|
||||
Elements.Add(new Label(Manager) { rectangle = new Rectangle((wigth - 50) / 2, (height - 50) / 2, 50, 50), text = $"Score: {0}", mainColor = Color.Transparent, scale = 0.7f, fontName = "ButtonFont", fontColor = Color.White });
|
||||
var butMenu = new ButtonText(Manager) { rectangle = new Rectangle((wigth - 300) / 2, (height - 50) / 2 + 80, 300, 50), text = "Back to menu", scale = 0.7f, fontName = "ButtonFont" };
|
||||
Elements.Add(butMenu);
|
||||
butMenu.LeftButtonPressed += () =>
|
||||
{
|
||||
AppManager.Instance.ChangeGameState(GameState.Menu);
|
||||
};
|
||||
foreach (var item in Elements)
|
||||
{
|
||||
item.rectangle.X = (int)(scaler * item.rectangle.X);
|
||||
item.rectangle.Y = (int)(scaler * item.rectangle.Y);
|
||||
item.rectangle.Width = (int)(scaler * item.rectangle.Width);
|
||||
item.rectangle.Height = (int)(scaler * item.rectangle.Height);
|
||||
if (item is DrawableTextedUiElement)
|
||||
{
|
||||
(item as DrawableTextedUiElement).scale *= scaler;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
base.Update(gameTime);
|
||||
}
|
||||
}
|
72
DangerousD/GameCore/GUI/DebugHUD.cs
Normal file
|
@ -0,0 +1,72 @@
|
|||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using MonogameLibrary.UI.Elements;
|
||||
using static System.String;
|
||||
|
||||
namespace DangerousD.GameCore.GUI
|
||||
{
|
||||
public class DebugHUD : IDrawableObject
|
||||
{
|
||||
private SpriteFont _spriteFont;
|
||||
private Dictionary<string, string> _text = new();
|
||||
private List<string> _log = new();
|
||||
|
||||
public void Initialize()
|
||||
{
|
||||
}
|
||||
|
||||
public void LoadContent()
|
||||
{
|
||||
_spriteFont = AppManager.Instance.Content.Load<SpriteFont>("Font_12");
|
||||
}
|
||||
|
||||
public void Update(GameTime gameTime)
|
||||
{
|
||||
}
|
||||
|
||||
public void Draw(SpriteBatch spriteBatch)
|
||||
{
|
||||
var keysString = Join("\n", _text.Select(el => el.Key + ": " + el.Value).ToList());
|
||||
spriteBatch.Begin();
|
||||
spriteBatch.DrawString(
|
||||
_spriteFont,
|
||||
keysString,
|
||||
new Vector2(10, 10),
|
||||
Color.Cyan,
|
||||
0,
|
||||
Vector2.Zero,
|
||||
1,
|
||||
SpriteEffects.None,
|
||||
0
|
||||
);
|
||||
spriteBatch.DrawString(
|
||||
_spriteFont,
|
||||
Join("\n", _log),
|
||||
new Vector2(10, 10 + _spriteFont.MeasureString(keysString).Y),
|
||||
Color.Green,
|
||||
0,
|
||||
Vector2.Zero,
|
||||
1,
|
||||
SpriteEffects.None,
|
||||
0
|
||||
);
|
||||
spriteBatch.End();
|
||||
}
|
||||
|
||||
public void Set(string key, string value)
|
||||
{
|
||||
_text[key] = value;
|
||||
}
|
||||
|
||||
public void Log(string value)
|
||||
{
|
||||
_log.Add(value);
|
||||
if (_log.Count > 30)
|
||||
{
|
||||
_log.RemoveAt(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
85
DangerousD/GameCore/GUI/HUD.cs
Normal file
|
@ -0,0 +1,85 @@
|
|||
using System;
|
||||
using Microsoft.Xna.Framework;
|
||||
using MonogameLibrary.UI.Base;
|
||||
using MonogameLibrary.UI.Elements;
|
||||
using System.Xml.Linq;
|
||||
using DangerousD.GameCore.Managers;
|
||||
using DangerousD.GameCore;
|
||||
using System.Collections.Generic;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using static System.Formats.Asn1.AsnWriter;
|
||||
using static System.Net.Mime.MediaTypeNames;
|
||||
|
||||
namespace DangerousD.GameCore.GUI
|
||||
{
|
||||
public class HUD : IDrawableObject
|
||||
{
|
||||
int wigth = AppManager.Instance.inGameResolution.X;
|
||||
int height = AppManager.Instance.inGameResolution.Y;
|
||||
float scaler = AppManager.Instance.resolution.Y / (float)AppManager.Instance.inGameHUDHelperResolution.Y;
|
||||
Texture2D texture;
|
||||
SpriteFont spriteFont;
|
||||
|
||||
public void Draw(SpriteBatch spriteBatch)
|
||||
{
|
||||
spriteBatch.Begin();
|
||||
spriteBatch.Draw(texture, new Rectangle(wigth / 35 - 2, height / 35 - 2, 120 + 2, 70 + 2), Color.DarkRed);
|
||||
spriteBatch.DrawString(spriteFont, "AMMO", new Vector2(wigth / 34 + 4, height / 30 - 6), Color.Gray, 0, Vector2.Zero, 1.8f, SpriteEffects.None, 0);
|
||||
spriteBatch.DrawString(spriteFont, "AMMO", new Vector2(wigth / 34 + 1, height / 30 - 6), Color.White, 0, Vector2.Zero, 1.8f, SpriteEffects.None, 0);
|
||||
for (int i = 1; i < 6; i++)
|
||||
{
|
||||
if (i <= AppManager.Instance.GameManager.players[0].Bullets)
|
||||
{
|
||||
spriteBatch.Draw(texture, new Rectangle(wigth / 30 + i * 13 + 2, height / 17 + 4, 5, 20), new Color(0.8f, 0.8f, 0, 1f));
|
||||
spriteBatch.Draw(texture, new Rectangle(wigth / 30 + i * 13, height / 17 + 4, 5, 20), Color.Yellow);
|
||||
}
|
||||
else
|
||||
{
|
||||
spriteBatch.Draw(texture, new Rectangle(wigth / 30 + i * 13, height / 17 + 4, 7, 20), new Color(0.2f, 0.2f, 0, 1f));
|
||||
}
|
||||
}
|
||||
spriteBatch.End();
|
||||
}
|
||||
|
||||
public void Initialize()
|
||||
{
|
||||
}
|
||||
|
||||
public void LoadContent()
|
||||
{
|
||||
texture = new Texture2D(AppManager.Instance.GraphicsDevice, 1, 1);
|
||||
texture.SetData<Color>(new Color[] { Color.White });
|
||||
spriteFont = AppManager.Instance.Content.Load<SpriteFont>("PixelFont");
|
||||
}
|
||||
|
||||
public void Update(GameTime gameTime)
|
||||
{
|
||||
}
|
||||
}
|
||||
//public class HUD1 : AbstractGui
|
||||
//{
|
||||
//
|
||||
// protected override void CreateUI()
|
||||
// {
|
||||
// DrawableUIElement background = new DrawableUIElement(Manager) { rectangle = new Rectangle(0, 0, wigth, height), mainColor = Color.Transparent };
|
||||
// Elements.Add(background);
|
||||
// Rect rect = new Rect(Manager) { rectangle = new Rectangle(wigth / 35, height / 35, 120, 70), mainColor = Color.DarkRed };
|
||||
// Elements.Add(rect);
|
||||
// Label label = new Label(Manager) { rectangle = new Rectangle(wigth / 34, height / 30, 120, 20), text = "ammout", fontName = "font2", scale = 0.2f, mainColor = Color.Transparent, fontColor = Color.Black };
|
||||
// Elements.Add(label);
|
||||
|
||||
// }
|
||||
// public override void Update(GameTime gameTime)
|
||||
// {
|
||||
//
|
||||
// rects.Clear();
|
||||
// for (int i = 0; i < ammout; i++)
|
||||
// {
|
||||
// rects.Add(new Rect(Manager) { rectangle = new Rectangle(wigth / 29 + i * 13, height / 17, 5, 20), mainColor = Color.Yellow });
|
||||
// rects[i].LoadTexture(AppManager.Instance.Content);
|
||||
// }
|
||||
// base.Update(gameTime);
|
||||
// }
|
||||
//}
|
||||
}
|
||||
|
|
@ -11,6 +11,7 @@ using DangerousD.GameCore.Managers;
|
|||
using MonogameLibrary.UI.Base;
|
||||
using System.Diagnostics;
|
||||
using DangerousD.GameCore.Network;
|
||||
using System.Xml.Linq;
|
||||
|
||||
namespace DangerousD.GameCore.GUI
|
||||
{
|
||||
|
@ -24,14 +25,18 @@ namespace DangerousD.GameCore.GUI
|
|||
{
|
||||
int screenWidth = AppManager.Instance.inGameResolution.X;
|
||||
int screenHeight = AppManager.Instance.inGameResolution.Y;
|
||||
float scaler = AppManager.Instance.resolution.Y / (float)AppManager.Instance.inGameHUDHelperResolution.Y;
|
||||
|
||||
var lobbyBackground = new DrawableUIElement(Manager) { rectangle = new Rectangle(0, 0, screenWidth, screenHeight), textureName = "menuFon3" };
|
||||
Elements.Add(lobbyBackground);
|
||||
lobbyBackground.LoadTexture(AppManager.Instance.Content);
|
||||
|
||||
// CheckBoxs
|
||||
Elements.Add(new Label(Manager) { rectangle = new Rectangle(screenWidth / 30 * 2, screenHeight / 30 * 5,
|
||||
screenWidth / 30 * 26, screenHeight / 15 * 10) });
|
||||
var lobby = new Label(Manager) { rectangle = new Rectangle(screenWidth / 30 * 2, screenHeight / 30 * 5,
|
||||
screenWidth / 30 * 26, screenHeight / 15 * 10), textureName = "textboxbackground2,5-1" };
|
||||
Elements.Add(lobby);
|
||||
lobby.LoadTexture(AppManager.Instance.Content);
|
||||
|
||||
|
||||
// Buttons and ip textbox
|
||||
{
|
||||
|
@ -41,11 +46,13 @@ namespace DangerousD.GameCore.GUI
|
|||
screenWidth / 30 * 10, screenHeight / 30 * 3),
|
||||
text = "ip",
|
||||
scale = 0.16f,
|
||||
fontColor = Color.Gray,
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2",
|
||||
textAligment = TextAligment.Left
|
||||
textAligment = TextAligment.Left,
|
||||
textureName = "textboxbackground6-1"
|
||||
|
||||
};
|
||||
Elements.Add(searchBarTextBox);
|
||||
searchBarTextBox.TextChanged += input => {
|
||||
if (searchBarTextBox.fontColor == Color.Gray)
|
||||
{
|
||||
|
@ -59,67 +66,92 @@ namespace DangerousD.GameCore.GUI
|
|||
searchBarTextBox.text = "ip";
|
||||
}
|
||||
};
|
||||
Button backButton = new ButtonText(Manager)
|
||||
Button backButton = new Button(Manager)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 30, screenHeight / 30, 60, 50),
|
||||
rectangle = new Rectangle(screenWidth / 30, screenHeight / 30, (int)(40 * 2.4), (int)(40 * 2.4)),
|
||||
text = "<-",
|
||||
scale = 0.3f,
|
||||
scale = 0.72f,
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2"
|
||||
fontName = "font2",
|
||||
textureName = "textboxbackground1-1"
|
||||
};
|
||||
Elements.Add(backButton);
|
||||
backButton.LeftButtonPressed += () => {
|
||||
AppManager.Instance.ChangeGameState(GameState.Menu);
|
||||
};
|
||||
|
||||
Button hostButton = new ButtonText(Manager)
|
||||
Button hostButton = new Button(Manager)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 30, screenHeight / 15 * 13, 120, 50),
|
||||
rectangle = new Rectangle(screenWidth / 30, screenHeight / 15 * 13, (int)(120 * 2.4), (int)(50 * 2.4)),
|
||||
text = "Host",
|
||||
scale = 0.2f,
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2"
|
||||
scale = 0.48f,
|
||||
fontColor = Color.DarkBlue,
|
||||
fontName = "buttonFont",
|
||||
textureName = "textboxbackground2-1"
|
||||
};
|
||||
Elements.Add(hostButton);
|
||||
hostButton.LeftButtonPressed += () => {
|
||||
|
||||
AppManager.Instance.ChangeGameState(GameState.Game);
|
||||
AppManager.Instance.NetworkManager.HostInit(AppManager.Instance.IpAddress);
|
||||
|
||||
};
|
||||
|
||||
Button refreshButton = new ButtonText(Manager)
|
||||
Button refreshButton = new Button(Manager)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 30 * 6, screenHeight / 15 * 13, 120, 50),
|
||||
rectangle = new Rectangle(screenWidth / 30 * 6, screenHeight / 15 * 13, (int)(120 * 2.4), (int)(50 * 2.4)),
|
||||
text = "Refresh",
|
||||
scale = 0.2f,
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2"
|
||||
scale = 0.48f,
|
||||
fontColor = Color.DarkBlue,
|
||||
fontName = "buttonFont",
|
||||
textureName = "textboxbackground2-1"
|
||||
};
|
||||
Elements.Add(refreshButton);
|
||||
refreshButton.LeftButtonPressed += () => {
|
||||
|
||||
};
|
||||
|
||||
Button joinSelectedButton = new ButtonText(Manager)
|
||||
Button joinSelectedButton = new Button(Manager)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 30 * 25, screenHeight / 15 * 13, 120, 50),
|
||||
rectangle = new Rectangle(screenWidth / 30 * 25, screenHeight / 15 * 13, (int)(120 * 2.4), (int)(50 * 2.4)),
|
||||
text = "Join",
|
||||
scale = 0.2f,
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2"
|
||||
scale = 0.48f,
|
||||
fontColor = Color.DarkBlue,
|
||||
fontName = "buttonFont",
|
||||
textureName = "textboxbackground2-1"
|
||||
};
|
||||
Elements.Add(joinSelectedButton);
|
||||
joinSelectedButton.LeftButtonPressed += () => {
|
||||
AppManager.Instance.ChangeGameState(GameState.Game);
|
||||
AppManager.Instance.NetworkManager.ClientInit(AppManager.Instance.IpAddress);
|
||||
};
|
||||
Button joinByIpButton = new ButtonText(Manager)
|
||||
Button joinByIpButton = new Button(Manager)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 30 * 25, screenHeight / 30, 120, 50),
|
||||
rectangle = new Rectangle(screenWidth / 30 * 25, screenHeight / 30, (int)(120 * 2.4), (int)(50 * 2.4)),
|
||||
text = "JoinByIp",
|
||||
scale = 0.2f,
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2"
|
||||
scale = 0.48f,
|
||||
fontColor = Color.DarkBlue,
|
||||
fontName = "buttonFont",
|
||||
textureName = "textboxbackground2-1"
|
||||
};
|
||||
Elements.Add(joinByIpButton);
|
||||
joinByIpButton.LeftButtonPressed += () => {
|
||||
AppManager.Instance.NetworkManager.ClientInit(searchBarTextBox.text);
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
|
||||
foreach (var item in Elements)
|
||||
{
|
||||
item.rectangle.X = (int)(scaler * item.rectangle.X);
|
||||
item.rectangle.Y = (int)(scaler * item.rectangle.Y);
|
||||
item.rectangle.Width = (int)(scaler * item.rectangle.Width);
|
||||
item.rectangle.Height = (int)(scaler * item.rectangle.Height);
|
||||
if (item is DrawableTextedUiElement)
|
||||
{
|
||||
(item as DrawableTextedUiElement).scale *= scaler;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -26,31 +26,49 @@ namespace DangerousD.GameCore.GUI
|
|||
{
|
||||
int screenWidth = AppManager.Instance.inGameResolution.X;
|
||||
int screenHeight = AppManager.Instance.inGameResolution.Y;
|
||||
float scaler = AppManager.Instance.resolution.Y / (float)AppManager.Instance.inGameHUDHelperResolution.Y;
|
||||
|
||||
var loginBackground = new DrawableUIElement(Manager) { rectangle = new Rectangle(0, 0, screenWidth, screenHeight), textureName = "menuFon2" };
|
||||
Elements.Add(loginBackground);
|
||||
loginBackground.LoadTexture(AppManager.Instance.Content);
|
||||
|
||||
Elements.Add(new Label(Manager) {
|
||||
rectangle = new Rectangle(screenWidth / 2 - 250, screenHeight / 6 - 50, 500, 100),
|
||||
rectangle = new Rectangle(screenWidth / 2 - (int)(250 * 2.4), screenHeight / 6 - 100, (int)(500 * 2.4), (int)(100 * 2.4)),
|
||||
text = "Login",
|
||||
scale = 0.8f,
|
||||
scale = 1.7f,
|
||||
fontColor = Color.White,
|
||||
mainColor = Color.Transparent,
|
||||
fontName = "ButtonFont"
|
||||
});
|
||||
|
||||
Button backButton = new Button(Manager)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 20, screenHeight / 15, (int)(40 * 2.4), (int)(40 * 2.4)),
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2",
|
||||
textureName = "textboxbackground1-1"
|
||||
};
|
||||
backButton.LeftButtonPressed += () => {
|
||||
AppManager.Instance.ChangeGameState(GameState.Menu);
|
||||
};
|
||||
Elements.Add(backButton);
|
||||
|
||||
|
||||
// TextBox-ы
|
||||
{
|
||||
TextBox loginTextBox = new TextBox(Manager)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 2 - 125, screenHeight / 6 * 2 - 20, 250, 40),
|
||||
rectangle = new Rectangle(screenWidth / 2 - (int)(125 * 2.4), screenHeight / 6 * 2 - 20, (int)(250 * 2.4), (int)(40 * 2.4)),
|
||||
text = "NickName",
|
||||
scale = 0.16f,
|
||||
scale = 0.33f,
|
||||
fontColor = Color.Gray,
|
||||
fontName = "Font2",
|
||||
textAligment = TextAligment.Left
|
||||
textAligment = TextAligment.Left,
|
||||
textureName = "textboxbackground6-1"
|
||||
|
||||
};
|
||||
Elements.Add(loginTextBox);
|
||||
loginTextBox.LoadTexture(AppManager.Instance.Content);
|
||||
loginTextBox.TextChanged += input => {
|
||||
if (loginTextBox.fontColor == Color.Gray)
|
||||
{
|
||||
|
@ -64,16 +82,20 @@ namespace DangerousD.GameCore.GUI
|
|||
loginTextBox.fontColor = Color.Gray;
|
||||
}
|
||||
};
|
||||
Elements.Add(loginTextBox);
|
||||
|
||||
TextBox passwordTextBox = new TextBox(Manager)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 2 - 125, screenHeight / 6 * 3 - 40, 250, 40),
|
||||
rectangle = new Rectangle(screenWidth / 2 - (int)(125 * 2.4), screenHeight / 6 * 3 - 40, (int)(250 * 2.4), (int)(40 * 2.4)),
|
||||
text = "Password",
|
||||
scale = 0.16f,
|
||||
scale = 0.33f,
|
||||
fontColor = Color.Gray,
|
||||
fontName = "font2",
|
||||
textAligment = TextAligment.Left
|
||||
textAligment = TextAligment.Left,
|
||||
textureName = "textboxbackground6-1"
|
||||
};
|
||||
Elements.Add(passwordTextBox);
|
||||
passwordTextBox.LoadTexture(AppManager.Instance.Content);
|
||||
passwordTextBox.TextChanged += input => {
|
||||
if (passwordTextBox.fontColor == Color.Gray)
|
||||
{
|
||||
|
@ -87,45 +109,53 @@ namespace DangerousD.GameCore.GUI
|
|||
passwordTextBox.fontColor = Color.Gray;
|
||||
}
|
||||
};
|
||||
Elements.Add(passwordTextBox);
|
||||
}
|
||||
|
||||
// Кнопки
|
||||
{
|
||||
Button logButton = new ButtonText(Manager) {
|
||||
rectangle = new Rectangle(screenWidth / 4 + 50, screenHeight / 6 * 4, 100, 50),
|
||||
Button logButton = new Button(Manager) {
|
||||
rectangle = new Rectangle(screenWidth / 4 + (int)(50 * 2.4), screenHeight / 6 * 3 + 100, (int)(100 * 2.4), (int)(50 * 2.4)),
|
||||
text = "LogIn",
|
||||
scale = 0.2f,
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2"
|
||||
scale = 0.6f,
|
||||
fontColor = Color.White,
|
||||
fontName = "ButtonFont",
|
||||
textureName = "textboxbackground2-1"
|
||||
};
|
||||
Elements.Add(logButton);
|
||||
logButton.LeftButtonPressed += () => {
|
||||
if (CheckUser())
|
||||
{
|
||||
AppManager.Instance.ChangeGameState(GameState.Lobby);
|
||||
}
|
||||
};
|
||||
Elements.Add(logButton);
|
||||
|
||||
Button regButton = new ButtonText(Manager)
|
||||
Button regButton = new Button(Manager)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 4 * 2 + 50, screenHeight / 6 * 4, 100, 50),
|
||||
rectangle = new Rectangle(screenWidth / 4 * 2 + (int)(50 * 2.4), screenHeight / 6 * 3 + 100, (int)(100 * 2.4), (int)(50 * 2.4)),
|
||||
text = "Reg",
|
||||
scale = 0.2f,
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2"
|
||||
scale = 0.6f,
|
||||
fontColor = Color.White,
|
||||
fontName = "ButtonFont",
|
||||
textureName = "textboxbackground2-1"
|
||||
};
|
||||
Elements.Add(regButton);
|
||||
regButton.LeftButtonPressed += GoToRegWebServer;
|
||||
Elements.Add(regButton);
|
||||
|
||||
Button backButton = new ButtonText(Manager)
|
||||
|
||||
}
|
||||
foreach (var item in Elements)
|
||||
{
|
||||
rectangle = new Rectangle(screenWidth / 20, screenHeight / 15, 50, 50),
|
||||
text = "<-",
|
||||
scale = 0.3f,
|
||||
fontColor = Color.Black,
|
||||
fontName = "font2"
|
||||
};
|
||||
backButton.LeftButtonPressed += () => {
|
||||
AppManager.Instance.ChangeGameState(GameState.Menu);
|
||||
};
|
||||
item.rectangle.X = (int)(scaler * item.rectangle.X);
|
||||
item.rectangle.Y = (int)(scaler * item.rectangle.Y);
|
||||
item.rectangle.Width = (int)(scaler * item.rectangle.Width);
|
||||
item.rectangle.Height = (int)(scaler * item.rectangle.Height);
|
||||
if (item is DrawableTextedUiElement)
|
||||
{
|
||||
(item as DrawableTextedUiElement).scale *= scaler;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,64 +1,114 @@
|
|||
using DangerousD.GameCore.Managers;
|
||||
using Microsoft.VisualBasic;
|
||||
using Microsoft.Xna.Framework;
|
||||
using MonogameLibrary.UI.Base;
|
||||
using MonogameLibrary.UI.Elements;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Linq;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace DangerousD.GameCore.GUI;
|
||||
|
||||
internal class MenuGUI : AbstractGui
|
||||
{
|
||||
int selected = 0;
|
||||
Color[] colors = new Color[] { new Color(64, 53, 51), new Color(84, 58, 52),
|
||||
new Color(170, 101, 63), new Color(254, 208, 116), new Color(252, 231, 124) };
|
||||
List<Label> MainLetterLabels = new List<Label>();
|
||||
List<Label> BigLetterLabels = new List<Label>();
|
||||
List<Vector2> MainLetterPositions = new List<Vector2>();
|
||||
List<Vector2> BigLetterPositions = new List<Vector2>();
|
||||
protected override void CreateUI()
|
||||
{
|
||||
int wigth = AppManager.Instance.inGameHUDHelperResolution.X;
|
||||
int height = AppManager.Instance.inGameHUDHelperResolution.Y;
|
||||
float scaler = AppManager.Instance.resolution.Y / (float)AppManager.Instance.inGameHUDHelperResolution.Y;
|
||||
|
||||
|
||||
int wigth = AppManager.Instance.Window.ClientBounds.Width;
|
||||
int height = AppManager.Instance.Window.ClientBounds.Height;
|
||||
var menuBackground = new DrawableUIElement(Manager) { rectangle = new Rectangle(0, 0, wigth, height), textureName = "menuFon" };
|
||||
Elements.Add(menuBackground);
|
||||
menuBackground.LoadTexture(AppManager.Instance.Content);
|
||||
int TopMenu = 0;
|
||||
Color[] colors = new Color[] { new Color(64, 53, 51), new Color(84, 58, 52),
|
||||
new Color(170, 101, 63), new Color(254, 208, 116), new Color(252, 231, 124) };
|
||||
|
||||
for (int i = 0; i < colors.Length; i++)
|
||||
Elements.Add(new Label(Manager) { rectangle = new Rectangle((wigth - 50) / 2 - 60, 60, 50, 50), text = "Dangerous", mainColor = Color.Transparent, scale = 1-0.05f*i*i/10, fontName = "Font2", fontColor = colors[i] });
|
||||
{
|
||||
Elements.Add(new Label(Manager) { rectangle = new Rectangle((wigth - 50) / 2 - 60, 220, 50, 50), text = "Dangerous", mainColor = Color.Transparent, scale = 1.35f - 0.05f * i * i / 10, fontName = "Font2", fontColor = colors[i] });
|
||||
MainLetterLabels.Add(Elements.Last() as Label);
|
||||
MainLetterPositions.Add(new Vector2(Elements.Last().rectangle.X, Elements.Last().rectangle.Y));
|
||||
}
|
||||
|
||||
int dx = 100;
|
||||
Color[] colors2 = new Color[] { new Color(64, 53, 51), new Color(84, 58, 52),
|
||||
new Color(170, 101, 63), new Color(254, 208, 116), new Color(252, 231, 124) };
|
||||
for (int i = 0; i < colors2.Length; i++)
|
||||
Elements.Add(new Label(Manager) { rectangle = new Rectangle((wigth - 50) / 2 + 250 + dx-i*i, 90 - i * i/5, 50, 50), text = "D", mainColor = Color.Transparent, scale = 1.3f - 0.05f * i * i / 5, fontName = "Font2", fontColor = colors2[i] });
|
||||
int dx = 50;
|
||||
for (int i = 0; i < colors.Length; i++)
|
||||
{
|
||||
Elements.Add(new Label(Manager) { rectangle = new Rectangle((wigth - 50) / 2 + 480 + dx - i * i, 260 - i * i / 5, 50, 50), text = "D", mainColor = Color.Transparent, scale = 2.15f - 0.05f * i * i / 5, fontName = "Font2", fontColor = colors[i] });
|
||||
BigLetterLabels.Add(Elements.Last() as Label);
|
||||
BigLetterPositions.Add(new Vector2(Elements.Last().rectangle.X, Elements.Last().rectangle.Y));
|
||||
}
|
||||
|
||||
var butSingle = new ButtonText(Manager) { rectangle = new Rectangle((wigth - 300) / 2, 130, 300, 50), text = "Singleplayer", fontName = "ButtonFont" };
|
||||
var butSingle = new ButtonText(Manager) { rectangle = new Rectangle((wigth - (int)(300 * 2.4)) / 2, 350, (int)(300 * 2.4), (int)(50 * 2.4)), text = "Singleplayer", scale = 1.2f, fontName = "ButtonFont" };
|
||||
Elements.Add(butSingle);
|
||||
butSingle.LeftButtonPressed += () =>
|
||||
{
|
||||
AppManager.Instance.ChangeGameState(GameState.Game);
|
||||
AppManager.Instance.SetMultiplayerState(MultiPlayerStatus.SinglePlayer);
|
||||
|
||||
};
|
||||
var butMulti = new ButtonText(Manager) { rectangle = new Rectangle((wigth - 300) / 2, 190, 300, 50), text = "Multiplayer", fontName = "ButtonFont" };
|
||||
|
||||
var butMulti = new ButtonText(Manager) { rectangle = new Rectangle((wigth - (int)(300 * 2.4)) / 2, 470, (int)(300 * 2.4), (int)(50 * 2.4)), text = "Multiplayer", scale = 1.2f, fontName = "ButtonFont" };
|
||||
|
||||
Elements.Add(butMulti);
|
||||
butMulti.LeftButtonPressed += () =>
|
||||
{
|
||||
AppManager.Instance.ChangeGameState(GameState.Login);
|
||||
};
|
||||
var butOption = new ButtonText(Manager) { rectangle = new Rectangle((wigth - 300) / 2, 250, 300, 50), text = "Option", fontName = "ButtonFont" };
|
||||
var butOption = new ButtonText(Manager) { rectangle = new Rectangle((wigth - (int)(160 * 2.4)) / 2, 590, (int)(160 * 2.4), (int)(50 * 2.4)), text = "Option", scale = 1.2f, fontName = "ButtonFont" };
|
||||
Elements.Add(butOption);
|
||||
butOption.LeftButtonPressed += () =>
|
||||
{
|
||||
// открытие настроек
|
||||
AppManager.Instance.ChangeGameState(GameState.Options);
|
||||
};
|
||||
var butExit = new ButtonText(Manager) { rectangle = new Rectangle((wigth - 300) / 2, 310, 300, 50), text = "Exit", fontName = "ButtonFont" };
|
||||
var butExit = new ButtonText(Manager) { rectangle = new Rectangle((wigth - (int)(110 * 2.4)) / 2, 710, (int)(110 * 2.4), (int)(50 * 2.4)), text = "Exit", scale = 1.2f, fontName = "ButtonFont" };
|
||||
Elements.Add(butExit);
|
||||
butExit.LeftButtonPressed += () =>
|
||||
{
|
||||
AppManager.Instance.Exit();
|
||||
};
|
||||
|
||||
foreach ( var item in Elements)
|
||||
{
|
||||
item.rectangle.X = (int)(scaler * item.rectangle.X);
|
||||
item.rectangle.Y = (int)(scaler * item.rectangle.Y);
|
||||
item.rectangle.Width = (int)(scaler * item.rectangle.Width);
|
||||
item.rectangle.Height = (int)(scaler * item.rectangle.Height);
|
||||
if (item is DrawableTextedUiElement)
|
||||
{
|
||||
(item as DrawableTextedUiElement).scale *= scaler;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
for (int i = 0; i < MainLetterLabels.Count; i++)
|
||||
{
|
||||
MainLetterLabels[i].fontColor = Color.FromNonPremultiplied(colors[i].ToVector4() *
|
||||
(float)(((Math.Sin(gameTime.TotalGameTime.TotalSeconds * 4) + 1) / 2f) * 0.3 + 0.8f)
|
||||
);
|
||||
BigLetterLabels[i].fontColor = Color.FromNonPremultiplied(colors[i].ToVector4()
|
||||
* (float)(((Math.Sin(gameTime.TotalGameTime.TotalSeconds * 4 - Math.PI) + 1) / 2f) * 0.3 + 0.8f)
|
||||
);
|
||||
MainLetterLabels[i].fontColor.A = 255;
|
||||
BigLetterLabels[i].fontColor.A = 255;
|
||||
MainLetterLabels[i].rectangle.Y = (int)(MainLetterPositions[i].Y +
|
||||
(20 * (Math.Sin(gameTime.TotalGameTime.TotalSeconds * 4) + 1) / 2f * 0.25) * (i - MainLetterLabels.Count / 2)
|
||||
);
|
||||
BigLetterLabels[i].rectangle.Y = (int)(BigLetterPositions[i].Y +
|
||||
(20 * (Math.Sin(gameTime.TotalGameTime.TotalSeconds * 4 - Math.PI) + 1) / 2f * 0.25) * (i - MainLetterLabels.Count / 2)
|
||||
);
|
||||
|
||||
}
|
||||
base.Update(gameTime);
|
||||
}
|
||||
}
|
101
DangerousD/GameCore/GUI/OptionsGUI.cs
Normal file
|
@ -0,0 +1,101 @@
|
|||
using System;
|
||||
using Microsoft.Xna.Framework;
|
||||
using MonogameLibrary.UI.Base;
|
||||
using MonogameLibrary.UI.Elements;
|
||||
using System.Xml.Linq;
|
||||
using DangerousD.GameCore.Managers;
|
||||
using DangerousD.GameCore;
|
||||
|
||||
namespace DangerousD.GameCore.GUI
|
||||
{
|
||||
public class OptionsGUI : AbstractGui
|
||||
{
|
||||
int selectedGUI = 0;
|
||||
protected override void CreateUI()
|
||||
{
|
||||
int wigth = AppManager.Instance.inGameHUDHelperResolution.X;
|
||||
int height = AppManager.Instance.inGameHUDHelperResolution.Y;
|
||||
float scaler = AppManager.Instance.resolution.Y / (float)AppManager.Instance.inGameHUDHelperResolution.Y;
|
||||
var menuBackground = new DrawableUIElement(Manager) { rectangle = new Rectangle(0, 0, wigth, height), textureName = "optionsBackground" };
|
||||
//Elements.Add(menuBackground);
|
||||
menuBackground.LoadTexture(AppManager.Instance.Content);
|
||||
|
||||
var slider = new Slider(Manager)
|
||||
{
|
||||
MinValue = 0,
|
||||
MaxValue = 1,
|
||||
rectangle = new Rectangle(wigth / 2 + 220, 275, (int)(100 * 2.4), 40),
|
||||
indentation = 5,
|
||||
textureName = "sliderBackground"
|
||||
};
|
||||
//Elements.Add(slider);
|
||||
//AppManager.Instance.SettingsManager.SetMainVolume(slider.GetSliderValue);
|
||||
|
||||
var cB = new CheckBox(Manager);
|
||||
cB.rectangle = new Rectangle(wigth / 2 + 440, 405, (int)(40 * 2.4), (int)(40 * 2.4));
|
||||
cB.Checked += (newCheckState) =>
|
||||
{
|
||||
SettingsManager sM = new SettingsManager();
|
||||
};
|
||||
cB.LoadTexture(AppManager.Instance.Content);
|
||||
Elements.Add(cB);
|
||||
|
||||
var checkBox = new CheckBox(Manager);
|
||||
checkBox.rectangle = new Rectangle(wigth / 2 + 360, 540, (int)(40 * 2.4), (int)(40 * 2.4));
|
||||
checkBox.Checked += (newCheckState) =>
|
||||
{
|
||||
AppManager.Instance.SettingsManager.SetIsFullScreen(newCheckState);
|
||||
};
|
||||
checkBox.LoadTexture(AppManager.Instance.Content);
|
||||
Elements.Add(checkBox);
|
||||
|
||||
Label lblOptions = new Label(Manager)
|
||||
{ fontName = "buttonFont", scale = 1.2f, text = "Options", fontColor = Color.White, rectangle = new Rectangle((wigth - 50) / 2, 40, 50, 50), mainColor = Color.Transparent };
|
||||
Elements.Add(lblOptions);
|
||||
|
||||
Label lblValue = new Label(Manager)
|
||||
{ fontName = "buttonFont", scale = 1f , text = "Volume", fontColor = Color.White, rectangle = new Rectangle((wigth - 50) / 2, 250, 50, 50), mainColor = Color.Transparent };
|
||||
Elements.Add(lblValue);
|
||||
|
||||
Label lblIsFullScreen = new Label(Manager)
|
||||
{ fontName = "buttonFont", scale = 1f , text = "Full Screen", fontColor = Color.White, rectangle = new Rectangle((wigth - 50) / 2, 580, 50, 50), mainColor = Color.Transparent };
|
||||
Elements.Add(lblIsFullScreen);
|
||||
|
||||
Label lblSwitchMode = new Label(Manager)
|
||||
{ fontName = "buttonFont", scale = 1f, text = "Left/Right Mode", fontColor = Color.White, rectangle = new Rectangle((wigth - 50) / 2, 415, 50, 50), mainColor = Color.Transparent };
|
||||
Elements.Add(lblSwitchMode);
|
||||
|
||||
Button bTExit = new Button(Manager)
|
||||
{ fontName = "Font2", scale = 0.72f, text = "<-", rectangle = new Rectangle(wigth / 30, height / 30, (int)(40 * 2.4), (int)(40 * 2.4)), textureName = "textboxbackground1-1" };
|
||||
Elements.Add(bTExit);
|
||||
bTExit.LeftButtonPressed += () =>
|
||||
{
|
||||
AppManager.Instance.ChangeGameState(GameState.Menu);
|
||||
};
|
||||
|
||||
foreach (var item in Elements)
|
||||
{
|
||||
item.rectangle.X = (int)(scaler * item.rectangle.X);
|
||||
item.rectangle.Y = (int)(scaler * item.rectangle.Y);
|
||||
item.rectangle.Width = (int)(scaler * item.rectangle.Width);
|
||||
item.rectangle.Height = (int)(scaler * item.rectangle.Height);
|
||||
if (item is DrawableTextedUiElement)
|
||||
{
|
||||
(item as DrawableTextedUiElement).scale *= scaler;
|
||||
}
|
||||
}
|
||||
slider.rectangle.X = (int)(scaler * slider.rectangle.X);
|
||||
slider.rectangle.Y = (int)(scaler * slider.rectangle.Y);
|
||||
//slider.rectangle.Width = (int)(scaler * slider.rectangle.Width);
|
||||
//slider.rectangle.Height = (int)(scaler * slider.rectangle.Height);
|
||||
if (slider is DrawableTextedUiElement)
|
||||
{
|
||||
(slider as DrawableTextedUiElement).scale *= scaler;
|
||||
}
|
||||
}
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
base.Update(gameTime);
|
||||
}
|
||||
}
|
||||
}
|
51
DangerousD/GameCore/GameObjects/Entities/Door.cs
Normal file
|
@ -0,0 +1,51 @@
|
|||
using DangerousD.GameCore.GameObjects.LivingEntities;
|
||||
using DangerousD.GameCore.Graphics;
|
||||
using Microsoft.Xna.Framework;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
|
||||
namespace DangerousD.GameCore.GameObjects.Entities
|
||||
{
|
||||
public class Door : Entity
|
||||
{
|
||||
private Rectangle _sourceRectangle;
|
||||
|
||||
public Door(Vector2 position, Vector2 size, Rectangle sourceRectangle) : base(position)
|
||||
{
|
||||
_sourceRectangle = sourceRectangle;
|
||||
Width = (int)size.X;
|
||||
Height = (int)size.Y;
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new("doors");
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
base.Update(gameTime);
|
||||
|
||||
}
|
||||
|
||||
public override void Draw(SpriteBatch spriteBatch)
|
||||
{
|
||||
GraphicsComponent.DrawAnimation(Rectangle, spriteBatch, _sourceRectangle);
|
||||
//spriteBatch.Draw(debugTexture, new Rectangle(Rectangle.X - GraphicsComponent.CameraPosition.X, Rectangle.Y - GraphicsComponent.CameraPosition.Y, Rectangle.Width, Rectangle.Height), Color.White);
|
||||
}
|
||||
public override void OnCollision(GameObject gameObject)
|
||||
{
|
||||
base.OnCollision(gameObject);
|
||||
if (gameObject is Player)
|
||||
{
|
||||
Player player = (Player)gameObject;
|
||||
if (player.isUping)
|
||||
{
|
||||
AppManager.Instance.GameManager.Remove(this);
|
||||
//тут спавн лута
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
13
DangerousD/GameCore/GameObjects/Entities/Items/Coin.cs
Normal file
|
@ -0,0 +1,13 @@
|
|||
using DangerousD.GameCore.Graphics;
|
||||
using Microsoft.Xna.Framework;
|
||||
|
||||
namespace DangerousD.GameCore.GameObjects.Entities.Items;
|
||||
|
||||
public class Coin : Entity
|
||||
{
|
||||
public Coin(Vector2 position) : base(position)
|
||||
{
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; }
|
||||
}
|
13
DangerousD/GameCore/GameObjects/Entities/Items/Diamond.cs
Normal file
|
@ -0,0 +1,13 @@
|
|||
using DangerousD.GameCore.Graphics;
|
||||
using Microsoft.Xna.Framework;
|
||||
|
||||
namespace DangerousD.GameCore.GameObjects.Entities.Items;
|
||||
|
||||
public class Diamond : Entity
|
||||
{
|
||||
public Diamond(Vector2 position) : base(position)
|
||||
{
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; }
|
||||
}
|
|
@ -1,7 +1,9 @@
|
|||
using DangerousD.GameCore.Graphics;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
@ -10,19 +12,22 @@ namespace DangerousD.GameCore.GameObjects.Entities
|
|||
{
|
||||
public class SilasBall : LivingEntity
|
||||
{
|
||||
|
||||
private Vector2 v;
|
||||
public SilasBall(Vector2 position) : base(position)
|
||||
{
|
||||
Height = 60;
|
||||
Width = 60;
|
||||
Height = 24;
|
||||
Width = 24;
|
||||
acceleration = Vector2.Zero;
|
||||
|
||||
}
|
||||
public SilasBall(Vector2 position, Vector2 velosity) : base(position)
|
||||
{
|
||||
Height = 60;
|
||||
Width = 60;
|
||||
Height = 24;
|
||||
Width = 24;
|
||||
acceleration = Vector2.Zero;
|
||||
velocity = velosity;
|
||||
v = velosity;
|
||||
|
||||
}
|
||||
|
||||
|
@ -30,6 +35,17 @@ namespace DangerousD.GameCore.GameObjects.Entities
|
|||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
base.Update(gameTime);
|
||||
if (AppManager.Instance.GameManager.physicsManager.CheckRectangle( new Rectangle(Rectangle.X-2,Rectangle.Y-2,Rectangle.Width+8,Rectangle.Height+8)).Count>0)
|
||||
{
|
||||
AppManager.Instance.GameManager.Remove(this);
|
||||
}
|
||||
velocity = v;
|
||||
}
|
||||
public override void Draw(SpriteBatch spriteBatch)
|
||||
{
|
||||
|
||||
base.Draw(spriteBatch);
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
36
DangerousD/GameCore/GameObjects/Entities/Trigger.cs
Normal file
|
@ -0,0 +1,36 @@
|
|||
using DangerousD.GameCore.Graphics;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DangerousD.GameCore.GameObjects.Entities
|
||||
{
|
||||
internal class Trigger : Entity
|
||||
{
|
||||
public Action<GameObject> OnCollisionAction;
|
||||
string trigger_Name;
|
||||
public Trigger(Rectangle rectangle, string trigger_Name) : base(new Vector2(rectangle.X, rectangle.Y))
|
||||
{
|
||||
_pos = new Vector2(rectangle.X, rectangle.Y);
|
||||
Width = rectangle.Width;
|
||||
Height = rectangle.Height;
|
||||
this.trigger_Name = trigger_Name;
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent => new GraphicsComponent(new List<string>() { "SilasBallMove" }, "SilasBallMove");
|
||||
public override void OnCollision(GameObject gameObject)
|
||||
{
|
||||
OnCollisionAction?.Invoke(gameObject);
|
||||
}
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
}
|
||||
public override void Draw(SpriteBatch spriteBatch)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
|
@ -14,11 +14,12 @@ namespace DangerousD.GameCore
|
|||
{
|
||||
protected Vector2 _pos;
|
||||
public Vector2 Pos => _pos;
|
||||
public int id;
|
||||
public bool isChildEntity = false;
|
||||
public bool isIdFromHost = false;
|
||||
public int Width { get; set; }
|
||||
public int Height { get; set; }
|
||||
public Rectangle Rectangle => new Rectangle((int)Pos.X, (int)Pos.Y, Width, Height);
|
||||
public Vector2 velocity;
|
||||
public Vector2 acceleration;
|
||||
protected abstract GraphicsComponent GraphicsComponent { get; }
|
||||
public GameObject(Vector2 pos)
|
||||
{
|
||||
|
@ -30,6 +31,7 @@ namespace DangerousD.GameCore
|
|||
|
||||
LoadContent();
|
||||
AppManager.Instance.GameManager.Register(this);
|
||||
GraphicsComponent.parentId = id;
|
||||
}
|
||||
|
||||
public virtual void OnCollision(GameObject gameObject)
|
||||
|
@ -46,10 +48,14 @@ namespace DangerousD.GameCore
|
|||
{
|
||||
}
|
||||
|
||||
public void LoadContent()
|
||||
public void PlayAnimation()
|
||||
{
|
||||
GraphicsComponent.LoadContent();
|
||||
}
|
||||
public void LoadContent()
|
||||
{
|
||||
PlayAnimation();
|
||||
}
|
||||
|
||||
public virtual void Update(GameTime gameTime)
|
||||
{
|
||||
|
@ -62,7 +68,18 @@ namespace DangerousD.GameCore
|
|||
{
|
||||
GraphicsComponent.DrawAnimation(Rectangle, spriteBatch);
|
||||
//debug
|
||||
// spriteBatch.Draw(debugTexture, Rectangle, Color.White);
|
||||
if (AppManager.Instance.InputManager.CollisionsCheat)
|
||||
{
|
||||
spriteBatch.Draw(debugTexture,
|
||||
new Rectangle(Rectangle.X - GraphicsComponent.CameraPosition.X,
|
||||
Rectangle.Y - GraphicsComponent.CameraPosition.Y, Rectangle.Width, Rectangle.Height),
|
||||
Color.White);
|
||||
}
|
||||
|
||||
}
|
||||
public GraphicsComponent GetGraphicsComponent()
|
||||
{
|
||||
return this.GraphicsComponent;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -4,7 +4,7 @@ using Microsoft.Xna.Framework.Graphics;
|
|||
|
||||
namespace DangerousD.GameCore.GUI
|
||||
{
|
||||
interface IDrawableObject
|
||||
public interface IDrawableObject
|
||||
{
|
||||
void Initialize();
|
||||
void LoadContent();
|
||||
|
|
|
@ -16,6 +16,9 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities
|
|||
protected int monster_speed;
|
||||
protected string name;
|
||||
protected bool isAlive = true;
|
||||
protected int leftBoarder = 0;
|
||||
protected int rightBoarder = 800;
|
||||
protected bool isGoRight;
|
||||
|
||||
public CoreEnemy(Vector2 position) : base(position)
|
||||
{
|
||||
|
@ -29,6 +32,7 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities
|
|||
public abstract void Death();
|
||||
|
||||
public abstract void Attack();
|
||||
public abstract void Attack(GameTime gameTime);
|
||||
|
||||
public abstract void Move(GameTime gameTime);
|
||||
|
||||
|
|
|
@ -12,16 +12,29 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
public class FlameSkull : CoreEnemy
|
||||
{
|
||||
private bool isAttack;
|
||||
|
||||
public FlameSkull(Vector2 position) : base(position)
|
||||
{
|
||||
Width = 62;
|
||||
Height = 40;
|
||||
monster_speed = 3;
|
||||
name = "Skull";
|
||||
acceleration = Vector2.Zero;
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "FlameSkullMoveRight" , "FlameSkullMoveLeft"}, "FlameSkullMoveRight");
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
if (!isAttack)
|
||||
{
|
||||
Move(gameTime);
|
||||
}
|
||||
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
public override void Attack()
|
||||
{
|
||||
|
||||
|
@ -34,7 +47,35 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
|
||||
public override void Move(GameTime gameTime)
|
||||
{
|
||||
if (isGoRight)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "FlameSkullMoveRight")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("FlameSkullMoveRight");
|
||||
}
|
||||
velocity.X = monster_speed;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "FlameSkullMoveLeft")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("FlameSkullMoveLeft");
|
||||
}
|
||||
velocity.X = -monster_speed;
|
||||
}
|
||||
if (Pos.X >= rightBoarder)
|
||||
{
|
||||
isGoRight = false;
|
||||
}
|
||||
else if (Pos.X <= leftBoarder)
|
||||
{
|
||||
isGoRight = true;
|
||||
}
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,24 +12,24 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
internal class Frank : CoreEnemy
|
||||
{
|
||||
private Vector2 position;
|
||||
private bool isGoRight = false;
|
||||
|
||||
public Vector2 Position
|
||||
public Frank(Vector2 position) : base(position)
|
||||
{
|
||||
get { return position; }
|
||||
}
|
||||
|
||||
public Frank(Vector2 position) : base(new Vector2(300, 200))
|
||||
{
|
||||
//position = new Vector2(300, 200);
|
||||
isGoRight = false;
|
||||
Width = 112;
|
||||
Height = 160;
|
||||
leftBoarder = 50;
|
||||
rightBoarder = 300;
|
||||
GraphicsComponent.StartAnimation("FrankMoveLeft");
|
||||
monster_speed = 3;
|
||||
monster_speed = 2;
|
||||
name = "Frank";
|
||||
}
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "FrankMoveRight", "FrankMoveLeft" }, "FrankMoveRight");
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "FrankMoveRight", "FrankMoveLeft" }, "FrankMoveLeft");
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
Move(gameTime);
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
public override void Attack()
|
||||
{
|
||||
|
@ -43,12 +43,6 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
|
||||
public override void Move(GameTime gameTime)
|
||||
{
|
||||
var player = AppManager.Instance.GameManager.players[0];
|
||||
if (player.Pos.X - _pos.X <= 20 || player.Pos.X - _pos.X <= -20)
|
||||
{
|
||||
player.Death(name);
|
||||
}
|
||||
|
||||
if (isGoRight)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "FrankMoveRight")
|
||||
|
@ -65,6 +59,24 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
}
|
||||
velocity.X = -monster_speed;
|
||||
}
|
||||
if (Pos.X >= rightBoarder)
|
||||
{
|
||||
isGoRight = false;
|
||||
}
|
||||
else if (Pos.X <= leftBoarder)
|
||||
{
|
||||
isGoRight = true;
|
||||
}
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,7 +14,9 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
public class FrankBalls : CoreEnemy
|
||||
{
|
||||
private Rectangle collision;
|
||||
private Vector2 position;
|
||||
private bool isFlyRight = true;
|
||||
private bool isFlyUp = true;
|
||||
private bool isAttacking = false;
|
||||
public Rectangle Collision
|
||||
{
|
||||
|
@ -27,8 +29,8 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
name = "FrankBalls";
|
||||
Width = 40;
|
||||
Height = 40;
|
||||
monster_speed = 2;
|
||||
monster_health = 13;
|
||||
monster_speed = 3;
|
||||
velocity = new Vector2(3,-3);
|
||||
acceleration = Vector2.Zero;
|
||||
velocity = new Vector2(monster_speed, monster_speed);
|
||||
}
|
||||
|
@ -36,58 +38,25 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "BallMoveRight" }, "BallMoveRight");
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
collision = new Rectangle((int)_pos.X, (int)_pos.Y, 40, 40);
|
||||
|
||||
if (!isAttacking)
|
||||
{
|
||||
Move(gameTime);
|
||||
}
|
||||
|
||||
if(GraphicsComponent.GetCurrentAnimation == "FrankMoveRight")
|
||||
{
|
||||
isFlyRight = true;
|
||||
}
|
||||
else if(GraphicsComponent.GetCurrentAnimation == "FrankMoveLeft")
|
||||
{
|
||||
isFlyRight = false;
|
||||
}
|
||||
|
||||
var foundObj = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)_pos.X-1, (int)_pos.Y-1, Width+2, Height+2), typeof(StopTile));
|
||||
|
||||
if (foundObj != null && foundObj.Count > 0)
|
||||
{
|
||||
|
||||
float av = foundObj.Sum(x => x.Rectangle.X)/foundObj.Count;
|
||||
float avy = foundObj.Sum(x => x.Rectangle.Y)/foundObj.Count;
|
||||
|
||||
if (avy <= _pos.Y)
|
||||
velocity.Y = monster_speed;
|
||||
else if (avy >= _pos.Y)
|
||||
velocity.Y = -monster_speed;
|
||||
if (av <= _pos.X)
|
||||
velocity.X = -monster_speed;
|
||||
else if (av >= _pos.X)
|
||||
velocity.X = monster_speed;
|
||||
monster_health--;
|
||||
}
|
||||
|
||||
AppManager.Instance.DebugHUD.Set(name, velocity.ToString());
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
public override void Attack()
|
||||
{
|
||||
isAttacking = true;
|
||||
|
||||
if(isFlyRight)
|
||||
}
|
||||
public override void OnCollision(GameObject gameObject)
|
||||
{
|
||||
if (gameObject is Player)
|
||||
{
|
||||
if (AppManager.Instance.GameManager.players[0].IsAlive)
|
||||
{
|
||||
AppManager.Instance.GameManager.players[0].Death(name);
|
||||
}
|
||||
else if(!isFlyRight)
|
||||
{
|
||||
AppManager.Instance.GameManager.players[0].Death(name);
|
||||
}
|
||||
|
||||
base.OnCollision(gameObject);
|
||||
}
|
||||
|
||||
public override void Death()
|
||||
|
@ -96,8 +65,58 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
}
|
||||
|
||||
public override void Move(GameTime gameTime)
|
||||
{
|
||||
var getColsHor = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y + Height / 2 - 2, 50, 2));
|
||||
var getColsVer= AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y + Height / 2 - 2, 50, 2)); ;
|
||||
if (isFlyRight)
|
||||
{
|
||||
getColsHor = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y , 42, 40));
|
||||
if(getColsHor.Count > 0)
|
||||
{
|
||||
isFlyRight = false;
|
||||
velocity.X = -velocity.X;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
getColsHor = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X-2, (int)Pos.Y, 42, 40));
|
||||
if (getColsHor.Count > 0)
|
||||
{
|
||||
isFlyRight = true;
|
||||
velocity.X = -velocity.X;
|
||||
}
|
||||
}
|
||||
if (isFlyUp)
|
||||
{
|
||||
|
||||
getColsVer = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X , (int)Pos.Y-3, 40, 43));
|
||||
if (getColsVer.Count > 0)
|
||||
{
|
||||
isFlyUp = false;
|
||||
velocity.Y = -velocity.Y;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
getColsVer = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y, 40, 43));
|
||||
if (getColsVer.Count > 0)
|
||||
{
|
||||
isFlyUp = true;
|
||||
velocity.Y = -velocity.Y;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,18 +10,32 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
public class Ghost : CoreEnemy
|
||||
{
|
||||
private bool isAttack;
|
||||
|
||||
public Ghost(Vector2 position) : base(position)
|
||||
{
|
||||
monster_speed = 1;
|
||||
isGoRight = true;
|
||||
monster_speed = 3;
|
||||
name = "Ghost";
|
||||
Width = 48;
|
||||
Height = 62;
|
||||
GraphicsComponent.StartAnimation("GhostSpawn");
|
||||
acceleration = Vector2.Zero;
|
||||
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "GhostMoveRight", "GhostMoveLeft", "GhostSpawn", "GhostAttack" }, "GhostMoveRight");
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
if (!isAttack)
|
||||
{
|
||||
Move(gameTime);
|
||||
}
|
||||
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
public override void Attack()
|
||||
{
|
||||
|
||||
|
@ -33,8 +47,45 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
}
|
||||
|
||||
public override void Move(GameTime gameTime)
|
||||
{
|
||||
if (isGoRight)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "GhostMoveRight")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("GhostMoveRight");
|
||||
}
|
||||
velocity.X = monster_speed;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "GhostMoveLeft")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("GhostMoveLeft");
|
||||
}
|
||||
velocity.X = -monster_speed;
|
||||
}
|
||||
if (Pos.X >= rightBoarder)
|
||||
{
|
||||
isGoRight = false;
|
||||
}
|
||||
else if (Pos.X <= leftBoarder)
|
||||
{
|
||||
isGoRight = true;
|
||||
}
|
||||
if (true)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -47,13 +47,13 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
Move(gameTime);
|
||||
}
|
||||
base.Update(gameTime);
|
||||
|
||||
}
|
||||
|
||||
public override void Attack()
|
||||
{
|
||||
var animation = GraphicsComponent.GetCurrentAnimation;
|
||||
isAttaking = true;
|
||||
|
||||
if (isGoRight)
|
||||
{
|
||||
if (animation != "HunchmanDaggerRight")
|
||||
|
@ -70,8 +70,16 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
}
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{}
|
||||
|
||||
public override void Death()
|
||||
{
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
Particle particle = new Particle(Pos);
|
||||
}
|
||||
|
||||
if (monster_health <= 0)
|
||||
{
|
||||
isVisible = false;
|
||||
|
@ -142,6 +150,5 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -29,6 +29,11 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public override void Death()
|
||||
{
|
||||
|
||||
|
@ -62,5 +67,10 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
|
||||
base.OnCollision(gameObject);
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
using DangerousD.GameCore.Graphics;
|
||||
using DangerousD.GameCore.Graphics;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Content;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
|
@ -10,13 +10,14 @@ using System.Threading.Tasks;
|
|||
|
||||
namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
||||
{
|
||||
public class SilasHands : CoreEnemy
|
||||
public class
|
||||
SilasHands : CoreEnemy
|
||||
{
|
||||
public SilasHands(Vector2 position) : base(position)
|
||||
{
|
||||
name = "SilasHand";
|
||||
Width = 48;
|
||||
Height = 48;
|
||||
Width = 16;
|
||||
Height = 16;
|
||||
monster_health = 2;
|
||||
monster_speed = 2;
|
||||
acceleration = Vector2.Zero;
|
||||
|
@ -26,6 +27,11 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
protected override GraphicsComponent GraphicsComponent { get; }=new GraphicsComponent(new List<string>() { "SilasHandMove" }, "SilasHandMove");
|
||||
|
||||
public override void Attack()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
@ -55,6 +61,12 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
velocity.X = monster_speed;
|
||||
}
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
base.Update(gameTime);
|
||||
|
|
|
@ -16,7 +16,6 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
private int attackTime = 60;
|
||||
private int moveTime = 360;
|
||||
private int currentTime = 0;
|
||||
private bool isGoRight = true;
|
||||
int leftBorder;
|
||||
int rightBorder;
|
||||
List<SilasHands> hands = new List<SilasHands>();
|
||||
|
@ -24,21 +23,17 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
public SilasMaster(Vector2 position) : base(position)
|
||||
{
|
||||
name = "SilasMaster";
|
||||
Width = 144;
|
||||
Height = 160;
|
||||
Width = 48;
|
||||
Height = 53;
|
||||
monster_health = 15;
|
||||
monster_speed = 4;
|
||||
monster_speed = 2;
|
||||
acceleration = Vector2.Zero;
|
||||
leftBorder = (int)position.X - 60;
|
||||
rightBorder = (int)position.X + 120;
|
||||
acceleration = Vector2.Zero;
|
||||
hands.Add(new SilasHands(new Vector2(Pos.X+60,Pos.Y+120)));
|
||||
hands.Add(new SilasHands(new Vector2(Pos.X + 90, Pos.Y + 120)));
|
||||
for (int i = 0; i < 4; i++)
|
||||
{
|
||||
SilasBall silasball = new SilasBall(new Vector2(Pos.X + i * 40, Pos.Y + 120), new Vector2((i - 2) * 4, 6));
|
||||
balls.Add(silasball);
|
||||
}
|
||||
hands.Add(new SilasHands(new Vector2(Pos.X+0,Pos.Y+53)));
|
||||
hands.Add(new SilasHands(new Vector2(Pos.X + 24, Pos.Y + 53)));
|
||||
|
||||
}
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new GraphicsComponent(new List<string>() { "SilasMove", "SilasAttack" }, "SilasMove");
|
||||
public override void Attack()
|
||||
|
@ -61,18 +56,28 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
}
|
||||
currentTime++;
|
||||
}
|
||||
|
||||
private void SpawnAttackBall()
|
||||
{
|
||||
for (int i = 0; i < balls.Count; i++)
|
||||
balls.Clear();
|
||||
for (int i = 0; i < 4; i++)
|
||||
{
|
||||
balls[i].SetPosition(new Vector2(Pos.X + i * 40, Pos.Y + 120));
|
||||
SilasBall silasball = new SilasBall(new Vector2(Pos.X + i * 12, Pos.Y + 53), new Vector2((i - 2) * 2, 2));
|
||||
|
||||
balls.Add(silasball);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public override void Death()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
|
||||
}
|
||||
|
||||
public override void Move(GameTime gameTime)
|
||||
|
@ -105,6 +110,12 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
isGoRight = true;
|
||||
}
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
base.Update(gameTime);
|
||||
|
|
|
@ -12,19 +12,165 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
public class Slime : CoreEnemy
|
||||
{
|
||||
|
||||
private bool isGoRight = true;
|
||||
private bool isDown = true;
|
||||
|
||||
int leftBorder;
|
||||
int rightBorder;
|
||||
bool isAttaking = false;
|
||||
int delay;
|
||||
bool isJumping = false;
|
||||
public Slime(Vector2 position) : base(position)
|
||||
{
|
||||
Width = 48;
|
||||
Height = 16;
|
||||
name = "Slime";
|
||||
monster_speed = 3;
|
||||
monster_health = 2;
|
||||
leftBorder = 100;
|
||||
rightBorder = 400;
|
||||
//acceleration = Vector2.Zero;
|
||||
delay = 30;
|
||||
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "SlimeMoveLeftTop", "SlimeMoveLeftBottom", "SlimeMoveRightTop",
|
||||
"SlimeMoveRightBottom", "SlimeReadyJumpRightBottom", "SlimeReadyJumpRightTop", "SlimeReadyJumpLeftBottom", "SlimeReadyJumpLeftTop", "SlimeJumpRightBottom",
|
||||
"SlimeJumpRightTop", "SlimeJumpLeftBottom", "SlimeJumpLeftTop" }, "");
|
||||
"SlimeJumpRightTop", "SlimeJumpLeftBottom", "SlimeJumpLeftTop" }, "SlimeMoveRightTop");
|
||||
|
||||
public override void Attack()
|
||||
{
|
||||
|
||||
}
|
||||
public void Jump(GameTime gameTime)
|
||||
{
|
||||
var getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle(0, 0, 100, 100));
|
||||
velocity.X = 0;
|
||||
Height = 32;
|
||||
|
||||
if (isGoRight && isDown)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeReadyJumpLeftBottom")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeReadyJumpLeftBottom");
|
||||
}
|
||||
delay--;
|
||||
if (delay <= 0)
|
||||
{
|
||||
|
||||
velocity = new Vector2(5, -4);
|
||||
acceleration.Y = 0;
|
||||
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeJumpLeftBottom")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeJumpLeftBottom");
|
||||
}
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y - 5, 48, 5));
|
||||
if (getCols.Count > 0 )
|
||||
{
|
||||
isJumping = false;
|
||||
isDown = false;
|
||||
isAttaking = false;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
else if (!isGoRight && isDown)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeReadyJumpRightBottom")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeReadyJumpRightBottom");
|
||||
}
|
||||
delay--;
|
||||
if (delay <= 0)
|
||||
{
|
||||
|
||||
velocity = new Vector2(-5, -4);
|
||||
acceleration.Y = 0;
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeJumpRightBottom")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeJumpRightBottom");
|
||||
}
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y - 5, 48, 5));
|
||||
if (getCols.Count > 0)
|
||||
{
|
||||
isJumping = false;
|
||||
isDown = false;
|
||||
isAttaking = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (isGoRight && !isDown)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeReadyJumpLeftTop")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeReadyJumpLeftTop");
|
||||
|
||||
}
|
||||
delay--;
|
||||
if (delay <= 0)
|
||||
{
|
||||
|
||||
velocity = new Vector2(5, 4);
|
||||
acceleration.Y = 0;
|
||||
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeJumpLeftTop")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeJumpLeftTop");
|
||||
}
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X+1, (int)Pos.Y + Height, 46, 5));
|
||||
|
||||
if (getCols.Count > 0 )
|
||||
{
|
||||
isJumping = false;
|
||||
isDown = true;
|
||||
isAttaking = false;
|
||||
acceleration.Y = 10;
|
||||
Move(gameTime);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
else if (!isGoRight && !isDown)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeReadyJumpRightTop")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeReadyJumpRightTop");
|
||||
}
|
||||
delay--;
|
||||
if (delay <= 0)
|
||||
{
|
||||
velocity = new Vector2(-5, 4);
|
||||
acceleration.Y = 0;
|
||||
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeJumpRightTop")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeJumpRightTop");
|
||||
}
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X+1, (int)Pos.Y + Height, 46, 5));
|
||||
if (getCols.Count > 0 )
|
||||
{
|
||||
isJumping = false;
|
||||
isDown = true;
|
||||
isAttaking = false;
|
||||
acceleration.Y = 10;
|
||||
Move(gameTime);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
public override void Draw(SpriteBatch spriteBatch)
|
||||
{
|
||||
|
||||
|
||||
base.Draw(spriteBatch);
|
||||
}
|
||||
public override void Death()
|
||||
{
|
||||
|
||||
|
@ -32,7 +178,175 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
|
||||
public override void Move(GameTime gameTime)
|
||||
{
|
||||
float delta = (float)gameTime.ElapsedGameTime.TotalSeconds;
|
||||
delay = 30;
|
||||
Height = 16;
|
||||
if (isGoRight && isDown)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeMoveRightBottom")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeMoveRightBottom");
|
||||
}
|
||||
velocity.X = monster_speed;
|
||||
|
||||
}
|
||||
|
||||
else if (!isGoRight && isDown)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeMoveLeftBottom")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeMoveLeftBottom");
|
||||
}
|
||||
velocity.X = -monster_speed;
|
||||
|
||||
}
|
||||
else if (!isDown && isGoRight)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeMoveRightTop")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeMoveRightTop");
|
||||
|
||||
}
|
||||
velocity.X = monster_speed;
|
||||
|
||||
|
||||
}
|
||||
else if (!isDown && !isGoRight)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SlimeMoveLeftTop")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SlimeMoveLeftTop");
|
||||
}
|
||||
velocity.X = -monster_speed;
|
||||
|
||||
}
|
||||
var getCols= AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y + Height / 2 - 2, 50, 2)); ;
|
||||
if (isGoRight)
|
||||
{
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y + Height / 2 - 2, 51, 2));
|
||||
}
|
||||
else
|
||||
{
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X-3, (int)Pos.Y + Height / 2 - 2, 51, 2));
|
||||
}
|
||||
|
||||
|
||||
foreach(var item in getCols)
|
||||
{
|
||||
if(item is MapObject)
|
||||
{
|
||||
isGoRight = !isGoRight;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
|
||||
if (isDown)
|
||||
{
|
||||
|
||||
if (acceleration.Y < 0)
|
||||
{
|
||||
acceleration.Y = -acceleration.Y;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
if (acceleration.Y > 0)
|
||||
{
|
||||
acceleration.Y = -acceleration.Y;
|
||||
}
|
||||
}
|
||||
AppManager.Instance.DebugHUD.Set(name, isAttaking.ToString());
|
||||
if(!isJumping)
|
||||
{
|
||||
if (isDown)
|
||||
{
|
||||
Jump(gameTime);
|
||||
}
|
||||
else if(IsInAim())
|
||||
{
|
||||
Jump(gameTime);
|
||||
isAttaking = true;
|
||||
}
|
||||
else if(!isAttaking)
|
||||
{
|
||||
Move(gameTime);
|
||||
|
||||
}
|
||||
else { Jump(gameTime); }
|
||||
}
|
||||
|
||||
|
||||
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
|
||||
}
|
||||
public bool IsInAim()
|
||||
{
|
||||
var getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y + Height, 48, 5));
|
||||
|
||||
|
||||
if (isGoRight && !isDown)
|
||||
{
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X + Width, (int)Pos.Y + Height, 200, 500), false);
|
||||
if (getCols.Count > 0)
|
||||
{
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
else if (!isGoRight && !isDown)
|
||||
{
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X - 200, (int)Pos.Y + Height, 200, 500), false);
|
||||
if (getCols.Count > 0)
|
||||
{
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
/*/else if (isGoRight && isDown)
|
||||
{
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X +Width, (int)Pos.Y -500, 200, 500), false);
|
||||
if (getCols.Count > 0)
|
||||
{
|
||||
isAttaking = true;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
else if (!isGoRight && isDown)
|
||||
{
|
||||
getCols = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X - 200, (int)Pos.Y - 500, 200, 500), false);
|
||||
if (getCols.Count > 0)
|
||||
{
|
||||
isAttaking = true;
|
||||
return true;
|
||||
}
|
||||
}/*/
|
||||
|
||||
return false;
|
||||
|
||||
}
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
|
||||
}
|
||||
public override void OnCollision(GameObject gameObject)
|
||||
{
|
||||
if (gameObject is Player)
|
||||
{
|
||||
if (AppManager.Instance.GameManager.players[0].IsAlive)
|
||||
{
|
||||
AppManager.Instance.GameManager.players[0].Death(name);
|
||||
}
|
||||
}
|
||||
base.OnCollision(gameObject);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
using DangerousD.GameCore.Graphics;
|
||||
using DangerousD.GameCore.GameObjects.MapObjects;
|
||||
using DangerousD.GameCore.Graphics;
|
||||
using DangerousD.GameCore.Managers;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Content;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
|
@ -12,37 +14,71 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
public class Spider : CoreEnemy
|
||||
{
|
||||
private bool isAttack;
|
||||
|
||||
protected SpiderWeb web;
|
||||
protected float delay;
|
||||
protected int webLength;
|
||||
protected bool isDown;
|
||||
protected bool isDownUp;
|
||||
protected PhysicsManager physicsManager;
|
||||
protected Player player;
|
||||
|
||||
public Spider(Vector2 position) : base(position)
|
||||
{
|
||||
player = AppManager.Instance.GameManager.players[0];
|
||||
isDownUp = true;
|
||||
isDown = true;
|
||||
web = new SpiderWeb(Pos);
|
||||
physicsManager = AppManager.Instance.GameManager.physicsManager;
|
||||
name = "Spider";
|
||||
Width = 112;
|
||||
Height = 24;
|
||||
delay = 0;
|
||||
web = new SpiderWeb(new Vector2(Pos.X-Width/2,Pos.Y));
|
||||
webLength = 0;
|
||||
monster_speed = 1;
|
||||
acceleration = Vector2.Zero;
|
||||
monster_speed = 3;
|
||||
acceleration = new Vector2(0, -50);
|
||||
isGoRight = true;
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "SpiderMoveRight", "SpiderMoveLeft", "SpiderOnWeb" }, "SpiderMoveRight");
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
if (isDownUp)
|
||||
if (!isAttack)
|
||||
{
|
||||
Move(gameTime);
|
||||
}
|
||||
else
|
||||
{
|
||||
Attack(gameTime);
|
||||
}
|
||||
Target();
|
||||
|
||||
base.Update(gameTime);
|
||||
}
|
||||
/// <summary>
|
||||
/// НИЧЕГО НЕ ДЕЛАЕТ! НУЖЕН ДЛЯ ПЕРЕОПРЕДЕЛЕНИЯ
|
||||
/// </summary>
|
||||
public override void Attack()
|
||||
{
|
||||
}
|
||||
/// <summary>
|
||||
/// Атака паука РАБОЧАЯ
|
||||
/// </summary>
|
||||
/// <param name="gameTime"></param>
|
||||
public override void Attack(GameTime gameTime)
|
||||
{ //48 72
|
||||
velocity.X = 0;
|
||||
delay += (float)gameTime.ElapsedGameTime.TotalSeconds;
|
||||
if (isAttack)
|
||||
{
|
||||
if (delay > 0.5 && webLength <= 4 && isDown)
|
||||
{
|
||||
Width = 48;
|
||||
Height = 72;
|
||||
delay += (float)gameTime.ElapsedGameTime.TotalSeconds;
|
||||
if (delay > 0.5 && webLength <= 4 && isDown)
|
||||
{
|
||||
StartCicycleAnimation("SpiderOnWeb");
|
||||
acceleration = Vector2.Zero;
|
||||
webLength++;
|
||||
_pos.Y += 25;
|
||||
web.Height = webLength * 25;
|
||||
|
@ -55,6 +91,8 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
}
|
||||
else if (delay > 0.5 && webLength != 0 && !isDown)
|
||||
{
|
||||
Width = 48;
|
||||
Height = 72;
|
||||
StartCicycleAnimation("SpiderOnWeb");
|
||||
webLength--;
|
||||
_pos.Y -= 25;
|
||||
|
@ -66,18 +104,22 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
isDown = true;
|
||||
}
|
||||
}
|
||||
else
|
||||
var entitiesInter = physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)Pos.Y, 200, 600));
|
||||
if (entitiesInter.Count > 0)
|
||||
{
|
||||
Width = 112;
|
||||
Height = 24;
|
||||
foreach (var entity in entitiesInter)
|
||||
{
|
||||
if (entity.GetType() == typeof(Player))
|
||||
{
|
||||
player.Death(name);
|
||||
}
|
||||
}
|
||||
|
||||
base.Update(gameTime);
|
||||
}
|
||||
public override void Attack()
|
||||
{ //48 72
|
||||
|
||||
}
|
||||
if (webLength == 0)
|
||||
{
|
||||
isAttack = false;
|
||||
}
|
||||
}
|
||||
|
||||
public override void Draw(SpriteBatch spriteBatch)
|
||||
|
@ -100,7 +142,39 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
|
||||
public override void Move(GameTime gameTime)
|
||||
{
|
||||
Width = 112;
|
||||
Height = 24;
|
||||
foreach (var entity in physicsManager.CheckRectangle(new Rectangle((int)Pos.X - 7, (int)Pos.Y, 126, 10)))
|
||||
{
|
||||
if (entity.GetType() == typeof(StopTile))
|
||||
{
|
||||
isGoRight = !isGoRight;
|
||||
}
|
||||
}
|
||||
if (isGoRight)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SpiderMoveRight")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SpiderMoveRight");
|
||||
}
|
||||
velocity.X = monster_speed;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "SpiderMoveLeft")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("SpiderMoveLeft");
|
||||
}
|
||||
velocity.X = -monster_speed;
|
||||
}
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
if (player.Pos.X >= Pos.X && player.Pos.X <= Pos.X+Width)
|
||||
{
|
||||
isAttack = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,6 +28,11 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public override void Death()
|
||||
{
|
||||
|
||||
|
@ -37,5 +42,10 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,16 +12,28 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
public class Werewolf : CoreEnemy
|
||||
{
|
||||
private bool isAttack;
|
||||
|
||||
public Werewolf(Vector2 position) : base(position)
|
||||
{
|
||||
name = "Wolf";
|
||||
monster_speed = 1;
|
||||
monster_speed = 4;
|
||||
Width = 78;
|
||||
Height = 96;
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "WolfMoveRight", "WolfMoveLeft", "WolfJumpRight", "WolfJumpLeft" }, "WolfMoveRight");
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
if (!isAttack)
|
||||
{
|
||||
Move(gameTime);
|
||||
}
|
||||
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
public override void Attack()
|
||||
{
|
||||
|
||||
|
@ -34,7 +46,39 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
|
||||
public override void Move(GameTime gameTime)
|
||||
{
|
||||
if (isGoRight)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "WolfMoveRight")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("WolfMoveRight");
|
||||
}
|
||||
velocity.X = monster_speed;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "WolfMoveLeft")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("WolfMoveLeft");
|
||||
}
|
||||
velocity.X = -monster_speed;
|
||||
}
|
||||
if (Pos.X >= rightBoarder)
|
||||
{
|
||||
isGoRight = false;
|
||||
}
|
||||
else if (Pos.X <= leftBoarder)
|
||||
{
|
||||
isGoRight = true;
|
||||
}
|
||||
}
|
||||
|
||||
public override void Attack(GameTime gameTime)
|
||||
{
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,12 +8,14 @@ using System.Linq;
|
|||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using DangerousD.GameCore.Managers;
|
||||
using DangerousD.GameCore.Network;
|
||||
|
||||
namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
||||
{
|
||||
public class Zombie : CoreEnemy
|
||||
{
|
||||
private bool isGoRight = true;
|
||||
private bool isAttack;
|
||||
|
||||
float leftBorder;
|
||||
float rightBorder;
|
||||
bool isAttaking = false;
|
||||
|
@ -23,11 +25,29 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
Width = 24;
|
||||
Height = 40;
|
||||
monster_speed = 3;
|
||||
monster_speed = 2;
|
||||
name = "Zombie";
|
||||
monster_health = 2;
|
||||
leftBorder = (int)position.X - 100;
|
||||
rightBorder = (int)position.X + 100;
|
||||
physicsManager = new PhysicsManager();
|
||||
Random random = new Random();
|
||||
if(random.Next(0, 2) == 0)
|
||||
{
|
||||
isGoRight = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
isGoRight = false;
|
||||
}
|
||||
|
||||
this.GraphicsComponent.actionOfAnimationEnd += (a) =>
|
||||
{
|
||||
if (a == "ZombieRightAttack" || a == "ZombieLeftAttack")
|
||||
{
|
||||
isAttaking = false;
|
||||
}
|
||||
};
|
||||
}
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "ZombieMoveRight", "ZombieMoveLeft", "ZombieRightAttack", "ZombieLeftAttack" }, "ZombieMoveLeft");
|
||||
|
||||
|
@ -38,11 +58,15 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
Target();
|
||||
Move(gameTime);
|
||||
}
|
||||
|
||||
fixBorder();
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
public override void Attack()
|
||||
{
|
||||
AppManager.Instance.GameManager.GetPlayer1.Death(name);
|
||||
}
|
||||
public void PlayAttackAnimation()
|
||||
{
|
||||
velocity.X = 0;
|
||||
isAttaking = true;
|
||||
|
@ -50,9 +74,8 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "ZombieRightAttack")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("ZombieAttackRight");
|
||||
GraphicsComponent.StartAnimation("ZombieRightAttack");
|
||||
}
|
||||
AppManager.Instance.GameManager.players[0].Death(name);
|
||||
}
|
||||
else if (!isGoRight)
|
||||
{
|
||||
|
@ -60,33 +83,31 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
{
|
||||
GraphicsComponent.StartAnimation("ZombieLeftAttack");
|
||||
}
|
||||
AppManager.Instance.GameManager.players[0].Death(name);
|
||||
}
|
||||
}
|
||||
|
||||
public override void Death()
|
||||
{
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
Particle particle = new Particle(Pos);
|
||||
}
|
||||
|
||||
AppManager.Instance.GameManager.Remove(this);
|
||||
|
||||
}
|
||||
|
||||
public override void Move(GameTime gameTime)
|
||||
{
|
||||
float delta = (float)gameTime.ElapsedGameTime.TotalSeconds;
|
||||
if (isGoRight)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "ZombieMoveRight")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("ZombieMoveRight");
|
||||
}
|
||||
StartCicycleAnimation("ZombieMoveRight");
|
||||
velocity.X = monster_speed;
|
||||
}
|
||||
|
||||
else if (!isGoRight)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "ZombieMoveLeft")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("ZombieMoveLeft");
|
||||
}
|
||||
StartCicycleAnimation("ZombieMoveLeft");
|
||||
velocity.X = -monster_speed;
|
||||
}
|
||||
|
||||
|
@ -102,34 +123,75 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities.Monsters
|
|||
}
|
||||
public override void OnCollision(GameObject gameObject)
|
||||
{
|
||||
if(gameObject is Player)
|
||||
if (gameObject.id == AppManager.Instance.GameManager.GetPlayer1.id && AppManager.Instance.GameManager.GetPlayer1.IsAlive)
|
||||
{
|
||||
if (AppManager.Instance.GameManager.players[0].IsAlive)
|
||||
if (AppManager.Instance.multiPlayerStatus != MultiPlayerStatus.Client)
|
||||
{
|
||||
Attack();
|
||||
}
|
||||
}
|
||||
else if (gameObject is Player)
|
||||
{
|
||||
if (AppManager.Instance.multiPlayerStatus == MultiPlayerStatus.Host)
|
||||
{
|
||||
NetworkTask task = new NetworkTask();
|
||||
AppManager.Instance.NetworkTasks.Add(task.KillPlayer(gameObject.id, name));
|
||||
}
|
||||
}
|
||||
base.OnCollision(gameObject);
|
||||
}
|
||||
|
||||
public void Target()
|
||||
{
|
||||
if(physicsManager.RayCast(this, AppManager.Instance.GameManager.players[0]) == null)
|
||||
if (AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X - 50, (int)Pos.Y, Width + 200, Height), typeof(Player)).Count > 0)
|
||||
{
|
||||
if(isGoRight && this._pos.X <= AppManager.Instance.GameManager.players[0].Pos.X)
|
||||
{
|
||||
isTarget = true;
|
||||
leftBorder = Pos.X - 10;
|
||||
leftBorder = Pos.X - 100;
|
||||
rightBorder = Pos.X + AppManager.Instance.GameManager.players[0].Pos.X;
|
||||
}
|
||||
|
||||
else if(!isGoRight && this._pos.X >= AppManager.Instance.GameManager.players[0].Pos.X)
|
||||
{
|
||||
isTarget = true;
|
||||
rightBorder = Pos.X + 10;
|
||||
rightBorder = Pos.X + 100;
|
||||
leftBorder = AppManager.Instance.GameManager.players[0].Pos.X;
|
||||
}
|
||||
}
|
||||
}
|
||||
public void fixBorder()
|
||||
{
|
||||
if(leftBorder <= 0)
|
||||
{
|
||||
leftBorder = 0;
|
||||
}
|
||||
if(rightBorder >= 800)
|
||||
{
|
||||
rightBorder = 760;
|
||||
}
|
||||
}
|
||||
public void SwitchToRight()
|
||||
{
|
||||
isGoRight = true;
|
||||
}
|
||||
|
||||
public void SwitchToLeft()
|
||||
{
|
||||
isGoRight = false;
|
||||
}
|
||||
public override void Attack(GameTime gameTime)
|
||||
{}
|
||||
|
||||
public void TakeDamage()
|
||||
{
|
||||
monster_health--;
|
||||
GraphicsComponent.StartAnimation("ZombieRightAttack");
|
||||
Particle particle = new Particle(Pos);
|
||||
if (monster_health <= 0)
|
||||
{
|
||||
Death();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
75
DangerousD/GameCore/GameObjects/LivingEntities/Particle.cs
Normal file
|
@ -0,0 +1,75 @@
|
|||
using DangerousD.GameCore.Graphics;
|
||||
using Microsoft.Xna.Framework;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DangerousD.GameCore.GameObjects.LivingEntities
|
||||
{
|
||||
public class Particle : LivingEntity
|
||||
{
|
||||
int delay;
|
||||
bool isFall;
|
||||
public Particle(Vector2 position) : base(position)
|
||||
{
|
||||
Width = 14;
|
||||
Height = 14;
|
||||
Random random = new Random();
|
||||
velocity = new Vector2(random.Next(-6, 6), random.Next(-8,4));
|
||||
acceleration.Y = 10;
|
||||
delay = 100;
|
||||
isFall = false;
|
||||
isOnGround = false;
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "GibsMoveLeftBottom", "GibsMoveLeftTop", "GibsMoveRightBottom", "GibsMoveRightTop", "GibsNotMove" }, "GibsMoveRightTop");
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
|
||||
delay--;
|
||||
if (delay<=80)
|
||||
{
|
||||
velocity.X=0;
|
||||
}
|
||||
if(isOnGround)
|
||||
{
|
||||
GraphicsComponent.StartAnimation("GibsNotMove");
|
||||
Width = 16;
|
||||
Height = 5;
|
||||
isFall=true;
|
||||
|
||||
; }
|
||||
|
||||
else if(!isFall)
|
||||
{
|
||||
Width = 14;
|
||||
Height= 14;
|
||||
if (velocity.Y<0 && velocity.X>0)
|
||||
{
|
||||
GraphicsComponent.StartAnimation("GibsMoveRightTop");
|
||||
}
|
||||
else if (velocity.Y < 0 && velocity.X < 0)
|
||||
{
|
||||
GraphicsComponent.StartAnimation("GibsMoveLeftTop");
|
||||
}
|
||||
else if (velocity.Y > 0 && velocity.X > 0)
|
||||
{
|
||||
GraphicsComponent.StartAnimation("GibsMoveRightBottom");
|
||||
}
|
||||
else if (velocity.Y > 0 && velocity.X < 0)
|
||||
{
|
||||
GraphicsComponent.StartAnimation("GibsMoveLeftBottom");
|
||||
}
|
||||
}
|
||||
if(delay<=0)
|
||||
{
|
||||
AppManager.Instance.GameManager.Remove(this);
|
||||
}
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -9,12 +9,12 @@ using Microsoft.Xna.Framework;
|
|||
|
||||
namespace DangerousD.GameCore.GameObjects.PlayerDeath
|
||||
{
|
||||
public class DeathRectangle : GameObject
|
||||
public class AnimationRectangle : GameObject
|
||||
{
|
||||
public DeathRectangle(Vector2 pos, string DeathType) : base(pos)
|
||||
public AnimationRectangle(Vector2 pos, string DeathType) : base(pos)
|
||||
{
|
||||
Height = 128;
|
||||
Width = 128;
|
||||
Height = 48;
|
||||
Width = 48;
|
||||
PlayDeath(DeathType);
|
||||
}
|
||||
|
|
@ -6,45 +6,286 @@ using System.Linq;
|
|||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using DangerousD.GameCore.GameObjects.PlayerDeath;
|
||||
using Microsoft.Xna.Framework.Input;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using DangerousD.GameCore.GameObjects.LivingEntities.Monsters;
|
||||
using DangerousD.GameCore.Network;
|
||||
|
||||
namespace DangerousD.GameCore.GameObjects.LivingEntities
|
||||
{
|
||||
public class Player : LivingEntity
|
||||
{
|
||||
bool isAlive = true;
|
||||
public Player(Vector2 position) : base(position)
|
||||
bool isRight = true;
|
||||
string stayAnimation;
|
||||
bool isJump = false;
|
||||
public int health;
|
||||
public Vector2 playerVelocity;
|
||||
public int rightBorder;
|
||||
public int leftBorder;
|
||||
public bool isVisible = true;
|
||||
private bool isAttacked = false;
|
||||
private bool isShooting = false;
|
||||
public GameObject objectAttack;
|
||||
private int bullets;
|
||||
public bool FallingThroughPlatform = false;
|
||||
public bool isUping = false;
|
||||
public bool isNetworkPlayer;
|
||||
private int shootLength = 160;
|
||||
|
||||
|
||||
|
||||
|
||||
public int Bullets { get { return bullets; } }
|
||||
|
||||
public Player(Vector2 position, bool isNetworkPlayer = false) : base(position)
|
||||
|
||||
{
|
||||
Width = 32;
|
||||
Height = 64;
|
||||
AppManager.Instance.InputManager.MovEventJump += AnimationJump;
|
||||
this.isNetworkPlayer = isNetworkPlayer;
|
||||
Width = 16;
|
||||
Height = 32;
|
||||
|
||||
if (!isNetworkPlayer)
|
||||
{
|
||||
AppManager.Instance.InputManager.ShootEvent += Shoot;
|
||||
AppManager.Instance.InputManager.MovEventJump += Jump;
|
||||
AppManager.Instance.InputManager.MovEventDown += MoveDown;
|
||||
velocity = new Vector2(0, 0);
|
||||
rightBorder = (int)position.X + 100;
|
||||
leftBorder = (int)position.X - 100;
|
||||
bullets = 5;
|
||||
|
||||
this.GraphicsComponent.actionOfAnimationEnd += (a) =>
|
||||
{
|
||||
if (a == "playerShootLeft" || a == "playerShootRight")
|
||||
{
|
||||
isShooting = false;
|
||||
}
|
||||
if (a == "playerReload")
|
||||
{
|
||||
bullets++;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public bool IsAlive { get { return isAlive; } }
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "ZombieMoveRight", "ZombieMoveLeft", "ZombieRightAttack", "ZombieLeftAttack", "DeathFromZombie" }, "ZombieMoveLeft");//TODO: Change to player
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "playerMoveLeft", "playerMoveRight", "DeathFromZombie", "playerRightStay", "playerStayLeft",
|
||||
"playerJumpRight" , "playerJumpLeft", "playerShootLeft", "playerShootRight", "playerReload", "smokeAfterShoot", "playerShootUpRight", "playerShootUpLeft"}, "playerReload");
|
||||
|
||||
public void Kill()
|
||||
public void Attack()
|
||||
{
|
||||
|
||||
if (objectAttack.Rectangle.Intersects(this.Rectangle))
|
||||
{
|
||||
isVisible = false;
|
||||
}
|
||||
|
||||
}
|
||||
public override void OnCollision(GameObject gameObject)
|
||||
{
|
||||
base.OnCollision(gameObject);
|
||||
}
|
||||
public override void Draw(SpriteBatch spriteBatch)
|
||||
{
|
||||
if (isVisible)
|
||||
{
|
||||
base.Draw(spriteBatch);
|
||||
}
|
||||
}
|
||||
public void Death(string monsterName)
|
||||
{
|
||||
if(monsterName == "Zombie")
|
||||
if (AppManager.Instance.InputManager.InvincibilityCheat)
|
||||
{
|
||||
DeathRectangle deathRectangle = new DeathRectangle(Pos, "DeathFrom" + monsterName);
|
||||
return;
|
||||
}
|
||||
isAttacked = true;
|
||||
if (monsterName == "Zombie")
|
||||
{
|
||||
AnimationRectangle deathRectangle = new AnimationRectangle(Pos, "DeathFrom" + monsterName);
|
||||
deathRectangle.Gr.actionOfAnimationEnd += (a) =>
|
||||
{
|
||||
if (a == "DeathFrom" + monsterName)
|
||||
{
|
||||
AppManager.Instance.ChangeGameState(GameState.GameOver);
|
||||
AppManager.Instance.ChangeGameState(GameState.Death);
|
||||
}
|
||||
};
|
||||
}
|
||||
else if (monsterName == "Spider")
|
||||
{
|
||||
AnimationRectangle deathRectangle = new AnimationRectangle(Pos, "DeathFrom" + monsterName);
|
||||
deathRectangle.Gr.actionOfAnimationEnd += (a) =>
|
||||
{
|
||||
if (a == "DeathFrom" + monsterName)
|
||||
{
|
||||
AppManager.Instance.ChangeGameState(GameState.Death);
|
||||
}
|
||||
};
|
||||
}
|
||||
isAlive = false;
|
||||
}
|
||||
public void AnimationJump()
|
||||
public void Jump()
|
||||
{
|
||||
velocity.Y = -300;
|
||||
if (isOnGround)
|
||||
{
|
||||
velocity.Y = -11;
|
||||
}
|
||||
// здесь будет анимация
|
||||
}
|
||||
public void Shoot()
|
||||
{
|
||||
if (bullets > 0)
|
||||
{
|
||||
if (!isAttacked)
|
||||
{
|
||||
if (!isShooting)
|
||||
{
|
||||
isShooting = true;
|
||||
bullets--;
|
||||
if (isRight)
|
||||
{
|
||||
StartCicycleAnimation("playerShootRight");
|
||||
var targets = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X, (int)(Pos.Y - 10f), shootLength + 24, 10), typeof(Zombie)).OrderBy(x => (x.Pos - Pos).LengthSquared());
|
||||
if (targets.Count() > 0)
|
||||
{
|
||||
Zombie targetZombie = (Zombie)targets.First();
|
||||
targetZombie.TakeDamage();
|
||||
}
|
||||
SmokeAfterShoot smokeAfterShoot = new SmokeAfterShoot(new Vector2(Pos.X + 30, Pos.Y + 7));
|
||||
}
|
||||
else
|
||||
{
|
||||
StartCicycleAnimation("playerShootLeft");
|
||||
var targets = AppManager.Instance.GameManager.physicsManager.CheckRectangle(new Rectangle((int)Pos.X - shootLength, (int)(Pos.Y - 10f), shootLength, 10), typeof(Zombie));
|
||||
if (targets != null)
|
||||
{
|
||||
foreach (var target in targets)
|
||||
{
|
||||
Zombie targetZombie = (Zombie)target;
|
||||
targetZombie.TakeDamage();
|
||||
}
|
||||
}
|
||||
SmokeAfterShoot smokeAfterShoot = new SmokeAfterShoot(new Vector2(Pos.X - 12, Pos.Y + 7));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
if (AppManager.Instance.InputManager.ScopeState == ScopeState.Up)
|
||||
{
|
||||
isUping = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
isUping = false;
|
||||
}
|
||||
if (isOnGround && FallingThroughPlatform)
|
||||
{
|
||||
FallingThroughPlatform = false;
|
||||
}
|
||||
GraphicsComponent.SetCameraPosition(Pos);
|
||||
if (!isAttacked || AppManager.Instance.InputManager.InvincibilityCheat)
|
||||
{
|
||||
if (!isShooting)
|
||||
{
|
||||
Move(gameTime);
|
||||
}
|
||||
else
|
||||
{
|
||||
velocity.X = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
velocity.X = 0;
|
||||
}
|
||||
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
public void Move(GameTime gameTime)
|
||||
{
|
||||
float delta = (float)gameTime.ElapsedGameTime.TotalSeconds;
|
||||
velocity.X = 5 * AppManager.Instance.InputManager.VectorMovementDirection.X;
|
||||
if (GraphicsComponent.GetCurrentAnimation != "playerShootLeft" && GraphicsComponent.GetCurrentAnimation != "playerShootRight")
|
||||
{
|
||||
if (AppManager.Instance.InputManager.VectorMovementDirection.X > 0)
|
||||
{
|
||||
isRight = true;
|
||||
if (GraphicsComponent.GetCurrentAnimation != "playerMoveRight")//идёт направо
|
||||
{
|
||||
GraphicsComponent.StartAnimation("playerMoveRight");
|
||||
}
|
||||
}
|
||||
else if (AppManager.Instance.InputManager.VectorMovementDirection.X < 0)//идёт налево
|
||||
{
|
||||
isRight = false;
|
||||
if (GraphicsComponent.GetCurrentAnimation != "playerMoveLeft")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("playerMoveLeft");
|
||||
}
|
||||
}
|
||||
else if (AppManager.Instance.InputManager.VectorMovementDirection.X == 0)//стоит
|
||||
{
|
||||
if (bullets < 5)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "playerReload")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("playerReload");
|
||||
}
|
||||
}
|
||||
else if (isRight)
|
||||
{
|
||||
if (isUping)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "playerShootUpRight")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("playerShootUpRight");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
GraphicsComponent.StartAnimation("playerRightStay");
|
||||
}
|
||||
}
|
||||
else if (!isRight)
|
||||
{
|
||||
if (isUping)
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "playerShootUpLeft")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("playerShootUpLeft");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
GraphicsComponent.StartAnimation("playerStayLeft");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (AppManager.Instance.multiPlayerStatus != MultiPlayerStatus.SinglePlayer)
|
||||
{
|
||||
NetworkTask task = new NetworkTask(id, Pos);
|
||||
AppManager.Instance.NetworkTasks.Add(task);
|
||||
}
|
||||
}
|
||||
public void MoveDown()
|
||||
{
|
||||
FallingThroughPlatform = true;
|
||||
isOnGround = false;
|
||||
}
|
||||
|
||||
public class Bullet : GameObjects.LivingEntity
|
||||
{
|
||||
public Bullet(Vector2 position) : base(position)
|
||||
{
|
||||
}
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new("ZombieMoveLeft");
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,42 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using DangerousD.GameCore.GameObjects;
|
||||
using DangerousD.GameCore.Graphics;
|
||||
using Microsoft.Xna.Framework;
|
||||
|
||||
namespace DangerousD.GameCore.GameObjects.PlayerDeath
|
||||
{
|
||||
public class SmokeAfterShoot : GameObject
|
||||
{
|
||||
public SmokeAfterShoot(Vector2 pos) : base(pos)
|
||||
{
|
||||
Height = 6;
|
||||
Width = 6;
|
||||
PlaySmoke();
|
||||
this.GraphicsComponent.actionOfAnimationEnd += (a) =>
|
||||
{
|
||||
if (a == "smokeAfterShoot")
|
||||
{
|
||||
AppManager.Instance.GameManager.Remove(this);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "smokeAfterShoot" },
|
||||
"smokeAfterShoot");
|
||||
|
||||
public GraphicsComponent Gr => GraphicsComponent;
|
||||
|
||||
private void PlaySmoke()
|
||||
{
|
||||
if (GraphicsComponent.GetCurrentAnimation != "smokeAfterShoot")
|
||||
{
|
||||
GraphicsComponent.StartAnimation("smokeAfterShoot");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -1,30 +1,41 @@
|
|||
using Microsoft.Xna.Framework;
|
||||
using DangerousD.GameCore.GameObjects.LivingEntities;
|
||||
using DangerousD.GameCore.Network;
|
||||
using Microsoft.Xna.Framework;
|
||||
|
||||
namespace DangerousD.GameCore.GameObjects;
|
||||
|
||||
public abstract class LivingEntity : Entity
|
||||
{
|
||||
private Vector2 targetPosition;
|
||||
public bool isOnGround = true;
|
||||
public Vector2 velocity;
|
||||
public Vector2 acceleration;
|
||||
|
||||
public LivingEntity(Vector2 position) : base(position)
|
||||
{
|
||||
acceleration = new Vector2(0, 30);
|
||||
}
|
||||
public override void SetPosition(Vector2 position)
|
||||
{
|
||||
targetPosition = position; _pos = position;
|
||||
_pos = position;
|
||||
if (AppManager.Instance.multiPlayerStatus != MultiPlayerStatus.SinglePlayer)
|
||||
{
|
||||
NetworkTask task = new NetworkTask(id, _pos);
|
||||
if (this is Player || AppManager.Instance.multiPlayerStatus == MultiPlayerStatus.Host)
|
||||
{
|
||||
AppManager.Instance.NetworkTasks.Add(task);
|
||||
}
|
||||
}
|
||||
|
||||
} //TODO befrend targetpos and physics engine
|
||||
|
||||
public override void Update(GameTime gameTime)
|
||||
{
|
||||
if (Vector2.Distance(Pos, targetPosition) > 0.5f)
|
||||
{
|
||||
Vector2 dir = targetPosition - Pos;
|
||||
dir.Normalize();
|
||||
_pos += dir * velocity;
|
||||
}
|
||||
//if (Vector2.DistanceSquared(Pos, targetPosition) > 0.25f)
|
||||
//{
|
||||
// Vector2 dir = targetPosition - Pos;
|
||||
// dir.Normalize();
|
||||
// _pos += dir * velocity;
|
||||
//}
|
||||
base.Update(gameTime);
|
||||
}
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ namespace DangerousD.GameCore.GameObjects;
|
|||
|
||||
public abstract class MapObject : GameObject
|
||||
{
|
||||
public bool IsColliderOn;
|
||||
public virtual bool IsColliderOn { get; protected set; } = true;
|
||||
private Rectangle _sourceRectangle;
|
||||
protected override GraphicsComponent GraphicsComponent { get; } = new("tiles");
|
||||
public MapObject(Vector2 position, Vector2 size, Rectangle sourceRectangle) : base(position)
|
||||
|
@ -22,8 +22,10 @@ public abstract class MapObject : GameObject
|
|||
|
||||
}
|
||||
|
||||
public void Draw(SpriteBatch spriteBatch)
|
||||
public virtual void Draw(SpriteBatch spriteBatch)
|
||||
{
|
||||
GraphicsComponent.DrawAnimation(Rectangle, spriteBatch, _sourceRectangle);
|
||||
//spriteBatch.Draw(debugTexture, new Rectangle(Rectangle.X - GraphicsComponent.CameraPosition.X, Rectangle.Y - GraphicsComponent.CameraPosition.Y, Rectangle.Width, Rectangle.Height), Color.White);
|
||||
|
||||
}
|
||||
}
|