mirror of
				https://github.com/SquidDev-CC/CC-Tweaked
				synced 2025-10-31 05:33:00 +00:00 
			
		
		
		
	Added Numpad Enter Support in rom lua programs. (#657)
This commit is contained in:
		| @@ -667,8 +667,8 @@ while bRunning do | ||||
|                 end | ||||
|             end | ||||
|  | ||||
|         elseif param == keys.enter then | ||||
|             -- Enter | ||||
|         elseif param == keys.enter or param == keys.numPadEnter then | ||||
|             -- Enter/Numpad Enter | ||||
|             if not bMenu and not bReadOnly then | ||||
|                 -- Newline | ||||
|                 local sLine = tLines[y] | ||||
|   | ||||
| @@ -350,7 +350,7 @@ local function accessMenu() | ||||
|                     selection = #mChoices | ||||
|                 end | ||||
|  | ||||
|             elseif key == keys.enter then | ||||
|             elseif key == keys.enter or key == keys.numPadEnter then | ||||
|                 -- Select an option | ||||
|                 return menu_choices[mChoices[selection]]() | ||||
|             elseif key == keys.leftCtrl or keys == keys.rightCtrl then | ||||
|   | ||||
| @@ -199,8 +199,8 @@ while true do | ||||
|             drawMenu() | ||||
|             drawFrontend() | ||||
|         end | ||||
|     elseif key == keys.enter then | ||||
|         -- Enter | ||||
|     elseif key == keys.enter or key == keys.numPadEnter then | ||||
|         -- Enter/Numpad Enter | ||||
|         break | ||||
|     end | ||||
| end | ||||
|   | ||||
| @@ -546,7 +546,7 @@ local function playGame() | ||||
|   msgBox("Game Over!") | ||||
|   while true do | ||||
|     local _, k = os.pullEvent("key") | ||||
|     if k == keys.space or k == keys.enter then | ||||
|     if k == keys.space or k == keys.enter or k == keys.numPadEnter then | ||||
|       break | ||||
|     end | ||||
|   end | ||||
| @@ -627,7 +627,7 @@ local function runMenu() | ||||
|       elseif key == keys.down or key == keys.s then | ||||
|         selected = selected % 2 + 1 | ||||
|         drawMenu() | ||||
|       elseif key == keys.enter or key == keys.space then | ||||
|       elseif key == keys.enter or key == keys.numPadEnter or key == keys.space then | ||||
|         break --begin play! | ||||
|       end | ||||
|     end | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Wojbie
					Wojbie