Squashing the vanilla warnings in rgl_log.txt

Users who are viewing this thread

When you run vanilla Warband, the game outputs a few warnings in rgl_log.txt:
Code:
 Loading Music...
 Loading Textures...
 Finished Loading Textures...
 L8 Format is  supported
 WARNING: UNABLE TO MAP SOUND CODE:  snd_release_crossbow_medium
 WARNING: UNABLE TO MAP SOUND CODE:  snd_release_crossbow_far
 WARNING: UNABLE TO MAP SOUND CODE:  snd_bullet_hit_body
 WARNING: UNABLE TO MAP SOUND CODE:  snd_player_hit_by_bullet
 WARNING: UNABLE TO MAP GAME PRESENTATION CODE:  prsnt_game_start
 WARNING: UNABLE TO MAP GAME PRESENTATION CODE:  prsnt_game_escape
 WARNING: UNABLE TO MAP GAME SCRIPT CODE:  game_check_party_sees_party
 WARNING: UNABLE TO MAP GAME SCRIPT CODE:  game_get_party_speed_multiplier
 WARNING: UNABLE TO MAP GAME SCRIPT CODE:  game_missile_launch
 WARNING: UNABLE TO MAP GAME SCRIPT CODE:  game_missile_dives_into_water
 WARNING: UNABLE TO MAP GAME SCRIPT CODE:  game_troop_upgrades_button_clicked
 WARNING: UNABLE TO MAP GAME SCRIPT CODE:  game_character_screen_requested
 Loading Module...
 Loading item kinds...
 Loading dialogs...
 Loading mission templates...
 Loading party templates...
 loading time:  25804
 Finished All...

I would like to remove them...
 
Last edited:
Solution
Nevermind, I figured it out. I managed to remove all of the warnings. Posting the solution here:

First warnings are missing sound declarations. Go to module_sounds.py and paste this somewhere:
Python:
    #MOD BEGIN - missing entries expected by game engine
    ("release_crossbow_medium",0,[]),
    ("release_crossbow_far",0,[]),
    ("bullet_hit_body",0,[]),
    ("player_hit_by_bullet",0,[]),
    #MOD END - missing entries expected by game engine
or if you have some usable sounds to put in there, here's how those same entries look like in NW and VC:
Python:
    #Viking Conquest...
Nevermind, I figured it out. I managed to remove all of the warnings. Posting the solution here:

First warnings are missing sound declarations. Go to module_sounds.py and paste this somewhere:
Python:
    #MOD BEGIN - missing entries expected by game engine
    ("release_crossbow_medium",0,[]),
    ("release_crossbow_far",0,[]),
    ("bullet_hit_body",0,[]),
    ("player_hit_by_bullet",0,[]),
    #MOD END - missing entries expected by game engine
or if you have some usable sounds to put in there, here's how those same entries look like in NW and VC:
Python:
    #Viking Conquest:
    ("release_crossbow_medium",sf_vol_3,["crossbow_shoot_01.wav","crossbow_shoot_02.wav","crossbow_shoot_03.wav","crossbow_shoot_04.wav","crossbow_shoot_05.wav","crossbow_shoot_06.wav"]),
    ("release_crossbow_far",sf_vol_1,["crossbow_shoot_01.wav","crossbow_shoot_02.wav","crossbow_shoot_03.wav","crossbow_shoot_04.wav","crossbow_shoot_05.wav","crossbow_shoot_06.wav"]),
    #Napoleonic Wars:
    ("bullet_hit_body",sf_priority_5|sf_vol_7,["body_hit_1.wav","body_hit_2.wav","body_hit_3.wav","impact_body2.wav","impact_body6.wav"]),
    ("player_hit_by_bullet",sf_priority_5|sf_vol_7,["body_hit_1.wav","body_hit_2.wav","body_hit_3.wav","impact_body2.wav","impact_body6.wav"]),
Use this as a base for your own sounds.

Next up - module_presentations.py. This was the trickiest one to figure out, because game_start absolutely must be placed as the very first presentation in the file! Make it look exactly like this:
Python:
presentations = [
    #MOD BEGIN - missing entries expected by game engine
    ("game_start",0,0,[]),
    ("game_escape",0,0,[]),
    #MOD END - missing entries expected by game engine
    ("game_credits",prsntf_read_only,mesh_load_window,
Well, actually you can probably add some triggers to them if you want, but what I show above is enough to remove the warnings.

Finally, the missing scripts. Go to module_scripts.py and add somewhere:
Python:
    #MOD BEGIN - missing entries expected by game engine
    #this is vanilla code, uncommenting parts of it:
    #script_game_check_party_sees_party
    #This script is called from the game engine when a party is inside the range of another party
    #Input: arg1 = seeing_party, arg2 = seen_party
    #Output: trigger_result = true or false (1 = true, 0 = false)
    ("game_check_party_sees_party",[]),
    #this is vanilla code, uncommenting parts it:
    #script_game_get_party_speed_multiplier
    #This script is called from the game engine when a skill's modifiers are needed
    #Input: arg1 = party_no
    #Output: trigger_result = multiplier (scaled by 100, meaning that giving 100 as the trigger result does not change the party speed)
    ("game_get_party_speed_multiplier",[(set_trigger_result,100),]),
    #script_game_missile_launch
    #Called from the game engine when weapon is shot - can be used to trigger weapon effects, like shot sounds or particle bursts.
    #Input: arg1 = shooter_agent_id, arg2 = agent_weapon_item_id, arg3 = missile_weapon_id, arg4 = missile_item_id, pos1 = weapon_item_position
    #Output: none
    ("game_missile_launch",[]),
    #script_game_missile_dives_into_water
    #Called from the game engine when a missile hits water - main use would be for triggering splash visuals and sounds.
    #Input: arg1 = missile_item_id, arg2 = launcher_item_id, arg3 = shooter_agent_id, pos1 = missile_position_on_water
    # Output: none
    ("game_missile_dives_into_water",[]),
    #script_game_troop_upgrades_button_clicked
    #Called from the game engine when the player clicks on a troop's upgrade button in the party screen. Can be used to hook into the troop upgrade mechanics and replace them. Probably requires show_troop_upgrades_button = 1 in module.ini
    #Input: arg1 = troop_id
    ("game_troop_upgrades_button_clicked",[]),
    #script_game_character_screen_requested
    #Called from the game engine when attempting to open the character screen. Can be used to display something instead the hardcoded character screen.
    #Input: none
    ("game_character_screen_requested",[]),
    #MOD END - missing entries expected by game engine

If moderators think it's better to remove this topic, then feel free to do it without contacting me.
 
Last edited:
Upvote 0
Solution
Back
Top Bottom