Prince Of Persia.net written in C#

Threads about other remakes and ports.
David
The Prince of Persia
The Prince of Persia
Posts: 2848
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: Prince Of Persia.net written in C#

Post by David »

So could you install MonoDevelop and MonoGame?
At what part are you stuck?
Did you try to compile your game?
polipo
Vizier
Vizier
Posts: 89
Joined: September 6th, 2012, 8:34 am

Re: Prince Of Persia.net written in C#

Post by polipo »

yes, i have installed a virtual machine with Ubuntu 10.04.4
after i have installed monodevelop 4.0 and added the Monogame template

Now i could compile it!!!!!

On my virtual machine the PoP.net it's very slow, but i think is a problem on my virtual machine

If you try look on my official repository you can found the linux project and the compiled version!

PS
remenber the linux project NOT CONTAINS the Content file it can be BUILD only by windows..
David
The Prince of Persia
The Prince of Persia
Posts: 2848
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: Prince Of Persia.net written in C#

Post by David »

Right.
Currently I don't have access to a Linux computer, so I can't test it now.
polipo
Vizier
Vizier
Posts: 89
Joined: September 6th, 2012, 8:34 am

Re: Prince Of Persia.net written in C#

Post by polipo »

If someone can test on real linux environment
can send me some feedback ? thanks
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5745
Joined: April 9th, 2009, 10:58 pm

Re: Prince Of Persia.net written in C#

Post by Norbert »

Is compilation under Linux really necessary?
I wrote on August 2nd:
Norbert wrote:polipo, can you provide a download link for just the program, without the ClickOnce or classic MSI setup?
It was my understanding that Mono should be able to run the program that also runs on Windows.
Then again, maybe .NET isn't portable enough, since it was never meant to work on Linux.
polipo
Vizier
Vizier
Posts: 89
Joined: September 6th, 2012, 8:34 am

Re: Prince Of Persia.net written in C#

Post by polipo »

Dear Norber,
i know your idea about .NET but you are wrong.
Mono can compile in varius platform win, linux, android, ios ecc , .NET is portable!

Monogame project haven't realeased yet the possibilty to compile the "Content Project"
actually is the only Linux limitation about porting a monogame prj on Linux environment.

>> "Is compilation under Linux really necessary?" No, if someone already compiled it.

I have already compiled for linux Ubuntu Lucid and Windows, follow this step:
1) https://princeofpersia.codeplex.com/

2) Go in Download and look OTHER Release you can found the binary Windows or Linux

Bye
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5745
Joined: April 9th, 2009, 10:58 pm

Re: Prince Of Persia.net written in C#

Post by Norbert »

polipo wrote:I have already compiled for linux Ubuntu Lucid and Windows, follow this step:
1) https://princeofpersia.codeplex.com/

2) Go in Download and look OTHER Release you can found the binary Windows or Linux
Yes, I can run that under Linux.
Unfortunately, in-game, it only has one frame every 9 (or so) seconds, so it's too slow to play the game.
polipo
Vizier
Vizier
Posts: 89
Joined: September 6th, 2012, 8:34 am

Re: Prince Of Persia.net written in C#

Post by polipo »

Thanks Norbert,
i will check as soon, wait from me some news.
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: Prince Of Persia.net written in C#

Post by salvadorc17 »

Norbert wrote:
Yes, I can run that under Linux.
Unfortunately, in-game, it only has one frame every 9 (or so) seconds, so it's too slow to play the game.

That hapenned to me too, what i should have to do to make project run faster is to change the monogame to xna, but that will not work with linux...
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5745
Joined: April 9th, 2009, 10:58 pm

Re: Prince Of Persia.net written in C#

Post by Norbert »

salvadorc17 wrote:xna, but that will not work with linux...
Are you sure?
Several games at http://en.wikipedia.org/wiki/Microsoft_ ... at_use_XNA are available for Linux.
(Like Bastion and Fez, I own both on Steam.)
Although maybe those games only use XNA under Windows, I dunno.
polipo
Vizier
Vizier
Posts: 89
Joined: September 6th, 2012, 8:34 am

Re: Prince Of Persia.net written in C#

Post by polipo »

Hi to all
First question:

"..change monogame to xna..." for windows is possible BUT is not a solution, with the recent monogame 3.2 it runs perfectly on Windows.
if there are some slow frame on win, please send me some test to do (windows version ecc ecc)
i will investigate if is a PoP engine problem or monogame engine problem.
(remenber XNA is abandoned project from Microsoft ;-()

"...slow frame rate on linux.." it's a mistery i havent a "real" linux machine and effectively is slow, i can have time to install a real
ubuntu for test it.

My test on Android with monogame it runs perfectly the only problem is a slow LOADING content files.

Question :
Have Someone tested PoP.net on WINE / Linux?

Bye
David
The Prince of Persia
The Prince of Persia
Posts: 2848
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: Prince Of Persia.net written in C#

Post by David »

I could start the game on Linux (with Mono).

I don't have the problem that Norbert has, but there are other problems:

- If I start PrinceOfPersia.exe from the file manager, the game closes itself when I press a key to start level 1.
This does not happen if I start it from the command line.

- Loading level 1 takes 15 seconds.
- When the loading ends, I get some errors on the console: (repeated 5 times)

Code: Select all

ERROR:Content.Load<dContentRes>System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary.
  at System.Collections.Generic.Dictionary`2[System.String,System.Object].get_Item (System.String key) [0x00000] in <filename unknown>:0 
  at PrinceOfPersia.Sequence.Initialize (Microsoft.Xna.Framework.Content.ContentManager Content) [0x00000] in <filename unknown>:0 CONFIG_sprite_kidKid_166
But level 1 starts despite those errors.
- There is some unreadable black text at the top of the screen.
According to your screenshots they should be white.
- The game's window is bigger than the room.
Sometimes both right and down, sometimes only down.

- The game crashes when the kid lands after a standing jump.
I get this error: (it is written twice on the console)

Code: Select all

Unhandled Exception:
System.NullReferenceException: Object reference not set to an instance of an object
  at PrinceOfPersia.Frame.PlaySound () [0x00000] in <filename unknown>:0 
  at PrinceOfPersia.AnimationSequence.UpdateFrame (Single elapsed, PrinceOfPersia.Position& position, Microsoft.Xna.Framework.Graphics.SpriteEffects& spriteEffects, PrinceOfPersia.PlayerState& playerState) [0x00000] in <filename unknown>:0 
  at PrinceOfPersia.Player.Update (Microsoft.Xna.Framework.GameTime gameTime, KeyboardState keyboardState, GamePadState gamePadState, TouchCollection touchState, AccelerometerState accelState, DisplayOrientation orientation) [0x00000] in <filename unknown>:0 
  at PrinceOfPersia.PrinceOfPersiaGame.Update (Microsoft.Xna.Framework.GameTime gameTime, Boolean otherScreenHasFocus, Boolean coveredByOtherScreen) [0x00000] in <filename unknown>:0 
  at PrinceOfPersia.ScreenManager.Update (Microsoft.Xna.Framework.GameTime gameTime) [0x00000] in <filename unknown>:0 
  at Microsoft.Xna.Framework.Game.<.cctor>b__19 (IUpdateable updateable, Microsoft.Xna.Framework.GameTime gameTime) [0x00000] in <filename unknown>:0 
  at Microsoft.Xna.Framework.Game+SortingFilteringCollection`1[Microsoft.Xna.Framework.IUpdateable].ForEachFilteredItem[GameTime] (System.Action`2 action, Microsoft.Xna.Framework.GameTime userData) [0x00000] in <filename unknown>:0 
  at Microsoft.Xna.Framework.Game.Update (Microsoft.Xna.Framework.GameTime gameTime) [0x00000] in <filename unknown>:0 
  at Microsoft.Xna.Framework.Game.DoUpdate (Microsoft.Xna.Framework.GameTime gameTime) [0x00000] in <filename unknown>:0 
  at Microsoft.Xna.Framework.Game.Tick () [0x00000] in <filename unknown>:0 
  at Microsoft.Xna.Framework.OpenTKGameWindow.OnUpdateFrame (System.Object sender, OpenTK.FrameEventArgs e) [0x00000] in <filename unknown>:0 
  at (wrapper delegate-invoke) System.EventHandler`1<OpenTK.FrameEventArgs>:invoke_void__this___object_TEventArgs (object,OpenTK.FrameEventArgs)
  at OpenTK.GameWindow.OnUpdateFrame (OpenTK.FrameEventArgs e) [0x00000] in <filename unknown>:0 
  at OpenTK.GameWindow.OnUpdateFrameInternal (OpenTK.FrameEventArgs e) [0x00000] in <filename unknown>:0 
  at OpenTK.GameWindow.RaiseUpdateFrame (System.Diagnostics.Stopwatch update_watch, System.Double& next_update, OpenTK.FrameEventArgs update_args) [0x00000] in <filename unknown>:0 
  at OpenTK.GameWindow.DispatchUpdateAndRenderFrame (System.Object sender, System.EventArgs e) [0x00000] in <filename unknown>:0 
  at OpenTK.GameWindow.Run (Double updates_per_second, Double frames_per_second) [0x00000] in <filename unknown>:0 
  at OpenTK.GameWindow.Run (Double updateRate) [0x00000] in <filename unknown>:0 
  at Microsoft.Xna.Framework.OpenTKGamePlatform.RunLoop () [0x00000] in <filename unknown>:0 
  at Microsoft.Xna.Framework.Game.Run (GameRunBehavior runBehavior) [0x00000] in <filename unknown>:0 
  at Microsoft.Xna.Framework.Game.Run () [0x00000] in <filename unknown>:0 
  at PrinceOfPersia.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0 
- Safe step does works only with the left shift key.
- The cheats don't work if the kid died.
So I can't restart the level.
- The ". = give sword to kid" does not seem to work at all.
It works, but I have to press numpad 5 to draw the sword.
- The kid attacks with the sword only if I press left or right together with shift.
- I can't hurt the guard.
- Can't put the sword away.
- If I press numpad 2/4/6/8 too long, their actions are done twice.
It's possible to move into a wall room, but I can't move out from there. Then the only thing I can do is to restart the level.
- Can't climb up to a different room.
- Can't drink potions.
- Potions have white bubbles.
- The kid does not die if he falls into spikes.
- Can't pick up the sword.
- Can't climb up to a gate that is currently closing.
If kid is already at the gate, he falls down.
- Gates close even if kid is standing on their open button.
- Close buttons are replaced with open buttons.
- The level ends when kid touches the exit door.
- Guards can walk on air. (See the first guard on level 2.)
- Top half of big pillars is replaced with floor.
- Can't step to edge, kid steps *off* the edge instead.
- All guards are blue.
- Gates that should be initially open are closed. (See level 2.)
- Level 3: at the bottom of the first room there are wall pieces.
In the same room, kid appears *in front of* some pillars.
This also happens in the room with the exit door.
- There are no chompers or skeletons.
- Can't go near closed gates from left. (See level 4.)
- Doortops and arches are replaced with floors.
- Loose floors don't press buttons.
- Guards can't press buttons.
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: Prince Of Persia.net written in C#

Post by salvadorc17 »

Norbert wrote:
Are you sure?
Several games at http://en.wikipedia.org/wiki/Microsoft_ ... at_use_XNA are available for Linux.
(Like Bastion and Fez, I own both on Steam.)
Although maybe those games only use XNA under Windows, I dunno.
I think those exceptions was converted to different platform using monogame or something else, but xna is made for windows, and xbox 360...
polipo
Vizier
Vizier
Posts: 89
Joined: September 6th, 2012, 8:34 am

Re: Prince Of Persia.net written in C#

Post by polipo »

Hi David,
whoaaa thanks for your feedback!!!!

Can you use for tracking bugs the ISSUE on CODEPLEX? Can you create a new ISSUE?
https://princeofpersia.codeplex.com/workitem/list/basic

For now i asnwer you:

-> slow loading : fixed CORRECT = previous version loading ALL inused sound/graphics in the content ISNT necessary, TODO: implement % loading on screen

Safe step does works only with the left shift key.
AMF> shift left : to be fixed TODO: no problem

- The cheats don't work if the kid died.
So I can't restart the level.
AMF> i will investigate, but you have press space, kid can restart..

- The ". = give sword to kid" does not seem to work at all.
It works, but I have to press numpad 5 to draw the sword.
AMF> "." : my mistake the sword is 5 keypad the "." is for RESTART

- The kid attacks with the sword only if I press left or right together with shift.
AMF> investigate

- I can't hurt the guard.
AMF> investigate

- Can't put the sword away.
AMF> kid automatically put sword ayay when the guard died or when kid is on a different guard row. Is there a button in the orginal for put away sword?

- If I press numpad 2/4/6/8 too long, their actions are done twice.
It's possible to move into a wall room, but I can't move out from there. Then the only thing I can do is to restart the level.
AMF-> yes i don't love i will fix it as soon

- Can't climb up to a different room.
AMF> ?
- Can't drink potions.
AMF> with shift kid drink
- Potions have white bubbles.
AMF> graphics not implemented
- The kid does not die if he falls into spikes.
AMF> sometime it happens, is a bug i will fix
- Can't pick up the sword.
AMF> press shift key
- Can't climb up to a gate that is currently closing.
If kid is already at the gate, he falls down.
AMF> yes to be implement
- Gates close even if kid is standing on their open button.
AMF> investigate
- Close buttons are replaced with open buttons.
AMF> investigate
- The level ends when kid touches the exit door.
AMF> to be implement anim and sound... have someone the animation of the kid climb up the ladder?
- Guards can walk on air. (See the first guard on level 2.)
AMF> yes guard routine are very simple now can only move left or right and don't understand if there a floor over it TO BE IMPLEMENT
- Top half of big pillars is replaced with floor.
AMF> missed graphics to be implement
- Can't step to edge, kid steps *off* the edge instead.
AMF> investigate
- All guards are blue.
AMF> missed graphics
- Gates that should be initially open are closed. (See level 2.)
AMF> investigate
- Level 3: at the bottom of the first room there are wall pieces.
In the same room, kid appears *in front of* some pillars.
This also happens in the room with the exit door.
- There are no chompers or skeletons.
AMF> yes missed tile and guard type, this version have only one type of guard TODO implement it
- Can't go near closed gates from left. (See level 4.)
AMF> investigate
- Doortops and arches are replaced with floors.
AMF> missed tile graphics
- Loose floors don't press buttons.
AMF> to be implement no problem
- Guards can't press buttons.
AMF>to be implement no problem

VERY THANKS i will fix them as soon
salvadorc17
Calif
Calif
Posts: 553
Joined: August 27th, 2011, 2:04 am

Re: Prince Of Persia.net written in C#

Post by salvadorc17 »

So many bugs David have found, i think some of them are just little mistake, but also hope custom events will added, " like a potion opens the door"
Post Reply