These are chat archives for ikkentim/SampSharp

24th
Jan 2017
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 00:19

@ikkentim You were right, animations for TextDraws is a terrible idea.

Console.WriteLine("It took {0} milliseconds to render the Textdraws.", (DateTime.Now - start).Milliseconds);

Took 18 milliseconds PER CALL, to render 2 TextDraws across the screen.

Michael Kilpatrick
@NewbProgramming
Jan 24 2017 01:27
Okay I made an update and now it takes 2 milliseconds to render the textdraws, this is starting to look more plausible :D
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 01:32
blob
Creating the TextDraws = 19 ms, moving them across the screen, decrements.
Tim Potze
@ikkentim
Jan 24 2017 09:47
I wasn’t speaking about the delays in the calls, more that if you have a slightly raised ping it looks horrible
Oleg
@5LICK
Jan 24 2017 09:59
@ikkentim thanks for explanation about identified pool's
Oleg
@5LICK
Jan 24 2017 16:02
I tried use SampShap Native Invoke for FCNPC plugin on the Linux, and when bot is connected to the server, i think i get same error which in the issue #174 . (This happens with NPC too.. Also i will check it on Windows later)
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 16:46
@5LICK
FCNPC works on Windows :D Made a class wrapper for it, that's how I know.
Diego Cea López
@dcealopez
Jan 24 2017 17:22
I guess I will develop on Windows for now. For some reason the plugin seems to be broken on Linux (using CentOS 7 here), some events don't even get fired such as OnPlayerSpawn and other methods such as SendClientMessage send the player an empty string. It's really weird, don't know what could be the cause of all of this. I hope this gets resolved because this project is great.
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 17:46
@dcealopez
You could use the older version of SampSharp, all versions previous versions are available, the last build did work on Linux (Ubuntu32) :)
Oleg
@5LICK
Jan 24 2017 17:58
@NewbProgramming Yes, i checked FCNPC on the windows and all works fine :)
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 17:58
@5LICK
Windows > Linux :D
Oleg
@5LICK
Jan 24 2017 17:59
@dcealopez I develop for Windows too, and now all works good
@NewbProgramming :)
Oleg
@5LICK
Jan 24 2017 18:13
@dcealopez i checked OnPlayerSpawn, this works for me
Diego Cea López
@dcealopez
Jan 24 2017 18:20
@NewbProgramming Which version specifically? This one? 0.7.6221.37952, from 12 days ago.
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 18:20
Diego Cea López
@dcealopez
Jan 24 2017 18:21
Alright, thank you. I will try that one.
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 18:21
Let me find the old .so for you
and then in the NuGet package manager, there's a drop down menu you can choose the version for.
Diego Cea López
@dcealopez
Jan 24 2017 18:56
The problem persists. I will try to compile that version myself and see if that fixes it.
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 19:04
:+1:
Oleg
@5LICK
Jan 24 2017 19:35
I already tried few versions, and few linux distributives, and different compilers and platforms, but same problem on spawn.
Diego Cea López
@dcealopez
Jan 24 2017 19:38
Yeah. Still having the same problem even if compiling the plugin myself.
Guess I will develop for Windows now until it gets fixed.
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 19:58
Probably best just to use Windows :P
Tim Potze
@ikkentim
Jan 24 2017 19:58
i will try to fix it
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 19:59
If you want a cheap Windows VPS to host your server on, I've never had a problem with EpicHosts.co.uk, the owner also lets you use Skype for support and responds within 24 hours.
blob
blob
Oleg
@5LICK
Jan 24 2017 20:20
@NewbProgramming you tried to use FCNP_GoTo function?
@NewbProgramming when i use this function, FCNPC plugin falls
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 20:54

// Var
INative FCNPC_GoTo = null;

// Somewhere to pre-load natives. (I use BaseMode)
if(Native.Exists("FCNPC_GoTo") == true) {
FCNPC_GoTo = Native.Load("FCNPC_GoTo", typeof(int), typeof(float), typeof(float), typeof(float), typeof(int), typeof(float), typeof(bool));
}

// When you want to call the native.
if(FCNPC_GoTo != null)
{
FCNPC_GoTo.Invoke(npcId, posX, posY, posZ, MOVE_TYPE, speedFloat, false);
}

There we go, that's how it's done.
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 20:59
If you want to use MapAndreas, set the last param to true.
But you also have to use MapAndreas lol.
Oleg
@5LICK
Jan 24 2017 21:39
My code is same
But npc doesn't walk
Michael Kilpatrick
@NewbProgramming
Jan 24 2017 21:53
Alright, I am driving around town for family members, I will pop on later and figure this out for you :)
Might just send you my class wrapper.
Oleg
@5LICK
Jan 24 2017 22:06
At would be good to look on class
I think i have some mistake in my code
Oleg
@5LICK
Jan 24 2017 22:29
hmm
I tested FCNPC 1.6.1 on clear game mode (without SampSharp), and NPCs do not go too :)