share/hedgewars/Data/Scripts/Multiplayer/HedgeEditor.lua
changeset 12007 ad7205e66578
parent 12006 86cd92f64979
child 12008 9b4abde68e3b
equal deleted inserted replaced
12006:86cd92f64979 12007:ad7205e66578
  2494 
  2494 
  2495 	end
  2495 	end
  2496 
  2496 
  2497 end
  2497 end
  2498 
  2498 
  2499 function updateHelp()
  2499 function updateHelp(curAmmoType)
  2500 
  2500 	if curAmmoType == nil then
  2501 	if (GetCurAmmoType() ~= amGirder) and (GetCurAmmoType() ~= amRubber) and (GetCurAmmoType() ~= amAirAttack) then
  2501 		curAmmoType = GetCurAmmoType()
       
  2502 	end
       
  2503 
       
  2504 	if (curAmmoType ~= amGirder) and (curAmmoType ~= amRubber) and (curAmmoType ~= amAirAttack) then
  2502 
  2505 
  2503 		if not hedgeEditorMissionPanelShown then
  2506 		if not hedgeEditorMissionPanelShown then
  2504 			showHedgeEditorMissionPanel()
  2507 			showHedgeEditorMissionPanel()
  2505 		end
  2508 		end
  2506 
  2509 
  2804 
  2807 
  2805 	if helpDisabled == true then
  2808 	if helpDisabled == true then
  2806 		HideMission()
  2809 		HideMission()
  2807 	end
  2810 	end
  2808 
  2811 
       
  2812 end
       
  2813 
       
  2814 function onSetWeapon(ammoType)
       
  2815 	curWep = ammoType
       
  2816 	updateHelp(ammoType)
       
  2817 end
       
  2818 
       
  2819 function onSlot()
       
  2820 	curWep = GetCurAmmoType()
       
  2821 	updateHelp(ammoType)
  2809 end
  2822 end
  2810 
  2823 
  2811 -- called in onGameTick()
  2824 -- called in onGameTick()
  2812 function HandleHedgeEditor()
  2825 function HandleHedgeEditor()
  2813 
  2826 
  2945 
  2958 
  2946 			if sSprite ~= nil then
  2959 			if sSprite ~= nil then
  2947 				SetVisualGearValues(sSprite, nil, nil, 0, 0, nil, nil, 10000, nil, 10000 )
  2960 				SetVisualGearValues(sSprite, nil, nil, 0, 0, nil, nil, 10000, nil, 10000 )
  2948 			end
  2961 			end
  2949 
  2962 
       
  2963 			updateHelp()
       
  2964 
  2950 		end
  2965 		end
  2951 
  2966 
  2952 	end
  2967 	end
  2953 
  2968 
  2954 
  2969