Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » Spidertest's 3D textures engine's new textures wont work.
- hippyofdoom
- Scratcher
82 posts
Spidertest's 3D textures engine's new textures wont work.
I am using spidertest's 3D textures engine( https://scratch.mit.edu/projects/155851099 ), but when I try to upload new textures, it doesn't see them and of course, doesn't show.
I have tried everything. From asking unresponsive users, to making new lists and variables, just like everyone else did, BUT NOTHING WORKS!!
Help would be MUCH, MUCH appreciated and I will be universally grateful.
The project I need help with is this: https://scratch.mit.edu/projects/259938892
I have tried everything. From asking unresponsive users, to making new lists and variables, just like everyone else did, BUT NOTHING WORKS!!
Help would be MUCH, MUCH appreciated and I will be universally grateful.
The project I need help with is this: https://scratch.mit.edu/projects/259938892
Last edited by hippyofdoom (Nov. 12, 2018 01:36:38)
- imfh
- Scratcher
1000+ posts
Spidertest's 3D textures engine's new textures wont work.
You need to add the name of the list holding your texture to the list Textures. You also need to run the block ScanToList with the name of the list and the costume# for the list. Then you need to edit the World Map with the number of the texture in Textures.
Scratch to Pygame converter: https://scratch.mit.edu/discuss/topic/600562/
- hippyofdoom
- Scratcher
82 posts
Spidertest's 3D textures engine's new textures wont work.
@imfh, first of all I don’t think there is a list holding textures. If you delete the textures costumes, the game still somehow draws it. Second of all, I have NO clue on what and how to do that. Can you remix? I will appreciate it.
- hippyofdoom
- Scratcher
82 posts
Spidertest's 3D textures engine's new textures wont work.
You need to add the name of the list holding your texture to the list Textures. You also need to run the block ScanToList with the name of the list and the costume# for the list. Then you need to edit the World Map with the number of the texture in Textures.
@imfh, first of all I don’t think there is a list holding textures. If you delete the textures costumes, the game still somehow draws it. Second of all, I have NO clue on what and how to do that. Can you remix? I will appreciate it.
- imfh
- Scratcher
1000+ posts
Spidertest's 3D textures engine's new textures wont work.
I would remix it, but this is literally all you need to do:
After running that, show list World Map and randomly replace some of the numbers with 6s, the texture id of the texture you just added.
The reason deleting costumes doesn't do anything, is because the ScanToList function saves a costume to a list that can easily be read by the program.
ScanToList [FarmDoorL] (2) ::custom // Name for the texture, costume#
add [FarmDoorL] to [Textures v] // Save the name of the list for the program
think (length of [Textures v] :: list) // The textureId of the texture just added
After running that, show list World Map and randomly replace some of the numbers with 6s, the texture id of the texture you just added.
The reason deleting costumes doesn't do anything, is because the ScanToList function saves a costume to a list that can easily be read by the program.
Scratch to Pygame converter: https://scratch.mit.edu/discuss/topic/600562/
- deck26
- Scratcher
1000+ posts
Spidertest's 3D textures engine's new textures wont work.
This is a more concise version of what I said in your other topic. The ScantoList custom block is not called by the project, only manually when you want to add a new texture. I would remix it, but this is literally all you need to do:ScanToList [FarmDoorL] (2) ::custom // Name for the texture, costume#
add [FarmDoorL] to [Textures v] // Save the name of the list for the program
think (length of [Textures v] :: list) // The textureId of the texture just added
After running that, show list World Map and randomly replace some of the numbers with 6s, the texture id of the texture you just added.
The reason deleting costumes doesn't do anything, is because the ScanToList function saves a costume to a list that can easily be read by the program.
- hippyofdoom
- Scratcher
82 posts
Spidertest's 3D textures engine's new textures wont work.
Everything works, the texture is added to the list, BUT the system still does not texturize it for some reason. I would remix it, but this is literally all you need to do:ScanToList [FarmDoorL] (2) ::custom // Name for the texture, costume#
add [FarmDoorL] to [Textures v] // Save the name of the list for the program
think (length of [Textures v] :: list) // The textureId of the texture just added
After running that, show list World Map and randomly replace some of the numbers with 6s, the texture id of the texture you just added.
The reason deleting costumes doesn't do anything, is because the ScanToList function saves a costume to a list that can easily be read by the program.
- deck26
- Scratcher
1000+ posts
Spidertest's 3D textures engine's new textures wont work.
Why did you delete the empty and empty2 costumes for Textures? Those are the costumes it uses to scan for colours although as long as you have a solid 32x32 properly centred costume it shouldn't matter. Your costumes have to be 32 x 32 pixels.
The ScanToList custom block uses hacked blocks to allow you to use lists as parameters. That mean you have to be careful - if you break a hacked block you can't put it back together. The block before ‘repeat until y position = -16’ is a hacked block and your copy is no longer holding together so the length isn't functioning the way you want. You need to recopy that block. That may not be the only problem but if I was you I'd recopy the ScanToList script into your project and try again to recreate one of your textures.
The ScanToList custom block uses hacked blocks to allow you to use lists as parameters. That mean you have to be careful - if you break a hacked block you can't put it back together. The block before ‘repeat until y position = -16’ is a hacked block and your copy is no longer holding together so the length isn't functioning the way you want. You need to recopy that block. That may not be the only problem but if I was you I'd recopy the ScanToList script into your project and try again to recreate one of your textures.
- hippyofdoom
- Scratcher
82 posts
Spidertest's 3D textures engine's new textures wont work.
This is a more concise version of what I said in your other topic. The ScantoList custom block is not called by the project, only manually when you want to add a new texture. I would remix it, but this is literally all you need to do:ScanToList [FarmDoorL] (2) ::custom // Name for the texture, costume#
add [FarmDoorL] to [Textures v] // Save the name of the list for the program
think (length of [Textures v] :: list) // The textureId of the texture just added
After running that, show list World Map and randomly replace some of the numbers with 6s, the texture id of the texture you just added.
The reason deleting costumes doesn't do anything, is because the ScanToList function saves a costume to a list that can easily be read by the program.
I would remix it, but this is literally all you need to do:ScanToList [FarmDoorL] (2) ::custom // Name for the texture, costume#
add [FarmDoorL] to [Textures v] // Save the name of the list for the program
think (length of [Textures v] :: list) // The textureId of the texture just added
After running that, show list World Map and randomly replace some of the numbers with 6s, the texture id of the texture you just added.
The reason deleting costumes doesn't do anything, is because the ScanToList function saves a costume to a list that can easily be read by the program.
Also, where should I put these scripts EVEN if they work?!
- imfh
- Scratcher
1000+ posts
Spidertest's 3D textures engine's new textures wont work.
Put them in sprite Textures and click on it to run it. They only need to run once. It looks like you have done this though.
You skipped one of steps I gave you. Here it is again, it is important if you want the map to have your texture in it. “After running that, show list World Map and randomly replace some of the numbers with 6s, the texture id of the texture you just added.”
List Textures holds the name of every texture and it's texture id, or the position of the texture name in the list. The texture id is put into list World Map to make it show up in the map when you run the program. Replacing random numbers in World Map will make the texture show up in the map somewhere. Alternatively you can reorder the textures, which could replace one texture with another.
I don't know what format World Map uses, but it shouldn't be too hard to figure out by playing with it.
You skipped one of steps I gave you. Here it is again, it is important if you want the map to have your texture in it. “After running that, show list World Map and randomly replace some of the numbers with 6s, the texture id of the texture you just added.”
List Textures holds the name of every texture and it's texture id, or the position of the texture name in the list. The texture id is put into list World Map to make it show up in the map when you run the program. Replacing random numbers in World Map will make the texture show up in the map somewhere. Alternatively you can reorder the textures, which could replace one texture with another.
I don't know what format World Map uses, but it shouldn't be too hard to figure out by playing with it.
Scratch to Pygame converter: https://scratch.mit.edu/discuss/topic/600562/
- imfh
- Scratcher
1000+ posts
Spidertest's 3D textures engine's new textures wont work.
I have created a remix, you can see it here. Another reason I didn't create one before was because you would still need to know how to do it yourself so you could add the rest of the textures.
The pictures you are using are the wrong size. It can only save a 32x32 square, so trying to render the pictures you have results in red blobs. I created a rough imitation of one of your pictures in a 32x32 size(duplicate the empty black square; it helps) to give you an idea of what to do.
The pictures you are using are the wrong size. It can only save a 32x32 square, so trying to render the pictures you have results in red blobs. I created a rough imitation of one of your pictures in a 32x32 size(duplicate the empty black square; it helps) to give you an idea of what to do.
Scratch to Pygame converter: https://scratch.mit.edu/discuss/topic/600562/
- deck26
- Scratcher
1000+ posts
Spidertest's 3D textures engine's new textures wont work.
This really isn't that difficult.
Assume you had no lists at all and no texture costumes. Let's say you draw a brick costume and a stone costume. Those have to be converted into lists so the project can draw a tile in a wall and do so at an angle if necessary. So a simple costume is no use - we need to extract the data representing the costume so we can transform it in different ways.
OK, let's make a brick texture. We first make a list called brick. We then scan the costume in some way to put data into that list so we can use it. That's what the ScanToList does. It takes the costume number specified, scans 32x32 pixels and records the data to the list.
Similrly we can create a list called stone and convert the stone costume into data in that list.
At this point the costumes are no longer relevant as we've extracted the data. However if we lose the data in one of the lists we'd need to recreate it.
The ScanToList script is run manually and we let Scratch remember the data. We could scan each costume every time we run the project but it's not really necessary.
So we have two textures but how does the project use them? We need to add ‘brick’ and ‘stone’ to the textures list so we have some way to refer to them. So if the map says this bit of ‘wall’ is texture 1 we look at the textures list to get the name of the texture. That is also the name of the list that contains the data so the map says texture 1, the textures list tells us that is ‘brick’ so we use the list ‘brick’ to draw that wall segment.
Assume you had no lists at all and no texture costumes. Let's say you draw a brick costume and a stone costume. Those have to be converted into lists so the project can draw a tile in a wall and do so at an angle if necessary. So a simple costume is no use - we need to extract the data representing the costume so we can transform it in different ways.
OK, let's make a brick texture. We first make a list called brick. We then scan the costume in some way to put data into that list so we can use it. That's what the ScanToList does. It takes the costume number specified, scans 32x32 pixels and records the data to the list.
Similrly we can create a list called stone and convert the stone costume into data in that list.
At this point the costumes are no longer relevant as we've extracted the data. However if we lose the data in one of the lists we'd need to recreate it.
The ScanToList script is run manually and we let Scratch remember the data. We could scan each costume every time we run the project but it's not really necessary.
So we have two textures but how does the project use them? We need to add ‘brick’ and ‘stone’ to the textures list so we have some way to refer to them. So if the map says this bit of ‘wall’ is texture 1 we look at the textures list to get the name of the texture. That is also the name of the list that contains the data so the map says texture 1, the textures list tells us that is ‘brick’ so we use the list ‘brick’ to draw that wall segment.
- Discussion Forums
- » Help with Scripts
- » Spidertest's 3D textures engine's new textures wont work.