23 lines
614 B
Verilog
23 lines
614 B
Verilog
module state_manager
|
|
|
|
|
|
// pub struct StateManager {
|
|
// pub mut:
|
|
// questions map[string]models.Question
|
|
// state string
|
|
// client &client.Client
|
|
// }
|
|
//
|
|
// pub fn (mut sm StateManager) listener(state string) {
|
|
// sm.state = state
|
|
// sm.send_question()
|
|
// }
|
|
//
|
|
// pub fn (mut sm StateManager) send_question() {
|
|
// mut question := sm.questions[sm.state]
|
|
// mut message := unsafe { strconv.v_sprintf('%s\n%s', question.title, question.description)}
|
|
// for _, button in question.buttons {
|
|
// message += unsafe { strconv.v_sprintf('\n%s', button.text)}
|
|
// }
|
|
// sm.client.send_message(message)
|
|
// }
|