Jump to content
  • 0

Custom Obstacle not displaying properly


Captain_Neko

Question

So I made a Tree (TRED.png) to be used as a Decoration

Imige.PNG.3f82ca0d6d6561e9563abc3208f73f05.PNG

I flowed some tutorials and ended up with this in Slade.

Slade.PNG.f74e70ecc718a3b7b202f4b9e5065683.PNG

But when I go into UDB the name of the decoration is correct but I get a frame of the red torch instead of my beautiful tree!

DB.PNG.35f0fac107f0206affe11dfd1fa19d2c.PNG

I'm unsure how to fix this...

Share this post


Link to post

8 answers to this question

Recommended Posts

  • 0

I HAVE FOUND THE SOLUTION!!!!!!!!!!

 

All I had to do was to change

States

{

Spawn:

DTRE A 0

Stop

}

}

 

to

 

States

{

Spawn:

DTRE A -1

Stop

}

}

 

Not relay sure why changing the rotation from 0 to -1 was the solution but im not going to look this gift horse in the mouth!

 

Thanks for the help y'all!

Share this post


Link to post
  • 0
13 minutes ago, rouge_means_red said:

The sprite has to be named TREDA0.png (TRED is the sprite, A is the frame, 0 is the rotation)

 

Yes this, and also the folder it is in needs to be named "Sprites" for it to be registered as a sprite.

And also TRED is already a name of sprite for the red torch, so it is probably better to give it different name, otherwise existing red torches will flicker between the tree sprite (1 frame) and original torch sprites (3 frames).

Share this post


Link to post
  • 0
Quote

Yes this, and also the folder it is in needs to be named "Sprites" for it to be registered as a sprite.

And also TRED is already a name of sprite for the red torch, so it is probably better to give it different name, otherwise existing red torches will flicker between the tree sprite (1 frame) and original torch sprites (3 frames).

 

ahhhhhhh! I wasn't aware of that. Thanks.

Share this post


Link to post
  • 0

I did what was suggested but now there is a new problem. the tree appears in UDB when I'm editing but it doesn't when I play test.

DB3.PNG.925ded87578cc21b9b674872e122d5a2.PNG

DB2.PNG.d2ecddc962dff6f425f6065dc5a85070.PNG

DB1.PNG.9c22144ff9595039053dfe167243b410.PNG

Share this post


Link to post
  • 0

Offsets maybe? Try selecting the tree sprite in SLADE and clicking the "modify offsets" button at the bottom of the screen, use automatic offsets for monster.

Share this post


Link to post
  • 0
Posted (edited)
19 minutes ago, plums said:

Offsets maybe? Try selecting the tree sprite in SLADE and clicking the "modify offsets" button at the bottom of the screen, use automatic offsets for monster.

No luck. Maybe because its a Graphic (DOOM) instead of a Graphic (PNG)?

Edit: it was not.

Slade.PNG.66f9c23d6b34fd715abe5c3cdeb656eb.PNGSlade2.PNG.2d4790c69f7e1414f930249afe455645.PNG

Edited by Captain_Neko

Share this post


Link to post
  • 0
58 minutes ago, Captain_Neko said:

Not relay sure why changing the rotation from 0 to -1 was the solution but im not going to look this gift horse in the mouth!

That's not the rotation, that's the frame duration. You don't specify the rotation in the state definitions, it's chosen based on the angle you're viewing the sprite at. (rotation 0 means it looks the same from all directions though.)

 

For duration, 0 means display for 0 frames, which means never show up. -1 on the other hand means infinite duration.

 

Glad you got it fixed!

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...