Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - ai_enabled

Pages: [1] 2 3 ... 63
1
Bug reports / Re: Error in multiplayer horribly
« on: February 11, 2018, 10:24:36 pm »
It's not possible to create a random item generation mod similar to Diablo 2.
Regarding localization of DLC - it was discussed there http://steamcommunity.com/app/324260/discussions/0/133258593406618170/#c133258593407269390

2
Bug reports / Re: Error in multiplayer horribly
« on: February 09, 2018, 01:08:40 pm »
Hello!

Thanks for reporting!
We've got a few reports of this issue and were able to reproduce it in some cases.
Surprisingly, the game doesn't work very well with some VPN connections. If the players who experienced this issue are using VPN, please ask them to disconnect from VPN and try to connect directly to the game server.

Another source of the issue could be your localization mod. Please try to remove it from ModsConfig.xml for your server and restart it. If that helps, you can upload your mod and post the link - we will check it and tell you how to resolve this issue for your mod.

We're planning to release the patch for VoidExpanse later this month, but I'm very unsure if we will be able to resolve this issue as it's really hard to reproduce.

Regards!

3
I think the error is quite different from what we had with the asteroids.
This error message appears if you're asking Scripting API to perform some action on a ship and the provided ship ID is 0. You can try to isolate some parts of your scripts to find the line which leads to this error message.
If you're unable to locate it, I will be able to look into the source of this issue when our vacation is over (we're going to a Lunar New Year holidays for the next ~1.5 weeks).

Regards!

4
Development discussion / Re: CryoFall - new screenshots & news
« on: February 07, 2018, 12:49:54 am »
I'm happy too as we didn't find any serious bugs and overall the game is rock stable.
Bottom line is - the game is kickass, prepare to throw us your money within 30 days or maybe even less! ;D
Though, we are planning to release the game completely for free during this initial period!

5
Help section / Re: Is there a IMCache.GetValue and IMCache.SetValue?
« on: February 05, 2018, 12:27:13 pm »
IMCache is done on purpose in such way to build the "ship stats cache".

The cache re-calculation is expensive should not happen too often (ideally it should happen only once for every NPC ship - on spawn or savegame reload).

Basically, it's the "stats" parameters of the ship which are populated with by the scripts (with AddValue and MulValue methods) and then combined with other caches (such as weapons/equipment cache) and finalized. You should never use it in any other cases. I'm not even sure if you can override/extend it and use in other scripts (I mean it could break the code from CalculateShip.js).

Alas, VE was made in a big rush years ago (with 99% of these scripts written by a member of the team who left even before the release) and now it's all legacy code and incomplete documentation...

6
>> It's a tiny lag spike just when the AI's pathfind activates

Does it happen for every new drone AI or just a single time? Sounds like a script loading/compilation lag, in that case you can't do much.

7
atan2 is the way we're usually using to get the angle between two vectors.
Actually, atan2 call is a little bit slower than sqrt on modern CPUs.
Anyway, it's not something to worry about until you really perceive the issue with the performance.

Regards!

8
Hi nine,

There are two functions to calculate the dot product between two 2D vectors A and B:
Code: [Select]
// first approach uses vector lengths and so requires expensive sqrt calculation
var dot = a.Length * b.Length * Math.Cos(angle); // it also uses angle between A and B vectors

// second approach is much simpler
var dot = a.X * b.X + a.Y * b.Y;

So you can simply use the second approach to calculate the dot product.
If you need to get the angle between them, you can use this function:
Code: [Select]
var angle = Math.Acos(dot / (a.Length * b.Length));

Regards!

UPD. Oops, I was wrong :-), corrected the post.
So you actually need vector lengths (and so sqrt) to calculate the angle between vectors with the dot product (IF the dot product alone is not enough for your case).
I think this is a premature optimization. Even thousands of sqrt calculations per second are not that slow on modern CPUs. Don't optimize until you actually can feel that it's too slow.

9
Bug reports / Re: Too many Heap sections crash!
« on: December 27, 2017, 09:26:11 am »
Great to hear!
I'm afraid you will be unable to release it yet as it might require some API improvements which are available only in the server preview build I've sent to you. Better to check with the vanilla server build from Steam Client.

Regards!

10
Bug reports / Re: Too many Heap sections crash!
« on: December 26, 2017, 07:05:13 am »
Hi,
This is just the client crash (server detected the client is not running anymore and also stopped).
I'm quite sure this is just a memory leak at the NVorbis plugin we're using for music decoding/streaming. Will check for the next VE patch. With the last patch we didn't check the game stability after many hours in idle and nobody reported this issue before (most players run it just for a few hours max).
Thanks for reporting!

Regards!

11
You're right, the prices are modified (and their statuses too). The price for cargo is calculated by SetResourceBasePrice method at Station.js. This is implemented this way to adjust prices randomly with 10% deviation. Yeah, that's really overcomplicated. Each station generates items/cargo for sale and calls this method for each of them to calculate the price, then this price is stored on server, but players receive another price which is calculated by CalculateBuyPriceOfCargo and CalculateSellPriceOfCargo (or same methods for items).
The only solution will be to implement new API methods for getting the final price of item/cargo by providing player's ship ID and station ID.

12
I verified the C# code and can definitely say that it calling Station.js file, methods CalculateBuyPriceOfCargo and CalculateSellPriceOfCargo, to calculate the prices. Have you tried to add the console logging to these two methods?
The game calculates the prices for a player during docking, when the items are added/removed from the shop items list (such as during stock items regeneration) and when a player tries to buy/sell to calculate the current price.

"args.cargo_price" is the price of cargo/resource from the XML file.
It seems there is no API for getting the price by cargo/resource XML ID so you're stuck with this for now, alas.

13
Hi,

The price is adjusted for every player as you think. It's not clear from the scripting as this code is called from C#.
Here are methods which we're calling:
Station.js - CalculateBuyPriceOfItemModifi er and CalculateSellPriceOfItemModif ier - for calculation of item price.
Station.js - CalculateBuyPriceOfCargo and CalculateSellPriceOfCargo - for calculation of cargo price.

Unfortunately, these methods require quite a complex argument structure. For items:
Code: [Select]
int base_id;
int faction_relation; // this is a pre-calculated relation between the player's ship and the station faction
int item_id;
int ship_id;

For cargo it's more complicated:
Code: [Select]

[code]
string base_faction; // station faction ID
int base_id; // station ID
string cargo_id; // XML ID of the cargo
double cargo_price; // base price of cargo (from XML, I'm very unsure if this can be get from scripting API now - we might need an update to the game server for this API)
int faction_relation; // relation between the player's ship and the station faction
string ship_faction; // player ship faction ID
int ship_id; // player ship
int status; // cargo status

Alas, it's really complicated. Maybe a better approach would be to implement new scripting API methods accepting ship ID, station ID and item ID or cargo XML ID and returning the calculated price (by reusing the C# code).

Regards!

14
Modding info / Re: Problem with script
« on: October 29, 2017, 10:09:01 pm »
@Teerawut, ok, post it here and we will try to help!

15
Development discussion / Re: CryoFall - Visual effects research (VFX)
« on: September 05, 2017, 04:14:11 am »
Tchey, we too, honestly.
Most of the post-effects we want to implement will improve the visual feedback of the game. When you receive serious damage or accumulating radiation it will be much more obvious than the simple status effects icons in the corner of the screen, and much more immersive too.
Most of these effects will be configurable (by the way, we recently finished the options system and menu, adding new options is very easy).
Though, some of the post effects will be forced (such as color grading for day-night cycle; I think everyone will agree it's not really good when the (vanilla) game allows to "turn of the night" in the options). But still, the modders are free to customize the existing post effects and even implement their own (yes, everything is implemented in the scriptable part of the game, including shaders code!). So we can expect a lot of crazy stuff and customization for every kind of player.
Regards!

Pages: [1] 2 3 ... 63