Weird problem
#1

PHP код:
C:\Users\Mark\Desktop\House.pwn(62) : error 052multi-dimensional arrays must be fully initialized
Pawn compiler 3.2.3664              Copyright 
(c1997-2006ITB CompuPhase
1 Error

On this code:
PHP код:
new Float:HouseInts[HOUSE_INTERIORS][3] = {
    {
244.3520,305.1155,999.1484}, //Ghetto interior number 1
    
{223.4590,1288.3843,1082.1328}, //Ghetto interior number 2
    
{446.7157,507.2780,1001.4195}, //Ghetto interior number 3
    
{1.6971,-2.9713,999.4284}, //Ghetto interior number 4
    
{1520.8916,-48.3468,1002.1310}, //Poor interior number 1
    
{2463.9517,-1698.2009,1013.5078}, //Poor interior number 2
    
{2260.5476,-1136.0232,1050.6328}, //Poor interior number 3
    
{261.1226,1285.5820,1080.2578}, //Poor interior number 4
    
{221.4591,1141.2242,1082.6094}, //Poor interior number 5
    
{-42.5892,1407.2678,1084.4297}, //Poor interior number 6
    
{260.6703,1238.5961,1084.2578}, //Poor interior number 7
    
{318.564971,1118.209960,1083.882812}, //Poor interior number 8
    
{267.6748,305.0058,999.1484}, //Medium interior number 1
    
{2233.7551,-1114.3158,1050.8828}, //Medium interior number 2
    
{226.1468,1240.0355,1082.1406}, //Medium interior number 3
    
{295.1834,1472.9905,1080.2578}, //Medium interior number 4
    
{22.7375,1403.7123,1084.4297}, //Medium interior number 5
    
{-68.5118,1353.4136,1080.2109}, //Medium interior number 6
    
{2496.0500,-1692.9301,1014.7422}, //Medium interior number 7
    
{2194.4177,-1204.3459,1049.0234}, //Rich interior number 1
    
{235.2902,1187.4883,1080.2578}, //Rich interior number 2
    
{447.2202,1397.8140,1084.3047}, //Rich interior number 3
    
{24.2423,1340.8003,1084.3750}, //Rich interior number 4
    
{-262.0742,1456.8008,1084.3672}, //Rich interior number 5
    
{2807.4795,-1172.5560,1025.5703}, //Rich interior number 6
    
{2365.2979,-1132.9210,1050.8750}, //Rich interior number 7
    
{2317.7949,-1025.7349,1050.2109}, //Very Rich interior number 1
    
{227.2880,1114.3633,1080.9980}, //Very Rich interior number 2
    
{140.1100,1367.9536,1083.8623}, //Very Rich interior number 3
    
{234.3993,1064.4279,1084.2112}, //Very Rich interior number 4
    
{83.6514,1323.9059,1083.8594}, //Very Rich interior number 5
    
{520.3837,-9.3049,1001.5653}, // Special interior number 1
    
{300.8854,305.5660,1003.5391}, // Special interior number 2
    
{344.4496,304.8713,999.1484}, // Special interior number 3
    
{-2158.7676,642.5422,1052.3750}, // Special interior number 4
    
{744.1997,1436.9790,1102.7031// Special interior number 5
}; 
PHP код:
#define         HOUSE_INTERIORS         41 
Reply
#2

I think you can do it like this:
pawn Код:
new Float:HouseInts[][3] = { // note first index is empty
/* all stuff here */
};
// and right beneath that you put this
#define HOUSE_INTERIORS sizeof(HouseInts)
Since sizeof is an operator and not a function, it will only slightly affect your compile time, but not the overall performance ingame.
Reply
#3

Try editing this line.

Quote:

new Float:HouseInts[HOUSE_INTERIORS][3] = {

too..
Quote:

new Float:HouseInts[HOUSE_INTERIORS][41] = {

because i am sure the 3 means the amount of positions.

I think :P

Hope this helped
Reply
#4

^ no, three means something else

anywho i found another way to fix it, thanks anyways!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)