ECS vectors v1.1.2 (by George) 19/06/2011

Discuss, get help with, or post new graphics for TTDPatch and OpenTTD, using the NewGRF system, here. Graphics for plain TTD also acceptable here.

Moderator: Graphics Moderators

Do you use ECS with TTDP?

I use ECS under TTDP
5
3%
I use ECS under TTDP and OTTD
6
4%
I use ECS under OTTD
158
93%
 
Total votes: 169

User avatar
George
Tycoon
Tycoon
Posts: 4364
Joined: 16 Apr 2003 16:09
Skype: george-vb
Location: Varna, Bulgaria
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by George »

wallyweb wrote:Hi George,
On the ECS Agricultural Vector wiki page, under Default Cargoes, you show two ID's for fruit: Fruit (ID 07) and Fruit (ID 0D). Is this correct?
Wood is 07. Fruit (ID 0D)
wallyweb wrote:Also, are you moving Banks from Basic to Town?
Done. I'll upload changes as soon as I make some tests.
Image Image Image Image
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by wallyweb »

George wrote:
wallyweb wrote:Also, are you moving Banks from Basic to Town?
Done. I'll upload changes as soon as I make some tests.
Will this mean that you will have Valuables (Temperate), Gold (Arctic) and Diamonds (Tropic) together in the same Vector?
User avatar
George
Tycoon
Tycoon
Posts: 4364
Joined: 16 Apr 2003 16:09
Skype: george-vb
Location: Varna, Bulgaria
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by George »

wallyweb wrote:
George wrote:
wallyweb wrote:Also, are you moving Banks from Basic to Town?
Done. I'll upload changes as soon as I make some tests.
Will this mean that you will have Valuables (Temperate), Gold (Arctic) and Diamonds (Tropic) together in the same Vector?
No. Town vector specifies valuables. Basic vector for Arctic/tropic would override it with Gold/Diamonds
Image Image Image Image
User avatar
George
Tycoon
Tycoon
Posts: 4364
Joined: 16 Apr 2003 16:09
Skype: george-vb
Location: Varna, Bulgaria
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by George »

Rubidium wrote:Not for industry tile type 11h (17), the one with the cut trees and the one causing the problems. This one only applies to industry tile type 10h (16).
Sorry, but forest consists only from tiles 10h and 80h

Code: Select all

// = Forest (ID 12, part 10, 80) =
  235 * 29	 00 09 0A 01 10
                 08 10   
                 0A 00 00
                 0B 00 00
                 0C 00 00
                 0D 10   
                 0E 73   
                 0F 80 01
                 10 07   
                 11 00   
                 12 01   
  236 * 29	 00 09 0A 01 80
                 08 0C   
                 0A 07 08
                 0B 00 00
                 0C 00 00
                 0D 10   
                 0E 55   
                 0F 02 00
                 10 01   
                 11 00   
                 12 00
  237 * 81	 00 0A 19 01 12
                 08 12         
                 0B 02         
                 0C 32 48      
                 0D 35 48      
                 0E 39 48      
                 0F FF         
                 10 08 FF      
                 11 07 FF FF 00
                 12 00         
                 13 00         
                 14 14         
                 15 00
                 16 93 8E FF
                 17 06         
                 18 0C         
                 19 53         
                 1A 00 00 02 00
                 1B 2E 48      
                 1C 00 00 00 00
                 1D 00 00 00 00
                 1E 00 00 00 00
                 1F 05 48      
                 20 FF FF FF FF
                 21 BD         
                 22 05         
  238 * 342	 00 0A 01 01 12
                 0A 03 4B 01 00 00
                 00 00 FE 10 00
                 01 00 FE 10 00
                 02 00 FE 10 00
                 03 00 FE 10 00
                 00 01 FE 10 00
                 01 01 FE 10 00
                 02 01 FE 10 00
                 03 01 FE 10 00
                 00 02 FE 10 00
                 01 02 FE 10 00
                 02 02 FE 10 00
                 03 02 FE 10 00
                 00 03 FE 10 00
                 01 03 FE 10 00
                 02 03 FE 10 00
                 03 03 FE 10 00
                 01 04 FE 10 00
                 02 04 FE 10 00
                 03 04 FE 80 00
                 00 80 00 00 FE 10 00
                 01 00 FE 10 00
                 02 00 FE 10 00
                 03 00 FE 10 00
                 04 00 FE 10 00
                 00 01 FE 10 00
                 01 01 FE 10 00
                 02 01 FE 10 00
                 03 01 FE 10 00
                 04 01 FE 10 00
                 00 02 FE 10 00
                 01 02 FE 10 00
                 02 02 FE 10 00
                 03 02 FE 10 00
                 04 02 FE 10 00
                 00 03 FE 10 00
                 01 03 FE 10 00
                 02 03 FE 10 00
                 03 03 FE 10 00
                 04 03 FE 10 00
                 01 04 FE 10 00
                 02 04 FE 10 00
                 03 04 FE 10 00
                 04 04 FE 80 00
                 00 80 00 00 FE 10 00
                 01 00 FE 10 00
                 02 00 FE 10 00
                 03 00 FE 10 00
                 00 01 FE 10 00
                 01 01 FE 10 00
                 02 01 FE 10 00
                 03 01 FE 10 00
                 04 01 FE 10 00
                 00 02 FE 10 00
                 01 02 FE 10 00
                 02 02 FE 10 00
                 03 02 FE 10 00
                 04 02 FE 10 00
                 00 03 FE 10 00
                 01 03 FE 10 00
                 02 03 FE 10 00
                 03 03 FE 10 00
                 04 03 FE 10 00
                 01 04 FE 10 00
                 02 04 FE 10 00
                 03 04 FE 80 00
                 00 80
as you can see, tile 80h has prop 0E = 55, and according to wiki

Code: Select all

0	1	use callback 26 to decide the next animation frame
1	2	use callback 27 to decide animation speed
2	4	use callback 2B to decide amount of acceptance (only from 2.0.1 a55 vcs 3)
3	8	use callback 2C to decide accepted types (only from 2.0.1 a55 vcs 3)
4	10	use callback 2F to check if a slope is suitable
5	20	use callback 30 to decide if default foundations need to be drawn
6	40	use callback 3C to allow or deny autosloping below the tile (only from 2.5 beta 3)
this means not to check for callback 30h = always draw foundation.

Sorry, but I can't understand, what bug in my code are you referring to. Could you give me more details about the problem?
Image Image Image Image
Rubidium
OpenTTD Developer
OpenTTD Developer
Posts: 3815
Joined: 09 Feb 2006 19:15

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by Rubidium »

The chopped wood is industry tile type 11h. The non-chopped trees are tile type 10h (and the house 80h). Whenever the trees are chopped the industry tile type changes from 10h to 11h. Once the chopped wood is removed and trees are replanted it is changed from 11h to 10h back. I assume this happens in TTDP too as I seem to remember sprites where you have chopped wood and it looks like it is using the chopped wood graphics according to the wiki too.

As you do not tell the industry tiles of type 11h must be drawn on foundations if needed, OpenTTD tries to draw them on foundations but finds out that it is impossible to make a level foundation for the tile. For industry tiles of type 10h there level foundations are explicitly turned off.
User avatar
Csaboka
Tycoon
Tycoon
Posts: 1202
Joined: 25 Nov 2002 16:30
Location: Tiszavasvári, Hungary
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by Csaboka »

There may be a misunderstanding here. Even though old industry tile 10h is supposed to change into 11h when cargo is transported from it, new industry tiles shouldn't change types, ever. TTDPatch has code to prevent this conversion from happening for new industry tiles, see class8periodicproc2 in newindu.asm. If the GRF author wants to imitate the behavior of the original forest, (s)he has to do that via the animation feature. Changing the type of the tile would be confusing, and as this example shows, can be disastrous, too.

My guess is that the anim_production and anim_next fields of IndustryTileSpec are copied from the substitute tile type when defining a new industry tile, while they shouldn't be, and instead should always be set to INDUSTRYTILE_NOANIM. Unfortunately, I can't seem to find the code where this copying takes place, so I can't offer a diff to fix this, but I'm sure belugas knows exactly what to change after reading this post :)
Reality is that which, when you stop believing in it, doesn't go away.—Philip K. Dick
User avatar
belugas
OpenTTD Developer
OpenTTD Developer
Posts: 1507
Joined: 05 Apr 2005 01:48
Location: Deep down the deepest blue
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by belugas »

Yup, i think I do.
I'm checking it right now :)
Csaboka wrote:My guess is that the anim_production and anim_next fields of IndustryTileSpec are copied from the substitute tile type when defining a new industry tile, while they shouldn't be, and instead should always be set to INDUSTRYTILE_NOANIM.
Are these the only properties not to be transported from spec to new?

P.S.: Good luck with studies and nice to hear from you ;)
If you are not ready to work a bit for your ideas, it means they don't count much for you.
OpenTTD and Realism? Well... Here are a few thoughs on the matter.
He he he he
------------------------------------------------------------
Music from the Bloody Time Zones
User avatar
Csaboka
Tycoon
Tycoon
Posts: 1202
Joined: 25 Nov 2002 16:30
Location: Tiszavasvári, Hungary
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by Csaboka »

belugas wrote:Are these the only properties not to be transported from spec to new?
I think those two are the only ones that shouldn't be copied. Anim_state is a bit tricky because it shouldn't matter for a new industry tile, but it can still make a difference when the graphics aren't available and substitute graphics must be used instead. In other words, it must be copied, but shouldn't be used when new graphics are available. The code gets this part right, I'm just saying that it would be nicer to document it somewhere.
belugas wrote:Good luck with studies and nice to hear from you
Thank you.:)
Reality is that which, when you stop believing in it, doesn't go away.—Philip K. Dick
User avatar
belugas
OpenTTD Developer
OpenTTD Developer
Posts: 1507
Joined: 05 Apr 2005 01:48
Location: Deep down the deepest blue
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by belugas »

Done in r11665. So, now... Watch the effects :)
If you are not ready to work a bit for your ideas, it means they don't count much for you.
OpenTTD and Realism? Well... Here are a few thoughs on the matter.
He he he he
------------------------------------------------------------
Music from the Bloody Time Zones
User avatar
George
Tycoon
Tycoon
Posts: 4364
Joined: 16 Apr 2003 16:09
Skype: george-vb
Location: Varna, Bulgaria
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by George »

2Wally:
I wrote the page, could you check the text, please?
http://wiki.ttdpatch.net/tiki-index.php ... ronOreMine

Also, when do you plan to make the text at this page more detailed?
http://wiki.ttdpatch.net/tiki-index.php ... neralRules
Image Image Image Image
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by wallyweb »

George wrote:2Wally:
I wrote the page, could you check the text, please?
http://wiki.ttdpatch.net/tiki-index.php ... ronOreMine
Done with some revisions,
except for:
"!!Possible locations
Iron ore mines can not be built on flat land far from towns (Rz0 + 6 < Ed). They can't be built near other iron ore mines, steel mills."
This says that:
1. Iron ore mines cannot be built on flat land [they must be built on slopes]
2. Iron ore mines cannot be built far from towns (Rz0 + 6 < Ed) [they must be built near towns]
3. Iron ore mines cannot be built near other iron ore mines.
4. Iron ore mines cannot be built near steel mills.
Are these correct?
Also, please check the revisions.
Also, when do you plan to make the text at this page more detailed?
http://wiki.ttdpatch.net/tiki-index.php ... neralRules
What details are missing?

Also
"Production level
ECS industries use data from Industry array
Offset Size Meaning
13 B Production multiplier, always either 00 (which means the industry has announced imminent closure) or an integer power of 2. 10 is the default, 04 is the minimum, 80 is the maximum."
This is confusing me. What is "Offset Size Meaning"?
User avatar
George
Tycoon
Tycoon
Posts: 4364
Joined: 16 Apr 2003 16:09
Skype: george-vb
Location: Varna, Bulgaria
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by George »

wallyweb wrote:
George wrote:2Wally:
I wrote the page, could you check the text, please?
http://wiki.ttdpatch.net/tiki-index.php ... ronOreMine
Done with some revisions,
except for:
"!!Possible locations
Iron ore mines can not be built on flat land far from towns (Rz0 + 6 < Ed). They can't be built near other iron ore mines, steel mills."
This says that:
1. Iron ore mines cannot be built on flat land [they must be built on slopes]
Mistake. should be on flat land
wallyweb wrote:2. Iron ore mines cannot be built far from towns (Rz0 + 6 < Ed) [they must be built near towns]
No, they should be build far from towns. (at least 6 tiles away)
wallyweb wrote:3. Iron ore mines cannot be built near other iron ore mines.
Yes
wallyweb wrote:4. Iron ore mines cannot be built near steel mills.
Yes
wallyweb wrote:
Also, when do you plan to make the text at this page more detailed? http://wiki.ttdpatch.net/tiki-index.php ... neralRules
What details are missing?
I suppose a lot. I mean this description is enough for me and you, but for a user, who played without new industries, there are surprises. I think we need more details to write there. I'll try to form a plan.
wallyweb wrote:Also
"Production level
ECS industries use data from Industry array
Offset Size Meaning
13 B Production multiplier, always either 00 (which means the industry has announced imminent closure) or an integer power of 2. 10 is the default, 04 is the minimum, 80 is the maximum."
This is confusing me. What is "Offset Size Meaning"?
I've answered this question before in this thread :?
Image Image Image Image
User avatar
George
Tycoon
Tycoon
Posts: 4364
Joined: 16 Apr 2003 16:09
Skype: george-vb
Location: Varna, Bulgaria
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by George »

wallyweb wrote:What details are missing?
I've placed remarks on the page.
Image Image Image Image
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by wallyweb »

OK ... Iron Ore Mines are done.
George wrote:
wallyweb wrote:What details are missing?
I've placed remarks on the page.
I see "to write: what does it mean?" ... So will you be writing what it means so that I can edit it? Or do you want me to write what it means (which might be difficult as I may not know what it means until you write what it means)?
User avatar
George
Tycoon
Tycoon
Posts: 4364
Joined: 16 Apr 2003 16:09
Skype: george-vb
Location: Varna, Bulgaria
Contact:

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by George »

wallyweb wrote:
George wrote:
wallyweb wrote:What details are missing?
I've placed remarks on the page.
I see "to write: what does it mean?" ... So will you be writing what it means so that I can edit it? Or do you want me to write what it means (which might be difficult as I may not know what it means until you write what it means)?
I supposed that we both would write these parts, every one from his point of view. You will write what does it mean for you as a player, your filling and emotions. I shall write some code related things.
Because I'm afraid your text may affect your text, I'd like you to write your part first, then I'll write my part, and after that you'll fix your part according to my part.

I mean I supposed that you'll write what new did you discovered while servicing new industries. Like "I had to control accepting/amount of cargo waiting/profit, use more/less vehicles than usual, use transfer stations ...". Because I never played my industries myself. I made a test saved games, but there I used unlimited money, ultra fast vehicles with ultra high capacity, never controlled income... It is a test situation to check the code, but is not a game in any way. That's why I can't write "what's new" for the gameplay - I do not know it. I can do it only for a code part.
Image Image Image Image
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by wallyweb »

George wrote:I supposed that we both would write these parts ...
OK, I understand what you are looking for now. Would it not be better to wait until you finish updating all your download files to Beta 3?
User avatar
napocram
Engineer
Engineer
Posts: 10
Joined: 28 Oct 2007 19:26
Location: Italy but Canadian

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by napocram »

to george and wallyweb

Hi guys! :D

I am fairly new to the forum and maybe I have missed it somewhere it the threads, but I could not find a detailed description of the new industry windows. maybe in the wiki pages there should be a detailed description of each single voice and/or info given.

I looked for any explanations in the forum but I just could not find them. :?
do you think is it a good idea to put that info on the wiki pages? :)
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by wallyweb »

napocram wrote:do you think is it a good idea to put that info on the wiki pages? :)
That is something that can be done. As most of the windows are similar for all of George's ECS Industries, one would only need to use one as an example and it would fit nicely in that General Rules page, perhaps under a small heading "The Industry Window". Let me see what I can do with this.

@George, Can you change the title of that page from "General Rules" to "General Information" or to "General Data"? It would be more appropriate. :wink:
User avatar
napocram
Engineer
Engineer
Posts: 10
Joined: 28 Oct 2007 19:26
Location: Italy but Canadian

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by napocram »

Thanks guys!

Helpfull as usual!
and in any case...

Merry Xmas and Happy New Year
User avatar
Rainer
Traffic Manager
Traffic Manager
Posts: 240
Joined: 14 Nov 2007 10:01
Location: Wiesbaden, Germany

Re: ECS implementation by George: ECS vectors. Beta 3 08/10/2007

Post by Rainer »

Hi,

I just downloaded and installed the new Machinery Vector version and activated it in a running game (OTTD single user).

The Iron Ore Mines have a wrong Tile on the top.
Wrong Tile on Iron Ore Mine
Wrong Tile on Iron Ore Mine
Rainer 16-2007 Transport, 16. Mai 1939.png (10.71 KiB) Viewed 2389 times
Within a year three serviced Ore Mines (about 70% transported) closed down.

Is that a bug or a feature?

cu
Rainer
Post Reply

Return to “Graphics Development”

Who is online

Users browsing this forum: No registered users and 22 guests