Jump to content
MakeWebGames

Installed Improved Crimes from Chris Dayo


Karma

Recommended Posts

I can't create crimes. I have followed the instructions to add the Improved Crimes to my game and this is what I get when I try to access it. This is on the main game area, not the admin, however on the admin...

File: /home/cosanostramafia/public_html/modules/installed/crimes/crimes.inc.php
Line: 14
Error: Uncaught PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'mafia.crimes' doesn't exist in /home/cosanostramafia/public_html/modules/installed/crimes/crimes.inc.php:14 Stack trace: #0 /home/cosanostramafia/public_html/modules/installed/crimes/crimes.inc.php(14): PDOStatement->execute() #1 /home/cosanostramafia/public_html/class/module.php(30): crimes->constructModule() #2 /home/cosanostramafia/public_html/class/page.php(107): module->__construct() #3 /home/cosanostramafia/public_html/class/page.php(50): page->load('crimes') #4 /home/cosanostramafia/public_html/init.php(76): page->loadPage('crimes') #5 /home/cosanostramafia/public_html/index.php(5): require('/home/cosanostr...') #6 {main} thrown
Type: E_RECOVERABLE_ERROR

When i go to click on to create crimes... in the Game Mechanics  I get this.

File: /home/cosanostramafia/public_html/modules/installed/crimes/crimes.admin.php
Line: 28
Error: Uncaught PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'mafia.crimes' doesn't exist in /home/cosanostramafia/public_html/modules/installed/crimes/crimes.admin.php:28 Stack trace: #0 /home/cosanostramafia/public_html/modules/installed/crimes/crimes.admin.php(28): PDOStatement->execute() #1 /home/cosanostramafia/public_html/modules/installed/crimes/crimes.admin.php(165): adminModule->getCrime() #2 /home/cosanostramafia/public_html/modules/installed/admin/admin.inc.php(96): adminModule->method_view() #3 /home/cosanostramafia/public_html/modules/installed/admin/admin.inc.php(30): admin->viewModule() #4 /home/cosanostramafia/public_html/class/module.php(30): admin->constructModule() #5 /home/cosanostramafia/public_html/class/page.php(107): module->__construct() #6 /home/cosanostramafia/public_html/class/page.php(50): page->load('admin') #7 /home/cosanostramafia/public_html/init.php(76): page->loadPage('admin') #8 /home/cosanostramafia/public_html/index.php(5): require('/home/cosanostr...'
Type: E_RECOVERABLE_ERROR

I am hoping Urban or Chris to answer and correct this problem for me.

Thank you.

Link to comment
Share on other sites

 

37 minutes ago, Karma said:

So, how do I get it back? LOL

Note: This walkthrough is based on the freely-available Gangster-Legends-V2 repo. I do not have access to a paid copy.

Log into your database. If memory serves, you've previously stated you're hosting with MWG; so you'll be able to do this via your cPanel by clicking on phpMyAdmin and selecting your database.
Once you're on your database, click on the SQL tab.
If you've got this far, you're prepared to restore the table.

Copy lines 9 - 20 of install/schema.sql
From

CREATE TABLE IF NOT EXISTS `crimes` (

all the way to

) DEFAULT CHARSET=utf8;

Paste it into the SQL tab you opened up a moment ago, then click on .. either "Run" or "Go" (I can't quite remember which verb is used).
If it successfully ran, that's your table restored.

Now, if you want the default crimes that come with GLv2:
Copy lines 11 - 13 of install/data.sql and paste that into the SQL tab too

Link to comment
Share on other sites

29 minutes ago, Magictallguy said:

 

Note: This walkthrough is based on the freely-available Gangster-Legends-V2 repo. I do not have access to a paid copy.

Log into your database. If memory serves, you've previously stated you're hosting with MWG; so you'll be able to do this via your cPanel by clicking on phpMyAdmin and selecting your database.
Once you're on your database, click on the SQL tab.
If you've got this far, you're prepared to restore the table.

Copy lines 9 - 20 of install/schema.sql
From

CREATE TABLE IF NOT EXISTS `crimes` (


CREATE TABLE IF NOT EXISTS `crimes` (

all the way to

) DEFAULT CHARSET=utf8;


) DEFAULT CHARSET=utf8;

Paste it into the SQL tab you opened up a moment ago, then click on .. either "Run" or "Go" (I can't quite remember which verb is used).
If it successfully ran, that's your table restored.

Now, if you want the default crimes that come with GLv2:
Copy lines 11 - 13 of install/data.sql and paste that into the SQL tab too

actually i'm not... i wanted too but i wasn't unable to get an account soo... its my own serveer..

Link to comment
Share on other sites

4 minutes ago, Karma said:

actually i'm not... i wanted too but i wasn't unable to get an account soo... its my own serveer..

Welp, my mistake!
Does your server have some form of control panel? If so, and if it's cPanel, the directions above stand.
If it's Plesk, then you'll need to visit the domain, click on Databases in the top right menu, then phpMyAdmin. The "how to navigate phpMyAdmin" part still stands here too.

If it's something else (or nothing), let me know and I'll see if I can provide a walk-through for ya - if not, someone else probably can

Link to comment
Share on other sites

1 minute ago, Magictallguy said:

Welp, my mistake!
Does your server have some form of control panel? If so, and if it's cPanel, the directions above stand.
If it's Plesk, then you'll need to visit the domain, click on Databases in the top right menu, then phpMyAdmin. The "how to navigate phpMyAdmin" part still stands here too.

If it's something else (or nothing), let me know and I'll see if I can provide a walk-through for ya - if not, someone else probably can

I think Urban might be helping me with this. he has access to my Cpanel. 🙂 I do thank you guys for helping though, much appreciated

and boys it has been fixed. Thank you for the suggestions, hope you all have a merry Christmas.

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...