Midonik - sounds PASSED

Here i will list the apprentices and their learning tasks, so others also can follow how it goes.
Please DONT POST HERE any solutions on the given task earlier than the apprentice, you can ask questions from him tough.
Post Reply
Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Midonik - sounds PASSED

Post by Stratego (dev) » Sat Sep 23, 2017 6:55 pm

In AOW there are no sounds implemented yet in json, so
task 1: put in this sound to json form:

the defaultSoundUh means "unit_selected_small4.ogg" file, and its weight is given by its number of occurence - never ask why was it :)


Code: Select all

	
int defaultSoundUh = SoundsDef.addSound("unit_selected_small4.ogg");

	SoundsDef.packs.append(SOUND_PACK_UNIT_SELECT_US_BLD, 
				new int[] { 
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				SoundsDef.addSound("unit_selected_us_yes.ogg"),
				SoundsDef.addSound("unit_selected_us_yes_sir.ogg"),
				SoundsDef.addSound("unit_selected_us_your_orders.ogg"),				
				}

			);

		SoundsDef.packs.append(SOUND_PACK_UNIT_SELECT_GER_BLD, 
				new int[] { 
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh, 
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				defaultSoundUh,
				SoundsDef.addSound("unit_selected_us_yes.ogg"),
				SoundsDef.addSound("unit_selected_us_yes_sir.ogg"),
				SoundsDef.addSound("unit_selected_us_your_orders.ogg"),				
				}

			);


		// -----------------------
		// UNIT DAMAGE
		// -----------------------
		
		
		SoundsDef.packs.append(SOUND_PACK_UNIT_DAMAGE_TANK, 
				new int[] { 
				SoundsDef.addSound("unit_damage_tank.ogg"),
				}
		); 
		SoundsDef.packs.append(SOUND_PACK_UNIT_DAMAGE_VEHICLE, 
				new int[] { 
				SoundsDef.addSound("unit_damage_tank.ogg"),
				}
		); 
		SoundsDef.packs.append(SOUND_PACK_UNIT_DAMAGE_SHIP, 
				new int[] { 
				SoundsDef.addSound("unit_damage_tank.ogg"),
				}
		); 
		SoundsDef.packs.append(SOUND_PACK_UNIT_DAMAGE_PLANE, 
				new int[] { 
				SoundsDef.addSound("unit_damage_tank.ogg"),
				}
		); 
		SoundsDef.packs.append(SOUND_PACK_UNIT_DAMAGE_INF, 
				new int[] { 
				SoundsDef.addSound("unit_damage_tank.ogg"),
				} 
		); 
		SoundsDef.packs.append(SOUND_PACK_UNIT_DAMAGE_FIXED, 
				new int[] { 
				SoundsDef.addSound("unit_damage_tank.ogg"),
				}
		);  
		SoundsDef.packs.append(SOUND_PACK_UNIT_DAMAGE_BLD, 
				new int[] { 
				SoundsDef.addSound("unit_damage_tank.ogg"),
				}
		); 
		
		// -----------------------
		// UNIT MEND/HEAL etc. SOUNDS
		// -----------------------
		
		SoundsDef.packs.append(SOUND_PACK_UNIT_HEAL, 
				new int[] {
				SoundsDef.addSound("unit_action_heal.ogg"),
				}
		);

		SoundsDef.packs.append(SOUND_PACK_UNIT_CONVERT, 
				new int[] {
				SoundsDef.addSound("unit_action_convert.ogg"),
				}
		);
		
		SoundsDef.packs.append(SOUND_PACK_UNIT_MEND_BUILD, 
				new int[] {
				SoundsDef.addSound("unit_action_mend_build.ogg"),
				}
		);

		SoundsDef.packs.append(SOUND_PACK_UNIT_MEND_BUILD, 
				new int[] {
				SoundsDef.addSound("unit_action_mend_build.ogg"),
				}
		);



Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Fri Sep 29, 2017 11:11 pm

any proggress here?

Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Fri Oct 06, 2017 6:05 am

How is it going?

Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Mon Oct 09, 2017 5:47 pm

Hi, are are you about finish this lecture?

Midonik
Posts: 3752
Joined: Mon Sep 05, 2016 5:27 pm
Location: Poland

Re: Midonik - sounds

Post by Midonik » Tue Dec 26, 2017 11:17 am

Ok,I started to make it (by editing Sunrise Samurai json,is it ok?),and I have a question: all units types should have the same sound file (unit_damage_tank.ogg) when damaged?
Support new AoS variant, Age of Galaxy: http://www.androidutils.com/forum/viewforum.php?f=135
All help will be welcome.

Midonik
Posts: 3752
Joined: Mon Sep 05, 2016 5:27 pm
Location: Poland

Re: Midonik - sounds

Post by Midonik » Tue Dec 26, 2017 11:42 am

Ok,I think its ready.
Attachments
sounds.json
(2.85 KiB) Downloaded 44 times
Support new AoS variant, Age of Galaxy: http://www.androidutils.com/forum/viewforum.php?f=135
All help will be welcome.

Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Wed Dec 27, 2017 8:11 am

"SOUND_PACK_UNIT_CONVERT"
is wrongly embedded into an other sound pack.

here is the current sound json, please add yours here similarily (sort of merging).
Attachments
sounds.json
(1.8 KiB) Downloaded 46 times

Midonik
Posts: 3752
Joined: Mon Sep 05, 2016 5:27 pm
Location: Poland

Re: Midonik - sounds

Post by Midonik » Wed Dec 27, 2017 1:35 pm

Is it good?
Attachments
sounds.json
(4.78 KiB) Downloaded 61 times
Support new AoS variant, Age of Galaxy: http://www.androidutils.com/forum/viewforum.php?f=135
All help will be welcome.

Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Wed Dec 27, 2017 7:32 pm

what editor are u using?

Midonik
Posts: 3752
Joined: Mon Sep 05, 2016 5:27 pm
Location: Poland

Re: Midonik - sounds

Post by Midonik » Wed Dec 27, 2017 7:47 pm

JSON editor,its its name.
Support new AoS variant, Age of Galaxy: http://www.androidutils.com/forum/viewforum.php?f=135
All help will be welcome.

Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Wed Dec 27, 2017 9:07 pm

could u please use a simple text editor? (that app ruins the nicely aligned, compact textfile that was well readable)

Midonik
Posts: 3752
Joined: Mon Sep 05, 2016 5:27 pm
Location: Poland

Re: Midonik - sounds

Post by Midonik » Wed Dec 27, 2017 9:08 pm

But... it is simply text editor.
Support new AoS variant, Age of Galaxy: http://www.androidutils.com/forum/viewforum.php?f=135
All help will be welcome.

Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Wed Dec 27, 2017 9:11 pm

are u using a pc? or phone?

for pc i use the free "TextPad"

Midonik
Posts: 3752
Joined: Mon Sep 05, 2016 5:27 pm
Location: Poland

Re: Midonik - sounds

Post by Midonik » Wed Dec 27, 2017 9:15 pm

Phone.
Support new AoS variant, Age of Galaxy: http://www.androidutils.com/forum/viewforum.php?f=135
All help will be welcome.

Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Wed Dec 27, 2017 10:37 pm

ok.
so you dont see that you change the total file by only loading and saving with that app? (it automatically "beautifies" it, that is unwanted - maybe can u turn beautifying off?)

Midonik
Posts: 3752
Joined: Mon Sep 05, 2016 5:27 pm
Location: Poland

Re: Midonik - sounds

Post by Midonik » Thu Dec 28, 2017 8:10 am

Hmm. Can you tell me what does it beatifying? Mayby I make this unintentionally. I were using it all the time.
Support new AoS variant, Age of Galaxy: http://www.androidutils.com/forum/viewforum.php?f=135
All help will be welcome.

Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Thu Dec 28, 2017 8:41 am

in your version
- the weights are not in same row with the soundfile
- also check the brackets they are all in separate row instead of being packed nicely.

check the file i attached comparing to yours
(remark: this does not effect the working of a json - these are only beauty things, json can work in any way even without line breaks)

here are samples:

Code: Select all

{
      "packIDString": "SOUND_PACK_UNIT_MOVE_FIXED",
      "items": [
         {
            "fileName": "unit_selected_unit_move_tank.ogg",
            "weight": 1
         }
      ]
   }

Code: Select all

{
	"packIDString": "SOUND_PACK_UNIT_ATTACK_VEHICLE_SHOOT",
	"items": [
		{"fileName": "unit_tank_shoot.ogg", 	"weight": 1}
	]		
}

Stratego (dev)
Site Admin
Posts: 10648
Joined: Fri Apr 25, 2014 9:28 pm

Re: Midonik - sounds

Post by Stratego (dev) » Sat Jan 27, 2018 12:57 pm

i am doing it now as i have to compile aow with it

Post Reply

Return to “Under the Hood studies”