Physion

  • Increase font size
  • Default font size
  • Decrease font size
Welcome, Guest
Username Password: Remember me

Version 1.2.0 Released ...
(1 viewing) (1) Guest
  • Page:
  • 1

TOPIC: Version 1.2.0 Released ...

Version 1.2.0 Released ... 1 year, 9 months ago #928

  • Lynxx
  • OFFLINE
  • Gold Boarder
  • Java/C#-Developer
  • Posts: 223
Nice to see your still doing something for the project.
But there are a lot of bugs in it, some scripts not working:
zzz_mousefilter
ObjectList Dock

Debugger says QApplication.keyboardModifiers() is no function, tried the direct access queryKeyboardModifiers() aswell, didn't work too.

Writing to disc causes problems, for example all SoundTools i did are not working, for example QFile.size() cant be called.

Tetris not working, tiles dont fall down.
Labyrinth not working, exit of level isnt recocnized.

Tried some other complex scenes which i did, most of them wont work.

I checked the documentation for qt 5.5, none of the functions is deprecated.

Up/Downloading Scenes doesnt work, all old scenes are missing??
I wanted to download an old scene of mine ( django.physion.net/assets/scenes/Lynxx/%...Arkanoidhysion.scene ) which file is missing locally, but it seems their all gone??? :-/
Infinity is vast, especially near end.
bye, Lynxx

Re: Version 1.2.0 Released ... 1 year, 9 months ago #929

  • Dimitris
  • OFFLINE
  • Administrator
  • Posts: 218
Hi Lynxx,

Yeah, it's been a while since Physion was last updated...

You are right. Some of the scripts fail to function correctly and this is mainly due to the changes introduced in Qt5. More specifically:

QApplication should be replaced by QGuiApplication. By doing that, both zzz_mousefilter.script and ObjectListDock.script are working properly.

I haven't tried the sound toolbar but I suspect that something similar is going on. The same goes for any scene that is using old (Qt4) scripting calls.


Up/Downloading Scenes: This feature has been temporarily disabled. At some point I will try to move physion.net to Wordpress. In doing so, I will also try to implement a better system for the user submitted scenes (rating, bigger screenshots, descriptions and comments).


As you may have noticed, the new Physion installer supports the idea of packages. Currently there are 4 packages in the installer:
- The root package (i.e. the main Physion application)
- The textures package
- The scripts package and
- The scenes package

The 4 packages listed above are fetched directly from the physion.net repository. The good thing with the new install system is that you can fetch packages from different repositories which live in different domains.


If you're interested in creating and managing your own repos (in rawhi.de for example) which would then be selectable packages in Physion installer, let me know.

An example of these repos could be:
- Lynxx's Scenes
- Lynxx's Scripts
Last Edit: 1 year, 9 months ago by Dimitris.

Re: Version 1.2.0 Released ... 1 year, 9 months ago #931

  • Lynxx
  • OFFLINE
  • Gold Boarder
  • Java/C#-Developer
  • Posts: 223
Damn, this Qt-Guys never care about backward-compability which really sucks.
I still remember the ugly fix for V1.01:
// physicsItemForGraphicsItem was replaced against physicsItemFromGraphicsItem in V1.01 world.physicsItemForGraphicsItem=world.physicsItemForGraphicsItem?world.physicsItemForGraphicsItem:world.physicsItemFromGraphicsItem;


Atleast the Keyboard/Mouse-Issues could be fixed with this script:
function debug(t){ 	app.debug(QTime.currentTime() + " " + t); }
if (app.applicationVersion=="1.2.0") {
debug("Physionfix V1.20 by Holger 'Lynxx' Hippenstiel initialized.");
QApplication.keyboardModifiers=QGuiApplication.keyboardModifiers;
QApplication.mouseButtons=QGuiApplication.mouseButtons;
}

But on other things i dont know how to fix them, for example QFile.size(), it should be there but it isnt .. :-/
On other bugs i tried looking at the script debugger, but as the editor for big files in AdvancedSoundConvert Toolbar isnt working anymore i had to use the standard editor, but after 2-3 uses or ~30s Physion crashes with the error:
"This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information." :-//

Scene-Rating and downloading scenes sorted by Rating sounds great.

Own repos, mhh .. nice to be able to "auto-install" scripts, but what about updates?
Seems i got a lot of fixing to do.
Infinity is vast, especially near end.
bye, Lynxx

Re: Version 1.2.0 Released ... 1 year, 9 months ago #932

  • Dimitris
  • OFFLINE
  • Administrator
  • Posts: 218
Some of the QFile methods work (e.g. QFile.exists()) but some others don't (e.g. QFile.size()). Really strange indeed...

A work-around for getting the size of a file is to use the QFileInfo class:

 
var fileInfo = new QFileInfo("test.txt");
var size = fileInfo.size();
 


Tetris Scene: Running the Tetris scene, the debugger outputs the following message:

ReferenceError: Can't find variable: count


And the corresponding code is:

 
control.onUpdate = function() {
count++;
if (count%speed==0) {
if (shouldplay && !snd_tetris.isplaying) {
snd_tetris.start();
}
playGame();
} }
 


This should be handled as follows:

 
if(this.counter == null)
this.counter = 0;
this.counter++;
 
...
 
 


I don't know why this used to work in the previous version...

As for your own repos, here are the typical steps:
  • You create your own packages (e.g. "Lynxx's Scripts") as described here: doc.qt.io/qtinstallerframework/ifw-creating-installers.html)
  • Your packages have their own version number which is independent of Physion's version number.
  • You create a repository (based on your packages) and you upload that repo to your server.
  • I add your repo URL to the Physion installer so that when the Physion installer runs it lists your packages as available options (selected by default)
  • If you then decide to update your script for example, you do that and you simply increase the version number. The installer will do the rest.


Have a look at the maintenancetool in Physion's installation directory to see how it works.
Last Edit: 1 year, 9 months ago by Dimitris.

Re: Version 1.2.0 Released ... 1 year, 9 months ago #934

  • Lynxx
  • OFFLINE
  • Gold Boarder
  • Java/C#-Developer
  • Posts: 223
Dimitris wrote:
A work-around for getting the size of a file is to use the QFileInfo class:

 
var fileInfo = new QFileInfo("test.txt");
var size = fileInfo.size();
 



To bad it always returns 0, try:
app.debug("Size: "+new QFileInfo("C:\Windows\explorer.exe").size());

else this could be fixed with:
QFile.prototype.size = function() { return new QFileInfo(this.fileName()).size(); }

(and QFile.fileName() also reports function not defined ...)


Dimitris wrote:

...
This should be handled as follows:

 
if(this.counter == null)
this.counter = 0;
this.counter++;
 
...
 
 


I don't know why this used to work in the previous version...

Well, i just was lazy there and used the normal javascript-behaviour, which creates a var if wasnt defined before.

Dimitris wrote:

As for your own repos, here are the typical steps:
  • You create your own packages (e.g. "Lynxx's Scripts") as described here: doc.qt.io/qtinstallerframework/ifw-creating-installers.html)
  • Your packages have their own version number which is independent of Physion's version number.
  • You create a repository (based on your packages) and you upload that repo to your server.
  • I add your repo URL to the Physion installer so that when the Physion installer runs it lists your packages as available options (selected by default)
  • If you then decide to update your script for example, you do that and you simply increase the version number. The installer will do the rest.


Have a look at the maintenancetool in Physion's installation directory to see how it works.

Will have a look at that .. well, i even looked at replacing the prototype of QFile and so to add the missing functionality, but since every other method didn't work as well im done with it, it's not my job to fix missing functionality. In V1.01 it was only one line, but this is ridiculous.
You have my ok to do Installer-packages of my scripts/scenes, i wont do it.
Infinity is vast, especially near end.
bye, Lynxx
Last Edit: 1 year, 9 months ago by Lynxx.
  • Page:
  • 1
Time to create page: 0.19 seconds