ineedbots / iw5_bot_warfare

The Bot Warfare mod for MW3
https://www.moddb.com/mods/bot-warfare
114 stars 29 forks source link

Script runtime error when client disconnects at the wrong time. (2/2) #93

Closed xerxes-at closed 12 months ago

xerxes-at commented 1 year ago

While debugging some issues with my own scripts I have found that a script runtime error is thrown if a followed player disconnects before the bot can chat they stopped following them.

******* script runtime error *******
pair 'well that was fun following ' and 'undefined' has unmatching types 'string' and 'undefined'

     at function "bot_chat_follow_watch" in file "maps/mp/bots/_bot_chat.gsc"
     at function "start_chat_watch" in file "maps/mp/bots/_bot_chat.gsc"
************************************
******* script runtime error *******
pair 'undefined' and ' for ' has unmatching types 'undefined' and 'string'

     at function "bot_chat_follow_watch" in file "maps/mp/bots/_bot_chat.gsc"
     at function "start_chat_watch" in file "maps/mp/bots/_bot_chat.gsc"
************************************
******* script runtime error *******
pair 'undefined' and '14' has unmatching types 'undefined' and 'integer'

     at function "bot_chat_follow_watch" in file "maps/mp/bots/_bot_chat.gsc"
     at function "start_chat_watch" in file "maps/mp/bots/_bot_chat.gsc"
************************************
******* script runtime error *******
pair 'undefined' and ' seconds' has unmatching types 'undefined' and 'string'

     at function "bot_chat_follow_watch" in file "maps/mp/bots/_bot_chat.gsc"
     at function "start_chat_watch" in file "maps/mp/bots/_bot_chat.gsc"
************************************
ineedbots commented 12 months ago

Addressed in 980faf91744dca420e731217af1e35fb2d96879f