These are chat archives for ikkentim/SampSharp

24th
Feb 2017
Florian van Dillen
@fvandillen
Feb 24 2017 07:24
It really is quite good :)
And really fast. Depending on server performance, I can choose what data is loaded into RAM when the server starts up and what not. Saves a lot of querying and data.
Tim Potze
@ikkentim
Feb 24 2017 09:44
@fvandillen ohhhhhhh
@fvandillen hang on, i remember this
I'll publish a quick hotfix
Tim Potze
@ikkentim
Feb 24 2017 09:50
Wow, never pushed a full release for the streamer plugin aparently
It's building now, so fix should be available in a bit
Florian van Dillen
@fvandillen
Feb 24 2017 10:14
lol
I thought I was going mad
Tim Potze
@ikkentim
Feb 24 2017 10:14
I even made an issue for it a long while ago
Florian van Dillen
@fvandillen
Feb 24 2017 10:14
Oh and for future reference (maybe handy for in the docs):
By default, vector3 isn't recognised by Nhibernate
You can make custom component maps (the same way as a classmap) for vector3
Tim Potze
@ikkentim
Feb 24 2017 10:15
If I had two weeks of time each week I'd have giant docs by now
Florian van Dillen
@fvandillen
Feb 24 2017 10:15
And by doing so, Nhibernate will be able to map the properties of Vector3 to your database
Tim Potze
@ikkentim
Feb 24 2017 10:16
using FluentNHibernate.Mapping;
using SampSharp.GameMode;

namespace SampSharp.NHibernate
{
    public class Vector3ComponentMap : ComponentMap<Vector3>
    {
        public Vector3ComponentMap()
        {
            Map(v => v.X);
            Map(v => v.Y);
            Map(v => v.Z);
        }
    }
}
Florian van Dillen
@fvandillen
Feb 24 2017 10:16
Yup, that's it
Tim Potze
@ikkentim
Feb 24 2017 10:16
^^
Florian van Dillen
@fvandillen
Feb 24 2017 10:16
You built that into the framework?
Maybe I should load your component mappings in my FluentNhibernate configuration then :)
Tim Potze
@ikkentim
Feb 24 2017 10:17
Nah into my own SampSharp.NHibernate, I once wanted to create a simple utility library for fluent nhibernate
something for another day
using FluentNHibernate.Mapping;
using SampSharp.GameMode.SAMP;

namespace SampSharp.NHibernate
{
    public class ColorComponentMap : ComponentMap<Color>
    {
        public ColorComponentMap()
        {
            Map(c => c.R);
            Map(c => c.G);
            Map(c => c.B);
            Map(c => c.A);
        }
    }
}

using FluentNHibernate.Mapping;
using SampSharp.GameMode;

namespace SampSharp.NHibernate
{
    public class Vector2ComponentMap : ComponentMap<Vector2>
    {
        public Vector2ComponentMap()
        {
            Map(v => v.X);
            Map(v => v.Y);
        }
    }
}
That's basically all that's in there
Florian van Dillen
@fvandillen
Feb 24 2017 10:19
Oh so it isn't in the framework?
Tim Potze
@ikkentim
Feb 24 2017 10:19
nope
maybe one day it'll be a package
Florian van Dillen
@fvandillen
Feb 24 2017 10:19
Ahh, well I built them myself so that's settled :smile:
Tim Potze
@ikkentim
Feb 24 2017 10:19
Here's another snippet
Yup, 2015, that's the last time I worked on my gamemode :/
Florian van Dillen
@fvandillen
Feb 24 2017 10:20
Got spring break next week
So hoping to be finally able to push a beta release of my gamemode
Your object fix is just in time for that :)
Fully dynamic and ingame mapping system
Billboards, houses, vehicles, groups
Everything is in place currently
Tim Potze
@ikkentim
Feb 24 2017 10:20
Nice :)
I once build a mapping system in pawn
loong time ago
written without testing and it worked after just a few bug fixed, yay!
Florian van Dillen
@fvandillen
Feb 24 2017 10:21
It took me under an hour to build the code
Tim Potze
@ikkentim
Feb 24 2017 10:21
nice
Florian van Dillen
@fvandillen
Feb 24 2017 10:21
With collections it's REALLY easy to build it in C#
Tim Potze
@ikkentim
Feb 24 2017 10:21
it took me me 10k lines of code
yea :P
Florian van Dillen
@fvandillen
Feb 24 2017 10:21
I have Maps and MapObjects
Maps have a collection called objects
And methods to spawn/despawn
Samp is perfect for OOP however people keep using pawn
Florian van Dillen
@fvandillen
Feb 24 2017 10:40
@ikkentim What was the actual bug with editting objects?
Tim Potze
@ikkentim
Feb 24 2017 10:41
It called EditPlayerObject instead of EditDynamicObject :|
Florian van Dillen
@fvandillen
Feb 24 2017 10:41
lol
Tim Potze
@ikkentim
Feb 24 2017 10:41
Sorry for your waste of time
Florian van Dillen
@fvandillen
Feb 24 2017 10:41
Lol no worries, everything thus far works
You only wasted like 45 minutes
So thats about EUR5,50 worth of my time xD
you owe me two beers
Tim Potze
@ikkentim
Feb 24 2017 10:42
You owe me more
Florian van Dillen
@fvandillen
Feb 24 2017 10:42
Since you created the frameworks, that calls it even
Tim Potze
@ikkentim
Feb 24 2017 10:42
;)
Florian van Dillen
@fvandillen
Feb 24 2017 10:42
ol
Yes
Tim Potze
@ikkentim
Feb 24 2017 10:42
#185 thinks everything is broken
if I decrypted his messages right
Florian van Dillen
@fvandillen
Feb 24 2017 10:42
lemme see
Tim Potze
@ikkentim
Feb 24 2017 10:42
It's only the 6th cryptic issue he opened
Florian van Dillen
@fvandillen
Feb 24 2017 10:43
I'm quite sure that if his coding abilities are anywhere near his level of english, that's the cause of his crash
Tim Potze
@ikkentim
Feb 24 2017 10:43
yea
First question he asked was about c#, so ...
Florian van Dillen
@fvandillen
Feb 24 2017 10:44
Disclaimer: I didn't know any C# when I started with SampSharp
Tim Potze
@ikkentim
Feb 24 2017 10:44
And now he thinks sampsharp is causing a crash when you "taran gate in zona 51 where airport on vehicle model 495"
I never decrypted taran
Yea it's you in the last comment
Florian van Dillen
@fvandillen
Feb 24 2017 10:46
if(taran.GetGates().Where(g => g.zona == '51' && g.Airport == true).FirstOrDefault().VehicleModel == 495) return CrashServer(true);
Only thing I could come up with :D
Tim Potze
@ikkentim
Feb 24 2017 10:47
¯_(ツ)_/¯
¯\_(ツ)_/¯
gitter can't handle shruggies :(
Florian van Dillen
@fvandillen
Feb 24 2017 10:47
lel
Tim Potze
@ikkentim
Feb 24 2017 10:47
I still feel like moving to Slack
Slack is so much better
Florian van Dillen
@fvandillen
Feb 24 2017 10:48
Love slack
Oh meant to ask you
Did you ever use log4net?
Tim Potze
@ikkentim
Feb 24 2017 10:48
Maybe I'll just do it
not yet
Florian van Dillen
@fvandillen
Feb 24 2017 10:48
Specifically: log4net with a slack appender?
Tim Potze
@ikkentim
Feb 24 2017 10:48
planned to use it but never done it
Florian van Dillen
@fvandillen
Feb 24 2017 10:48
I am using it (it's epic)
however, the slack appender doesn't work, doesn't send any messages to my channel
Which irritates me :smile:
Tim Potze
@ikkentim
Feb 24 2017 10:49
I'm working on a big project, but ended up writing something custom there
Which does post to slack :)
(and other locations)
#logs and #emergency (for high priority messages)
Florian van Dillen
@fvandillen
Feb 24 2017 10:49
Yup, I just need to hook slack into Log.Error
[21:44:17] INFO  trinityRPG.GameMode - ** trinityRPG build 6261 starting up..
[21:44:22] INFO  trinityRPG.Groups.Core - Loading groups..
[21:44:22] INFO  trinityRPG.Groups.Core - Loaded 1 groups.
[21:44:22] INFO  trinityRPG.World.DWATS - World clock started. It is now midnight (00:00).
[21:44:22] INFO  trinityRPG.Vehicles.VehicleController - Loading vehicles..
[21:44:22] INFO  trinityRPG.Vehicles.VehicleController - Loaded 0 vehicles.
[21:44:22] INFO  trinityRPG.GameMode - ** Startup complete!
[21:49:37] INFO  trinityRPG.Player - Loading account data for =AV=Marcel(0).
[21:49:37] INFO  trinityRPG.Accounts.LoginRegisterController - Player =AV=Marcel(0) connected from IP 82.217.212.242 with GPCI D8EEE8D9989D9C8F40EED09C5C0FDC4CD45CEE94
[21:49:38] INFO  trinityRPG.Accounts.LoginRegisterController -  - Account password: test
[21:49:38] INFO  trinityRPG.Accounts.LoginRegisterController - Successful authentication for =AV=Marcel(0).
[21:57:18] INFO  trinityRPG.Player - Saving account data for =AV=Marcel(0).
[21:57:18] INFO  trinityRPG.Accounts.LoginRegisterController - Logged-in player =AV=Marcel(0) disconnected. Saved data as ID 1.
[22:27:52] INFO  trinityRPG.Player - Loading account data for =AV=Marcel(0).
[22:27:52] INFO  trinityRPG.Accounts.LoginRegisterController - Player =AV=Marcel(0) connected from IP 82.217.212.242 with GPCI D8EEE8D9989D9C8F40EED09C5C0FDC4CD45CEE94
[22:27:54] INFO  trinityRPG.Accounts.LoginRegisterController -  - Account password: test
[22:27:54] INFO  trinityRPG.Accounts.LoginRegisterController - Successful authentication for =AV=Marcel(0).
[22:28:34] INFO  trinityRPG.Player - Loading account data for khm(1).
[22:28:34] INFO  trinityRPG.Accounts.LoginRegisterController - Player khm(1) connected from IP 41.225.195.165 with GPCI E9E9DDE88C995EAEA944F4CF0AC89989AF40EDDC
[22:35:01] INFO  trinityRPG.Player - Saving account data for khm(1).
[22:35:01] INFO  trinityRPG.Accounts.LoginRegisterController - Logged-in player khm(1) disconnected. Saved data as ID 2.
[22:35:06] INFO  trinityRPG.Player - Saving account data for =AV=Marcel(0).
[22:35:06] INFO  trinityRPG.Accounts.LoginRegisterController - Logged-in player =AV=Marcel(0) disconnected. Saved data as ID 1.
this is log4net in my gamemode
Tim Potze
@ikkentim
Feb 24 2017 10:51
I think I'll move to Slack this evening or tomorrow, will tell ofc when I do
nice
Florian van Dillen
@fvandillen
Feb 24 2017 10:51
love the class references
Always know what's up
Tim Potze
@ikkentim
Feb 24 2017 10:52
Totally irrelated but awesome: terrain generation, whoop! https://puu.sh/uhEHU/5b61153c2e.jpg
I love my job, haha
Florian van Dillen
@fvandillen
Feb 24 2017 10:53
That your coaster game?
Looks slick
Tim Potze
@ikkentim
Feb 24 2017 10:53
yea the game I'm working on
but it's not mine :P
I did write the terrain generation tho
Florian van Dillen
@fvandillen
Feb 24 2017 10:54
Nice man
Oleg
@5LICK
Feb 24 2017 11:01
:)
I never decrypted taran - I think this is translates to - "bump into gate"
taran it is russian word
Tim Potze
@ikkentim
Feb 24 2017 11:01
ah
ty
Tim Potze
@ikkentim
Feb 24 2017 11:16
https://sampsharp.herokuapp.com/ << to join the SampSharp slack group
Will put it in the samp topic and repo readme later
Florian van Dillen
@fvandillen
Feb 24 2017 11:17
Will join after the company lunch!
Michael Kilpatrick
@NewbProgramming
Feb 24 2017 11:51
What's the difference between Slack, Discord, and Gitter?
Tim Potze
@ikkentim
Feb 24 2017 11:51
Discord is made for gamers
Gitter for programming, but TBH the client is a little meh/crappy
Michael Kilpatrick
@NewbProgramming
Feb 24 2017 11:51
They all accomplish the same thing though :P