Elvas Tower: Freight Animation Include Statement and Sounds - Elvas Tower

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Freight Animation Include Statement and Sounds Rate Topic: -----

#1 User is online   darwins 

  • Superintendant
  • Group: Status: Elite Member
  • Posts: 1,236
  • Joined: 25-September 17
  • Gender:Male
  • Simulator:Open Rails
  • Country:

Posted 16 December 2020 - 01:16 PM

In an eng file I have been using an include statement to add a freight animation. This seems to influence the sounds. Should the order of these two things matter?

If the sounds follow the include statement - they do not work.

ORTSFreightAnims (

  FreightAnimStatic (
	SubType( Default )
	Shape( "..\\common.crew\\Steam_Crew\\driver01.s" )
	Offset( 0.95, 1.68, 5.06 ))

  FreightAnimStatic (
	SubType( Default )
	Shape( "..\\common.crew\\Steam_Crew\\fireman01.s" )
	Offset( 0, 1.44, 5.30 ))
    
  Include ( Headcodes\\Loco_10400_Class1.inc )

 	)
	 
Sound ( "..\\..\\common.sound\\RvD_2cyl\\2c_01_Eng.sms"  )



If the sounds precede the include statement - they do work.


Sound ( "..\\..\\common.sound\\RvD_2cyl\\2c_01_Eng.sms"  )

ORTSFreightAnims (

  FreightAnimStatic (
	SubType( Default )
	Shape( "..\\common.crew\\Steam_Crew\\driver01.s" )
	Offset( 0.95, 1.68, 5.06 ))

  FreightAnimStatic (
	SubType( Default )
	Shape( "..\\common.crew\\Steam_Crew\\fireman01.s" )
	Offset( 0, 1.44, 5.30 ))
    
  Include ( Headcodes\\Loco_10400_Class1.inc )

 	)



The include file is like this

Comment ( Class 1 Headlamps - for Locomotives 10400 to 10454 )

Comment ( Express Passenger Train, or break-down van train going to clear the line, or light-engine going to assist disabled train, or fire brigade train )

FreightAnimStatic(
SubType( Default )
Shape( "..\\common.headcodes\\DS_LMS\\Head_LMS.s" )
Offset( 0.883, 1.407, -4.904 ))

FreightAnimStatic(
SubType( Default )
Shape( "..\\common.headcodes\\DS_LMS\\Head_LMS.s" )
Offset( -0.883, 1.407, -4.904 ))


If the eng file is changed to use

ORTSFreightAnims (

  FreightAnimStatic (
	SubType( Default )
	Shape( "..\\common.crew\\Steam_Crew\\driver01.s" )
	Offset( 0.95, 1.68, 5.06 ))

  FreightAnimStatic (
	SubType( Default )
	Shape( "..\\common.crew\\Steam_Crew\\fireman01.s" )
	Offset( 0, 1.44, 5.30 )) )
    
Include ( Headcodes\\Loco_10400_Class1.inc )


and the include file is changed to read

ORTSFreightAnims (

FreightAnimStatic(
SubType( Default )
Shape( "..\\common.headcodes\\DS_LMS\\Head_LMS.s" )
Offset( 0.883, 1.407, -4.904 ))

FreightAnimStatic(
SubType( Default )
Shape( "..\\common.headcodes\\DS_LMS\\Head_LMS.s" )
Offset( -0.883, 1.407, -4.904 ))
)


The results are identical. Sounds are only heard if the sound statement precedes the include statement / freight anims.

On the other hand if the include statement is replaced with the raw content thus

ORTSFreightAnims (

  FreightAnimStatic (
	SubType( Default )
	Shape( "..\\common.crew\\Steam_Crew\\driver01.s" )
	Offset( 0.95, 1.68, 5.06 ))

  FreightAnimStatic (
	SubType( Default )
	Shape( "..\\common.crew\\Steam_Crew\\fireman01.s" )
	Offset( 0, 1.44, 5.30 ))
    
FreightAnimStatic(
SubType( Default )
Shape( "..\\common.headcodes\\DS_LMS\\Head_LMS.s" )
Offset( 0.883, 1.407, -4.904 ))

FreightAnimStatic(
SubType( Default )
Shape( "..\\common.headcodes\\DS_LMS\\Head_LMS.s" )
Offset( -0.883, 1.407, -4.904 ))

 	)


There is no problem putting the sound statement after the FreightAnims statement.

#2 User is offline   Csantucci 

  • Member, Board of Directors
  • Group: Status: Elite Member
  • Posts: 6,998
  • Joined: 31-December 11
  • Gender:Male
  • Country:

Posted 16 December 2020 - 01:27 PM

Does the include file have an empty line at its beginning and end?

#3 User is online   darwins 

  • Superintendant
  • Group: Status: Elite Member
  • Posts: 1,236
  • Joined: 25-September 17
  • Gender:Male
  • Simulator:Open Rails
  • Country:

Posted 16 December 2020 - 01:39 PM

Yes. In fact two empty lines at the start. The contents are correctly included and the engine part of the file, which follows the wag part is correctly followed (including cab sounds).

#4 User is offline   Csantucci 

  • Member, Board of Directors
  • Group: Status: Elite Member
  • Posts: 6,998
  • Joined: 31-December 11
  • Gender:Male
  • Country:

Posted 16 December 2020 - 01:46 PM

What works here is one empty line at the beginning and one at the end of the .inc file, no less, no more.

#5 User is offline   Aldarion 

  • Engineer
  • PipPipPipPipPip
  • Group: ET Owner
  • Posts: 629
  • Joined: 11-February 13
  • Gender:Male
  • Location:Lisbon, Portugal
  • Simulator:Open Rails
  • Country:

Posted 17 December 2020 - 02:52 PM

hey... maybe that's I'm getting lots of parse errors in my files after the ORTSbrakeshoefriction.
I'm going all of my inc files to see if all of them have an empty line at the end, Carlo!

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users