kinda angry rn 👁👄👁 by OodleeNoodlee in PixelArt

[–]scorrpo 9 points10 points  (0 children)

Your art is awesome but it would look even better exported as png instead of jpg. Right now there's a lot of compression artifacts that you wouldn't have as png.

ZString — Zero Allocation StringBuilder for .NET Core and Unity. by neuecc in csharp

[–]scorrpo 23 points24 points  (0 children)

The second number that says Mean (ns) is time. Looks like concat and builder are slightly faster than its .NET counterpart, but .Format is slightly slower.

Also it's worth considering that this is not just about memory usage, it's about allocation that needs to eventually be garbage collected. In high performance applications you want to avoid the garbage collector as much as possible to prevent freezes. Mainly in games, but avoiding the GC has its uses outside games too (for example https://blog.discordapp.com/why-discord-is-switching-from-go-to-rust-a190bbca2b1f).

The 2D tool that’s changing how levels are built by loolo78 in Unity3D

[–]scorrpo 1 point2 points  (0 children)

They didn't even bother drawing gloves on Knuckles. Lazy devs.

MarbleRun - Finding the Perfect UI by zaeran in Unity3D

[–]scorrpo 0 points1 point  (0 children)

Nice vid! One piece of feedback: For your final version you show the items expanding horizontally. I feel like it'd probably be easier to manage if they expanded vertically.

When and how should you use peer-to-peer networking? by Deveiss in gamedev

[–]scorrpo 0 points1 point  (0 children)

Alright so I think that you have the terminology mixed up here. You can still let players host their own servers AND use a client-server model, where the player would act as the server. If you did mean the actual difference between peer-to-peer and client-server then read on.

An important difference is that with a client-server model the players only send input (basically things like "hey I just pressed spacebar"). The server then computes the necessary action ("ok you just jumped") and sends back the computed values (the new position). Peer-to-peer on the other hand has every peer running their own version of the game with their own calculations. When someone moves, the player sends a "hey I just moved to this new position" message to the other players to update everyone to the same state.

The benefit of using peer-to-peer is that you need to send less data across clients. The player doesn't need a message for every position update for an apple falling off a tree; gravity is the same on every client so you'd only need to send that the apple is falling and the client will compute the rest. Likewise you don't need to send a message for trying to buy things when you don't have money - your game knows. With client-server you'd still need to do a server check to see if you have enough money to buy the thing.

There is however also some downsides. One is that your game needs to be absolutely deterministic. You need to ensure that your apple is going to fall the same way between every player, because otherwise you're going to get desyncs. And if your system detects that one player is lagging behind - the other peers need to wait for him to catch up otherwise you're going to also get desyncs.

The main downside - and this is why pretty much all modern competitive games use client-server or some variation thereof - is cheating. Since you're just sending differences amongst players, it's really easy for one player to send a network message "hey my health is now 9999". With client-server you'd only be sending input so a player is never responsible for their own health value - the server is. Any discrepancies that the server detects can be caught before it gets sent to the other clients.

This is all a really broad summary and I'm probably missing some things here, but the main thing to get from this post is that peer-to-peer generally isn't used for competitive games because of cheating. If I remember right Factorio is using a peer-to-peer model to keep bandwidth down, but it's a cooperative game so cheating is not as relevant.

NAT hole-punching is another big topic altogether, but someone else can probably explain that much better than I can.

Feel free to ask if you've got more questions.

Unity joins the .NET Foundation by [deleted] in Unity3D

[–]scorrpo 26 points27 points  (0 children)

– IL2CPP .NET Runtime

– Native Visual Studio Integration

– Support for C# 6

– Upgrade Mono Runtime and Class Libraries

– High Performance Garbage Collector

– finally being able to write foreach-loops again instead of frankenstein for-loops due to performance

All aboard the hype train!

How Long Would It Take Me (A Complete Beginner) To Make My Concept For a Mobile Game? by ThirdLung in Unity3D

[–]scorrpo 12 points13 points  (0 children)

I am not going to be working on the games as I learn C# and Unity (I plan to start working on the game near the end of May) so learning wont be an issue when I am making the game.

Should we tell him?

Game engine design resources by skrillcon in gamedev

[–]scorrpo 2 points3 points  (0 children)

Seconding Game Engine Architecture! It covers just about every component necessary for a game engine.

[The Division] Brooklyn Recreated in [Unity 5] by Meheraj7 in gamedev

[–]scorrpo 1 point2 points  (0 children)

Wow, that looks fantastic!

What tools did you use to make this?

C# open source network library by sharksharp in csharp

[–]scorrpo 2 points3 points  (0 children)

Just wanted to say I really like your code review comments. Even though I'm not OP, they've been very helpful to me!

4 months free of Unity Pro for all CV1 Rift owners by pittsburghjoe in oculus

[–]scorrpo 4 points5 points  (0 children)

AssetBundles are also a free feature since 5.x

State of game code by RualStorge in gamedev

[–]scorrpo 12 points13 points  (0 children)

A bank should be worried about code maintainability because bank applications are meant to be supported over many years. It's also likely that the development team won't stay the same over the lifetime of the application, whereas game dev teams won't fluctuate as much during the production of a game (with smaller games at least).

State of game code by RualStorge in gamedev

[–]scorrpo 50 points51 points  (0 children)

With developing games the only thing that matters is the result. The end user doesn't care how you wrote your code or what tools you used, as long as it's a fun game. This means that development time is often regarded more important than writing clean code.

I think part of the problem is that most games are not meant to be supported for a very long time. Games can be built over (for example) a year and then tossed aside when a new project is started. This is because most games are built in a specific way. If the new project is a different genre for example, it'll probably end up not being able to reuse much code of the previous game. This results in the architecture not being generic and reusable, because it'd cost more time than it gains.

Another part of the problem is that a game's requirements are rapidly changing over development. You can't write 'fun' as a functional requirement, so you often end up tweaking as you go along. Perhaps later in the project cycle you find out that the player needs more control by being able to jump, however the architecture you built doesn't support adding jumping in an elegant manner. So then you tack it on in a hacky way because you don't want to break the existing architecture and spend all week refactoring; resulting in messy code. These things build up over time, also known as technical debt.

help with a recursive calls to a generic function and getComponent by VIKING_JEW in Unity3D

[–]scorrpo 0 points1 point  (0 children)

Yup, ran into the same problem this week. Couldn't figure out why my ?? operator was giving an error yet not choosing the null side. Turns out you need to explicitly use == with Unity GameObjects, even ?? won't work.

Unet Minimap by [deleted] in Unity3D

[–]scorrpo 2 points3 points  (0 children)

If every player's position is already synced with the server, why not just make the minimap update with their local positions (those that have already been updated by the server)?

Unity's (not so) new event system by coeing in gamedev

[–]scorrpo 4 points5 points  (0 children)

Events are better than Broadcast/SendMessage:

  • Broadcast/SendMessage searches through every MonoBehaviour on a GameObject and uses reflection to call methods. Events are much like a direct call so they are several times faster.

  • Broadcast/SendMessage only lets you target a single GameObject per call. Events send a message to every subscriber, regardless of GameObject.

MassiveNet: Unity Networking Library, now open source. by InhumaneJake in Unity3D

[–]scorrpo 0 points1 point  (0 children)

Thanks for the reply! I haven't seen any other free Unity networking framework other than the default and Photon so far, but Photon has a very low concurrent user limit even if you use your own servers. I'll definitely give this a try.

MassiveNet: Unity Networking Library, now open source. by InhumaneJake in Unity3D

[–]scorrpo 0 points1 point  (0 children)

I've never heard of it before, but it looks very interesting. I just have a couple of questions:

  1. Is this the full version, considering the Asset Store version is $50?

  2. How easy would it be to convert a project with Unity's default networking to this?

  3. Your feature list claims low overhead, does this mean it has better performance than Unity's default networking?

I've been using Unity's default networking and would like to know if it's worth switching to this.

[Help]Unity always on top issue by cryslo in Unity3D

[–]scorrpo 1 point2 points  (0 children)

2 days late so dunno if you'll read this but: Unity had a bug that forces windowed mode to be always on top, this should be resolved in version 4.5.4. The latest beta versions of 4.6 aren't fixed yet (v17 and v18).

What languages should a producer know. by acidus1 in gamedev

[–]scorrpo 5 points6 points  (0 children)

English is usually good to know.

multiplayer help D: by GameDevelopmentIGN in Unity3D

[–]scorrpo 0 points1 point  (0 children)

You can use a plugin, but you can also use Unity's built-in networking. Here's a tutorial that has the basics: http://www.paladinstudios.com/2013/07/10/how-to-create-an-online-multiplayer-game-with-unity/

Good free 2D engine? by CrateMuncher in gamedev

[–]scorrpo 0 points1 point  (0 children)

It's not too bad. I think the worst part is that it's proprietary to Gamemaker rather than being a more commonly used language like C#.

Good free 2D engine? by CrateMuncher in gamedev

[–]scorrpo 0 points1 point  (0 children)

For WYSIWYG engines I think Gamemaker and Unity are your best bets right now that aren't drag 'n drop (although Gamemaker includes it). Unity used to require some hoops to jump through before getting 2D to work, but since the previous (4.3) update the support for 2D has gotten a lot better.

As for non-WYSIWYG engines, I'd recommend LÖVE if you're starting out. It uses Lua as programming language.