- Joined
- Nov 11, 2013
- Messages
- 161
- Reaction score
- 36
Enter World work now!
but still very much todo need this parsers from tera schock emu!
but still very much todo need this parsers from tera schock emu!
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature currently requires accessing the site using the built-in Safari browser.
Hi, the sub system you need implemented, isn't a simple one, it has to do with almost all other systems in the server.
Implementing the "visibillity system" its not a simple task, it requires in depth knowledge about all the other systems in the server.
Implementing only the part where you see each other is just the begining, then you need to implement the broadcasting feature so the server "can (neets implementation)" broadcast all the actions of each player, eg. moving, using skills, social, etc.
Unfortunately, the TERA SHOCK project is quite dead... A lot of things are needed to continue the project and it will not worth to do it cause the version is very old.Waiting for news, excited about this
@Override
public void createPlayer(Player player) {
WorldPosition pos = player.getWorldPosition();
PlayerAppearance app = player.getPlayerAppearance();
PreparedStatement st = DB
.prepareStatement("INSERT INTO players(`id`, `name`, race, gender, class, level, exp, rested_exp, max_rested_exp, hp, mp, creation_time, last_online, description, settings, map_id, x, y, z, h, channel," +
" account_id, awaken_level, laurel, achievment_points, fatigue, world_map, world_guard, arena_id, delete_time, appearance, appearance2, details, shape, ban, ban_time, new_player, change_name) " +
"VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)");
try {
st.setInt(1, player.getId());
st.setString(2, player.getName());
st.setString(3, player.getRace().toString());
st.setString(4, player.getGender().toString());
st.setString(5, player.getPlayerClass().toString());
st.setInt(6, player.getLevel());
st.setLong(7, player.getExperience());
st.setLong(8, player.getCurrentRestedExperience());
st.setLong(9, player.getMaxRestedExperience());
st.setLong(10, player.getCurrentStats().getHp());
st.setLong(11, player.getCurrentStats().getMp());
st.setTimestamp(12, player.getCreationTime());
st.setTimestamp(13, player.getLastOnlineTime());
st.setString(14, player.getDescription());
st.setBytes(15, player.getUserSettings());
st.setInt(16, pos.getMapId());
st.setFloat(17, pos.getX());
st.setFloat(18, pos.getY());
st.setFloat(19, pos.getZ());
st.setInt(20, pos.getHeading());
st.setInt(21, pos.getChannelId());
st.setInt(22, player.getAccount().getId());
st.setInt(23, player.getAwakenLevel());
st.setString(24, player.getLaurel().toString());
st.setInt(25, player.getAchievmentPoints());
st.setInt(26, player.getGatherCraftPoints());
st.setInt(27, pos.getWorldMapWorldId());
st.setInt(28, pos.getWorldMapGuardId());
st.setInt(29, pos.getAreaNameId());
st.setTimestamp(30, player.getDeletionTime());
st.setBytes(31, app.getAppearance());
st.setBytes(32, app.getAppearance2());
st.setBytes(33, app.getDetails());
st.setBytes(34, app.getShape());
st.setBoolean(35, player.isBan());
st.setTimestamp(36, player.getBanTime());
st.setBoolean(37, player.isNewPlayer());
st.setBoolean(38, player.isNamechange());
st.executeUpdate();
} catch (SQLException e) {
log.error("Can't inser player", e);
} finally {
DB.close(st);
}
}
<item_template id="17" name="Boucle d'oreille de roue citadine personnelle" coolTime="0" category="EARRING" level="10" requiredLevel="10" rank="0" maxStack="1" rareGrade="3" requiredEquipmentType="NO_COMBAT" combatItemType="EQUIP_ACCESSORY" boundType="NONE" coolTimeGroup="0" linkCrestId="0" linkCustomizingId="0" linkEquipmentId="40113300" linkLookInfoId="0" linkPetAdultId="0" linkPetOrbId="0" linkSkillId="0" linkSocialId="0" linkEnchantId="0" mix_id="0" masterpieceRate="0.0" requiredClass="All" sellPrice="850" buyPrice="8500" slotLimit="0" sortingNumber="9" unidentifiedItemGrade="0" linkPassivityId="190612" linkMasterpiecePassivityId="0" action_value="0" expire_day="0">
<item_stats balance="3" def="7" impact="0" maxAtk="0" minAtk="0" passivity="0" />
</item_template>
package com.ryzen.game.model.channel;
import com.ryzen.game.instance.handlers.InstanceHandler;
import com.ryzen.game.model.AbstractTeraModel;
import com.ryzen.game.model.visible.creature.Creature;
import com.ryzen.game.model.visible.creature.Monster;
import com.ryzen.game.model.visible.door.Door;
import com.ryzen.game.model.visible.drop.DropItem;
import com.ryzen.game.model.visible.workobject.WorkObject;
import com.ryzen.game.model.visible.gather.Gather;
import com.ryzen.game.model.visible.player.Player;
import javolution.util.FastList;
import javolution.util.FastMap;
import java.util.List;
import java.util.Map;
public class Channel extends AbstractTeraModel {
private List<Player> players = new FastList<>();
private List<Monster> monsters = new FastList<Monster>();
private List<Creature> npcs = new FastList<Creature>();
private List<Gather> gathers = new FastList<Gather>();
private List<DropItem> drops = new FastList<DropItem>();
private List<WorkObject> workObject = new FastList<WorkObject>();
private List<Door> doors = new FastList<Door>();
private int mapId;
private boolean isDungeon;
public Channel(final Integer id) {
super(id);
}
public void removePlayer(final Player player) {
this.players.remove(player);
}
public void addPlayer(final Player player) {
this.players.add(player);
}
public void setPlayer(List<Player> pls) {
this.players = pls;
}
public List<Player> getPlayers() {
return players;
}
public void addMonster(final Monster monster) {
this.monsters.add(monster);
}
public List<Monster> getMonsters() {
return monsters;
}
public void setNpcs(List<Creature> npc) {
this.npcs = npc;
}
public void addNpc(Creature npc) {
this.npcs.add(npc);
}
public List<WorkObject> getWorkObects() {
return workObject;
}
public void setWorkObjects(List<WorkObject> workObjects) {
this.workObject = workObjects;
}
public void addWorkObject(WorkObject wo) {
this.workObject.add(wo);
}
public List<Creature> getNpcs() {
return npcs;
}
public void addGather(final Gather gather) {
this.gathers.add(gather);
}
public List<Gather> getGathers() {
return gathers;
}
public void setGathers(List<Gather> gather) {
this.gathers = gather;
}
public List<DropItem> getDrops() {
return drops;
}
public void setDrops(List<DropItem> drops) {
this.drops = drops;
}
public void setMapId(int mapId) {
this.mapId = mapId;
}
public int getMapId() {
return mapId;
}
private InstanceHandler instanceHandler;
public final InstanceHandler getInstanceHandler() {
return instanceHandler;
}
public final void setInstanceHandler(InstanceHandler instanceHandler) {
this.instanceHandler = instanceHandler;
}
public List<Door> getDoors() {
return doors;
}
public void setDoors(List<Door> doors) {
this.doors = doors;
}
public void addDoor(Door door) {
this.doors.add(door);
}
public boolean isDungeon() {
return isDungeon;
}
public void setDungeon(boolean dungeon) {
isDungeon = dungeon;
}
}