Commit Graph

638 Commits

Author SHA1 Message Date
Loïc Hoguin
d69fe073a8 egs_users: Introduce broadcast_all/1 to broadcast messages to all online users. 2011-02-21 02:30:39 +01:00
Loïc Hoguin
6c8b831fd2 egs_users: Replace read({pid, Pid}) calls by the new find_by_pid/1 function. 2011-02-21 01:34:54 +01:00
Loïc Hoguin
953da28a3e egs_game_server: Make sure the egs_users:read can't fail in on_exit. 2011-02-21 00:58:14 +01:00
Loïc Hoguin
344c534812 egs_login_server: Remove the unused on_exit/1. 2011-02-21 00:37:15 +01:00
Loïc Hoguin
3280e79743 egs_game: The egs_users:read/1 call can't fail. Simplify the cast/3 function. 2011-02-21 00:12:47 +01:00
Loïc Hoguin
6e922a7ec9 egs_users: Remove broadcast_unspawn/2 in favor of broadcast/2. 2011-02-21 00:07:37 +01:00
Loïc Hoguin
823ee73e7d egs_users: Remove broadcast_spawn/2 in favor of broadcast/2. 2011-02-21 00:04:23 +01:00
Loïc Hoguin
40d2eed01b egs_users: Remove select({neighbors, User}). Use egs_zones for broadcasting. 2011-02-20 23:39:56 +01:00
Loïc Hoguin
ac8d6858cd egs_users: Remove the unused select(all) function. 2011-02-20 23:06:32 +01:00
Loïc Hoguin
e409241a50 egs_game: Counter zone data is just many 0s. Don't use a file for that. 2011-02-20 20:24:21 +01:00
Loïc Hoguin
25c9548ec3 Merge a few .gitignore into the top-level one and update it. 2011-02-20 20:14:42 +01:00
Loïc Hoguin
0b8c4dbd85 egs_users: Remove mnesia from users handling. Convert to a gen_server.
Mnesia has now been fully removed from EGS. It will be replaced by Riak
at a later time, when we need to store permanent data to disk.
2011-02-20 20:00:04 +01:00
Loïc Hoguin
8eae404797 Fix dependency handling in start.sh. 2011-02-20 19:47:07 +01:00
Loïc Hoguin
840db6b7b3 egs_accounts: Fix the type spec for #state.accounts. 2011-02-20 17:39:02 +01:00
Loïc Hoguin
d5b5afa0a7 Use ex_reloader instead of reloader. Include it as a rebar dependency. 2011-02-20 15:30:35 +01:00
Loïc Hoguin
344b88eec4 egs_accounts: Add tmp_gid/0. Remove the table/record counters. 2011-02-20 02:42:40 +01:00
Loïc Hoguin
69a07dfad2 egs_accounts: Remove mnesia for accounts handling. Convert to a gen_server. 2011-02-20 02:01:16 +01:00
Loïc Hoguin
57e4e91187 Remove all references to the unused psu_object record/table. 2011-02-20 01:15:05 +01:00
Loïc Hoguin
722e0a53f4 reloader: Update to the latest HEAD version. 2011-02-20 00:40:56 +01:00
Loïc Hoguin
0f64bea72d egs_network: Match as binary instead of bits to avoid calculating the bit size. 2011-02-20 00:37:18 +01:00
Loïc Hoguin
b380fe9d23 egs_prs: Replace an exit call by the more appropriate erlang:nif_error/1. 2011-02-20 00:20:23 +01:00
Loïc Hoguin
ecee1226aa Cleanup: Replace a lot of 'little-unsigned-integer' by 'little' for binaries. 2011-02-20 00:18:14 +01:00
Loïc Hoguin
378e9a9927 egs_game_server: Properly leave the zone when the user is disconnecting. 2011-02-19 22:23:42 +01:00
Loïc Hoguin
2de4359c32 Create the user at character selection rather than login. 2011-02-19 21:21:35 +01:00
Loïc Hoguin
b728731830 Properly handle the LID per player and per zone. Remove related hacks. 2011-02-19 19:45:50 +01:00
Loïc Hoguin
1be3c4f5c6 Do not load the quest or zone nbl unless we actually need to send it. 2011-02-19 17:04:26 +01:00
Loïc Hoguin
e7246271ad users: Remove the setid property. Sets are fully handled by the zone now. 2011-02-19 16:58:09 +01:00
Loïc Hoguin
ad7071a61b psu_game: Load the players already in the zone on zone change. 2011-02-19 16:05:01 +01:00
Loïc Hoguin
50c2a2615f egs_zones: Broadcast spawn/unspawn directly from enter/leave. 2011-02-19 15:26:54 +01:00
Loïc Hoguin
afb888e566 egs_game: Leave the lobby's zone when entering a counter. 2011-02-19 13:31:38 +01:00
Loïc Hoguin
326b356d02 egs_zones: Add enter and leave functions for players entering/leaving the zone. 2011-02-18 02:52:25 +01:00
Loïc Hoguin
9d10c28504 egs_quests: Add the function zone_pid to retrieve a quest's zone pid. 2011-02-17 23:35:27 +01:00
Loïc Hoguin
06a032652a egs_universes: Add the function lobby_pid to retrieve a uni's lobby pid. 2011-02-17 23:17:11 +01:00
Loïc Hoguin
a4d9c5a35d egs_zones: Build a list of indexed and target objects, saved in the state. 2011-02-17 20:12:45 +01:00
Loïc Hoguin
526f281e2b egs_zones: Roughly initialize all the objects available so far. 2011-02-17 17:12:57 +01:00
Loïc Hoguin
bf7fa44897 egs_zones: Iterate through the set file to later create objects. 2011-02-16 23:08:28 +01:00
Loïc Hoguin
11a03f3a96 egs_quests_db: Fix crash when trying to load the set configuration file. 2011-02-16 21:59:33 +01:00
Loïc Hoguin
7e42b9b26a egs_zones: Load the set configuration at process initialization. 2011-02-16 00:09:46 +01:00
Loïc Hoguin
a1b8b1909e egs_zones: Determine which set to use at process initialization. 2011-02-15 23:26:48 +01:00
Loïc Hoguin
8f069e72d8 egs_sup: Delete the useless upgrade function. 2011-02-15 02:46:36 +01:00
Loïc Hoguin
9247e51fb7 Add egs_servers_sup to properly handle dependencies on egs_conf at startup. 2011-02-15 02:46:11 +01:00
Loïc Hoguin
ea25d1bd74 Universes start lobby quests automatically which in turn start their zones.
Universes are all stored in a single process; on the other hand, each quest
and each zone have their own process.
2011-02-15 01:15:28 +01:00
Loïc Hoguin
ffd27bda46 Rename egs_quests_db:quest and :zone into :quest_nbl and :zone_nbl. 2011-02-14 13:04:26 +01:00
Loïc Hoguin
fdfd49179f Remove psu_instance; to be replaced with egs_quests and egs_zones. 2011-02-13 19:26:08 +01:00
Loïc Hoguin
0989664035 Cleanup area loading code. Remove myroom, mission and spaceport support. 2011-02-13 18:06:25 +01:00
Loïc Hoguin
74f54e7e71 Move the server startup command into start.sh. 2011-02-13 12:20:23 +01:00
Loïc Hoguin
a484de77e0 egs_users: Rename id into gid inside the users record. 2011-02-13 00:35:05 +01:00
Loïc Hoguin
098ad5243a Get rid of psu_area; use a normal tuple instead (for now). 2011-02-12 23:28:56 +01:00
Loïc Hoguin
05149483c8 Use a normal tuple instead of a record for the pos values. 2011-02-12 20:12:48 +01:00
Loïc Hoguin
4dcaa79371 Add types to the users record and convert egs_users into a functions module.
The egs_user_model module was renamed into egs_users.
The egs_user_model record was renamed into users.
2011-02-12 19:58:53 +01:00