Time for a report...
1) Rifles and crossbows can coexist, the trick is to follow the same naming conventions for rifles as for crossbows (in the example below, I had the rifle named w_crsbH100):


The bad news is that both types will obviously use the same ammo. It's not really visible during the combat animations, but even if you create a specific item for bullets, the slot will in fact take precedence (so the crossbow could use bullets and the rifle fire bolts...)

2) The "out of ammo" message is definitely a hard-coded issue: in the baseitems.2da file, at the line defining the sling, I just changed the number 27 (referring to the sling ammo) to 206 (the new ammo type I created). Everything else remained unchanged, but I got the "out of ammo" message as soon as I tried to attack with the sling (although all ammo slots were filled).

3) The workaround I used is to use charges (one charge = one bullet), automatically reload when putting the ammo in the ammo slot (i.e. add the same number of charges as there are bullets in the ammo box if the quantity is less than the maximum capacity of the clip, or deduct from the ammo box the number of bullets used to refill the clip to the maximum number of charges of the rifle).
Thanks to Lance Botelle's trick, I was able to use animations specially done for the new weapons, without the "use item / cast spray" part!

The annoying part is that you can't attack by clicking on the target: you'll have to right-click on the rifle, activate the item (long range), and select the target:

Additionally, you won't see the damage done (the red number floating above the target), but this can be fixed in the console window:

(the pic above was taken BEFORE I made the changes to nwn2_animstan.2da).
4) So I finally decided to create a ranged weapon without ammo as far as NWN2 engine is concerned (thus getting rid of the missing damage information, of the right-click / activate / select target sequence, of the risk of breaking spell casting due to animstan modifications). More importantly, it would also give the NPC / creatures the ability to use the rifle too!

Through scripting, I was able to add the ammo requirement and the projectile path effect:
- easy for the NPC and monsters, through the end of combat turn script.
- easy too for the PC, but not as synchronized, as I tried with the module hearbeat.

(see the quantity indicated in the first item in the inventory? Decreased from 15 to 14 after a shot was fired).