add хуех on эх, start command
This commit is contained in:
		
							parent
							
								
									7e26dfa38d
								
							
						
					
					
						commit
						b0f616fd32
					
				
					 5 changed files with 18 additions and 2 deletions
				
			
		|  | @ -12,6 +12,7 @@ return { | |||
|     'command', | ||||
|     'ready', | ||||
|     'inlineQuery', | ||||
|     'message', | ||||
|   }, | ||||
|   parts = { | ||||
|     'locale', | ||||
|  |  | |||
|  | @ -1,6 +1,6 @@ | |||
| return { | ||||
|   hide = true, | ||||
|   run = function(C, msg) | ||||
|     C.api:reply(msg, 'TODO!') | ||||
|     C.api:reply(msg, msg.loc.msg) | ||||
|   end | ||||
| } | ||||
| } | ||||
|  |  | |||
							
								
								
									
										9
									
								
								src/events/message.lua
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								src/events/message.lua
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,9 @@ | |||
| return function(C, api, msg) | ||||
|   -- надоели эхать | ||||
|   if msg.text | ||||
|   and msg.text:match '[Ээ]+[Хх]+' then | ||||
|     C.api:reply(msg, msg.text | ||||
|       :gsub('[Ээ]+[Хх]+', 'хуех') | ||||
|     ,nil) | ||||
|   end | ||||
| end | ||||
|  | @ -26,6 +26,9 @@ | |||
|       "cur": "Currency at %s:\n%s", | ||||
|       "notf": "\nNot found: ", | ||||
|       "prov": "\nData provided from central bank of Russia." | ||||
|     }, | ||||
|     "start": { | ||||
|       "msg": "Hi! I'm Computer - an open-source bot.\nIf you looking for source code: https://gitdab.com/er2/comp-tg" | ||||
|     } | ||||
|   } | ||||
| } | ||||
|  |  | |||
|  | @ -26,6 +26,9 @@ | |||
|       "cur": "Курс на %s:\n%s", | ||||
|       "notf": "\nНе нашлось: ", | ||||
|       "prov": "\nДанные предоставлены центральным банком России." | ||||
|     }, | ||||
|     "start": { | ||||
|       "msg": "Привет! Я Computer - бот с открытым исходным кодом.\nЕсли ты ищешь исходники: https://gitdab.com/er2/comp-tg" | ||||
|     } | ||||
|   } | ||||
| } | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue