Guild icon
DDraceNetwork
Development / developer
Development discussion. Logged to https://ddnet.tw/irclogs/ Connected with DDNet's IRC channel, Matrix room and GitHub repositories — IRC: #ddnet on Quakenet | Matrix: #ddnet-developer:matrix.org GitHub: https://github.com/ddnet
Between 2021-07-09 00:00:00Z and 2021-07-10 00:00:00Z
Avatar
it's already in ddnet client
Avatar
yeah I guess not many people know about it
Avatar
you need a quad with an envelope assigned and enable Info
00:57
ah and I think you can't move the first and last points or so, so add some in the envelope
00:59
wait its so buggy tho
🐛 2
Avatar
Add info next to the player's nickname where I can see I have a strong or weak hook to him
Avatar
Avatar
CovER
Add info next to the player's nickname where I can see I have a strong or weak hook to him
off by default, cl_nameplates_strong 1 to enable also shown in debug mode (ctrl-shift-d) Checklist Tested the change ingame Provided screenshots if it is a visual change Tested in combination...
poggers 2
Avatar
this a lots numbers!
Avatar
To the rustaceans:impl From<&str> for Error { fn from(msg: &str) -> Error { Error(msg.to_owned()) } } impl From<String> for Error { fn from(msg: String) -> Error { Error(msg) } }Can I shorten this?
11:20
To the rustaceans:pub struct Error(String); impl From<&str> for Error { fn from(msg: &str) -> Error { Error(msg.to_owned()) } } impl From<String> for Error { fn from(msg: String) -> Error { Error(msg) } }Can I shorten this?
11:21
I want to be able to create errors from static strings and from strings built for example with format!
11:22
In a function that returns Result<(), Error> I want to be able to write return Err("message".into())
11:24
Oh, and I can't really use Result<(), String> because I need to distinguish between different Error types, e.g. module1::Error
Avatar
Cow<str, 'static> ?
11:49
Cow<'static, str> *
11:51
ups
11:51
use std::borrow::Cow; pub struct Error(Cow<'static, str>); impl From<&'static str> for Error { fn from(msg: &'static str) -> Error { Error(Cow::Borrowed(msg)) } } impl From<String> for Error { fn from(msg: String) -> Error { Error(Cow::Owned(msg)) } } fn lol() -> Result<(), Error> { Err("my error".into()) } fn lol2() -> Result<(), Error> { Err(String::from("hello").into()) } fn main() {}
11:52
@timakro i would do it like this i guess
11:52
greenthing
Avatar
Avatar
timakro
To the rustaceans:pub struct Error(String); impl From<&str> for Error { fn from(msg: &str) -> Error { Error(msg.to_owned()) } } impl From<String> for Error { fn from(msg: String) -> Error { Error(msg) } }Can I shorten this?
impl<T: Into<String>> From<T> for Error { fn from(msg: T) -> Error { Error(msg.into()) } } Not quite sure if the compiler is smart enough to optimize this but it should work
Avatar
Avatar
Learath2
impl<T: Into<String>> From<T> for Error { fn from(msg: T) -> Error { Error(msg.into()) } } Not quite sure if the compiler is smart enough to optimize this but it should work
13:27
ups
13:27
actually i think mine is better
13:28
i just gotta figure out hwo to share
13:28
this
Avatar
Ofc a cow will have better performance, he asked for shorter 😄
troll 1
13:28
monkalaugh
13:28
oh shorten
13:28
but i think its better to use cow
13:30
i fixed the functions
Avatar
@Kaffeine the problem is likely that the server doesn't support the extended serverinfo protocol, but just the old fstd protocol
Avatar
imagine have ability to abort vote as vote starter
Avatar
holy shit
19:57
that HAS to be an issue already
Avatar
didn't find any heh
Avatar
lol this is great 😄
Avatar
chillerdragon BOT 2021-07-09 21:43:19Z
Stack over trolls
troll 1
🇼 1
🇭 1
🇴 1
Avatar
Greetings! Today I'm happy to announce a new era in Tor implementation. Over the past year or so, we've been working on "Arti", a project to rewrite Tor in Rust. Thanks to funding from Zcash Open Major Grants (ZOMG), we can finally put the Arti project up in our priorities list, and devote more time to it. Below I'll talk about why we're doing t...
Exported 45 message(s)