Jump to content
tipforeveryone

Publish game problem

Recommended Posts

I publish my game as Standalone version with "Only include used files" checked

When I double click mygame.exe, a window appears and suddenly disappear without any error warning, I guess my game are lacking of some files but I don't know which one

Then I publish with "Only include used files" unchecked and my game run properly but with a huge size package

I suppose it is fine with included used files but it is not.

btw, is there any way to point out which file my game lacks.

Thanks :D

Share this post


Link to post

You can create a bat file to launch your game and read the printed output, like this:

mygame.exe
pause

You have the coolest user name on Leadwerks.com BTW. Every time I see it I think "Yay, everyone gets tips!"

Share this post


Link to post

That does not make any sense. The program should print out a few lines of text at least.

Share this post


Link to post
27 minutes ago, Josh said:

That does not make any sense. The program should print out a few lines of text at least.

Maybe I put a wrong content for the .bat file, here is my published project.

can you help me to point out which lacked files, I don't want to pack every unused files for the game to run. I have plenty of them in my project folder and they are about 4 GB

https://www.dropbox.com/s/xj1knh7z5x8b2sd/CSCDVMP.zip?dl=0

Share this post


Link to post

I don't understand what is going on here...it won't even print out a single line...

Share this post


Link to post

I am running it in the debugger now and may have found something...

  • Like 1

Share this post


Link to post

cscdvmp.exe > output.txt

Lua Error: [string "/Scripts/Custom Scripts/Menu/MenuFunctions.lua"]:69: attempt to index a nil value

 

Share this post


Link to post
Just now, Jazz said:

cscdvmp.exe > output.txt

Lua Error: [string "/Scripts/Custom Scripts/Menu/MenuFunctions.lua"]:69: attempt to index a nil value

Woww. show me how can I get this ? :D

Share this post


Link to post
Just now, tipforeveryone said:

Woww. show me how can I get this ? :D

Put that command in your .bat file. It will output it in output.txt

  • Like 1
  • Thanks 1

Share this post


Link to post

@Jazz Thank you for show me this

@Josh

I found out a problem, there are some missing folders in published game, see image below.
There is something to be worked on "Only include used file" option when publishing game

Leadwerks only include files which are used in existed map, not in code

example, "Menu" folder contain all textures which I use Texture:Load() for and they are not included in.

image.png.eab7f3333c7bb63a18a972e5eed59a3f.png

Share this post


Link to post

I thank that is the way Leadwerks works. Or at least in the sense that Leadwerks doesn't scan your code to see what kind of files you load. For compiled C++ that would also be pretty difficult to do. It only exports files that are loaded/referenced in the editor

Share this post


Link to post

So that "Only include USED files" option is kind of questionable and somehow... useless because there are not many entities / models / materials / textures are used in the Editor

Share this post


Link to post

I remember a blog post when this option was introduced. I asked the question what would happen with entities loaded by code. The answer was something like "These are not included". But that blog was more than 1 or 2 years ago so things might have changed.

Share this post


Link to post
1 hour ago, AggrorJorn said:

I remember a blog post when this option was introduced. I asked the question what would happen with entities loaded by code. The answer was something like "These are not included". But that blog was more than 1 or 2 years ago so things might have changed.

This one?

 

  • Like 1

Share this post


Link to post

The editor DOES scan your Lua and CPP code files to look for any files that might be needed. However, if your name is created programmatically, like "MyFile" + ".tex" then there is no way to include it.

  • Like 1
  • Thanks 1

Share this post


Link to post
46 minutes ago, Josh said:

The editor DOES scan your Lua and CPP code files to look for any files that might be needed. However, if your name is created programmatically, like "MyFile" + ".tex" then there is no way to include it.

Thanks for pointing this out. I have a plenty of code like this. "something" .. self.variable .. ".tex" :) this is not a bug finally. you should put this as a Note (with red color) in the Publish window. I think

Share this post


Link to post

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...