点金bug
parent
9ead3452d4
commit
2e97a23f31
|
@ -1,5 +1,6 @@
|
|||
package com.ljsd.jieling.logic.activity;
|
||||
|
||||
import com.ljsd.GameApplication;
|
||||
import com.ljsd.jieling.jbean.ActivityMission;
|
||||
import com.ljsd.jieling.logic.OnlineUserManager;
|
||||
import com.ljsd.jieling.logic.activity.event.HourTaskEvent;
|
||||
|
@ -31,13 +32,14 @@ class BuyGoldActivity extends AbstractActivity {
|
|||
public BuyGoldActivity(int id) {
|
||||
super(id);
|
||||
Poster.getPoster().listenEvent(this, UserOnlineEvent.class);
|
||||
Poster.getPoster().listenEvent(this, HourTaskEvent.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void initActivity(User user) throws Exception {
|
||||
super.initActivity(user);
|
||||
SGlobalActivity sGlobalActivity = STableManager.getConfig(SGlobalActivity.class).get(id);
|
||||
int time = (int) (sGlobalActivity.getEndTimeLong() / 1000);
|
||||
int time = (int) (GameApplication.serverConfig.getCacheOpenTime()/1000+sGlobalActivity.getEndTimeLong());
|
||||
HashSet<Integer> ids = new HashSet<>();
|
||||
List<Integer> listValue = SSpecialConfig.getListValue(SSpecialConfig.Gold_touch);
|
||||
listValue.forEach(type -> SPrivilegeTypeConfig.privilegeByType.get(type).forEach(sPrivilegeTypeConfig -> {
|
||||
|
@ -61,7 +63,7 @@ class BuyGoldActivity extends AbstractActivity {
|
|||
return;
|
||||
}
|
||||
setUpTime(user);
|
||||
}, new ArrayList<>(OnlineUserManager.sessionMap.keySet()), 120);
|
||||
}, new ArrayList<>(OnlineUserManager.sessionMap.keySet()), 1);
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -96,7 +98,7 @@ class BuyGoldActivity extends AbstractActivity {
|
|||
List<Integer> listValue = SSpecialConfig.getListValue(SSpecialConfig.Gold_touch);
|
||||
listValue.forEach(type -> SPrivilegeTypeConfig.privilegeByType.get(type).forEach(sPrivilegeTypeConfig -> {
|
||||
ids.add(sPrivilegeTypeConfig.getId());
|
||||
user.getPlayerInfoManager().refreshVipByType(sPrivilegeTypeConfig.getId());
|
||||
user.getPlayerInfoManager().refreshVipByType(type);
|
||||
}));
|
||||
notifyClient(user, ids);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue