Documentation ¶
Index ¶
- Constants
- type TaskModel
- func (p *TaskModel) AbandonTask(userId int64, taskId int32) (normalTasks *dbData.NormalTaskList, err error)
- func (p *TaskModel) AbandonTaskList(userId int64, taskListType proto.TaskListType) error
- func (p *TaskModel) AcceptTask(userId int64, taskId int32) (normalTasks *dbData.NormalTaskList, err error)
- func (p *TaskModel) AcceptTaskList(userId int64, taskListType proto.TaskListType, talentType proto.TalentType) (listData *dbData.TaskList, err error)
- func (p *TaskModel) ClearUserTaskCache(userId int64)
- func (p *TaskModel) Daily(utc time.Time)
- func (p *TaskModel) GetItemHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, ...) error
- func (p *TaskModel) GetPlayerSceneData(userId int64) (*dbData.PlayerSceneData, error)
- func (p *TaskModel) GetUserTalentData(userId int64) (*dbData.TalentData, error)
- func (p *TaskModel) GetUserTask(userId int64) (*dbData.PlayerTask, error)
- func (p *TaskModel) HandInItemHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, ...) error
- func (p *TaskModel) Hourly(utc time.Time)
- func (p *TaskModel) KillMonsterHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, ...) error
- func (p *TaskModel) Minutely(utc time.Time)
- func (p *TaskModel) OnInit() error
- func (p *TaskModel) OnTick(utc time.Time)
- func (p *TaskModel) Secondly(utc time.Time)
- func (p *TaskModel) TalentLevelUpdateHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, ...) (err error)
- func (p *TaskModel) TalentNodeUpdateHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, ...) (err error)
- func (p *TaskModel) TargetPositionHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, ...) error
- func (p *TaskModel) TaskFinishCountHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, ...) error
- func (p *TaskModel) TaskListTypeCountHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, ...) error
- func (p *TaskModel) TaskReward(userId int64, taskId int32) (normalTasks *dbData.NormalTaskList, err error)
- func (p *TaskModel) TaskRewardByTaskList(userId int64, kind proto.TaskListType) (tl *dbData.TaskList, err error)
- func (p *TaskModel) UseItemHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, itemCid int32, ...) error
- func (p *TaskModel) UseRecipeHandler(userId int64, upNormalTask bool, tlTypes []proto.TaskListType, ...) error
Constants ¶
View Source
const TASK_PROTECT_SEC = 60 * 3 // 3min
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TaskModel ¶
type TaskModel struct { module_base.ModuleBase // contains filtered or unexported fields }
func GetTaskModel ¶
func NewTaskModel ¶
func NewTaskModel() *TaskModel
func (*TaskModel) AbandonTask ¶
func (p *TaskModel) AbandonTask( userId int64, taskId int32, ) (normalTasks *dbData.NormalTaskList, err error)
放弃普通任务
func (*TaskModel) AbandonTaskList ¶
func (p *TaskModel) AbandonTaskList( userId int64, taskListType proto.TaskListType, ) error
放弃任务链任务
func (*TaskModel) AcceptTask ¶
func (p *TaskModel) AcceptTask( userId int64, taskId int32, ) (normalTasks *dbData.NormalTaskList, err error)
领取普通任务
func (*TaskModel) AcceptTaskList ¶
func (p *TaskModel) AcceptTaskList( userId int64, taskListType proto.TaskListType, talentType proto.TalentType, ) (listData *dbData.TaskList, err error)
领取任务链
func (*TaskModel) ClearUserTaskCache ¶
func (*TaskModel) GetItemHandler ¶
func (p *TaskModel) GetItemHandler( userId int64, upNormalTask bool, tlTypes []proto.TaskListType, items []base_data.GrpcItemBaseInfo, ) error
func (*TaskModel) GetPlayerSceneData ¶
func (p *TaskModel) GetPlayerSceneData(userId int64) (*dbData.PlayerSceneData, error)
func (*TaskModel) GetUserTalentData ¶
func (p *TaskModel) GetUserTalentData(userId int64) (*dbData.TalentData, error)
func (*TaskModel) GetUserTask ¶
func (p *TaskModel) GetUserTask(userId int64) (*dbData.PlayerTask, error)
func (*TaskModel) HandInItemHandler ¶
func (p *TaskModel) HandInItemHandler( userId int64, upNormalTask bool, tlTypes []proto.TaskListType, targetTask int32, handInItems []*proto.TaskOptionItem, ) error
func (*TaskModel) KillMonsterHandler ¶
func (*TaskModel) TalentLevelUpdateHandler ¶
func (p *TaskModel) TalentLevelUpdateHandler( userId int64, upNormalTask bool, tlTypes []proto.TaskListType, lvs []base_data.GrpcTalentLevel, ) (err error)
func (*TaskModel) TalentNodeUpdateHandler ¶
func (p *TaskModel) TalentNodeUpdateHandler( userId int64, upNormalTask bool, tlTypes []proto.TaskListType, trees []base_data.GrpcTalentTreeUpdate, ) (err error)
func (*TaskModel) TargetPositionHandler ¶
func (p *TaskModel) TargetPositionHandler( userId int64, upNormalTask bool, tlTypes []proto.TaskListType, targetTask int32, position *proto.TaskOptionTargetPosition, ) error
func (*TaskModel) TaskFinishCountHandler ¶
func (p *TaskModel) TaskFinishCountHandler( userId int64, upNormalTask bool, tlTypes []proto.TaskListType, finishTaskListType proto.TaskListType, ) error
func (*TaskModel) TaskListTypeCountHandler ¶
func (p *TaskModel) TaskListTypeCountHandler( userId int64, upNormalTask bool, tlTypes []proto.TaskListType, finishTaskListType proto.TaskListType, ) error
func (*TaskModel) TaskReward ¶
func (p *TaskModel) TaskReward( userId int64, taskId int32, ) (normalTasks *dbData.NormalTaskList, err error)
领取普通任务奖励
func (*TaskModel) TaskRewardByTaskList ¶
func (p *TaskModel) TaskRewardByTaskList( userId int64, kind proto.TaskListType, ) (tl *dbData.TaskList, err error)
领取任务链的任务奖励
func (*TaskModel) UseItemHandler ¶
func (*TaskModel) UseRecipeHandler ¶
func (p *TaskModel) UseRecipeHandler( userId int64, upNormalTask bool, tlTypes []proto.TaskListType, targetTask int32, recipeInfo *proto.TaskOptionUseRecipe, ) error
Click to show internal directories.
Click to hide internal directories.