Search Issue Tracker
Duplicate
Votes
1
Found in
5.3.2f1
Issue ID
766643
Regression
No
Resources.Load returns null when loading same game object in another scene on standalone player
Steps to reproduce:
1. Open attached project
2. Open Build settings
3. Build for windows standalone with Developement build and Script debugging enabled
4 Press Play! button. Then standalone player will load Bug scene. Bug scene calls Resources.Load<GameObject>("Chobie").
5. Press PRESS button. This will load Bug2 scene asynchronously. Bug2 scene also calls Resources.Load<GameObject>("Chobie") but this will fail (notice exceptions in console)
Note: Everything works as expected in editor.
Reproduced with: 5.3.2f1, 5.3.2p1, 5.4.0b4
Comments (1)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Console shows Exception: {"error":"not found","detail":["not found"]} after opening Build History window
- [HDRP] Volumetric cloud shadows disappear when there is no directional light shadows
- “Selector” column names in the Search window are lowercase when added
- Install List Project Counter Panel can be right clicked through and Install Context Menu can be opened disabling Project Counter Panel's buttons
- [MacOS] Scene is marked/flickering as dirty (with asterisk) when dragging a Material on a GameObject in Scene view
jordenson
Feb 02, 2016 07:22
Just out of interest, have you tried basic file access with 5.3.2f1, 5.3.2p1? I found file stream failed to read altogether with this latest version. Even something basic like File.ReadAllBytes(file_name) failed to load the data correctly. Previous versions the loading code was fine, but particles were broken... Some test code if curious (works fine in Editor, fails on 64bit iOS device):
void Update () {
string file_name = string.Format("{0}{1}test.txt", Application.persistentDataPath, Path.DirectorySeparatorChar);
if (counter == 0)
{
Debug.Log( "Writing file " + file_name );
byte[] data = new byte[10];
data[0] = 23;
Debug.Log( data[0] );
File.WriteAllBytes( file_name, data );
Debug.Log( "Writing file done" );
counter++;
}
else if (counter == 1)
{
Debug.Log( "Reading file " + file_name );
Debug.Log( File.Exists( file_name ) ? "File exists" : "File does not exist" );
byte[] readData = File.ReadAllBytes( file_name );
Debug.Log( readData[0] );
Debug.Log( "Reading file done" );
counter++;
}
}