[SOLVED] How to debug the extDB version of custom loudout addon?

I've implemented the extDB version of supporter addon according to CRE4MPIE's mission. However, it doesn't work. My loudouts will not change after I respawn.

Here's the commit I did:

https://github.com/Jermin/ArmA3_Wasteland.Altis/commit/e9c417786d8d8f79da996ce22f94b6709ad3e98b

The sql statement I used to add the SupporterLevel column is:

Code: [Select]
alter table PlayerInfo add column SupporterLevel tinyint unsigned default 0;
  • Offline CREAMPIE
  • Armaholic
  • Veteran
  • ******
  • Posts: 1081
  • ^_^;;

Re: How to debug the extDB version of custom loudout addon?

« Reply #1 posted: Jul 11, 2015, 12:56 PM »
I've implemented the extDB version of supporter addon according to CRE4MPIE's mission. However, it doesn't work. My loudouts will not change after I respawn.

Here's the commit I did:

https://github.com/Jermin/ArmA3_Wasteland.Altis/commit/e9c417786d8d8f79da996ce22f94b6709ad3e98b

The sql statement I used to add the SupporterLevel column is:

Code: [Select]
alter table PlayerInfo add column SupporterLevel tinyint unsigned default 0;

you coulda just asked me ;)

Did you add the supportLevel column in the database and using the amended a3wasteland.ini for the extDB calls?

- from the grassy knoll -

Re: How to debug the extDB version of custom loudout addon?

« Reply #2 posted: Jul 11, 2015, 01:01 PM »
Yes for both questions.
  • Offline CREAMPIE
  • Armaholic
  • Veteran
  • ******
  • Posts: 1081
  • ^_^;;

Re: How to debug the extDB version of custom loudout addon?

« Reply #3 posted: Jul 11, 2015, 03:54 PM »
Yes for both questions.

there's a few other places you need to add stuff in for supporters if you're using my GIT ...

https://github.com/CRE4MPIE/ArmA3_Wasteland_1.1e.Stratis/search?utf8=%E2%9C%93&q=supporter


- from the grassy knoll -

Re: How to debug the extDB version of custom loudout addon?

« Reply #4 posted: Jul 11, 2015, 05:05 PM »
I've checked them carefully.

Most of the edits that are not in my commit are used to raise initial money and disable survival system for supporters, which I don't want to implemented, at least not at the moment. I want to limit the custom loadouts to only cosmetic improvements for now.

The only two omittings that may have caused the bug are in spawnInTown.sqf and spawnOnBeacon.sqf

However, you just private variable _supporterLevel in these 2 files. There aren't any codes using it. So I don't think they are the cause.

Is there a way to check the value of _supporterLevel for a specific player while in the server?
  • Offline CREAMPIE
  • Armaholic
  • Veteran
  • ******
  • Posts: 1081
  • ^_^;;

Re: How to debug the extDB version of custom loudout addon?

« Reply #5 posted: Jul 11, 2015, 07:27 PM »
I've checked them carefully.

Most of the edits that are not in my commit are used to raise initial money and disable survival system for supporters, which I don't want to implemented, at least not at the moment. I want to limit the custom loadouts to only cosmetic improvements for now.

The only two omittings that may have caused the bug are in spawnInTown.sqf and spawnOnBeacon.sqf

However, you just private variable _supporterLevel in these 2 files. There aren't any codes using it. So I don't think they are the cause.

Is there a way to check the value of _supporterLevel for a specific player while in the server?

Yes ! You can check if a player has the supporterlevel set from the DB while running the missions. Change in DB , drop to lobby and come back in to see if it's changed.

log into the server as admin and run this on the console, it will return the supporterlevel value that's present in the database.

Code: [Select]
hint format["%1", player getVariable ["supporter", 0]];

- from the grassy knoll -

Re: How to debug the extDB version of custom loudout addon?

« Reply #6 posted: Jul 11, 2015, 07:55 PM »
The correct command is

Code: [Select]
hint format["%1", player getVariable ["SupporterLevel", 0]];

It's zero. But I can promise that the value in the DB is 5. I even tested with the statement in a3wasteland.ini. So it should be caused by the codes I added in a3wasteland.ini, which are created based on the BankMoney code block above them?
  • Offline CREAMPIE
  • Armaholic
  • Veteran
  • ******
  • Posts: 1081
  • ^_^;;

Re: How to debug the extDB version of custom loudout addon?

« Reply #7 posted: Jul 11, 2015, 09:07 PM »
The correct command is

Code: [Select]
hint format["%1", player getVariable ["SupporterLevel", 0]];

It's zero. But I can promise that the value in the DB is 5. I even tested with the statement in a3wasteland.ini. So it should be caused by the codes I added in a3wasteland.ini, which are created based on the BankMoney code block above them?


You added the custom SQL in the a3wasteland.ini ? Just have to double check

- from the grassy knoll -

Re: How to debug the extDB version of custom loudout addon?

« Reply #8 posted: Jul 11, 2015, 09:14 PM »
Yes. My server is using sql_custom_v2. So I didn't use your code directly. Instead, I created mine based on the BankMoney code in the sql_custom_v2 file.
  • Offline CREAMPIE
  • Armaholic
  • Veteran
  • ******
  • Posts: 1081
  • ^_^;;

Re: How to debug the extDB version of custom loudout addon?

« Reply #9 posted: Jul 12, 2015, 10:04 AM »
Yes. My server is using sql_custom_v2. So I didn't use your code directly. Instead, I created mine based on the BankMoney code in the sql_custom_v2 file.

last question - did you update your main_config.sqf to include the supporter stuff ?

Code: [Select]
A3W_supportersEnabled = 1; // Enable/Disable Supporter Features
https://github.com/CRE4MPIE/A3Wasteland_Settings/blob/master/main_config.sqf#L22

- from the grassy knoll -

Re: How to debug the extDB version of custom loudout addon?

« Reply #10 posted: Jul 12, 2015, 11:17 AM »
Problem solved!

https://github.com/Jermin/ArmA3_Wasteland.Altis/commit/764575701c390fa7e5323b7cbbde428fb91765a7

It's the capital letter. I don't know why it works for your mission but not mine. I guess it is because my server is run on Linux?