[RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
After a long time of thinking I came too the conclusion the improved source of Pokémon-Sky should be open source and stay open source.
I've majorly improved the core, Added PDO (a lot of mysql functions need to be replaced before it is PHP7 ready), removed a lot of "very" insecure and leaky code and added a bunch of new features:
An awesome battle system overhaul! (Both above and under the hood, check the screenshots).
Animated Pokémon(.gif),
Kalos,
Mega Pokémon,
Mega stone drops,
Multiplayer Blackjack,
A better friends system,
A better profile,
User specific shops,
Missions,
A better referal system,
A better News system and an awesome Facebook chat
And much more!
**I haven't invested time in translating, you might need to replace some hard coded dutch language strings.
If i feel fit i will add minor patches now and then, be nice and add a little credit to me "darkshifty".
Code:
Tested server configuration:
Apache (enable short tags)
PHP: 5.6.30 (install the module mbstring)
MySQL: 5.6.37 (disable strict mode)
Charset: UTF-8 Unicode (utf8)
see thishttps://www.siteground.com/kb/how_to_have_different_php_versions/
or simple rewrite code to php 7 isnt dificult, seems u also have a directory error maybe paste name wrong or something check it
11-09-17
d3nniL
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Thanks for this amazing release... to bad I couldn´t figure out why I´m getting the following error....
Quote:
Parse error: syntax error, unexpected '}' in C:\phpStudy\PHPTutorial\WWW\rpg-master\index.php on line 638
11-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by d3nniL
Thanks for this amazing release... to bad I couldn´t figure out why I´m getting the following error....
Did you adjust the index.php? it looks like that you've added new brackets(without closing them)
Try reuploading the index.php
--------------------------
Sorry the solution to this is to enable short open tags:
1. Click on the wampserver tray icon.
2. Go to PHP. ThenPHP Settings 3. Enable short open tag.
11-09-17
d3nniL
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by darkshifty
Did you adjust the index.php? it looks like that you've added new brackets(without closing them)
Try reuploading the index.php
Didnt touched the files at all.... :o
EDIT: Fixed the problem by switching from apache to nginx. Now I got another problem when trying to import the db.
Quote:
Error
SQL query:
CREATE TABLE `gebruikers` ( `user_id` int(11) NOT NULL, `aanmeld_datum` datetime NOT NULL, `datum` datetime NOT NULL, `account_code` varchar(255) NOT NULL, `username` varchar(12) NOT NULL, `wachtwoord` varchar(32) NOT NULL, `email` varchar(40) NOT NULL, `profielfoto` varchar(255) NOT NULL DEFAULT 'images/you/Ash-red.png', `cover` varchar(255) NOT NULL DEFAULT 'images/cover.png', `views` int(255) NOT NULL DEFAULT '0', `ip_aangemeld` varchar(15) NOT NULL, `ip_ingelogd` varchar(15) NOT NULL, `premiumaccount` int(4) NOT NULL DEFAULT '1', `admin` tinyint(1) NOT NULL DEFAULT '0', `test` tinyint(2) NOT NULL, `spec` tinyint(3) NOT NULL DEFAULT '0', `Adminstatus` tinyint(1) NOT NULL DEFAULT '0', `wereld` varchar(6) NOT NULL, `silver` int(10) UNSIGNED NOT NULL DEFAULT '75', `gold` int(10) UNSIGNED NOT NULL DEFAULT '300', `bank` int(10) UNSIGNED NOT NULL DEFAULT '0', `storten` tinyint(1) NOT NULL DEFAULT '5', `store` text, `profilestore` longtext,[...] MySQL said: http://localhost/phpMyAdmin/themes/dot.gif
#1067 - Invalid default value for 'reclameAanSinds'
12-09-17
Mugaru
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
I'm working on the source to make it PHP 7.0 ready.
Won't change anything on the source until its ready for PHP 7.0.
When i got files ready, i might upload them here so people can use them too.
Quote:
Originally Posted by d3nniL
Didnt touched the files at all.... :o
EDIT: Fixed the problem by switching from apache to nginx. Now I got another problem when trying to import the db.
How are you importing the DB? Since there should be no problem importing the SQL file at all..
12-09-17
d3nniL
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
This is line 2590 in the .sql file, this is the line which is causing the error.
You can also try to copy everything thats in the .sql file and paste it in the SQL tab of PHPMyAdmin.
It worked for me and had no errors at all.
13-09-17
Mugaru
2 Attachment(s)
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Sorry for the double post
I've edited some files to make the source work on PHP 7.0/7.1
Just extract those files, fill in the data of your database in the config.php file and you'll see a running index page.
Maybe DarkShifty will add this to the git of the source. :cool:
This is just the start, and not much effort has been put in since i downloaded the source because of time.
I will work on the source tomorrow evening, so more updates will follow :w00t:
Code:
Remove the error reporting from the Index.php to deny all the notices (i'll try to fix them in the near future)
Attachment 161474
Also in this screenshot, deny the notices since i've got my error reporting turned ON
I change display_errors in php.ini into Off, then it didn't show the errors anymore, but I dont know does it affect to the game's engine?
As long as those errors in your screenshots are only Notices, nope. It won't affect the game.
13-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
@mirochan: it seems that your cache dir isn't writeable, if you have a xamp or wamp try editing the folder rights. it should take half off the notices.
- - - Updated - - -
Looks good! i will add most of your changes and add a credit :cool: thanks mate!
Quote:
Originally Posted by Mugaru
Sorry for the double post
I've edited some files to make the source work on PHP 7.0/7.1
Just extract those files, fill in the data of your database in the config.php file and you'll see a running index page.
Maybe DarkShifty will add this to the git of the source. :cool:
This is just the start, and not much effort has been put in since i downloaded the source because of time.
I will work on the source tomorrow evening, so more updates will follow :w00t:
Code:
Remove the error reporting from the Index.php to deny all the notices (i'll try to fix them in the near future)
Attachment 161474
Also in this screenshot, deny the notices since i've got my error reporting turned ON
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
I'm getting this error, can anyone help me ?
I have not changed anything at index.php
Parse error: syntax error, unexpected '}' in C:\wamp64\www\poketest\index.php on line 642
13-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Click on the wampserver tray icon.
Go to PHP. Then PHP Settings
Enable short open tag.
Quote:
Originally Posted by Horikita
I'm getting this error, can anyone help me ?
I have not changed anything at index.php
Parse error: syntax error, unexpected '}' in C:\wamp64\www\poketest\index.php on line 642
13-09-17
Horikita
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Thank you very much, the error did not appear any more, but now has another error, I tried to create a new user in MySQL and change the password, but it did not work, I will send a print of the error and configuration file. https://i.imgur.com/CZyQKSb.png https://i.imgur.com/CZyQKSb.png
13-09-17
Klemenxer
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by Horikita
Thank you very much, the error did not appear any more, but now has another error, I tried to create a new user in MySQL and change the password, but it did not work, I will send a print of the error and configuration file
What's your PHP version?
13-09-17
garall94
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Almost have a full english translation done. My fingers hurt from all the typing. More than likely it will be an extremely rough translation, but it will be easier to work out the kinks down the line for those looking for an english version of this awesome release. All the text is 3/4 done, after that I will work on changing the coded values to english.
14-09-17
Horikita
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by JasonDev
What's your PHP version?
I use version 5.6.25
14-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
@Horikita: You need to edit your php ini and disable warnings, find the value error_reporting and change it to:
Mind that keeping error reporting on while developing makes it a lot easier.
- - - Updated - - -
@garall94: Note that there are translation files in the source already, they aren't complete and indeed some values are hardcoded. I will work on a solution to set a language soon.
14-09-17
Horikita
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
@Horikita: You need to edit your php ini and disable warnings, find the value error_reporting and change it to:
Mind that keeping error reporting on while developing makes it a lot easier.
I found the file and changed it as you said, but it still keeps giving the same error
14-09-17
Mugaru
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by Horikita
I found the file and changed it as you said, but it still keeps giving the same error
Try it without a MySQL password.. seems like there is no password set for your MySQL?
14-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by Horikita
I found the file and changed it as you said, but it still keeps giving the same error
You need to restart the server :-)
14-09-17
Horikita
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Try it without a MySQL password.. seems like there is no password set for your MySQL?
I got the password and it still did not work, it still has the same error :(
Quote:
You need to restart the server :-)
Before @ has two "in these two quotes was to appear the login user, but it is not appearing, the only thing I can think of is that it is not being able to find the MySQL user login
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
I am aware there are translation files. I have fully translated the files roughly. I am playing the various aspects of the game to edit them as I see fit because frankly the rough translation leads to some things not making much sense. The only thing I haven't translated is the Admin panel. All in game features have been translated to English.
My next step will be to change over the hard coded values which in all honesty shouldn't be that difficult if I do them one at a time.
After that I will do the admin panel last.
@Horikita check your config. It doesn't look like you're using a MySQL user if that is your error. Check to see if you deleted something out of your config file causing it to throw the error.
15-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by Horikita
I got the password and it still did not work, it still has the same error :(
Before @ has two "in these two quotes was to appear the login user, but it is not appearing, the only thing I can think of is that it is not being able to find the MySQL user login
Aha, do you see any error? Could you make a screenshot? :-)
- - - Updated - - -
Quote:
Originally Posted by garall94
I am aware there are translation files. I have fully translated the files roughly. I am playing the various aspects of the game to edit them as I see fit because frankly the rough translation leads to some things not making much sense. The only thing I haven't translated is the Admin panel. All in game features have been translated to English.
My next step will be to change over the hard coded values which in all honesty shouldn't be that difficult if I do them one at a time.
After that I will do the admin panel last.
@Horikita check your config. It doesn't look like you're using a MySQL user if that is your error. Check to see if you deleted something out of your config file causing it to throw the error.
Ah sweet, you are taking a load of my back. I can help if needed, just pm me if you have such a case that doesnt make sense.
15-09-17
Horikita
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
There is apparently no error in MySQL, the error is that of the print when I try to open the site.
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by Mugaru
Sorry for the double post
I've edited some files to make the source work on PHP 7.0/7.1
Just extract those files, fill in the data of your database in the config.php file and you'll see a running index page.
Maybe DarkShifty will add this to the git of the source. :cool:
This is just the start, and not much effort has been put in since i downloaded the source because of time.
I will work on the source tomorrow evening, so more updates will follow :w00t:
Code:
Remove the error reporting from the Index.php to deny all the notices (i'll try to fix them in the near future)
Attachment 161474
Also in this screenshot, deny the notices since i've got my error reporting turned ON
Seems again nearly running.... but just nearly... x*D
16-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
I got it running smoothly with:
wampserver.com
created a virtual host which i directed to my source folder
made sure it was set to php 5.6
enabled short_open_tags
disabled display_errors
commented line 2030 of my php.ini (;zend_extension =)
added my mysql user details (localhost and root) to the includes/config.php file
rebooted the server.
Now it may complain about the news table beeing empty in news.php or the google captcha that isn't set up properly in register.php
All the rest should be functioning fine, disable the captcha temporary by coding and create a user. set that user to admin level 3 and your good to go.
16-09-17
fallenfate
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Shame it's using old mysql functions and not progressive methods such as PDO :(, and too many lines for me to be bothered editing, lol. Guess I'll have to give this one a miss but it looks quite good. Thanks for releasing it to the community :).
16-09-17
d3nniL
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by darkshifty
I got it running smoothly with:
wampserver.com
created a virtual host which i directed to my source folder
made sure it was set to php 5.6
enabled short_open_tags
disabled display_errors
commented line 2030 of my php.ini (;zend_extension =)
added my mysql user details (localhost and root) to the includes/config.php file
rebooted the server.
Now it may complain about the news table beeing empty in news.php or the google captcha that isn't set up properly in register.php
All the rest should be functioning fine, disable the captcha temporary by coding and create a user. set that user to admin level 3 and your good to go.
If you got some free time, do you mind taking a look over TeamViewer if you can see what`s the problem? Can`t get it.
Edit: Switched from php 7 to 5.6 and it`s working fine. lol :P
16-09-17
fallenfate
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
@d3nniL I imagine it was mostly just the fact it's using mysql rather than mysqli or PDO functions, mysql functions were deprecated after PHP 5.5/5.6. Part of the reason I haven't tested. I might have my own spin off in future that's updated in terms of PHP and will run in newer versions. But that'll be a long way off as there's a lot of code to make :).
16-09-17
d3nniL
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by fallenfate
@d3nniL I imagine it was mostly just the fact it's using mysql rather than mysqli or PDO functions, mysql functions were deprecated after PHP 5.5/5.6. Part of the reason I haven't tested. I might have my own spin off in future that's updated in terms of PHP and will run in newer versions. But that'll be a long way off as there's a lot of code to make :).
I stopped with PHP when those mysql functions has been changed.... long time ago now.
Anyway even if it seems to look like it would work, I still couldn`t login yet because I can`t get this captcha working.... I pasted the api-key but the captcha is still not showing. Anyone mind to explain how to fix the captcha?
Meanwhile I translated some of the files... :P
16-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by d3nniL
I stopped with PHP when those mysql functions has been changed.... long time ago now.
Anyway even if it seems to look like it would work, I still couldn`t login yet because I can`t get this captcha working.... I pasted the api-key but the captcha is still not showing. Anyone mind to explain how to fix the captcha?
Meanwhile I translated some of the files... :P
On localhost google recaptcha isn't working, the best you can do is open up register.php and replace the following line:
Code:
if (intval($responseKeys["success"]) !== 1) {
to this:
Code:
if (intval($responseKeys["success"]) !== 1 && 1==2) {
I've also added a major update today, be sure to remove your global definitions file and update the database before opening your website.
17-09-17
d3nniL
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by darkshifty
On localhost google recaptcha isn't working, the best you can do is open up register.php and replace the following line:
Code:
if (intval($responseKeys["success"]) !== 1) {
to this:
Code:
if (intval($responseKeys["success"]) !== 1 && 1==2) {
I've also added a major update today, be sure to remove your global definitions file and update the database before opening your website.
Ohhh okay... Updated the files and db.... removed the global definitions file and removed it from index file.
But if I change the lines like you said and I try to register an account he only goes back to the index if you press on "Register".
17-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by d3nniL
Ohhh okay... Updated the files and db.... removed the global definitions file and removed it from index file.
But if I change the lines like you said and I try to register an account he only goes back to the index if you press on "Register".
Yes, it should log you in once you create an account.
18-09-17
d3nniL
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by darkshifty
Yes, it should log you in once you create an account.
No, the username is not even registred after I register one.
19-09-17
SimaoMP
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
create one on db
19-09-17
loveyeudau
1 Attachment(s)
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by d3nniL
No, the username is not even registred after I register one.
Then you might have an error(the one i can think of is mysql mode strict), try dumping the result of the query.
20-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Updated the source with updated PHP7 compatible pages
20-09-17
Mugaru
1 Attachment(s)
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Fixed SQL File in attachment for the people who are having issues uploading the latest update of Darkshifty with the Recaptcha and Language in the Settings Table :-)
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
i already enable short tag and save the document and restart the xampp server but still gives me this error: Parse error: syntax error, unexpected '}' in C:\xampp5.6\htdocs\pokeworld\index.php on line 638
Next update will be Work, battles, trainer battles etc.
Hope to have this done next weekend so the game will be almost playable on a PHP 7.0 server :-)
26-09-17
fallenfate
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Thanks for sharing the files @darkshifty, also nice work in supporting the community @Mugaru :D. If I had the time I'd have changed all the functions and such but as I'm sure you're finding, there's a lot to change to PDO :).
- - - Updated - - -
Thanks for sharing the files @darkshifty, also nice work in supporting the community @Mugaru :D. If I had the time I'd have changed all the functions and such but as I'm sure you're finding, there's a lot to change to PDO :).
26-09-17
Mugaru
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by fallenfate
Thanks for sharing the files @darkshifty, also nice work in supporting the community @Mugaru :D. If I had the time I'd have changed all the functions and such but as I'm sure you're finding, there's a lot to change to PDO :).
- - - Updated - - -
Thanks for sharing the files @darkshifty, also nice work in supporting the community @Mugaru :D. If I had the time I'd have changed all the functions and such but as I'm sure you're finding, there's a lot to change to PDO :).
Its a pleasure :-)! And yes, there is a lot to change to PDO! But i like to do it :-)
27-09-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Thanks man!, i've added your PHP7 code.
29-09-17
pokegamer
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Help me I sent all the files to my site but even then nothing appears the page is always blank Look here at the link: Pkmorigin.a0001.net
29-09-17
pokegamer
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
I am having an error in globaldef.php
Notice: Undefined variable: db in /home/vol13_1/byethost14.com/b14_20732101/pkmorigin.a0001.net/htdocs/includes/globaldefs.php on line 16
Fatal error: Uncaught Error: Call to a member function prepare() on null in /home/vol13_1/byethost14.com/b14_20732101/pkmorigin.a0001.net/htdocs/includes/globaldefs.php:16 Stack trace: #0 /home/vol13_1/byethost14.com/b14_20732101/pkmorigin.a0001.net/htdocs/index.php(12): include_once() #1 {main} thrown in /home/vol13_1/byethost14.com/b14_20732101/pkmorigin.a0001.net/htdocs/includes/globaldefs.php on line 16
29-09-17
pokegamer
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Help me
- - - Updated - - -
I'm trying to put this game on my site but i'm getting it because it say:
Notice: Undefined variable: db in /home/vol13_1/byethost14.com/b14_20732101/pkmorigin.a0001.net/htdocs/includes/globaldefs.php on line 16
Fatal error: Call to a member function prepare() on null in /home/vol13_1/byethost14.com/b14_20732101/pkmorigin.a0001.net/htdocs/includes/globaldefs.php on line 16
30-09-17
David1414
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
This could be a Database issue, seems like you did not run the upgraded SQL.
Do other pages work?
Run this in PHPMyAdmin
Code:
ALTER TABLE `nieuws` ADD `titel_en` VARCHAR(255) NOT NULL AFTER `id`;
INSERT INTO `settings` (`setting`, `value`, `globaldef`) VALUES ('editorLanguage', 'en-EN', 1);
<?php
#Script laden zodat je nooit pagina buiten de index om kan laden
include("includes/security.php");
#Als je geen pokemon bij je hebt, terug naar index.
if ($gebruiker['in_hand'] == 0) header('Location: index.php');
$page = 'pokemoncenter';
#Goeie taal erbij laden voor de page
include_once('language/language-pages.php');
#Als er op de heal knop gedrukt word
if (isset($_POST['heal'])) {
#Teller op 0 zetten voor het tellen van de pokemon
$count = 0;
#Voor alle enabelde checkboxen tellen welke aangevinkt zijn
$missieAlert = 1;
for ($i = 0; $i <= $_POST['teller']; $i++) {
#Makkelijke naam toewijzen
$pokeid = $_POST['pokemonid' . $i];
#Kijken als $pokeid numeriek is voor het tellen van de pokemon.
if (is_numeric($pokeid)) {
#Is het nummeriek er 1 bij optellen
if ($gebruiker['admin'] == 1) $count = 1;
elseif ($gebruiker['premiumaccount'] >= 1) $count = 10;
else $count = 10;
}
#Voor alle pokemon leven op 100% zetten en effect weghalen
$healAll = $db->prepare("UPDATE `pokemon_speler` SET `leven`=`levenmax`, `effect`='' WHERE `id`=:pokeId");
$healAll->bindValue(':pokeId', $pokeid, PDO::PARAM_INT);
$healAll->execute();
//complete mission 1
if ($gebruiker['missie_1'] == 0) {
$completeMission = $db->prepare("UPDATE `gebruikers` SET `missie_1`=1, `silver`=`silver`+50,`rankexp`=rankexp+50 WHERE `user_id`=:uid");
$completeMission->bindValue(':uid', $gebruiker['user_id'], PDO::PARAM_INT);
$completeMission->execute();
if ($missieAlert == 1) {
echo showToastr("info", "Je hebt een missie behaald!");
}
$missieAlert++;
}
}
#Pokemon center tijden opstellen
if ($gebruiker['premiumaccount'] > 0) {
$tijdnu = date('Y-m-d H:i:s', strtotime('-1 hour'));
} else {
$tijdnu = date('Y-m-d H:i:s');
};
#Tijden opslaan
$saveTimes = $db->prepare("UPDATE `gebruikers` SET `pokecentertijdbegin`=:timeNow, `pokecentertijd`=:countTime WHERE `user_id`=:uid");
$saveTimes->bindValue(':timeNow', $tijdnu);
$saveTimes->bindValue(':countTime', $count);
$saveTimes->bindValue(':uid', $_SESSION['id'], PDO::PARAM_INT);
$saveTimes->execute();
#Is er geen tijd, dus ook geen pokemon opgegeven, dan bericht niet laten zien
if (($count == 10) OR ($count == 20) OR ($count == 30) OR ($count == 40) OR ($count == 50) OR ($count == 60)) {
$wat = "seconden";
}
What PHP version are you running?
Did you also follow the instructions of the readme?
- - - Updated - - -
Quote:
Originally Posted by Mugaru
That will solve your problem, it should still be cleaned up, but for now you can use it to heal your Pokemon :-)
Thank you Mugaru i've added the fixed version to git.
02-10-17
David1414
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by Mugaru
This could be a Database issue, seems like you did not run the upgraded SQL.
Do other pages work?
Run this in PHPMyAdmin
Code:
ALTER TABLE `nieuws` ADD `titel_en` VARCHAR(255) NOT NULL AFTER `id`;
INSERT INTO `settings` (`setting`, `value`, `globaldef`) VALUES ('editorLanguage', 'en-EN', 1);
replace the code in your Pokemoncenter.php with:
Spoiler:
Code:
<?php
#Script laden zodat je nooit pagina buiten de index om kan laden
include("includes/security.php");
#Als je geen pokemon bij je hebt, terug naar index.
if ($gebruiker['in_hand'] == 0) header('Location: index.php');
$page = 'pokemoncenter';
#Goeie taal erbij laden voor de page
include_once('language/language-pages.php');
#Als er op de heal knop gedrukt word
if (isset($_POST['heal'])) {
#Teller op 0 zetten voor het tellen van de pokemon
$count = 0;
#Voor alle enabelde checkboxen tellen welke aangevinkt zijn
$missieAlert = 1;
for ($i = 0; $i <= $_POST['teller']; $i++) {
#Makkelijke naam toewijzen
$pokeid = $_POST['pokemonid' . $i];
#Kijken als $pokeid numeriek is voor het tellen van de pokemon.
if (is_numeric($pokeid)) {
#Is het nummeriek er 1 bij optellen
if ($gebruiker['admin'] == 1) $count = 1;
elseif ($gebruiker['premiumaccount'] >= 1) $count = 10;
else $count = 10;
}
#Voor alle pokemon leven op 100% zetten en effect weghalen
$healAll = $db->prepare("UPDATE `pokemon_speler` SET `leven`=`levenmax`, `effect`='' WHERE `id`=:pokeId");
$healAll->bindValue(':pokeId', $pokeid, PDO::PARAM_INT);
$healAll->execute();
//complete mission 1
if ($gebruiker['missie_1'] == 0) {
$completeMission = $db->prepare("UPDATE `gebruikers` SET `missie_1`=1, `silver`=`silver`+50,`rankexp`=rankexp+50 WHERE `user_id`=:uid");
$completeMission->bindValue(':uid', $gebruiker['user_id'], PDO::PARAM_INT);
$completeMission->execute();
if ($missieAlert == 1) {
echo showToastr("info", "Je hebt een missie behaald!");
}
$missieAlert++;
}
}
#Pokemon center tijden opstellen
if ($gebruiker['premiumaccount'] > 0) {
$tijdnu = date('Y-m-d H:i:s', strtotime('-1 hour'));
} else {
$tijdnu = date('Y-m-d H:i:s');
};
#Tijden opslaan
$saveTimes = $db->prepare("UPDATE `gebruikers` SET `pokecentertijdbegin`=:timeNow, `pokecentertijd`=:countTime WHERE `user_id`=:uid");
$saveTimes->bindValue(':timeNow', $tijdnu);
$saveTimes->bindValue(':countTime', $count);
$saveTimes->bindValue(':uid', $_SESSION['id'], PDO::PARAM_INT);
$saveTimes->execute();
#Is er geen tijd, dus ook geen pokemon opgegeven, dan bericht niet laten zien
if (($count == 10) OR ($count == 20) OR ($count == 30) OR ($count == 40) OR ($count == 50) OR ($count == 60)) {
$wat = "seconden";
}
I'm sorry for the work you're taking to help me. :/
No problem mate.
For the error message on the News:
Go to your PHPMyAdmin > SQL and run this:
Code:
ALTER TABLE `nieuws` ADD `titel_en` VARCHAR(255) NOT NULL AFTER `id`;
INSERT INTO `settings` (`setting`, `value`, `globaldef`) VALUES ('editorLanguage', 'en-EN', 1);
this wil solve most of your issue :closedeyes:
For the others:
Here are the updated Wild attack files (will work with PHP 7.* now): Attachment 161592
Here is the SQL for the 'voordeel' table which everybody is missing.
No data is in it, but it will solve some errors in the battles.
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @old_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @old_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @old_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8mb4 */;
CREATE TABLE `voordeel` (
`id` int(11) NOT NULL,
`krachtiger` int(11) NOT NULL,
`aanval` int(11) NOT NULL,
`verdediger` int(11) NOT NULL,
`soort` int(11) NOT NULL,
`type1` int(11) NOT NULL,
`type2` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
/*!40101 SET CHARACTER_SET_CLIENT @old_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS @old_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION @old_COLLATION_CONNECTION */;
I'm not sure if every table type is right, but since there is no data in it at the moment it will only fix some minor error messages in your console...
Table is not needed to make battles fully working
so i'll probably delete the code in the attack files which are calling the queries.
04-10-17
sunnycar
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Thanks! I can login now, but... still dont show pages. :/
This error happens when I click to fight (on the map). After that no page works anymore.
I think you still are on the wrong PHP version, however replace the function with this one:
Code:
function computer_naam($old){ //Staat er een f/m achter de naam Male/Female Character maken
if (preg_match('/\s/', $old)) {
$pokemon = explode(" ", $old);
if($pokemon[1] == "f")
return $pokemon[0]." ♀";
elseif($pokemon[1] == "m")
return $pokemon[0]." ♂";
else return $old;
} //Naam bevat geen spatie
else return $old;
}
11-10-17
Mugaru
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Market.php PHP 7.* ready :-)
Spoiler:
Code:
<?
#Script laden zodat je nooit pagina buiten de index om kan laden
include("includes/security.php");
if (($gebruiker['rank'] < 5) && ($_GET['shopitem'] == 'attacks')) header('Location: index.php?page=pokemarket');
$page = 'market';
#Goeie taal erbij laden voor de page
include_once('language/language-pages.php');
#Kijken of je nog wel een itemplek overhebt
if ($gebruiker['item_over'] < 1) {
echo '<div class="blue">' . $txt['alert_itemplace'] . '</div>';
}
?>
<?
#Ruimte vast stellen Per item.
#Vast stellen welke items nog te koop zijn.
if ($gebruiker['itembox'] == 'Red box') $ruimte['max'] = 250;
elseif ($gebruiker['itembox'] == 'Blue box') $ruimte['max'] = 100;
elseif ($gebruiker['itembox'] == 'Yellow box') $ruimte['max'] = 50;
elseif ($gebruiker['itembox'] == 'Bag') $ruimte['max'] = 20;
#Pagina's opbouwen
switch ($_GET['shopitem']) {
#Als er op balls geklikt word. Het volgende laten zien
case "balls":
$sql = $db->prepare("SELECT `id`, `naam`, `silver`, `gold`, `omschrijving_en` FROM `markt` WHERE `soort`='balls'");
$sql->execute();
#Als er op de knop gedrukt word
if (isset($_POST['balls'])) {
$gebruiker_silver = $gebruiker['silver'];
$gebruiker_gold = $gebruiker['gold'];
#Laden voor de verwerking van de informatie
for ($i = 1; $i <= $_POST['teller']; $i++) {
#Item id opvragen
$itemid = $_POST['id' . $i];
#Aantal opvragen van het itemid
$aantal = $_POST['aantal' . $itemid];
#Als er geen aantal is
if (empty($aantal)) $niksingevoerd = True;
elseif (!is_numeric($aantal)) $niksingevoerd = True;
#Als er wel een aantal is
elseif (!empty($aantal)) {
#Item gegevens laden
$itemgegevensSQL = $db->prepare("SELECT `naam`, `silver`, `gold` FROM `markt` WHERE `id`=:itemId");
$itemgegevensSQL->bindValue(':itemId', $itemid);
$itemgegevensSQL->execute();
$itemgegevens = $itemgegevensSQL->fetch(PDO::FETCH_ASSOC);
#silver of gold berekenen voor de balls
if ($itemgegevens['naam'] == 'Master ball') {
$goldd = $aantal * ($itemgegevens['gold'] / 1);
} else $silverr = $aantal * ($itemgegevens['silver'] / 1);
#itemruimte over berekenen
$ruimteover = $ruimte['max'] - $gebruiker['items'];
#Kijken als het silver er wel voor is
if (($gebruiker_silver < $silverr) OR ($gebruiker_gold < $goldd)) {
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
} elseif ($aantal < 0)
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
elseif (!ctype_digit($aantal))
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
#Als speler niet genoeg ruimte heeft voor de balls
elseif ($ruimteover < $aantal) {
if ($aantal > 1) $netheid = "'s";
echo '<div class="red">' . $txt['alert_itembox_full_1'] . ' ' . $ruimteover . ' ' . $itemgegevens['naam'] . $netheid . ' ' . $txt['alert_itembox_full_2'] . '</div>';
} else {
#Opslaan
$totalesilver += $silverr;
$gebruiker_silver -= $silverr;
$totalegold += $goldd;
$gebruiker_gold -= $goldd;
<?
#Einde balls
break;
#Als er op potions geklikt word, het volgende laten zien
case "potions":
$sql = $db->prepare("SELECT `id`, `naam`, `silver`,`gold`, `omschrijving_en` FROM `markt` WHERE `soort`='potions'");
$sql->execute();
#Als er op de knop gedrukt word
if (isset($_POST['potions'])) {
$gebruiker_silver = $gebruiker['silver'];
#Laden voor de verwerking van de informatie
for ($i = 1; $i <= $_POST['teller']; $i++) {
#Item id opvragen
$itemid = $_POST['id' . $i];
#Aantal opvragen van het itemid
$aantal = $_POST['aantal' . $itemid];
#Als er geen aantal is
if (empty($aantal)) $niksingevoerd = True;
elseif (!is_numeric($aantal)) $niksingevoerd = True;
#Als er wel een aantal is
elseif (!empty($aantal)) {
$niksingevoerd = False;
#Gegevens laden van de te kopen item
$itemgegevensSQL = $db->prepare("SELECT `naam`, `silver` FROM `markt` WHERE `id`=:itemId");
$itemgegevensSQL->bindValue(':itemId', $itemid);
$itemgegevensSQL->execute();
$itemgegevens = $itemgegevensSQL->fetch(PDO::FETCH_ASSOC);
#Prijs bereken voor het aantal potions.
$silverr = $aantal * ($itemgegevens['silver'] / 1);
#itemruimte over berekenen
$ruimteover = $ruimte['max'] - $gebruiker['items'];
#Kijken als er wel genoeg silver is.
if ($gebruiker_silver < $silverr) {
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
} elseif ($aantal < 0)
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
elseif (!ctype_digit($aantal))
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
#Kijken als speler nog wel ruimte heeft voor de potions
elseif ($ruimteover < $aantal) {
if ($aantal > 1) $netheid = "'s";
echo '<div class="red">' . $txt['alert_itembox_full_1'] . ' ' . $ruimteover . ' ' . $itemgegevens['naam'] . $netheid . ' ' . $txt['alert_itembox_full_2'] . '</div>';
} else {
#Opslaan
$totalesilver += $silverr;
$gebruiker_silver -= $silverr;
$saveSilver = $db->prepare("UPDATE `gebruikers_item` SET `" . $itemgegevens['naam'] . "`=`" . $itemgegevens['naam'] . "`+:aantal WHERE `user_id`=:uid");
$saveSilver->bindValue(':aantal', $aantal);
$saveSilver->bindValue(':uid', $_SESSION['id']);
$saveSilver->execute();
<?
#items sluiten
break;
#Als er op special items geklikt word. Het volgende laten zien
case "stones":
$sql = $db->prepare("SELECT `id`, `naam`, `silver`, `omschrijving_en` FROM `markt` WHERE `soort`='stones'");
$sql->execute();
#Als er op de knop gedrukt word
if (isset($_POST['stones'])) {
$gebruiker_silver = $gebruiker['silver'];
#Laden voor de verwerking van de informatie
for ($i = 1; $i <= $_POST['teller']; $i++) {
#Item id opvragen
$itemid = $_POST['id' . $i];
#Aantal opvragen van het itemid
$aantal = $_POST['aantal' . $itemid];
#Als er geen aantal is
if (empty($aantal)) $niksingevoerd = False;
elseif (!is_numeric($aantal)) $niksingevoerd = False;
#Als er wel een aantal is
elseif (!empty($aantal)) {
#Item gegevens laden
$itemgegevensSQL = $db->prepare("SELECT `naam`, `silver` FROM `markt` WHERE `id`=:itemId");
$itemgegevensSQL->bindValue(':itemId', $itemid);
$itemgegevensSQL->execute();
$itemgegevens = $itemgegevensSQL->fetch(PDO::FETCH_ASSOC);
#silver berekenen voor de balls
$silverr = $aantal * ($itemgegevens['silver'] / 1);
#itemruimte over berekenen
$ruimteover = $ruimte['max'] - $gebruiker['items'];
#Kijken als het silver er wel voor is
if ($gebruiker_silver < $silverr) {
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
} elseif ($aantal < 0)
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
elseif (!ctype_digit($aantal))
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
#Kijken als speler nog wel ruimte heeft voor de potions
elseif ($ruimteover < $aantal) {
if ($aantal > 1) $netheid = "'s";
echo '<div class="red">' . $txt['alert_itembox_full_1'] . ' ' . $ruimteover . ' ' . $itemgegevens['naam'] . '' . $netheid . ' ' . $txt['alert_itembox_full_2'] . '</div>';
} else {
#Opslaan
$totalesilver += $silverr;
$gebruiker_silver -= $silverr;
#mysql_query("UPDATE `gebruikers` SET `silver`=`silver`-'".$silverr."' WHERE `user_id`='".$_SESSION['id']."'");
$updateSilver = $db->prepare("UPDATE `gebruikers_item` SET `" . $itemgegevens['naam'] . "`=`" . $itemgegevens['naam'] . "`+:aantal WHERE `user_id`=:uid");
$updateSilver->bindValue(':uid', $_SESSION['id']);
$updateSilver->bindValue(':aantal', $aantal);
$updateSilver->execute();
echo '<div class="green">' . $txt['success_market'] . ' ' . $itemgegevens['naam'] . ' ' . $aantal . 'x gekocht.</div>';
}
$welingevoerd = True;
}
}
#silver opslaan
$saveSilver = $db->prepare("UPDATE `gebruikers` SET `silver`=`silver`-:silver WHERE `user_id`=:uid");
$saveSilver->bindValue(':silver', $totalesilver);
$saveSilver->bindValue(':uid', $_SESSION['id']);
$saveSilver->execute();
#Als wel ingevoerd een waarde heeft/true is
if (!$welingevoerd) {
#Als niksingevoerd TRUE is
if ($niksingevoerd) {
echo '<div class="red">' . $txt['alert_nothing_selected'] . '</div>';
}
}
}
?>
<table width="660" cellpadding="0" cellmargin="0">
<tr>
<td width="120" rowspan="54" valign="top"><img src="http://forum.ragezone.com/images/market.gif"/></td>
</tr>
<?php #Form starten
echo '<form method="POST" name="stones">
<tr>
<td>';
#Als er op potions geklikt word, het volgende laten zien
case "attacks":
if (empty($_GET['subpage'])) $subpage = 1;
else $subpage = $_GET['subpage'];
#Max aantal pokemon per pagina
$max = 20;
$aantal_attacks = 92;
$aantal_paginas = ceil($aantal_attacks / $max);
if ($aantal_paginas == 0) $aantal_paginas = 1;
$pagina = $subpage * $max - $max;
$sql = $db->prepare("SELECT markt.id, markt.naam, silver, markt.omschrijving_en, tmhm.type1 , tmhm.type2
FROM `markt`
INNER JOIN tmhm
ON markt.id = tmhm.id
WHERE `soort`='tm'
LIMIT " . $pagina . ", " . $max);
$sql->execute();
#Als er op de knop gedrukt word
if (isset($_POST['tm'])) {
$gebruiker_silver = $gebruiker['silver'];
$itemid = $_POST['id' . $i];
#Aantal opvragen van het itemid
$aantal = $_POST['aantal' . $itemid];
echo $aantal;
#Laden voor de verwerking van de informatie
for ($i = 1; $i <= $_POST['teller']; $i++) {
#Item id opvragen
$itemid = $_POST['id' . $i];
#Aantal opvragen van het itemid
$aantal = $_POST['aantal' . $itemid];
#Als er geen aantal is
if (empty($aantal)) $niksingevoerd = True;
elseif (!is_numeric($aantal)) $niksingevoerd = True;
#Als er wel een aantal is
elseif (!empty($aantal)) {
$niksingevoerd = False;
#Gegevens laden van de te kopen item
$itemSQL = $db->prepare("SELECT `naam`, `silver` FROM `markt` WHERE `id`=:itemId");
$itemSQL->bindValue(':itemId', $itemid);
$itemSQL->execute();
$itemgegevens = $itemSQL->fetch(PDO::FETCH_ASSOC);
#Prijs bereken voor het aantal potions.
$silverr = $aantal * ($itemgegevens['silver'] / 1);
#itemruimte over berekenen
$ruimteover = $ruimte['max'] - $gebruiker['items'];
#Kijken als er wel genoeg silver is.
if ($gebruiker_silver < $silverr) {
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
} elseif ($aantal < 0)
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
elseif (!ctype_digit($aantal))
echo '<div class="red">' . $txt['alert_not_enough_money'] . '</div>';
#Kijken als speler nog wel ruimte heeft voor de potions
elseif ($ruimteover < $aantal) {
if ($aantal > 1) $netheid = "'s";
echo '<div class="red">' . $txt['alert_itembox_full_1'] . ' ' . $ruimteover . ' ' . $itemgegevens['naam'] . '' . $netheid . ' ' . $txt['alert_itembox_full_2'] . '</div>';
} else {
#Opslaan
$totalesilver += $silverr;
$gebruiker_silver -= $silverr;
$updateSilver = $db->prepare("UPDATE `gebruikers_tmhm` SET `" . $itemgegevens['naam'] . "`=`" . $itemgegevens['naam'] . "`+:aantal WHERE `user_id`=:uid");
$updateSilver->bindValue(':aantal', $aantal);
$updateSilver->bindValue(':uid', $_SESSION['id']);
$updateSilver->execute();
echo '<div class="green">' . $txt['success_market'] . ' ' . $itemgegevens['naam'] . ' ' . $aantal . 'x gekocht.</div>';
}
$welingevoerd = True;
}
}
#silver opslaan
$saveSilver = $db->prepare("UPDATE `gebruikers` SET `silver`=`silver`-:silver WHERE `user_id`=:uid");
$saveSilver->bindValue(':silver', $totalesilver);
$saveSilver->bindValue(':uid', $_SESSION['id']);
$saveSilver->execute();
#Als wel ingevoerd een waarde heeft/true is
if (!$welingevoerd) {
#Als niksingevoerd TRUE is
if ($niksingevoerd) {
echo '<div class="red">' . $txt['alert_nothing_selected'] . '</div>';
}
}
}
?>
<table width="660" cellpadding="0" cellmargin="0">
<tr>
<td width="120" rowspan="54" valign="top"><img src="http://forum.ragezone.com/images/market.gif"/></td>
</tr>
<?php #Form starten
echo '<form method="POST" name="tm">
<tr>
<td>';
for ($j = 1; $select = $sql->fetch(PDO::FETCH_ASSOC); $j++) {
if ($select['type2'] == $select['type1']) $type = $select['type1'];
else $type = $select['type1'] . ' en ' . $select['type2'];
#De willekeurige pokemon in de pokemon_speler tabel zetten
$randomPokemon = $db->prepare("INSERT INTO `pokemon_speler` (`wild_id`, `aanval_1`, `aanval_2`, `aanval_3`, `aanval_4`) SELECT `wild_id`, `aanval_1`, `aanval_2`, `aanval_3`, `aanval_4` FROM `pokemon_wild` WHERE `wild_id`=:wildId");
$randomPokemon->bindValue(':wildId', $query['wild_id']);
$randomPokemon->execute();
#id opvragen van de insert hierboven
$pokeid = $db->lastInsertId();
#Karakter kiezen
$karakterSQL = $db->prepare("SELECT * FROM `karakters` ORDER BY rand() limit 1");
$karakterSQL->execute();
$karakter = $karakterSQL->fetch(PDO::FETCH_ASSOC);
#Expnodig opzoeken en opslaan
$experienceSQL = $db->prepare("SELECT `punten` FROM `experience` WHERE `soort`=:groei AND `level`='6'");
$experienceSQL->bindValue(':groei', $query['groei']);
$experienceSQL->execute();
$experience = $experienceSQL->fetch(PDO::FETCH_ASSOC);
#Pokemon IV maken en opslaan
#Iv willekeurig getal tussen 1,31. Ik neem 2 omdat 1 te weinig is:P
$attack_iv = rand(2, 31);
$defence_iv = rand(2, 31);
$speed_iv = rand(2, 31);
$spcattack_iv = rand(2, 31);
$spcdefence_iv = rand(2, 31);
$hp_iv = rand(2, 31);
$updateMarket = $db->prepare("UPDATE markt SET beschikbaar = '0' WHERE id = :item");
$updateMarket->bindValue(':item', $itemgegevens['id']);
$updateMarket->execute();
#Gebeurtenissen wissen wat niet in de lijst staan
$hoeveelSQL = $db->prepare("SELECT COUNT(id) AS nu FROM gebeurtenis WHERE ontvanger_id = :uid");
$hoeveelSQL->bindValue(':uid', $_SESSION['id'], PDO::PARAM_INT);
$hoeveelSQL->execute();
$hoeveel = $hoeveelSQL->fetch(PDO::FETCH_ASSOC);
if ($toegestaan < $hoeveel['nu']) {
$delete = $hoeveel['nu'] - $toegestaan;
mysql_query("DELETE FROM gebeurtenis WHERE ontvanger_id=:uid ORDER BY id ASC LIMIT :deleteEvent");
$deleteEvent = $db->prepare();
$deleteEvent->bindValue(':uid', $_SESSION['id'], PDO::PARAM_INT);
$deleteEvent->bindValue(':deleteEvent', $delete);
$deleteEvent->execute();
}
if (isset($_POST['verwijder'])) {
#teller starten
$teller = 0;
#Als er wel een post id is
if (isset($_POST['eventid'])) {
foreach ($_POST['eventid'] as $eventid) {
#Alle ontvangen id's verwijderen
$deleteEverything = $db->prepare("DELETE FROM `gebeurtenis` WHERE `id`=:eventId AND `ontvanger_id`=:uid");
$deleteEverything->bindValue(':eventId', $eventid, PDO::PARAM_INT);
$deleteEverything->bindValue(':uid', $_SESSION['id'], PDO::PARAM_INT);
$deleteEverything->execute();
if ($eventid >= 1) $geselecteerd = true;
$teller++;
}
} #Als er geen post id is deze error
else
echo '<div class="red">' . $txt['alert_nothing_selected'] . '</div><br/><br/>';
#Gegevens laden
$event_sql = $db->prepare("SELECT `id`, `datum`, `ontvanger_id`, `bericht`, `gelezen` FROM `gebeurtenis` WHERE `ontvanger_id`=:uid and `type` NOT LIKE 'catch' ORDER BY `id` DESC LIMIT 0 , $toegestaan");
$event_sql->bindValue(':uid', $_SESSION['id'], PDO::PARAM_INT);
$event_sql->execute();
#Script laden zodat je nooit pagina buiten de index om kan laden
include("includes/security.php");
?>
<link href="includes/summernote/bootstrap.css" rel="stylesheet">
<link href="includes/summernote/summernote.css" rel="stylesheet">
<script>
$(document).ready(function () {
$('#summernote').summernote({
theme: 'yeti',
lang: "<?=GLOBALDEF_EDITORLANGUAGE?>",
toolbar: [
['style', ['style']],
['font', ['bold', 'italic', 'underline', 'clear']],
['fontname', ['fontname']],
['color', ['color']],
['para', ['ul', 'ol', 'paragraph']],
['height', ['height']],
['table', ['table']],
['insert', ['link', 'picture', 'video', 'hr']],
['view', ['fullscreen']]
]
});
});
</script>
Als je iets niet wil vergeten kan je het in je notepad zetten.<br/><br/>
<form method="post">
<?PHP
$SqlCount = $db->prepare("SELECT id FROM notes WHERE `user_id`=:uid");
$SqlCount->bindValue(':uid', $_SESSION['id'], PDO::PARAM_INT);
$SqlCount->execute();
echo showAlert("green","Je hebt succesvol ".$getProduct['naam']." in je winkel geplaatst.")."<br/><br/>"; refresh(3,"?page=items");
} else {
echo showAlert('red','Geef op of je het item voor gold of silver wil verkopen.').'<br/><br/>';
}
} else {
echo showAlert('red','Geef een prijs op.').'<br/><br/>';
}
}
}
#alle gegevens ophalen voor alle opties
$marktsql = $db->prepare("SELECT `id`, `soort`, `naam`, `silver`, `gold`, `omschrijving_nl` FROM markt ORDER BY soort ASC, id ASC");
$marktsql->execute();
<?
//als er een geen naam in de post zit
if (isset($_GET['player'])) $_POST['username'] = $_GET['player'];
//Pagina nummer opvragen
$subpage = 1;
if (isset($_GET['subpage'])) $subpage = $_GET['subpage'];
//Als er word gezocht op spelernaam
if (isset($_POST['username'])) {
//Max aantal leden per pagina
$max = 50;
$pagina = $subpage * $max - $max;
//Spelernaam schoonmaken, en er een % teken achterzetten voor het zoek systeem
$spelernaam = $_POST['username'];
//Leden tellen
$query = $db->prepare("SELECT `user_id` FROM gebruikers WHERE account_code='1' AND `username`=:playerName");
$query->bindValue(':playerName', $spelernaam);
$query->execute();
$aantal_leden = $query->rowCount();
$aantal_paginas = ceil($aantal_leden / $max);
if ($aantal_paginas == 0) $aantal_paginas = 1;
//Is er wel een speler naam op gegeven, zo ja dan verder
echo '
<table width="660" cellpadding="0" cellspacing="0">
<tr>
<td width="70" class="top_first_td">' . $txt['#'] . '</td>
<td width="180" class="top_td">' . $txt['username'] . '</td>
<td width="110" class="top_td">' . $txt['country'] . '</td>
<td width="180" class="top_td">' . $txt['rank'] . '</td>
<td width="120" class="top_td">' . $txt['status'] . '</td>
</tr>';
//Gegevens laden van het ingetoetste spelernaam
$dbresSQL = $db->prepare("SELECT user_id, username, wereld, online, rank, land, premiumaccount FROM gebruikers WHERE account_code='1' AND `username`=:playerName ORDER BY username LIMIT " . $pagina . ", " . $max);
$dbresSQL->bindValue('playerName', $spelernaam);
$dbresSQL->execute();
//Lijst opbouwen per lid gaat vanzelf
for ($j = $pagina + 1; $gegevens = $dbresSQL->fetch(PDO::FETCH_ASSOC); $j++) {
$strong = '';
$strongg = '';
$star = '';
$plaatje = "images/icons/status_offline.png";
$online = $txt['offline'];
//Kijken als je er zelf tussen zit, dan moet het dik gedrukt zijn.
if ($gegevens['username'] == $_SESSION['naam']) {
//Strong mee geven, moet zo omdat anders de link niet werkt
$strong = "<strong>";
$strongg = "</strong>";
}
$attackquery = $db->query("SELECT naam, sterkte, soort, mis, effect_kans, effect_naam, klaar FROM aanval ORDER BY naam ASC LIMIT ".$pagina.", ".$max."");
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by Mugaru
Didnt i upload a fix for this? If not, i will do it tomorrow.
Verstuurd vanaf mijn SM-G920F met Tapatalk
There is nothing wrong with pokemon info. Make sure that you are working on PHP 5.6
22-10-17
pokegamer
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Please upload files to media fire
22-10-17
The General
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Oh my. The code is such a mess.
23-10-17
Mugaru
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by The General
Oh my. The code is such a mess.
Haha, its the Pokemon Area source... so yea, its a mess..
23-10-17
darkshifty
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by The General
Oh my. The code is such a mess.
It is way better(and getting better) than any Pokemon Area source out there. But hey, thanks for your constructive criticism.
23-10-17
BloodyCode
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
he just saying its better you fix your release source before you share it because other people have no idea how to fix it at all
23-10-17
Mugaru
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by BloodyCode
he just saying its better you fix your release source before you share it because other people have no idea how to fix it at all
I dont agree with that...
Nobody will ever release a complete game for others to make a profit out of it... probably people can help us to make it better, it will help alot instead of only waiting for people to release something thats complete and bugfree.
23-10-17
BloodyCode
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
so you might post in wrong section better put it on developement to someone help you to fix this source and make it better
24-10-17
pokegamer
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
How to config cron jobs?
24-10-17
Mugaru
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
An explanation of this is in de Readme (:
Verstuurd vanaf mijn SM-G920F met Tapatalk
26-10-17
pokegamer
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
How to send activation code?
28-10-17
The General
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff
Quote:
Originally Posted by darkshifty
No one is interested, refrain from commenting if you do not have anything usefull to add please.
Dont be toxic, be constructive.
It was a reply Mugaru but apparently you dont follow your owm rules when it is in your own thread.
28-10-17
pokegamer
Re: [RELEASE] Pokeworld - a major improved Pokémon-SKY spinoff