HERDING LIVESTOCK TO MARKET

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

Post Reply
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

HERDING LIVESTOCK TO MARKET

Post by GarryG »

UPDATED: 27 April 2023

I have started making a road vehicle set without vehicles :roll:

So far there is:
* livestock that can be herded on the roads.
(Basically designed to take your livestock to the markets before road vehicles where invented)
* People riding bicycles.
(Will carry people as if the bikes are rented and when reach the bus stop they swap riders. Or can carry mail as if delivering mail).
* Military people marching. (Yet to add the military bands).

How to use:

* I designing 2 versions of these so have choice a small herd that will block just 1 lane of the road or a larger herd that will use both lanes of the road.
* The livestock when loaded have animals, people and dogs herding. When empty only have the people and dogs to return to the farm.
* There are also eye candy version for those who just want the animals roaming around the roads.

Intend to add:
* Pigs.
* Horses.
* People on parade.
* Wonder if I try doing marching girls?

Suggestions be appreciated.

Credits:

Many thanks go to the following:
Kruemelchen help with coding.

Graphics:
George did the sheep, cattle and pigs.
Can see his animals at
viewtopic.php?p=1150629#p1150629
McZapkie for the horses.
(From his Polroad Vehicle set .. took them off his horse and carts)
javelinnl for the bicycles.
(He has a set called "velo" where he has a single bike rider roaming the streets).

The following have help with ideas and showing me how they used what I did so far:
odisseus, ebla71, Captain Rand, RoyalExamination9410, Brickblock and belgi

Latest upload is on Page 5.
Last edited by GarryG on 27 Apr 2023 22:29, edited 1 time in total.
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
User avatar
odisseus
Director
Director
Posts: 568
Joined: 01 Nov 2017 21:19

Re: HERDING LIVESTOCK TO MARKET

Post by odisseus »

A livestock herd coded as a vehicle would take the same amount of space on the road whether it's full or empty. This could be a bit of a problem.

Also, livestock herds usually don't respect the traffic lanes. They often occupy the whole width of the road, as limited by fences or other obstacles.

Image
Kruemelchen
Transport Coordinator
Transport Coordinator
Posts: 287
Joined: 18 Feb 2017 17:47

Re: HERDING LIVESTOCK TO MARKET

Post by Kruemelchen »

I think the idea is pretty neat! :D

I thought of coding this with cattle and sheep one day, just haven't come around to draw the animals yet (I always do this in extra zoom). But I can definitely assist you with the code :)
odisseus wrote: 12 Apr 2023 12:04 A livestock herd coded as a vehicle would take the same amount of space on the road whether it's full or empty. This could be a bit of a problem.
I would make the "herd" an articulated vehicle of several herd segments. It could be possible to adjust the length of the segments depending on the cargo like this:

Code: Select all

switch(FEAT_ROADVEHS, SELF, herd_length_cargo, cargo_count) {
	0:		0;
	1..3:	1;
	4..6:	2;
	7..9:	3;
	10..13:	4;
	14..17:	5;
	18..21:	6;
	22..24:	7;
	default:	8;
}
switch(FEAT_ROADVEHS, SELF, herd_length, position_in_consist) {
	0:		1;
	default:	herd_length_cargo;
}
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

Re: HERDING LIVESTOCK TO MARKET

Post by GarryG »

Thanks for the feed back.
odisseus wrote: 12 Apr 2023 12:04 A livestock herd coded as a vehicle would take the same amount of space on the road whether it's full or empty. This could be a bit of a problem.
I think it will look good if they take up all the road like in real. Not sure how road vehicles will react when they become available. They might just have to wait till the animals have cleared. :D

I also like to make a extra road called a stock route so just the livestock can travel on it. But the livestock can also go on other roads.
Kruemelchen wrote: 12 Apr 2023 14:52 I thought of coding this with cattle and sheep one day, just haven't come around to draw the animals yet (I always do this in extra zoom). But I can definitely assist you with the code
Maybe Georges animals might be a good start till get it working properly and maybe adjust later..
That be appreciated if you can help. I hope to start on this project in a day or 2. Busy today as got medical appointments.
Kruemelchen wrote: 12 Apr 2023 14:52 I would make the "herd" an articulated vehicle of several herd segments. It could be possible to adjust the length of the segments depending on the cargo like this:
That sounds like a great idea. I see in the HEQS set some vehicles have 2 trailers. The problem will be when returning to the farm. We don't need to bring the livestock back to farm. Just the people herding who was herding the animals.

Cheers all .. I got to go .. got an hour to get ready before I go get the bus.
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
ebla71
Transport Coordinator
Transport Coordinator
Posts: 346
Joined: 14 Apr 2021 21:48
Location: Earth

Re: HERDING LIVESTOCK TO MARKET

Post by ebla71 »

GarryG wrote: 12 Apr 2023 21:52 I think it will look good if they take up all the road like in real. Not sure how road vehicles will react when they become available. They might just have to wait till the animals have cleared. :D
Or you will get a lot of minced lamb, if not 8)

I once got caught in a herd of sheep while driving around the Etna in Sicily and it is - hm - interesting. Luckily the car was rented :D
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

Re: HERDING LIVESTOCK TO MARKET

Post by GarryG »

ebla71 wrote: 12 Apr 2023 22:51 I once got caught in a herd of sheep while driving around the Etna in Sicily and it is - hm - interesting. Luckily the car was rented
When I work for railways had to herd the sheep, cattle and pigs on and off the wagons from the stock yards.

I think sheep are more intelligent then some car drivers these day :D

What speed should they travel at? Maybe sheep and pigs 5 mph (8 km/h) and cattle a little bit faster maybe 10 mph (16 km/h).

See if I can start making the templates this afternoon or in the morning. Like to make them fairly wide so that can take up a lot of road space.
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
User avatar
Captain Rand
Traffic Manager
Traffic Manager
Posts: 192
Joined: 28 Jan 2012 07:35

Re: HERDING LIVESTOCK TO MARKET

Post by Captain Rand »

GarryG wrote: 13 Apr 2023 02:16 What speed should they travel at? ..........
Human walking speed is about 3MPH, so if you have a shepherd guiding sheep on foot he's probably walking at a gentle stroll, which would be even slower. Cowboys on horseback (still walking) might be a bit quicker, but not by much.
Nothing in OTTD is really in scale though is it?, so you don't really need to be dead on accurate, but I think even 5MPH is really pushing it.

I think you may run in to another problem though. Stockpiling at the source farm. Your "vehicles" would be so slow that by the time they return empty to the farm that farm may have already gone through more than one cycle of cargo generation. The answer to this of course is simply to use more "vehicles", but then you could end up with a constant stream of "animals" on the road which just wouldn't look right.
You could just give each "vehicle" a high cargo capacity, but then it's impossible to predict how high this needs to be. There's too many other factors to consider. How far is the destination? How long is travel time? What industry set is being used?
These will all influence production rates.
If left at the source for too long, or source to destination is too far, then you could also face the problem of cargo aging.

I'm not trying to discourage you, I think this would make a brilliant GRF.

As an example, in one of my games I had a rail station serving three nearby farms. The farms were just outside the catchment area of the station. I linked them with the distant station function so the station was now collecting cargo directly from the farms. Then I made some dirt roads to link the farms to the station to give the illusion of livestock being herded. I had to use my imagination of course but that's half the fun! I used trucks with transfer orders for the other slightly more distant farms in the same cluster. I'd have absolutely used your GRF had it been available then for the closer farms with transfer orders rather than directly linking stations.

As always, I look forward to seeing what you come up with!

Pete.
There's nothing like a deadline to hone the concentration.

Good manners cost nothing, but earn respect.

" 'Impossible' is not in our vocabulary." Jack Chrichton, Farscape
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

Re: HERDING LIVESTOCK TO MARKET

Post by GarryG »

Captain Rand wrote: 13 Apr 2023 12:04 Human walking speed is about 3MPH, so if you have a shepherd guiding sheep on foot he's probably walking at a gentle stroll, which would be even slower. Cowboys on horseback (still walking) might be a bit quicker, but not by much.
Nothing in OTTD is really in scale though is it?, so you don't really need to be dead on accurate, but I think even 5MPH is really pushing it.
Getting a suitable speed will be a problem .. be a matter of testing different speeds to get something that looks good.
I think you may run in to another problem though. Stockpiling at the source farm. Your "vehicles" would be so slow that by the time they return empty to the farm that farm may have already gone through more than one cycle of cargo generation. The answer to this of course is simply to use more "vehicles", but then you could end up with a constant stream of "animals" on the road which just wouldn't look right.
But at least we will have a way to move livestock until trains and trucks become available. Fun part whan trains do become available can herd the livestock to nearest railway station to load them on to the trains to continue their journey. :D
You could just give each "vehicle" a high cargo capacity, but then it's impossible to predict how high this needs to be. There's too many other factors to consider. How far is the destination? How long is travel time? What industry set is being used?
These will all influence production rates.
Kruemelchen and McZapkie both did a "horse and cart set that is available for those who like to start their game 1700s and earlier and they carry livestock. These will get a small number of livestock to markets a wee bit quicker then herding. Depends what wagons you use can carry between 2 to 24 head of livestock. So you'd probably have a wagon train with many wagons heading to the markets. I imagine small amount of sheep and pigs would have been taken to market by wagons, but can't image a big cow being loaded on to a wagon.
I think having herds be more realistic and fun.
To have large herd I now wondering if I code them as train and have a special train track designed like a stock route. That way can have livestock as engine and a string of carriages to move large quantities at a time. :roll:

So next question is do I stick to the herding by road idea or try the herding using a special stock route.
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
RoyalExamination9410
Traffic Manager
Traffic Manager
Posts: 168
Joined: 14 Nov 2021 06:56
Location: Canada

Re: HERDING LIVESTOCK TO MARKET

Post by RoyalExamination9410 »

So next question is do I stick to the herding by road idea or try the herding using a special stock route.
I think you should code it as a road vehicle, livestock drives along highways can present an additional challenge for existing road vehicles. It also happens in the modern era.


Create it as a vehicles set, using shepherds/horses/dogs historically, switching to pickups in the present era as seen above.
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

Re: HERDING LIVESTOCK TO MARKET

Post by GarryG »

RoyalExamination9410 wrote: 14 Apr 2023 07:13 I think you should code it as a road vehicle, livestock drives along highways can present an additional challenge for existing road vehicles. It also happens in the modern era.
Making them a road set will make the game so much more fun .. be a bit slow using them as mentioned but that the fun of it all. Even when trains and trucks become available I think they will still have a use. Interesting part will be seeing what road vehicles do when they meet the livestock on the road. Will they go around them or stay behind. Maybe run over them and make lamb chops :D

We shall see what happens.

Hope to do some to them over the weekend.

Cheers
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
User avatar
Captain Rand
Traffic Manager
Traffic Manager
Posts: 192
Joined: 28 Jan 2012 07:35

Re: HERDING LIVESTOCK TO MARKET

Post by Captain Rand »

GarryG wrote: 13 Apr 2023 23:30 But at least we will have a way to move livestock until trains and trucks become available.
Yes. My comments didn't take pre truck/train games into account. I've never played a game that started so early (it's mostly about the trains for me).
GarryG wrote: 13 Apr 2023 23:30 Fun part whan trains do become available can herd the livestock to nearest railway station to load them on to the trains to continue their journey. :D
Which is exactly the way I'd use it, as I said in the example I gave.
As an example, in one of my games I had a rail station serving three nearby farms. The farms were just outside the catchment area of the station. I linked them with the distant station function so the station was now collecting cargo directly from the farms. Then I made some dirt roads to link the farms to the station to give the illusion of livestock being herded. I had to use my imagination of course but that's half the fun! I used trucks with transfer orders for the other slightly more distant farms in the same cluster. I'd have absolutely used your GRF had it been available then for the closer farms with transfer orders rather than directly linking stations.
GarryG wrote: 13 Apr 2023 23:30 So next question is do I stick to the herding by road idea or try the herding using a special stock route.
Definitely road. Could you also make the "vehicles" compatible with the dirt/unmade roadtype?

Pete.
There's nothing like a deadline to hone the concentration.

Good manners cost nothing, but earn respect.

" 'Impossible' is not in our vocabulary." Jack Chrichton, Farscape
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

Re: HERDING LIVESTOCK TO MARKET

Post by GarryG »

Captain Rand wrote: 14 Apr 2023 11:04 Yes. My comments didn't take pre truck/train games into account. I've never played a game that started so early (it's mostly about the trains for me).
Me too .. I always been train mad. What first got me interested about the livestock is like to be able to herd them from farm to a railway station for loading on train, and then got the idea these should be available as early as possible way before trains and trucks. So the idea developed from there. Maybe nice to also herd the sheep to a shearing shed to shear and produce wool :D
Definitely road. Could you also make the "vehicles" compatible with the dirt/unmade roadtype?
I will put as many road codes in as I can so they can go on almost all the roads. So if any one can help and start collecting the road IDs be appreciated.
Be fun the livestock going through the towns :D But maybe keep them off freeways.

Cheers .. my bed time now .. hope tomorrow start doing something towards this idea.

Cheers all
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
User avatar
odisseus
Director
Director
Posts: 568
Joined: 01 Nov 2017 21:19

Re: HERDING LIVESTOCK TO MARKET

Post by odisseus »

GarryG wrote: 14 Apr 2023 11:22 I will put as many road codes in as I can so they can go on almost all the roads.
There is quite a number road types which should be forbidden for livestock herds. Highways, pedestrian zones, roads with ground-level power supply, to name a few. Of course, there also are mock waterways.
Kruemelchen
Transport Coordinator
Transport Coordinator
Posts: 287
Joined: 18 Feb 2017 17:47

Re: HERDING LIVESTOCK TO MARKET

Post by Kruemelchen »

GarryG wrote: 14 Apr 2023 11:22 I will put as many road codes in as I can so they can go on almost all the roads. So if any one can help and start collecting the road IDs be appreciated. Be fun the livestock going through the towns :D But maybe keep them off freeways.
This should get you covered:

Code: Select all

//roadtype translation table 
roadtypetable { ROAD, /* TTD */
	LVST, /* this set */
	OFFR, SAND, /* country roads */
	WWAY, FORD, FRZN, IWAY, /* water ways */
	HAUL, /* hauling road */
	DIRT, GRAV, ASPT, HWAY, /* unspooled */
	OLD_, SETT,  ASP0, ASP1, ASP2, /* ratt */
	AUZB, AUZC, AUZD, BEAC, COBB, COB2, COB3, ACLK, AR12, AR11, AR13, AR14, /* Auz Road Sets Pt.1 */
	AUZF, AUZG, AUZM, AUZH, FWAY, AUZI, AUZJ, AR21, AR22, AR23, AR24, /* Auz Road Sets Pt.2 */
	AUZK, AUZL, YARD, COAL, FUEL, AUZY, ISR1, AR31, AR32, AR34, /* Auz Road Set Pt.3 */
	AUZE, AUZ5, AUZ1, AUZ4, /* Auz Road Set Deprecated */
	ORD0, ORD1, ORD2, ORD3, ORD4, SRD0, SRD1, SRD2, ARD0, ARD1, ARD2, ARD3, ARD4, ARD5, AER0, AER1, AER3, AER5, WRD0, WRD1, URD0, URD1, URD2, URD3, UER0, UER1, UER2, DRD0, DRD1, DRD2, DRD3, DRD4, DRD5, DER1, TRD_, /* U&RaTT */
	JF01, JF02, JF03, JF04, JF05, JF06, JF07, JF08, JF09, JF10, JF11, JF12, JF13, JF14, JF15, JF16, JF17, JF18, JF19, JF20, JF21, JF22, JF23, JF24, /*JFRattRoads*/
	CONC, TOWN, B_RD, A_RD, MWAY, /* Timberwolfs Roads */
	BIKE, BRIC, NL30, NL50, NL5F, NL60, NL80, NL10, NL12, /* Dutch Road Project */
	QR00, QR01, QR02, QR03, QR04, QR05, QR06, QR07, QR08, QR09, QR10, QR11, QR12, QR13, QR14, QR15, QR16, QR17, QR18, QR19, QR20, QR21, QR22, QR23, QR24, QR25, QR26, QR27, QR28, QR29, QR30, QR31, QR32, QR33, QR34, QR35, QR36, QR37, QR38, QR39, QR40, /* Quast65 */
	FOOT, PEDZ, CSRD, PTRD, ATRD, PCRD, ACRD, CHWY, AHWY, /* Auge's Basic Roadset */
	ELRD, YDRD, CBRD, CBRE, PVRD, PVRE, ISRD, ISRE, HAUL, ELHL, /* Docklands */
	ELSP, ELA0, ELA1, ELA2, /* Ratt Electric Roads */
	EGRV, ELAS, /* unspooled electric roads */
	IRD0, IRD1, /* U&RaTT depreciated */
}

item(FEAT_ROADTYPES, livestock, 0) {
	property {
		label: "LVST";
		powered_roadtype_list: ["HAUL", "ELHL", "OFFR", "FRZN", "SAND", "DIRT", "GRAV", "ROAD", "ASPT", "FORD", "OLD_", "SETT", "ASP0", "ASP1", "ELSP", "ELA0", "ELA1", "AUZB", "AUZC", "AUZD", "BEAC", "COBB", "COB2", "COB3", "ACLK", "AR11", "AR12", "AR13", "AR14", "AUZI", "AUZJ", "AR21", "AUZK", "AUZL", "YARD", "COAL", "FUEL", "AUZY", "ISR1", "AR31", "AR32", "AR34", "AUZE", "AUZ5", "AUZF", "AUZ1", "ORD0", "ORD1", "ORD2", "ORD3", "ORD4", "IRD0", "IRD1", "SRD0", "SRD1", "SRD2", "ARD0", "ARD1", "ARD2", "ARD3", "AER0", "AER1", "URD0", "URD1", "URD2", "URD3", "UER0", "UER1", "UER2", "DRD0", "DRD1", "DRD2", "DRD3", "DRD4", "DRD5", "DER1", "TRD_", "CONC", "TOWN", "B_RD", "BRIC", "NL30", "NL50", "NL5F", "NL60", "FOOT", "PEDZ", "CSRD", "PTRD", "ATRD", "PCRD", "ACRD", "YDRD", "CBRD", "PVRD", "PVRE", "ISRD", "ISRE", "ELRD", "EGRV", "ELAS", "JF01", "JF02", "JF03", "JF04", "JF05", "JF06", "JF07", "JF08", "JF09", "JF10", "JF11", "JF12", "JF13", "JF14", "JF15", "JF16", "JF19", "JF20", "JF21", "JF22", "JF23", "JF24", "QR00", "QR01", "QR02", "QR03", "QR04", "QR05", "QR06", "QR07", "QR08", "QR09", "QR10", "QR11", "QR12", "QR13", "QR14", "QR15", "QR16", "QR17", "QR18", "QR19", "QR20", "QR21", "QR22", "QR23", "QR24", "QR25", "QR26", "QR27", "QR28", "QR29", "QR30", "QR31", "QR32", "QR33", "QR34", "QR35", "QR36", "QR37", "QR38", "QR39", "QR40"];
	}
}


I am working on an implementation for my horse cart GRF, but the variable length doesn't seem to work :oops: (it only updates in the vehicle info window, but not on the game map)
I'm not sure if this is actually supported :oops:
This is the code:

Code: Select all

// vehicles in the centre are the animal herd
// length dependend on cargo
switch(FEAT_ROADVEHS, SELF, switch_cart_herder_length_cargo, cargo_count) {
	0:		1;
	1..9:		3;
	10..19:		5;
	20..29:		7;
	default:	8;
}
// first vehicle is the shepherd dog
switch(FEAT_ROADVEHS, SELF, switch_cart_herder_length_1, position_in_consist) {
	0: 2;
	default: switch_cart_herder_length_cargo;
}
// last vehicle is the shepherd
switch(FEAT_ROADVEHS, SELF, switch_cart_herder_length, position_in_consist_from_end) {
	0: 2;
	default: switch_cart_herder_length_1;
}
Edit: The variable length actually works, but it seems to take a lot of time for the length variable to be updated, plus a visit in a depot is mandatory for the change of length to be visible on the game map. So I guess we have to live with fixed lengths :lol:
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

Re: HERDING LIVESTOCK TO MARKET

Post by GarryG »

odisseus wrote: 14 Apr 2023 11:51 There is quite a number road types which should be forbidden for livestock herds. Highways, pedestrian zones, roads with ground-level power supply, to name a few. Of course, there also are mock waterways.
Kruemelchen has provided a list of road roadtypetables (above) .. if any of those any one thinks should not be included let us know.

Today I have the coding "example_road_vehicle" from NML examples to practice with .. I intend to change the sizes of all the templates. For instance vehicles facing North-South these templates are normally 8 pixels wide I intend to increase them to 12 wide same as width of vehicles from HEQS set. The normal size templates are not big enough to display a man on horse and a sheep. Definitely not much room for a herd even if the man was walking.
Sheep.png
Sheep.png (3.89 KiB) Viewed 2960 times
Shall see what happens if I can make the templates larger.

Cheers
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
User avatar
odisseus
Director
Director
Posts: 568
Joined: 01 Nov 2017 21:19

Re: HERDING LIVESTOCK TO MARKET

Post by odisseus »

I don't know those road types by heart, thus I'm afraid I can't help you with that. I just wanted to point out that allowing livestock herds to move on "almost all the roads" would be a mistake.
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

Re: HERDING LIVESTOCK TO MARKET

Post by GarryG »

odisseus wrote: 15 Apr 2023 05:07 I don't know those road types by heart, thus I'm afraid I can't help you with that. I just wanted to point out that allowing livestock herds to move on "almost all the roads" would be a mistake.
Once we get them working shall see what roads we can and shouldn't allow them on.

I tried testing using the examples that comes with nml, but keep finding errors when trying to make a GRF from it.

So will have to find another road vehicle source.

Cheers
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

Re: HERDING LIVESTOCK TO MARKET

Post by GarryG »

I not winning with this project.

I been trying to just test a herd of sheep and try get the speed they should travel at.
But I can not even get them to load.
First I was coming up with year errors saying to start a game after 1925. And when start a game just after 1925 all I get is a bus.

Trying to set start date as early as possible .. I have introduction_date: date(200,01,01);

Any way it late here so I head off to bed.

I upload the source and maybe some one can show me what I do wrong.

Cheers
Attachments
HerdingLivestock.rar
(39.58 KiB) Downloaded 42 times
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Brickblock1
Engineer
Engineer
Posts: 117
Joined: 04 Apr 2022 12:44
Location: The openttd discord server

Re: HERDING LIVESTOCK TO MARKET

Post by Brickblock1 »

I got it working, it seams you forgot to define what roadtype should be used. I set it to road which is probably the best that can be done right now.
Attachments
HerdingLivestock.zip
(40.33 KiB) Downloaded 49 times
User avatar
GarryG
Tycoon
Tycoon
Posts: 5875
Joined: 14 Feb 2015 00:44
Location: Newcastle, Australia

Re: HERDING LIVESTOCK TO MARKET

Post by GarryG »

Brickblock1 wrote: 15 Apr 2023 12:11 I got it working, it seams you forgot to define what roadtype should be used. I set it to road which is probably the best that can be done right now.
Glad it worked for you .. but it still not working for me.

Tried loading it with my normal GRFs and also I tried it on its own :oops:

Maybe it too early in the morning and I need to wait till I wake up properly.

Appreciate your help
Soot Happens
Screenshot Of The Month Winner March 2020
All my projects are GPLv2 License unless stated.
Auz Road Sets: viewtopic.php?f=29&t=87335
Auz Project Releases: viewtopic.php?f=67&t=84725
Auz Trains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
Auz Objects: viewtopic.php?f=26&t=75657
Auz Bridges: viewtopic.php?f=26&t=75248
Auz Stations: viewtopic.php?f=26&t=76390
Auz Tracks: viewtopic.php?f=26&t=82691
Auz Subway Stations: viewtopic.php?f=26&t=85335
Auz Eyecandy TramTracks: viewtopic.php?t=89908
Post Reply

Return to “Graphics Development”

Who is online

Users browsing this forum: No registered users and 55 guests