mirror of
https://github.com/mm201/pkmn-classic-framework.git
synced 2026-08-01 15:42:56 -05:00
Hide locked pokemon from search results
This commit is contained in:
parent
233e7feafa
commit
bf021c0cbf
|
|
@ -374,8 +374,9 @@ namespace PkmnFoundations.Data
|
|||
public GtsRecord4[] GtsSearch4(MySqlTransaction tran, Pokedex.Pokedex pokedex, int pid, ushort species, Genders gender, byte minLevel, byte maxLevel, byte country, int count)
|
||||
{
|
||||
List<MySqlParameter> _params = new List<MySqlParameter>();
|
||||
string where = "WHERE pid != @pid AND IsExchanged = 0";
|
||||
string where = "WHERE pid != @pid AND IsExchanged = 0 AND (LockedUntil < @now OR LockedUntil IS NULL)";
|
||||
_params.Add(new MySqlParameter("@pid", pid));
|
||||
_params.Add(new MySqlParameter("@now", DateTime.UtcNow));
|
||||
|
||||
if (species > 0)
|
||||
{
|
||||
|
|
@ -1567,8 +1568,9 @@ namespace PkmnFoundations.Data
|
|||
public GtsRecord5[] GtsSearch5(MySqlTransaction tran, Pokedex.Pokedex pokedex, int pid, ushort species, Genders gender, byte minLevel, byte maxLevel, byte country, int count)
|
||||
{
|
||||
List<MySqlParameter> _params = new List<MySqlParameter>();
|
||||
string where = "WHERE pid != @pid AND IsExchanged = 0";
|
||||
string where = "WHERE pid != @pid AND IsExchanged = 0 AND (LockedUntil < @now OR LockedUntil IS NULL)";
|
||||
_params.Add(new MySqlParameter("@pid", pid));
|
||||
_params.Add(new MySqlParameter("@now", DateTime.UtcNow));
|
||||
|
||||
if (species > 0)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user