This part works ok. It just uses the H key to cause the npc to wait and stop waiting. If the player is to far away, then a radio is used automatically, instead of activating a radio in the inventory.
The code is part of a quest script
if IsKeyPressed 35 ; HKEY if VNPCFollowers.bVeronicaHired == 1 if player.GetDistance VeronicaREF < 4000 if VeronicaREF.Waiting == 0 set VeronicaREF.Waiting to 1 VeronicaREF.evp VeronicaREF.sayto player GOODBYE else set VeronicaREF.Waiting to 0 VeronicaREF.evp endif else set useRadio to 1 endif ;elseif other followers hired ;do later endif endif
Next code block, when the npc to far away to call, use radio instead.
The problem is that the code in the menu does not execute. The NPC will carry on waiting. Also I made sure ButtonVar == 1 matches the message button index numbers,
if useRadio == 1 ShowMessage radioTransmitterMSG set buttonVar to GetButtonPressed if buttonVar > -1 set useRadio to 0 if buttonVar == 0 ;do later elseif buttonVar == 1 set VeronicaREF.Waiting to 0 VeronicaREF.evp showMessage DEBUG1 buttonVar elseif buttonVar == 2 ;do later ;more elseif''s etc... endif if buttonVar == 7 set RexREF.Waiting to 0 RexREF.evp endif if buttonVar == 8 ;FINISH - EXIT set buttonVar to -1 endif endif endif
Any ideas why the menu is not working